com.electrotank.electroserver5.client.api
Class EsCreateRoomRequest

java.lang.Object
  extended by com.electrotank.electroserver5.client.events.Event<EsMessageType>
      extended by com.electrotank.electroserver5.client.api.helper.EsMessage
          extended by com.electrotank.electroserver5.client.api.helper.EsRequest
              extended by com.electrotank.electroserver5.client.api.EsCreateRoomRequest
All Implemented Interfaces:
ThriftSerializable

public class EsCreateRoomRequest
extends EsRequest

This class represents a highly flexible server request. With it you can create a room, join that room if it already exists, set properties on that room (if it is being created), and set your own subscription properties for that room/zone.

Things to know about creating and joining rooms:


When joining a room there are many events that you are automatically subscribed to, unless you opt out.

Subscription properties when joining a room (all of the following default to true): Shows the most simple example of how to create a new room with all default properties.
package  {
        import com.electrotank.electroserver5.api.CreateRoomRequest;
        import com.electrotank.electroserver5.api.JoinRoomEvent;
        import com.electrotank.electroserver5.api.MessageType;
        import com.electrotank.electroserver5.ElectroServer;
        import com.electrotank.electroserver5.user.User;
        import com.electrotank.electroserver5.zone.Room;
        import flash.events.Event;

        public class RoomJoiner {

                private var _es:ElectroServer;

                public function initialize():void {
                        //listen for the JoinRoomEvent so we know when it happens
                        _es.engine.addEventListener(MessageType.JoinRoomEvent.name, onJoinRoomEvent);

                        //create the request and populate it with the room details
                        var crr:CreateRoomRequest = new CreateRoomRequest();
                        crr.roomName = "MyRoom";
                        crr.zoneName = "MyZone";

                        //send it
                        _es.engine.send(crr);
                }

                private function onJoinRoomEvent(e:JoinRoomEvent):void {
                        trace("room joined!");

                        //get the room you're in
                        var room:Room = _es.managerHelper.zoneManager.zoneById(e.zoneId).roomById(e.roomId);

                        //print out the users in the room
                        for each (var user:User in room.users) {
                                trace(user.userName);
                        }
                }

                public function set es(value:ElectroServer):void {
                        _es = value;
                }

        }

}
    
Here is a thorough example that uses room variables, changes room proprties, applies join subscriptions, and uses plugins.
package  {
        import com.electrotank.electroserver5.api.CreateRoomRequest;
        import com.electrotank.electroserver5.api.EsObject;
        import com.electrotank.electroserver5.api.JoinRoomEvent;
        import com.electrotank.electroserver5.api.MessageType;
        import com.electrotank.electroserver5.api.PluginListEntry;
        import com.electrotank.electroserver5.api.RoomVariable;
        import com.electrotank.electroserver5.ElectroServer;
        import com.electrotank.electroserver5.user.User;
        import com.electrotank.electroserver5.zone.Room;
        import flash.events.Event;

        public class RoomJoiner {

                private var _es:ElectroServer;

                public function initialize():void {
                        //listen for the JoinRoomEvent so we know when it happens
                        _es.engine.addEventListener(MessageType.JoinRoomEvent.name, onJoinRoomEvent);

                        var crr:CreateRoomRequest = new CreateRoomRequest();
                        crr.roomName = "MyRoom";
                        crr.zoneName = "MyZone";

                        //Set a few properties
                        crr.capacity = 10;
                        crr.roomDescription = "This is my room";
                        crr.password = "open sesame";

                        //create two room variables
                        //room var 1
                        var ob1:EsObject = new EsObject();
                        ob1.setString("Test_String", "blah");
                        ob1.setInteger("Test_int", 3);

                        var rv1:RoomVariable = new RoomVariable();
                        rv1.name = "test1";
                        rv1.value = ob1;
                        rv1.locked = true;
                        rv1.persistent = false;

                        //room var 2
                        var ob2:EsObject = new EsObject();
                        ob1.setString("Test_String2", "blah2");
                        ob1.setInteger("Test_int2", 12);

                        var rv2:RoomVariable = new RoomVariable();
                        rv2.name = "test2";
                        rv2.value = ob2;
                        rv2.locked = false;
                        rv2.persistent = false;

                        //add the room variables to the request
                        crr.variables = [rv1, rv2];

                        //Create a new plugin for this room
                        var pl:PluginListEntry = new PluginListEntry();
                        pl.extensionName = "ExamplePluginExtension";
                        pl.pluginHandle = "ExamplePlugin";
                        pl.pluginName = "ExamplePlugin";

                        //add the plugin to the request
                        crr.plugins = [pl];

                        //Now configure some of the user's subscription properties
                        crr.receivingRoomAttributeUpdates = false;//Don't want to receive updates about other rooms
                        crr.receivingRoomListUpdates = false;//Don't want to receive updates about when other rooms are created or destroyed
                        crr.receivingUserListUpdates = true;//true is the default. When true you will receive user list updates for your room.

                        //send it
                        _es.engine.send(crr);
                }

                private function onJoinRoomEvent(e:JoinRoomEvent):void {
                        trace("room joined!");

                        //get the room you're in
                        var room:Room = _es.managerHelper.zoneManager.zoneById(e.zoneId).roomById(e.roomId);

                        //print out the users in the room
                        for each (var user:User in room.users) {
                                trace(user.userName);
                        }
                }

                public function set es(value:ElectroServer):void {
                        _es = value;
                }

        }

}    


