IChatServicePingRoom Method |
Keeping alive user in a room. User has to call this method every few seconds to let server know that he is still online.
At the same time a new online users in a room and a new messages in a room are checked. Client sends the last time he made an update
of online users (roomUsersLastChange) and messages (roomMessagesLastChange). If something new
has happened since that time, the changes are sent back.
Namespace: CMS.ChatAssembly: CMS.Chat (in CMS.Chat.dll) Version: 12.0.0
Syntax ChatGeneralResponse<PingRoomResponseData> PingRoom(
int roomID,
Nullable<long> roomUsersLastChange,
Nullable<long> roomMessagesLastChange,
Nullable<int> maxMessagesCount
)
Parameters
- roomID
- Type: SystemInt32
ID of a chat room - roomUsersLastChange
- Type: SystemNullableInt64
Last update of members on this client (client gets this number in PingRoom().Users.LastChange) - if this param is null, client does not need online users. If it is 0, it is the first request and all users are returned. - roomMessagesLastChange
- Type: SystemNullableInt64
Last update of messages on this client (client gets this number in PingRoom().Messages.LastChange) - if this param is null, client does not need online users. If it is 0, it is the first request and all users are returned. - maxMessagesCount
- Type: SystemNullableInt32
Maximum number of messages returned
Return Value
Type:
ChatGeneralResponsePingRoomResponseDataPingRoomsResultData
See Also