hyphenate_SDK3.0 4.0.0
hyphenate java IM SDK
Public Member Functions | Static Public Attributes | List of all members
com.hyphenate.chat.EMCmdMessageBody Class Reference
Inheritance diagram for com.hyphenate.chat.EMCmdMessageBody:
com.hyphenate.chat.EMMessageBody

Public Member Functions

 EMCmdMessageBody (String action)
 
String action ()
 
boolean isDeliverOnlineOnly ()
 
void deliverOnlineOnly (boolean onlineOnly)
 
String toString ()
 
int describeContents ()
 
void writeToParcel (Parcel dest, int flags)
 

Static Public Attributes

static final Parcelable.Creator< EMCmdMessageBodyCREATOR
 

Detailed Description

The command message body.

EMCmdMessageBody body = new EMCmdMessageBody("delete", null);
EMCmdMessageBody(String action)
Definition: EMCmdMessageBody.java:50

Constructor & Destructor Documentation

◆ EMCmdMessageBody()

com.hyphenate.chat.EMCmdMessageBody.EMCmdMessageBody ( String  action)

Creates a command message.

Parameters
actionThe command action content.

Member Function Documentation

◆ action()

String com.hyphenate.chat.EMCmdMessageBody.action ( )

Gets the command action content.

Returns
The command action content.

◆ deliverOnlineOnly()

void com.hyphenate.chat.EMCmdMessageBody.deliverOnlineOnly ( boolean  onlineOnly)

Sets whether the current cmd msg is only delivered to online users.

Parameters
onlineOnlyWhether to deliver to online users only.
  • (Default)false: The message is delivered to all users.
  • true: The message is delivered to the online users only, so the offline users won't receive the message when they log in later.

◆ isDeliverOnlineOnly()

boolean com.hyphenate.chat.EMCmdMessageBody.isDeliverOnlineOnly ( )

Checks whether this cmd message is only delivered to online users.

Returns
- true: Only delivers to online users.
  • false: Delivers to all users.

◆ toString()

String com.hyphenate.chat.EMCmdMessageBody.toString ( )

Gets and displays the content of the CMD message.

Returns
The content of the action of the CMD message.

Member Data Documentation

◆ CREATOR

final Parcelable.Creator<EMCmdMessageBody> com.hyphenate.chat.EMCmdMessageBody.CREATOR
static
Initial value:
= new Parcelable.Creator<EMCmdMessageBody>() {
public EMCmdMessageBody createFromParcel(Parcel in) {
return new EMCmdMessageBody(in);
}
public EMCmdMessageBody[] newArray(int size) {
return new EMCmdMessageBody[size];
}
}

The documentation for this class was generated from the following file: