Packagecom.electrotank.electroserver4.message.request
Classpublic class CreateRoomRequest
InheritanceCreateRoomRequest Inheritance com.electrotank.electroserver4.message.request.RequestImpl

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 things that you can be subscribed to receive events.

Subscription properties when joining a room (all of the following default to true):


Example
Shows the most simple example of how to create a new room with all default properties.
     
    //Import the needed classes
    import com.electrotank.electroserver4.ElectroServer;
    import com.electrotank.electroserver4.message.MessageType;
    import com.electrotank.electroserver4.message.request.CreateRoomRequest;
    import com.electrotank.electroserver4.message.event.JoinRoomEvent;
    import com.electrotank.electroserver4.user.User;
    //
    //create the request
    var crr:CreateRoomRequest = new CreateRoomRequest();
    crr.setRoomName("Some Room");
    crr.setZoneName("Some Zone");
    //
    //Send the request
    es.send(crr);
    //
    //Configure the JoinRoomEvent so you know when you've been joined.
    es.addEventListener(MessageType.JoinRoomEvent, "onJoinRoomEvent", this);
    function onJoinRoomEvent(e:JoinRoomEvent):void {
        var roomId:Number = e.getRoomId();
        var zoneId:Number = e.getZoneId();
        //trace the users in your room
        for (var i:int=0;i>e.getUsers().length;++i) {
            var u:User = e.getUsers()[i];
            trace(u.getUserName());
        }
    }
    
Here is a thorough example that uses room variables, changes room proprties, applies join subscriptions, and uses plugins.
    import com.electrotank.electroserver4.ElectroServer;
    import com.electrotank.electroserver4.entities.RoomVariable;
    import com.electrotank.electroserver4.esobject.EsObject;
    import com.electrotank.electroserver4.message.request.CreateRoomRequest;
    import com.electrotank.electroserver4.message.MessageType;
    import com.electrotank.electroserver4.plugin.Plugin;
    
    var es:ElectroServer;
    es.addEventListener(MessageType.JoinRoomEvent, "onJoinRoomEvent", this);
    function createRoom():void {
        var crr:CreateRoomRequest = new CreateRoomRequest();
        crr.setRoomName("Some room");
        crr.setZoneName("Some zone");
        //Set a few properties
        crr.setCapacity(10);
        crr.setRoomDescription("This is a my room");
        crr.setPassword("secret");
        //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("test1", ob1, true, false);
        //room var 2
        var ob2:EsObject = new EsObject();
        ob1.setString("Test_String2", "blah2");
        ob1.setInteger("Test_int2", 12);
        var rv2:RoomVariable = new RoomVariable("test2", ob2, false, false);
        //add the room variables to the request
        crr.setRoomVariables([rv1, rv2]);
        //Create a new plugin for this room
        var pl:Plugin = new Plugin();
        pl.setExtensionName("ExamplePluginExtension");
        pl.setPluginHandle("ExamplePlugin");
        pl.setPluginName("ExamplePlugin");
        //add the plugin to the request
        crr.setPlugins([pl]);
        //Now configure some of the user's subscription properties
        crr.setIsReceivingRoomDetailUpdates(false);//Don't want to receive updates about other rooms
        crr.setIsReceivingRoomListUpdates(false);//Don't want to receive updates about when other rooms are created or destroyed
        crr.setIsReceivingUserListUpdates(true);//true is the default. When true you will receive user list updates for your room.
        //
        //Now send the request to the server
        es.send(crr);
    }
    function onJoinRoomEvent(e:JoinRoomEvent):void {
        var roomId:Number = e.getRoomId();
        var zoneId:Number = e.getZoneId();
        //trace the users in your room
        for (var i:int=0;i>e.getUsers().length;++i) {
            var u:User = e.getUsers()[i];
            trace(u.getUserName());
        }
    }
    
    



Public Methods
 MethodDefined by
  
Creates a new instance of the CreateRoomRequest object.
CreateRoomRequest
  
getBanDuration():Number
Returns the amount of time in seconds that a user will be banned if banned due to language fitler violation.
CreateRoomRequest
  
getCapacity():Number
Returns the maximum number of users allowed in this room at once.
CreateRoomRequest
  
