|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectsfs2x.client.requests.BaseRequest
sfs2x.client.requests.GenericMessageRequest
sfs2x.client.requests.PrivateMessageRequest
public class PrivateMessageRequest
Sends a private chat message.
The private message is dispatched to a specific user, who can be in any server Room, or even in no Room at all. The message is delivered by means of the privateMessage event. It is also returned to the sender: this allows showing the messages in the correct order in the application interface. It is also possible to send an optional object together with the message: it can contain custom parameters useful to transmit, for example, additional informations related to the message, like the text font or color, or other formatting details.
Example
SFSEvent.PRIVATE_MESSAGE| Field Summary |
|---|
| Fields inherited from class sfs2x.client.requests.GenericMessageRequest |
|---|
KEY_MESSAGE, KEY_MESSAGE_TYPE, KEY_RECIPIENT, KEY_RECIPIENT_MODE, KEY_ROOM_ID, KEY_SENDER_DATA, KEY_USER_ID, KEY_XTRA_PARAMS |
| Fields inherited from class sfs2x.client.requests.BaseRequest |
|---|
AddBuddy, AdminMessage, AutoJoin, BanUser, BlockBuddy, CallExtension, ChangeRoomCapacity, ChangeRoomName, ChangeRoomPassword, CreateRoom, CreateSFSGame, FindRooms, FindUsers, GenericMessage, GetRoomList, GoOnline, Handshake, InitBuddyList, InvitationReply, InviteUser, JoinRoom, KEY_ERROR_CODE, KEY_ERROR_PARAMS, KickUser, LeaveRoom, Login, Logout, ManualDisconnection, ModeratorMessage, ObjectMessage, PingPong, PlayerToSpectator, PrivateMessage, PublicMessage, QuickJoinGame, RemoveBuddy, SetBuddyVariables, SetRoomVariables, SetUserVariables, SpectatorToPlayer, SubscribeRoomGroup, UnsubscribeRoomGroup |
| Constructor Summary | |
|---|---|
PrivateMessageRequest(java.lang.String message,
int recipientId)
|
|
PrivateMessageRequest(java.lang.String message,
int recipientId,
com.smartfoxserver.v2.entities.data.ISFSObject params)
Creates a new PrivateMessageRequest instance. |
|
| Method Summary |
|---|
| Methods inherited from class sfs2x.client.requests.GenericMessageRequest |
|---|
execute, validate |
| Methods inherited from class sfs2x.client.requests.BaseRequest |
|---|
getId, getMessage, getTargetController, isEncrypted, setEncrypted, setId, setTargetController |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public PrivateMessageRequest(java.lang.String message,
int recipientId,
com.smartfoxserver.v2.entities.data.ISFSObject params)
message - The message to be sent to to the recipient user.recipientId - The id of the user to which the message is to be sent.params - An instance of SFSObject containing additional custom parameters to be sent to the message recipient (for example the color of the text, etc).SmartFox.send(sfs2x.client.requests.IRequest),
SFSObject
public PrivateMessageRequest(java.lang.String message,
int recipientId)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||