Constructor Summary
EsCreateRoomRequest()
           
EsCreateRoomRequest(org.apache.thrift.TBase t)
           
 
Method Summary
 void fromThrift(org.apache.thrift.TBase t_)
           
 int getCapacity()
          A room can be given a maximum number of users allowed in it at once.
 int getFloodingFilterBanDuration()
          This property is used if a custom flooding filter has been specified.
 int getFloodingFilterFailuresBeforeKick()
          This property is used if a custom flooding filter has been specified.
 int getFloodingFilterKicksBeforeBan()
          This property is used if a custom flooding filter has been specified.
 String getFloodingFilterName()
          The name of the custom flooding filter to use.
 int getLanguageFilterBanDuration()
          This is used with a custom language filter.
 int getLanguageFilterFailuresBeforeKick()
          This is used only with a custom language filter.
 int getLanguageFilterKicksBeforeBan()
          This is used with a custom language filter.
 String getLanguageFilterName()
          Custom language filters can be defined and given a name through the web-based administrator.
 String getPassword()
          This is optional.
 List<EsPluginListEntry> getPlugins()
          A list of PluginListEntry objects that represent the plugins that need to be created with this room.
 String getRoomDescription()
          This is an optional public room-level property.
 String getRoomName()
          Sets the name of the new room.
 List<EsRoomVariable> getVariables()
          A list of RoomVariables to be used in the new room that is being created.
 int getZoneId()
          The id of the zone in which you want to create the room.
 String getZoneName()
          The name of the zone in which to create the new room.
 boolean isCreateOrJoinRoom()
          The default is true.
 boolean isFloodingFilterResetAfterKick()
          If using a custom flooding filter then this property is used.
 boolean isFloodingFilterSpecified()
          You must set to true if a custom flooding filter name has been specified.
 boolean isHidden()
          The default is false.
 boolean isLanguageFilterDeliverMessageOnFailure()
          This is used only if a custom language filter is being used.
 boolean isLanguageFilterResetAfterKick()
          This is used if a custom language filter has been specified.
 boolean isLanguageFilterSpecified()
          If a custom language filter was specified by name using languageFilterName, then this property must be manually flagged to true.
 boolean isNonOperatorUpdateAllowed()
           
 boolean isNonOperatorVariableUpdateAllowed()
           
 boolean isPersistent()
          The default is false.
 boolean isReceivingRoomAttributeUpdates()
          The default is true.
 boolean isReceivingRoomListUpdates()
          The default is true.
 boolean isReceivingRoomVariableUpdates()
          The default is true.
 boolean isReceivingUserListUpdates()
          The default is true.
 boolean isReceivingUserVariableUpdates()
          The default is true.
 boolean isReceivingVideoEvents()
          Default is true.
 boolean isUsingFloodingFilter()
          The default if false.
 boolean isUsingLanguageFilter()
          The default is false.
 com.electrotank.electroserver5.thrift.ThriftCreateRoomRequest newThrift()
           
 void setCapacity(int v)
          A room can be given a maximum number of users allowed in it at once.
 void setCreateOrJoinRoom(boolean v)
          The default is true.
 void setFloodingFilterBanDuration(int v)
          This property is used if a custom flooding filter has been specified.
 void setFloodingFilterFailuresBeforeKick(int v)
          This property is used if a custom flooding filter has been specified.
 void setFloodingFilterKicksBeforeBan(int v)
          This property is used if a custom flooding filter has been specified.
 void setFloodingFilterName(String v)
          The name of the custom flooding filter to use.
 void setFloodingFilterResetAfterKick(boolean v)
          If using a custom flooding filter then this property is used.
 void setFloodingFilterSpecified(boolean v)
          You must set to true if a custom flooding filter name has been specified.
 void setHidden(boolean v)
          The default is false.
 void setLanguageFilterBanDuration(int v)
          This is used with a custom language filter.
 void setLanguageFilterDeliverMessageOnFailure(boolean v)
          This is used only if a custom language filter is being used.
 void setLanguageFilterFailuresBeforeKick(int v)
          This is used only with a custom language filter.
 void setLanguageFilterKicksBeforeBan(int v)
          This is used with a custom language filter.
 void setLanguageFilterName(String v)
          Custom language filters can be defined and given a name through the web-based administrator.
 void setLanguageFilterResetAfterKick(boolean v)
          This is used if a custom language filter has been specified.
 void setLanguageFilterSpecified(boolean v)
          If a custom language filter was specified by name using languageFilterName, then this property must be manually flagged to true.
 void setNonOperatorUpdateAllowed(boolean v)
           
 void setNonOperatorVariableUpdateAllowed(boolean v)
           
 void setPassword(String v)
          This is optional.
 void setPersistent(boolean v)
          The default is false.
 void setPlugins(List<EsPluginListEntry> v)
          A list of PluginListEntry objects that represent the plugins that need to be created with this room.
 void setReceivingRoomAttributeUpdates(boolean v)
          The default is true.
 void setReceivingRoomListUpdates(boolean v)
          The default is true.
 void setReceivingRoomVariableUpdates(boolean v)
          The default is true.
 void setReceivingUserListUpdates(boolean v)
          The default is true.
 void setReceivingUserVariableUpdates(boolean v)
          The default is true.
 void setReceivingVideoEvents(boolean v)
          Default is true.
 void setRoomDescription(String v)
          This is an optional public room-level property.
 void setRoomName(String v)
          Sets the name of the new room.
 void setUsingFloodingFilter(boolean v)
          The default if false.
 void setUsingLanguageFilter(boolean v)
          The default is false.
 void setVariables(List<EsRoomVariable> v)
          A list of RoomVariables to be used in the new room that is being created.
 void setZoneId(int v)
          The id of the zone in which you want to create the room.
 void setZoneName(String v)
          The name of the zone in which to create the new room.
 com.electrotank.electroserver5.thrift.ThriftCreateRoomRequest toThrift()
           
 