Returns the number of language filter failures before the user is kicked.
CreateRoomRequest
  
Returns the amount of time in seconds that a user will be banned if ban due to flooding.
CreateRoomRequest
  
Returns the number of flooding failures allowed before the user is kicked.
CreateRoomRequest
  
Returns the amount of times a user can be kicked due to flooding before being banned.
CreateRoomRequest
  
Returns the name of the custom flooding filter.
CreateRoomRequest
  
Returns true if a message is supposed to be delivered even if it fails language filter validation.
CreateRoomRequest
  
If a custom flooding filter was specified by name then this property is used by the room.
CreateRoomRequest
  
Returns true if a custom flooding filter name has been specified.
CreateRoomRequest
  
getIsHidden():Boolean
Returns false if the room is set to be hidden on create.
CreateRoomRequest
  
If a custom language filter was specified by name using setLanguageFilterName, then this method returns true.
CreateRoomRequest
  
CreateRoomRequest
  
CreateRoomRequest
  
getIsPersistent():Boolean
Returns false if the room is set to automatically be removed when the user list is 0.
CreateRoomRequest
  
Returns the isReceivingRoomDetailUpdates property.
CreateRoomRequest
  
Returns true if the user will receive room list updates.
CreateRoomRequest
  
Returns true if the user is set to receive RoomVariableUpdateEvent events.
CreateRoomRequest
  
Returns true if the user is set up to receive UserListUpdateEvent events for the new room.
CreateRoomRequest
  
Returns true if the user is set to receive UserVariableUpdateEvent events in the new room.
CreateRoomRequest
  
Returns the isReceivingVideoUpdates property.
CreateRoomRequest
  
Returns true if the number of language filter failures is to be reset after a user is kicked.
CreateRoomRequest
  
Returns true if flood filtering has been enabled for this room.
CreateRoomRequest
  
Returns true if language filtering is enabled.
CreateRoomRequest
  
Returns the number of times a user can be kicked before getting banned.
CreateRoomRequest
  
The name of the custom language filter used in this room, if any.
CreateRoomRequest
  
getPassword():String
Returns the optional password used to protect the room.
CreateRoomRequest
  
getPlugins():Array
Returns the array of Plugin objects that represent plugins to be created in this new room.
CreateRoomRequest
  
Returns the optional string description of the room.
CreateRoomRequest
  
getRoomName():String
Returns the name of the room to be created.
CreateRoomRequest
  
Returns an array of RoomVariable objecs that represent room variables to be created in the new room.
CreateRoomRequest
  
getZoneId():Number
Returns the id of the zone in which to create the room.
CreateRoomRequest
  
getZoneName():String
Returns the name of the zone in which the room will be created.
CreateRoomRequest
  
setBanDuration(duration:Number):void
This is used with a custom language filter.
CreateRoomRequest
  
setCapacity(capacity:Number):void
A room can be given a hard cap of the maximum number of users allowed in it at once.
CreateRoomRequest
  
setFailuresBeforeKick(failuresBeforeKick:Number):void
This is used only with a custom language filter.
CreateRoomRequest
  
setFloodingFilterBanDuration(banDuration:Number):void
This property is used if a custom flooding filter has been specified.
CreateRoomRequest
  
setFloodingFilterFailuresBeforeKick(failuresBeforeKick:Number):void
This property is used if a custom flooding filter has been specified.
CreateRoomRequest
  
setFloodingFilterKicksBeforeBan(kicksBeforeBan:Number):void
This property is used if a custom flooding filter has been specified.
CreateRoomRequest
  
setFloodingFilterName(filterName:String):void
The name of the custom flooding filter to use.
CreateRoomRequest
  
setIsDeliverMessageOnFailure(val:Boolean):void
This is used only if a custom language filter is being used.
CreateRoomRequest
  
setIsFloodingFilterResetAfterKick(isResetAfterKick:Boolean):void
If using a custom flooding filter then this property is used.
CreateRoomRequest
  
setIsHidden(hidden:Boolean):void
The default is false.
CreateRoomRequest
  
CreateRoomRequest
  
CreateRoomRequest
  
