MessageData
Object Hierarchy:
Description:
[ CCode ( copy_function = "unique_message_data_copy" , type_id = "unique_message_data_get_type ()" ) ]
[ Compact ]
public class MessageData
MessageData contains the data passed between instances of a App.
The MessageData structure received inside the signal handlers for UniqueApp:
UniqueMessageData:message-received is guaranteed to contain the Screen,
the workspace and the startup notification id of the instance sending the message.
Content:
Creation methods:
Methods:
- public unowned uchar[] @get (size_t length)
Retrieves the raw contents of this
set using unique_messaget_data_set.
- public void @set (uchar[]? data)
Sets data as the payload of
this.
- public MessageData copy ()
Copies this.
- public unowned string get_filename ()
- public unowned Screen get_screen ()
Returns a pointer to the screen from where the message came.
- public unowned string get_startup_id ()
Retrieves the startup notification id set inside
this.
- public string get_text ()
- public string[] get_uris ()
Retrieves a null-terminated string
vector containing the URIs set with set_uris.
- public uint get_workspace ()
Retrieves the workspace number from where the message came.
- public void set_filename (string filename)
Sets filename as the contents of
this.
- public bool set_text (string str, ssize_t length)
Sets str as the plain text payload of
this, converting it to UTF-8 if needed.
- public bool set_uris (string[] uris)
Converts uris to a valid URI list and sets it as payload
of this.