Methods inherited from class com.electrotank.electroserver5.client.api.helper.EsMessage
getMessageNumber, getMessageType, getRequestId, getServerId, setMessageNumber, setMessageType, setRequestId, setServerId
 
Methods inherited from class com.electrotank.electroserver5.client.events.Event
getType, setType
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EsCreateRoomRequest

public EsCreateRoomRequest()

EsCreateRoomRequest

public EsCreateRoomRequest(org.apache.thrift.TBase t)
Method Detail

toThrift

public com.electrotank.electroserver5.thrift.ThriftCreateRoomRequest toThrift()

newThrift

public com.electrotank.electroserver5.thrift.ThriftCreateRoomRequest newThrift()

fromThrift

public void fromThrift(org.apache.thrift.TBase t_)

getZoneName

public String getZoneName()
The name of the zone in which to create the new room. If a zone of that name doesn't exist, then it will be created. Either a zone name or a zone id must be specified. Usually it is the zone name.


setZoneName

public void setZoneName(String v)
The name of the zone in which to create the new room. If a zone of that name doesn't exist, then it will be created. Either a zone name or a zone id must be specified. Usually it is the zone name.


getZoneId

public int getZoneId()
The id of the zone in which you want to create the room. A zone must be specified, but it is usually done by name using the zoneName property.