setIsPersistent(persistent:Boolean):void
The default is false.
CreateRoomRequest
  
setIsReceivingRoomDetailUpdates(isReceiving:Boolean):void
The default is true.
CreateRoomRequest
  
setIsReceivingRoomListUpdates(receivingRoomListUpdates:Boolean):void
The default is true.
CreateRoomRequest
  
setIsReceivingRoomVariableUpdates(receivingRoomVariableUpdates:Boolean):void
The default is true.
CreateRoomRequest
  
setIsReceivingUserListUpdates(receivingUserListUpdates:Boolean):void
The default is true.
CreateRoomRequest
  
setIsReceivingUserVariableUpdates(receivingUserVariableUpdates:Boolean):void
The default is true.
CreateRoomRequest
  
setIsReceivingVideoEvents(isReceiving:Boolean):void
Default is true.
CreateRoomRequest
  
setIsResetAfterKick(resetAfterKick:Boolean):void
This is used if a custom language filter has been specified.
CreateRoomRequest
  
setIsUsingFloodingFilter(useFloodingFilter:Boolean):void
The default if false.
CreateRoomRequest
  
setIsUsingLanguageFilter(useLanguageFilter:Boolean):void
The default is false.
CreateRoomRequest
  
setKicksBeforeBan(kicksBeforeBan:Number):void
This is used with a custom language filter.
CreateRoomRequest
  
setLanguageFilterName(filterName:String):void
Custom language filters can be defined and given a name through the web-based administrator.
CreateRoomRequest
  
setPassword(password:String):void
This is optional.
CreateRoomRequest
  
setPlugins(plugins:Array):void
Sets an array of Plugin objects that represent the plugins that need to be created with this room.
CreateRoomRequest
  
setRoomDescription(description:String):void
This is an optional public room-level property.
CreateRoomRequest
  
setRoomName(name:String):void
Sets the name of the new room.
CreateRoomRequest
  
setRoomVariables(roomVariables:Array):void
Sets an array of RoomVariable objects to be used in the new room that is being created.
CreateRoomRequest
  
setZoneId(id:Number):void
Sets the id of the zone in which you want to create the room.
CreateRoomRequest
  
setZoneName(name:String):void
Sets the name of the zone in which to create the new room.
CreateRoomRequest
  
CreateRoomRequest
Constructor detail
CreateRoomRequest()constructor
public function CreateRoomRequest()

Creates a new instance of the CreateRoomRequest object.

Method detail
getBanDuration()method
public function getBanDuration():Number

Returns the amount of time in seconds that a user will be banned if banned due to language fitler violation.

Returns
Number — Returns the amount of time in seconds that a user will be banned if banned due to language fitler violation.
getCapacity()method 
public function getCapacity():Number

Returns the maximum number of users allowed in this room at once.

Returns
Number — Returns the maximum number of users allowed in this room at once.
getFailuresBeforeKick()method 
public function getFailuresBeforeKick():Number

Returns the number of language filter failures before the user is kicked.

Returns
Number — Returns the number of language filter failures before the user is kicked.
getFloodingFilterBanDuration()method 
public function getFloodingFilterBanDuration():Number

Returns the amount of time in seconds that a user will be banned if ban due to flooding.

Returns
Number — The amount of time in seconds of the ban.
getFloodingFilterFailuresBeforeKick()method 
public function getFloodingFilterFailuresBeforeKick():Number

Returns the number of flooding failures allowed before the user is kicked.

Returns
Number — The number of flooding failures before the user is kicked.
getFloodingFilterKicksBeforeBan()method 
public function getFloodingFilterKicksBeforeBan():Number

Returns the amount of times a user can be kicked due to flooding before being banned.

Returns
Number — The number of times the user can be kicked before getting banned.
getFloodingFilterName()method 
public function getFloodingFilterName():String

Returns the name of the custom flooding filter.

Returns
String — Returns the name of the custom flooding filter.
getIsDeliverMessageOnFailure()method 
public function getIsDeliverMessageOnFailure():Boolean

Returns true if a message is supposed to be delivered even if it fails language filter validation.

Returns
Boolean — Returns true if a message is supposed to be delivered even if it fails language filter validation.
getIsFloodingFilterResetAfterKick()method 
public function getIsFloodingFilterResetAfterKick():Boolean

