ElectroServer 5 Client: C#
Electrotank.Electroserver5.Api.GetUsersInRoomResponse Class Reference

This is the response to the GetUsersInRoomRequest. More...

Inheritance diagram for Electrotank.Electroserver5.Api.GetUsersInRoomResponse:
Electrotank.Electroserver5.Api.EsResponse Electrotank.Electroserver5.Api.EsMessage Electrotank.Electroserver5.Api.IThriftSerializable

Public Member Functions

 GetUsersInRoomResponse ()
 
 GetUsersInRoomResponse (TBase t)
 
override TBase ToThrift ()
 
override TBase NewThrift ()
 
override void FromThrift (TBase t_)
 
- Public Member Functions inherited from Electrotank.Electroserver5.Api.EsResponse
 EsResponse ()
 

Properties

int ZoneId [get, set]
 Id of the zone that contains the room. More...
 
int RoomId [get, set]
 Id of the room that contains the users. More...
 
List< UserListEntryUsers [get, set]
 List of UserListEntry objects, each of which describe a user in the room. More...
 

Detailed Description

This is the response to the GetUsersInRoomRequest.

It contains a list of UserListEntry objects describing the list of users. Each UserListEntry object contains properties about a user such as the userName and userVariables.

      This example shows how to request the list of users in a room, capture the response, and print the results.
private var _es:ElectroServer;
private var _room:Room;
private function initialize():void {
        _es.engine.addEventListener(MessageType.GetUsersInRoomResponse.name, onGetUsersInRoomResponse);
        var guir:GetUsersInRoomRequest = new GetUsersInRoomRequest();
        guir.zoneId = _room.zoneId;
        guir.roomId = _room.id;
        _es.engine.send(guir);
}
private function onGetUsersInRoomResponse(e:GetUsersInRoomResponse):void {
        trace("Users in this room: " + e.roomId.toString());
        for each (var ule:UserListEntry in e.users) {
                trace(ule.userName);
        }
}

Constructor & Destructor Documentation

Electrotank.Electroserver5.Api.GetUsersInRoomResponse.GetUsersInRoomResponse ( )
Electrotank.Electroserver5.Api.GetUsersInRoomResponse.GetUsersInRoomResponse ( TBase  t)

Member Function Documentation

override void Electrotank.Electroserver5.Api.GetUsersInRoomResponse.FromThrift ( TBase  t_)
virtual
override TBase Electrotank.Electroserver5.Api.GetUsersInRoomResponse.NewThrift ( )
virtual
override TBase Electrotank.Electroserver5.Api.GetUsersInRoomResponse.ToThrift ( )
virtual

Property Documentation

int Electrotank.Electroserver5.Api.GetUsersInRoomResponse.RoomId
getset

Id of the room that contains the users.

List<UserListEntry> Electrotank.Electroserver5.Api.GetUsersInRoomResponse.Users
getset

List of UserListEntry objects, each of which describe a user in the room.

int Electrotank.Electroserver5.Api.GetUsersInRoomResponse.ZoneId
getset

Id of the zone that contains the room.