setZoneId

public void setZoneId(int v)
The id of the zone in which you want to create the room. A zone must be specified, but it is usually done by name using the zoneName property.


getRoomName

public String getRoomName()
Sets the name of the new room. If a room of this name already exists in the specified zone, then you will be joined to that room. If you are joined to an existing room then none of the room-level properties specified here will be used. However, all of the user-subscription properies will be used.


setRoomName

public void setRoomName(String v)
Sets the name of the new room. If a room of this name already exists in the specified zone, then you will be joined to that room. If you are joined to an existing room then none of the room-level properties specified here will be used. However, all of the user-subscription properies will be used.


getCapacity

public int getCapacity()
A room can be given a maximum number of users allowed in it at once. This property is used to do that. The default is -1, which means that there is no limit.


setCapacity

public void setCapacity(int v)
A room can be given a maximum number of users allowed in it at once. This property is used to do that. The default is -1, which means that there is no limit.


getPassword

public String getPassword()
This is optional. The room can be password protected. To do that, set a password here. Users that attempt to join this room will need to use the password.


setPassword

public void setPassword(String v)
This is optional. The room can be password protected. To do that, set a password here. Users that attempt to join this room will need to use the password.


getRoomDescription

public String getRoomDescription()
This is an optional public room-level property. By setting a string value here anyone that can see this room in a room list will see the description property.


setRoomDescription

public void setRoomDescription(String v)
This is an optional public room-level property. By setting a string value here anyone that can see this room in a room list will see the description property.


isPersistent

public boolean isPersistent()
The default is false. When false, a room will automatically be removed from the server when there are no more users in it. When set to true, the room will not be removed when empty. Persistent rooms should be used wisely since that can cause a memory leak by leaving dangling rooms.


setPersistent

public void setPersistent(boolean v)
The default is false. When false, a room will automatically be removed from the server when there are no more users in it. When set to true, the room will not be removed when empty. Persistent rooms should be used wisely since that can cause a memory leak by leaving dangling rooms.


isHidden

public boolean isHidden()
The default is false. If set to true, then the room will not show up in the room list for the zone in which the room was created. Users can still join the room if they know the room and zone names. The hidden property of a room can be changed later using the UpdateRoomDetailsRequest.


setHidden

public void setHidden(boolean v)
The default is false. If set to true, then the room will not show up in the room list for the zone in which the room was created. Users can still join the room if they know the room and zone names. The hidden property of a room can be changed later using the UpdateRoomDetailsRequest.


isReceivingRoomListUpdates

public boolean isReceivingRoomListUpdates()
The default is true. This is a user-level property used when joining a room. You will find this property in the JoinRoomRequest as well. If true, the user will receive add/remove updaes to the room list for the current zone. This is part of the ZoneUpdateEvent.


setReceivingRoomListUpdates

public void setReceivingRoomListUpdates(boolean v)
The default is true. This is a user-level property used when joining a room. You will find this property in the JoinRoomRequest as well. If true, the user will receive add/remove updaes to the room list for the current zone. This is part of the ZoneUpdateEvent.


isReceivingRoomAttributeUpdates

public boolean isReceivingRoomAttributeUpdates()
The default is true. If true, you will receive UpdateRoomDetailsEvent events for all rooms in your zone. That includes description, capacity, password status, and room name.


setReceivingRoomAttributeUpdates

public void setReceivingRoomAttributeUpdates(boolean v)
The default is true. If true, you will receive UpdateRoomDetailsEvent events for all rooms in your zone. That includes description, capacity, password status, and room name.


isReceivingUserListUpdates

public boolean isReceivingUserListUpdates()
The default is true. This is a user-level property used when joining a room. You will find this property in the JoinRoomRequest as well. If true, the user will receive updates to the user list for this room through the RoomUserUpdateEvent.


setReceivingUserListUpdates

public void setReceivingUserListUpdates(boolean v)
The default is true. This is a user-level property used when joining a room. You will find this property in the JoinRoomRequest as well. If true, the user will receive updates to the user list for this room through the RoomUserUpdateEvent.


isReceivingUserVariableUpdates

public boolean isReceivingUserVariableUpdates()
The default is true. This is a user-level property used when joining a room. You will find this property in the JoinRoomRequest as well. If true, the user will receive UserVariableUpdateEvent events.


setReceivingUserVariableUpdates

public void setReceivingUserVariableUpdates(boolean v)
The default is true. This is a user-level property used when joining a room. You will find this property in the JoinRoomRequest as well. If true, the user will receive UserVariableUpdateEvent events.


isReceivingRoomVariableUpdates

public boolean isReceivingRoomVariableUpdates()
The default is true. This is a user-level property used when joining a room. You will find this property in the JoinRoomRequest as well. If true, the user will receive RoomVariableUpdateEvent events for the newly created room.


setReceivingRoomVariableUpdates

public void setReceivingRoomVariableUpdates(boolean v)
The default is true. This is a user-level property used when joining a room. You will find this property in the JoinRoomRequest as well. If true, the user will receive RoomVariableUpdateEvent events for the newly created room.


isReceivingVideoEvents

public boolean isReceivingVideoEvents()
Default is true. If true, you will receive RoomUserUpdateEvent events when users in your room start or stop publishing live streams to the server. Video is only supported in Flash clients.


setReceivingVideoEvents

public void setReceivingVideoEvents(boolean v)
Default is true. If true, you will receive RoomUserUpdateEvent events when users in your room start or stop publishing live streams to the server. Video is only supported in Flash clients.


isNonOperatorUpdateAllowed

public boolean isNonOperatorUpdateAllowed()

setNonOperatorUpdateAllowed

public void setNonOperatorUpdateAllowed(boolean v)

isNonOperatorVariableUpdateAllowed

public boolean isNonOperatorVariableUpdateAllowed()

setNonOperatorVariableUpdateAllowed

public void setNonOperatorVariableUpdateAllowed(boolean v)

isCreateOrJoinRoom

public boolean isCreateOrJoinRoom()
The default is true. When true, if a room with the same zone name (or zone id) and room name already exists, then you will be joined to it rather than it being created. If false, then if the room already exists you will fail to create or join the room. You will get a GenericErrorEvent.


setCreateOrJoinRoom

public void setCreateOrJoinRoom(boolean v)
The default is true. When true, if a room with the same zone name (or zone id) and room name already exists, then you will be joined to it rather than it being created. If false, then if the room already exists you will fail to create or join the room. You will get a GenericErrorEvent.


getPlugins

public List<EsPluginListEntry> getPlugins()
A list of PluginListEntry objects that represent the plugins that need to be created with this room.


setPlugins

public void setPlugins(List<EsPluginListEntry> v)
A list of PluginListEntry objects that represent the plugins that need to be created with this room.


getVariables

public List<EsRoomVariable> getVariables()
A list of RoomVariables to be used in the new room that is being created.


setVariables

public void setVariables(List<EsRoomVariable> v)
A list of RoomVariables to be used in the new room that is being created.


isUsingLanguageFilter

public boolean isUsingLanguageFilter()
The default is false. Use this property to enable language filtering for this room. If you enable language filtering and do nothing else, then the default language filter is used. That is defined in the web-based administrator. You can also create custom language filters through the web-based administrator and use them in a room. To use a custom language filter, assign it using the languageFilterName property. When a message fails language filter validation several actions can be taken. The default actions (for the default filter) are defined on the server. If you specify a custom filter then the actions are configurable on this request. The configuration allows you to control the delivery of a failed message and the punishment given to the user (kick, ban, nothing).