If a custom flooding filter was specified by name then this property is used by the room. The default is false.

Returns
Boolean — True or false
getIsFloodingFilterSpecified()method 
public function getIsFloodingFilterSpecified():Boolean

Returns true if a custom flooding filter name has been specified.

Returns
Boolean — Returns true if a custom flooding filter name has been specified.
getIsHidden()method 
public function getIsHidden():Boolean

Returns false if the room is set to be hidden on create. A hidden room does not show up in the room list.

Returns
Boolean — Returns false if the room is set to be hidden on create. A hidden room does not show up in the room list.
getIsLanguageFilterSpecified()method 
public function getIsLanguageFilterSpecified():Boolean

If a custom language filter was specified by name using setLanguageFilterName, then this method returns true. Otherwise it returns false.

Returns
Boolean — Returns true if a custom language filter was specified to be used by name.
getIsNonOperatorUpdateAllowed()method 
public function getIsNonOperatorUpdateAllowed():Boolean

Returns
Boolean
getIsNonOperatorVariableUpdateAllowed()method 
public function getIsNonOperatorVariableUpdateAllowed():Boolean

Returns
Boolean
getIsPersistent()method 
public function getIsPersistent():Boolean

Returns false if the room is set to automatically be removed when the user list is 0. Returns true when it is set to never die.

Returns
Boolean — Returns false if the room is set to automatically be removed when the user list is 0. Returns true when it is set to never die.
getIsReceivingRoomDetailUpdates()method 
public function getIsReceivingRoomDetailUpdates():Boolean

Returns the isReceivingRoomDetailUpdates property.

Returns
Boolean — Returns the isReceivingRoomDetailUpdates property.
getIsReceivingRoomListUpdates()method 
public function getIsReceivingRoomListUpdates():Boolean

Returns true if the user will receive room list updates.

Returns
Boolean — Returns true if the user will receive room list updates.
getIsReceivingRoomVariableUpdates()method 
public function getIsReceivingRoomVariableUpdates():Boolean

Returns true if the user is set to receive RoomVariableUpdateEvent events.

Returns
Boolean — Returns true if the user is set to receive RoomVariableUpdateEvent events.
getIsReceivingUserListUpdates()method 
public function getIsReceivingUserListUpdates():Boolean

Returns true if the user is set up to receive UserListUpdateEvent events for the new room.

Returns
Boolean — Returns true if the user is set up to receive UserListUpdateEvent events for the new room.
getIsReceivingUserVariableUpdates()method 
public function getIsReceivingUserVariableUpdates():Boolean

Returns true if the user is set to receive UserVariableUpdateEvent events in the new room.

Returns
Boolean — Returns true if the user is set to receive UserVariableUpdateEvent events in the new room.
getIsReceivingVideoEvents()method 
public function getIsReceivingVideoEvents():Boolean

Returns the isReceivingVideoUpdates property.

Returns
Boolean — Returns the isReceivingVideoUpdates property.
getIsResetAfterKick()method 
public function getIsResetAfterKick():Boolean

Returns true if the number of language filter failures is to be reset after a user is kicked.

Returns
Boolean — Returns true if the number of language filter failures is to be reset after a user is kicked.
getIsUsingFloodingFilter()method 
public function getIsUsingFloodingFilter():Boolean

Returns true if flood filtering has been enabled for this room.

Returns
Boolean — Returns true if flood filtering has been enabled for this room.
getIsUsingLanguageFilter()method 
public function getIsUsingLanguageFilter():Boolean

Returns true if language filtering is enabled.

Returns
Boolean — Returns true if language filtering is enabled.
getKicksBeforeBan()method 
public function getKicksBeforeBan():Number

Returns the number of times a user can be kicked before getting banned.

Returns
Number — Returns the number of times a user can be kicked before getting banned.
getLanguageFilterName()method 
public function getLanguageFilterName():String

The name of the custom language filter used in this room, if any.

Returns
String — The name of the custom language filter used in this room, if any.
getPassword()method 
public function getPassword():String

Returns the optional password used to protect the room.

