SIGN UP

IMessage

Interface that represents message within a conversation.

Methods

getConversation

String getConversation()

Get UUID of the conversation this message belongs to.

Returns

  • Return:

    String

    Conversation UUID

getPayload

List<Payload> getPayload()

Get list of Payload objects associated with the message.

Returns

  • Return:

    List<Payload>

    List of Payload

getSender

String getSender()

Get user id of the sender of this message.

Returns

  • Return:

    String

    User id

getSequence

long getSequence()

Get message sequence number.

Returns

  • Return:

    long

    Message sequence number

getText

String getText()

Get text of this message.

Returns

  • Return:

    String

    Message text

getUUID

String getUUID()

Get universally unique identifier of message. Can be used on client side for house keeping.

Returns

  • Return:

    String

    UUID of this message

remove

void remove()

Remove the message. Triggers the IMessengerListener.onRemoveMessage(IMessageEvent) event for all messenger objects on all clients, including this one. Clients that are not connected will receive it later.

update

void update(String text, List<Payload> payload)

Sends text and payload changes to the server.

Parameters

  • text:

    String

    New text of this message. If null, message text will not be updated.

  • payload:

    List<Payload>

    New payload of this message. If null, message payload will not be updated.