setUsingLanguageFilter

public void setUsingLanguageFilter(boolean v)
The default is false. Use this property to enable language filtering for this room. If you enable language filtering and do nothing else, then the default language filter is used. That is defined in the web-based administrator. You can also create custom language filters through the web-based administrator and use them in a room. To use a custom language filter, assign it using the languageFilterName property. When a message fails language filter validation several actions can be taken. The default actions (for the default filter) are defined on the server. If you specify a custom filter then the actions are configurable on this request. The configuration allows you to control the delivery of a failed message and the punishment given to the user (kick, ban, nothing).


isLanguageFilterSpecified

public boolean isLanguageFilterSpecified()
If a custom language filter was specified by name using languageFilterName, then this property must be manually flagged to true. The default is false.


setLanguageFilterSpecified

public void setLanguageFilterSpecified(boolean v)
If a custom language filter was specified by name using languageFilterName, then this property must be manually flagged to true. The default is false.


getLanguageFilterName

public String getLanguageFilterName()
Custom language filters can be defined and given a name through the web-based administrator. To assign a custom filter to this room specify its name here. In addition to setting this property you must also set usingLanguageFilter to true, and languageFilterSpecified to true.


setLanguageFilterName

public void setLanguageFilterName(String v)
Custom language filters can be defined and given a name through the web-based administrator. To assign a custom filter to this room specify its name here. In addition to setting this property you must also set usingLanguageFilter to true, and languageFilterSpecified to true.


isLanguageFilterDeliverMessageOnFailure

public boolean isLanguageFilterDeliverMessageOnFailure()
This is used only if a custom language filter is being used. The default is false. If true, then a message that fails language filter validation is still deliverd to the room.


setLanguageFilterDeliverMessageOnFailure

public void setLanguageFilterDeliverMessageOnFailure(boolean v)
This is used only if a custom language filter is being used. The default is false. If true, then a message that fails language filter validation is still deliverd to the room.


getLanguageFilterFailuresBeforeKick

public int getLanguageFilterFailuresBeforeKick()
This is used only with a custom language filter. The default is 3. Use this property to set the number of times a language filter failure is allowed before the user is kicked from the room.


setLanguageFilterFailuresBeforeKick

public void setLanguageFilterFailuresBeforeKick(int v)
This is used only with a custom language filter. The default is 3. Use this property to set the number of times a language filter failure is allowed before the user is kicked from the room.


getLanguageFilterKicksBeforeBan

public int getLanguageFilterKicksBeforeBan()
This is used with a custom language filter. The default is 3. This sets the number of times a user can be kicked due to language filter violations before that user is banned.


setLanguageFilterKicksBeforeBan

public void setLanguageFilterKicksBeforeBan(int v)
This is used with a custom language filter. The default is 3. This sets the number of times a user can be kicked due to language filter violations before that user is banned.


getLanguageFilterBanDuration

public int getLanguageFilterBanDuration()
This is used with a custom language filter. The default is -1, which is indefinate. If a user is kicked the number of times specified with the kicksBeforeBan property, then the user is banned from the server. The amount of time (in seconds) a user should be banned for is set with this property.


setLanguageFilterBanDuration

public void setLanguageFilterBanDuration(int v)
This is used with a custom language filter. The default is -1, which is indefinate. If a user is kicked the number of times specified with the kicksBeforeBan property, then the user is banned from the server. The amount of time (in seconds) a user should be banned for is set with this property.


isLanguageFilterResetAfterKick

public boolean isLanguageFilterResetAfterKick()
This is used if a custom language filter has been specified. When a language filter failure occurs it is stored and associated with that user. When the amount specified by the failuresBeforeKick property is reached the user is kicked from the room. If this property is true then that number is reset to 0 when the user comes back in the room. If false, then that number is not reset.


setLanguageFilterResetAfterKick

public void setLanguageFilterResetAfterKick(boolean v)
This is used if a custom language filter has been specified. When a language filter failure occurs it is stored and associated with that user. When the amount specified by the failuresBeforeKick property is reached the user is kicked from the room. If this property is true then that number is reset to 0 when the user comes back in the room. If false, then that number is not reset.