Returns
String — Returns the optional password used to protect the room.
getPlugins()method 
public function getPlugins():Array

Returns the array of Plugin objects that represent plugins to be created in this new room.

Returns
Array — Returns the array of Plugin objects that represent plugins to be created in this new room.
getRoomDescription()method 
public function getRoomDescription():String

Returns the optional string description of the room.

Returns
String — Returns the optional string description of the room.
getRoomName()method 
public function getRoomName():String

Returns the name of the room to be created.

Returns
String — Returns the name of the room to be created.
getRoomVariables()method 
public function getRoomVariables():Array

Returns an array of RoomVariable objecs that represent room variables to be created in the new room.

Returns
Array — Returns an array of RoomVariable objecs that represent room variables to be created in the new room.
getZoneId()method 
public function getZoneId():Number

Returns the id of the zone in which to create the room. If none has been specified then -1 is returned.

Returns
Number
getZoneName()method 
public function getZoneName():String

Returns the name of the zone in which the room will be created.

Returns
String — Returns the name of the zone in which the room will be created.
setBanDuration()method 
public function setBanDuration(duration:Number):void

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 setKicksBeforeBan method, then the user is banned from the server. The amount of time (in seconds) a user should be banned for is set with this method.

Parameters
duration:Number — The amount of time in seconds to ban the user that abused the language filter.
setCapacity()method 
public function setCapacity(capacity:Number):void

A room can be given a hard cap of the maximum number of users allowed in it at once. This method is used to do that. The default is -1, which means that there is no limit.

Parameters
capacity:Number — The maximum number of users allowed in the room at once.
setFailuresBeforeKick()method 
public function setFailuresBeforeKick(failuresBeforeKick:Number):void

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

Parameters
failuresBeforeKick:Number — The number of times a user can send a message that fails language filter validation before being kicked.
setFloodingFilterBanDuration()method 
public function setFloodingFilterBanDuration(banDuration:Number):void

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 method. The value is in seconds. A banned user cannot log back in.

Parameters
banDuration:Number — Time in seconds of the ban. Use -1 to ban indefinately (or until server reboot).
setFloodingFilterFailuresBeforeKick()method 
public function setFloodingFilterFailuresBeforeKick(failuresBeforeKick:Number):void

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.

Parameters
failuresBeforeKick:Number — The number of flooding failures before the user is kicked.
setFloodingFilterKicksBeforeBan()method 
public function setFloodingFilterKicksBeforeBan(kicksBeforeBan:Number):void

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 setFloodingFilterBanDuration.

Parameters
kicksBeforeBan:Number — The number of times to kick
setFloodingFilterName()method 
public function setFloodingFilterName(filterName:String):void

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 use this method and also use setIsUsingFloodingFilter to enabled flooding filters for the room.

Parameters
filterName:String — The name of the custom flooding filter.
setIsDeliverMessageOnFailure()method 
public function setIsDeliverMessageOnFailure(val:Boolean):void

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.

Parameters
val:Boolean — Pass in true if you want a failed message to still be delivered.
setIsFloodingFilterResetAfterKick()method 
public function setIsFloodingFilterResetAfterKick(isResetAfterKick:Boolean):void

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 with setFloodingFilterFailuresBeforeKick.

Parameters
isResetAfterKick:Boolean — Set to true to erase the number of flooding failures detected on kick.
setIsHidden()method 
public function setIsHidden(hidden:Boolean):void

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.

Parameters
hidden:Boolean — Pass in true if you want the room to not show up in the room list.
setIsNonOperatorUpdateAllowed()method 
public function setIsNonOperatorUpdateAllowed(val:Boolean):voidParameters
val:Boolean
setIsNonOperatorVariableUpdateAllowed()method 
public function setIsNonOperatorVariableUpdateAllowed(val:Boolean):voidParameters
val:Boolean
setIsPersistent()method 
public function setIsPersistent(persistent:Boolean):void

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.

Parameters
persistent:Boolean — Pass in true to keep a room around even if empty, false if you want it to get cleaned up when empty.
setIsReceivingRoomDetailUpdates()method 
public function setIsReceivingRoomDetailUpdates(isReceiving:Boolean):void

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.

