MatrixEventRoomMessage

MatrixEventRoomMessage — Class to hold an m.room.message event

Functions

Types and Values

Description

This event is used when sending messages in a room. Messages are not limited to be text. The `msgtype` key outlines the type of message, e.g. text, audio, image, video, etc. The `body` key is text and MUST be used with every kind of `msgtype` as a fallback mechanism for when a client cannot render a message. This allows clients to display *something* even if it is just plain text.

Functions

MATRIX_EVENT_TYPE_ROOM_MESSAGE

#define MATRIX_EVENT_TYPE_ROOM_MESSAGE (matrix_event_room_message_get_type ())

The type for MatrixEventRoomMessage.


matrix_event_room_message_new ()

MatrixEventRoomMessage *
matrix_event_room_message_new (void);

matrix_event_room_message_get_message ()

MatrixMessageBase *
matrix_event_room_message_get_message (MatrixEventRoomMessage *self);

Get and return the current value of the "message" property.

The message as a Matrix.Message object.

Parameters

self

the MatrixEventRoomMessage instance to query

 

Returns

the value of the "message" property


matrix_event_room_message_set_message ()

void
matrix_event_room_message_set_message (MatrixEventRoomMessage *self,
                                       MatrixMessageBase *value);

Set the value of the "message" property to value .

The message as a Matrix.Message object.

Parameters

self

the MatrixEventRoomMessage instance to modify

 

value

the new value of the "message" property

 

matrix_event_room_message_get_fallback_content ()

JsonNode *
matrix_event_room_message_get_fallback_content
                               (MatrixEventRoomMessage *self);

Get and return the current value of the "fallback-content" property.

The message as a JSON object. This gets set by Matrix.Message.Base.new_from_json if no handler is installed for the given message type.

Parameters

self

the MatrixEventRoomMessage instance to query

 

Returns

the value of the "fallback-content" property

Types and Values

struct MatrixEventRoomMessage

struct MatrixEventRoomMessage {
	MatrixEventRoom parent_instance;
	MatrixEventRoomMessagePrivate * priv;
};

Class to hold an m.room.message event

This event is used when sending messages in a room. Messages are not limited to be text. The `msgtype` key outlines the type of message, e.g. text, audio, image, video, etc. The `body` key is text and MUST be used with every kind of `msgtype` as a fallback mechanism for when a client cannot render a message. This allows clients to display *something* even if it is just plain text.


struct MatrixEventRoomMessageClass

struct MatrixEventRoomMessageClass {
	MatrixEventRoomClass parent_class;
};

The class structure for MATRIX_EVENT_TYPE_ROOM_MESSAGE. All the fields in this structure are private and should never be accessed directly.

Members

MatrixEventRoomClass parent_class;

the parent class structure