isUsingFloodingFilter

public boolean isUsingFloodingFilter()
The default if false. If set to true then flood filtering is enabled for the room using the server-defined default flooding filter. You can view and edit the properties of the default flooding filter through the web-based administrator. If you want to specify a custom flooding filter then use the floodingFilterName property.


setUsingFloodingFilter

public void setUsingFloodingFilter(boolean v)
The default if false. If set to true then flood filtering is enabled for the room using the server-defined default flooding filter. You can view and edit the properties of the default flooding filter through the web-based administrator. If you want to specify a custom flooding filter then use the floodingFilterName property.


isFloodingFilterSpecified

public boolean isFloodingFilterSpecified()
You must set to true if a custom flooding filter name has been specified. The default is false.


setFloodingFilterSpecified

public void setFloodingFilterSpecified(boolean v)
You must set to true if a custom flooding filter name has been specified. The default is false.


getFloodingFilterName

public String getFloodingFilterName()
The name of the custom flooding filter to use. The custom flooding filter is defined via the web-based administrator and given a name. That name is used here. In order to use a custom flooding filter in a room you must set usingFloodingFilter to true, and floodingFilterSpecified to true.


setFloodingFilterName

public void setFloodingFilterName(String v)
The name of the custom flooding filter to use. The custom flooding filter is defined via the web-based administrator and given a name. That name is used here. In order to use a custom flooding filter in a room you must set usingFloodingFilter to true, and floodingFilterSpecified to true.


getFloodingFilterFailuresBeforeKick

public int getFloodingFilterFailuresBeforeKick()
This property is used if a custom flooding filter has been specified. The default is 1. When flooding has been detected it counts as 1 failure. When a user has caused the number of failures specified by this property that user is then kicked from the room.


setFloodingFilterFailuresBeforeKick

public void setFloodingFilterFailuresBeforeKick(int v)
This property is used if a custom flooding filter has been specified. The default is 1. When flooding has been detected it counts as 1 failure. When a user has caused the number of failures specified by this property that user is then kicked from the room.


getFloodingFilterKicksBeforeBan

public int getFloodingFilterKicksBeforeBan()
This property is used if a custom flooding filter has been specified. The default is 3. The amount of times a user is kicked due to the flooding filter is tracked. When the user reaches the number specified here that user is banned. The duration of that ban is set with vai floodingFilterBanDuration.


setFloodingFilterKicksBeforeBan

public void setFloodingFilterKicksBeforeBan(int v)
This property is used if a custom flooding filter has been specified. The default is 3. The amount of times a user is kicked due to the flooding filter is tracked. When the user reaches the number specified here that user is banned. The duration of that ban is set with vai floodingFilterBanDuration.


getFloodingFilterBanDuration

public int getFloodingFilterBanDuration()
This property is used if a custom flooding filter has been specified. The default is -1, which is an indefinate ban (until server reboot). The ban duration can be set with this property. The value is in seconds. A banned user cannot log back in.


setFloodingFilterBanDuration

public void setFloodingFilterBanDuration(int v)
This property is used if a custom flooding filter has been specified. The default is -1, which is an indefinate ban (until server reboot). The ban duration can be set with this property. The value is in seconds. A banned user cannot log back in.


isFloodingFilterResetAfterKick

public boolean isFloodingFilterResetAfterKick()
If using a custom flooding filter then this property is used. The default is false. The user is kicked after a number of flood failures has been reached. That number is reset after kick if this property is set to true. You can configure the number of failures before kick via floodingFilterFailuresBeforeKick.


setFloodingFilterResetAfterKick

public void setFloodingFilterResetAfterKick(boolean v)
If using a custom flooding filter then this property is used. The default is false. The user is kicked after a number of flood failures has been reached. That number is reset after kick if this property is set to true. You can configure the number of failures before kick via floodingFilterFailuresBeforeKick.



Copyright © 2007-2010 Electrotank, Inc. All Rights Reserved.