Parameters
isReceiving:Boolean — Set to true if you want to receive these updates.
setIsReceivingRoomListUpdates()method 
public function setIsReceivingRoomListUpdates(receivingRoomListUpdates:Boolean):void

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.

Parameters
receivingRoomListUpdates:Boolean — Pass in true to receive room list updates with the ZoneUpdateEvent.
setIsReceivingRoomVariableUpdates()method 
public function setIsReceivingRoomVariableUpdates(receivingRoomVariableUpdates:Boolean):void

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.

Parameters
receivingRoomVariableUpdates:Boolean — Pass in true to receive RoomVariableUpdateEvent events.
setIsReceivingUserListUpdates()method 
public function setIsReceivingUserListUpdates(receivingUserListUpdates:Boolean):void

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 UserListUpdateEvent.

Parameters
receivingUserListUpdates:Boolean — Pass in true to receive UserListUpdateEvent events for this new room.
setIsReceivingUserVariableUpdates()method 
public function setIsReceivingUserVariableUpdates(receivingUserVariableUpdates:Boolean):void

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.

Parameters
receivingUserVariableUpdates:Boolean — Pass in true to receive UserVariableUpdateEvent events for the newly created room.
setIsReceivingVideoEvents()method 
public function setIsReceivingVideoEvents(isReceiving:Boolean):void

Default is true. If true, you will receive UserListUpdateEvent events when users in your room start or stop publishing live streams to the server.

Parameters
isReceiving:Boolean — Set to true if you want to receive these events.
setIsResetAfterKick()method 
public function setIsResetAfterKick(resetAfterKick:Boolean):void

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 setFailuresBeforeKick method 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.

Parameters
resetAfterKick:Boolean — Pass in true to resent the number of language filter failures associated with a user after they are kicked.
setIsUsingFloodingFilter()method 
public function setIsUsingFloodingFilter(useFloodingFilter:Boolean):void

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 setFloodingFilterName method.

Parameters
useFloodingFilter:Boolean — Pass in true if you want to flood filtering enabled in this room.
setIsUsingLanguageFilter()method 
public function setIsUsingLanguageFilter(useLanguageFilter:Boolean):void

The default is false. Use this method 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 setLanguageFilterName method. 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 here. The configuration allows you to control the delivery of a failed message and the punishment given to the user (kick, ban, nothing).

Parameters
useLanguageFilter:Boolean — Pass in true to enable language filtering.
setKicksBeforeBan()method 
public function setKicksBeforeBan(kicksBeforeBan:Number):void

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.

Parameters
kicksBeforeBan:Number — The number of times a user can be kicked before getting banned.
setLanguageFilterName()method 
public function setLanguageFilterName(filterName:String):void

Custom language filters can be defined and given a name through the web-based administrator. This method allows you to use one in this room. In addition to this method you must also use the setIsUsingLanguageFilter method to enable language filtering in this room.

Parameters
filterName:String — The name of the custom language filter to use.
setPassword()method 
public function setPassword(password:String):void

This is optional. The room can be password protected. To do that, set a password using this method. Users that attempt to join this room will need to use the password.

Parameters
password:String — The optional password used to protect the room.
setPlugins()method 
public function setPlugins(plugins:Array):void

Sets an array of Plugin objects that represent the plugins that need to be created with this room.

Parameters
plugins:Array — arr
setRoomDescription()method 
public function setRoomDescription(description:String):void

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.

Parameters
description:String — The optional string description of the room.
setRoomName()method 
public function setRoomName(name:String):void

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.

Parameters
name:String — The name of the room to be created.
setRoomVariables()method 
public function setRoomVariables(roomVariables:Array):void

Sets an array of RoomVariable objects to be used in the new room that is being created.

Parameters
roomVariables:Array — roomVariables
setZoneId()method 
public function setZoneId(id:Number):void

Sets 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 setZoneName method. The setZoneId method is rarely used.

Parameters
id:Number — The id of the zone in which to create the room.
setZoneName()method 
public function setZoneName(name:String):void

Sets 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.

Parameters
name:String — The name of the zone in which to create the room.
validate()method 
public override function validate():ValidationResponse

Returns
ValidationResponse