![]() |
![]() |
![]() |
wocky Reference Manual | ![]() |
---|---|---|---|---|
Top | Description | Object Hierarchy | Properties | Signals |
WockyPubsubNode; WockyPubsubNodeClass; const gchar * wocky_pubsub_node_get_name (WockyPubsubNode *self
); void wocky_pubsub_node_delete_async (WockyPubsubNode *self
,GCancellable *cancellable
,GAsyncReadyCallback callback
,gpointer user_data
); gboolean wocky_pubsub_node_delete_finish (WockyPubsubNode *self
,GAsyncResult *result
,GError **error
); WockyXmppStanza * wocky_pubsub_node_make_publish_stanza (WockyPubsubNode *self
,WockyXmppNode **pubsub_out
,WockyXmppNode **publish_out
,WockyXmppNode **item_out
); void wocky_pubsub_node_subscribe_async (WockyPubsubNode *self
,const gchar *jid
,GCancellable *cancellable
,GAsyncReadyCallback callback
,gpointer user_data
); WockyPubsubSubscription * wocky_pubsub_node_subscribe_finish (WockyPubsubNode *self
,GAsyncResult *result
,GError **error
); void wocky_pubsub_node_unsubscribe_async (WockyPubsubNode *self
,const gchar *jid
,const gchar *subid
,GCancellable *cancellable
,GAsyncReadyCallback callback
,gpointer user_data
); gboolean wocky_pubsub_node_unsubscribe_finish (WockyPubsubNode *self
,GAsyncResult *result
,GError **error
); void wocky_pubsub_node_list_affiliates_async (WockyPubsubNode *self
,GCancellable *cancellable
,GAsyncReadyCallback callback
,gpointer user_data
); gboolean wocky_pubsub_node_list_affiliates_finish (WockyPubsubNode *self
,GAsyncResult *result
,GList **affiliates
,GError **error
); void wocky_pubsub_node_list_subscribers_async (WockyPubsubNode *self
,GCancellable *cancellable
,GAsyncReadyCallback callback
,gpointer user_data
); gboolean wocky_pubsub_node_list_subscribers_finish (WockyPubsubNode *self
,GAsyncResult *result
,GList **subscribers
,GError **error
); WockyXmppStanza * wocky_pubsub_node_make_list_affiliates_stanza (WockyPubsubNode *self
,WockyXmppNode **pubsub_node
,WockyXmppNode **affiliations_node
); WockyXmppStanza * wocky_pubsub_node_make_list_subscribers_stanza (WockyPubsubNode *self
,WockyXmppNode **pubsub_node
,WockyXmppNode **subscriptions_node
); GList * wocky_pubsub_node_parse_affiliations (WockyPubsubNode *self
,WockyXmppNode *affiliations_node
); #define WOCKY_TYPE_PUBSUB_AFFILIATION #define WOCKY_TYPE_PUBSUB_AFFILIATION_STATE WockyPubsubAffiliation; enum WockyPubsubAffiliationState; WockyPubsubAffiliation * wocky_pubsub_affiliation_copy (WockyPubsubAffiliation *aff
); void wocky_pubsub_affiliation_free (WockyPubsubAffiliation *aff
); GList * wocky_pubsub_affiliation_list_copy (GList *affs
); void wocky_pubsub_affiliation_list_free (GList *affs
); WockyPubsubAffiliation * wocky_pubsub_affiliation_new (WockyPubsubNode *node
,const gchar *jid
,WockyPubsubAffiliationState state
);
"name" gchar* : Read / Write / Construct Only "service" WockyPubsubService* : Read / Write / Construct Only
const gchar * wocky_pubsub_node_get_name (WockyPubsubNode *self
);
|
|
Returns : |
void wocky_pubsub_node_delete_async (WockyPubsubNode *self
,GCancellable *cancellable
,GAsyncReadyCallback callback
,gpointer user_data
);
|
|
|
|
|
|
|
gboolean wocky_pubsub_node_delete_finish (WockyPubsubNode *self
,GAsyncResult *result
,GError **error
);
|
|
|
|
|
|
Returns : |
WockyXmppStanza * wocky_pubsub_node_make_publish_stanza (WockyPubsubNode *self
,WockyXmppNode **pubsub_out
,WockyXmppNode **publish_out
,WockyXmppNode **item_out
);
|
|
|
|
|
|
|
|
Returns : |
void wocky_pubsub_node_subscribe_async (WockyPubsubNode *self
,const gchar *jid
,GCancellable *cancellable
,GAsyncReadyCallback callback
,gpointer user_data
);
Attempts to subscribe to self
.
WockyPubsubSubscription * wocky_pubsub_node_subscribe_finish (WockyPubsubNode *self
,GAsyncResult *result
,GError **error
);
|
|
|
|
|
|
Returns : |
void wocky_pubsub_node_unsubscribe_async (WockyPubsubNode *self
,const gchar *jid
,const gchar *subid
,GCancellable *cancellable
,GAsyncReadyCallback callback
,gpointer user_data
);
Attempts to unsubscribe from self
.
|
a pubsub node |
|
the JID subscribed to self (usually the connection's bare or
full JID); may not be NULL
|
|
the identifier associated with the subscription |
|
optional GCancellable object, NULL to ignore
|
|
a callback to call when the request is completed |
|
data to pass to callback
|
gboolean wocky_pubsub_node_unsubscribe_finish (WockyPubsubNode *self
,GAsyncResult *result
,GError **error
);
|
|
|
|
|
|
Returns : |
void wocky_pubsub_node_list_affiliates_async (WockyPubsubNode *self
,GCancellable *cancellable
,GAsyncReadyCallback callback
,gpointer user_data
);
Retrieves the list of entities affilied to a node you own. callback
may
complete the call using wocky_pubsub_node_list_affiliates_finish()
.
(A note on naming: this is §8.9.1 — Retrieve Affiliations List — in XEP-0060, not to be confused with §5.7 — Retrieve Affiliations. The slightly different terminology in Wocky is intended to help disambiguate!)
|
a pubsub node |
|
optional GCancellable object |
|
function to call when the affiliates have been retrieved or an error has occured |
|
data to pass to callback .
|
gboolean wocky_pubsub_node_list_affiliates_finish (WockyPubsubNode *self
,GAsyncResult *result
,GList **affiliates
,GError **error
);
Completes a call to wocky_pubsub_node_list_affiliates_async()
. The list
returned in affiliates
should be freed with
wocky_pubsub_affiliation_list_free()
when it is no longer needed.
|
a pubsub node |
|
the result passed to a callback |
|
location at which to store a list of WockyPubsubAffiliation
pointers, or NULL
|
|
location at which to store an error, or NULL
|
Returns : |
TRUE if the list of subscribers was successfully retrieved; FALSE
and sets error if an error occured.
|
void wocky_pubsub_node_list_subscribers_async (WockyPubsubNode *self
,GCancellable *cancellable
,GAsyncReadyCallback callback
,gpointer user_data
);
Retrieves the list of subscriptions to a node you own. callback
may
complete the call using wocky_pubsub_node_list_subscribers_finish()
.
(A note on naming: this is §8.8.1 — Retrieve Subscriptions List — in XEP-0060, not to be confused with §5.6 — Retrieve Subscriptions. The different terminology in Wocky is intended to help disambiguate!)
|
a pubsub node |
|
optional GCancellable object |
|
function to call when the subscribers have been retrieved or an error has occured |
|
data to pass to callback .
|
gboolean wocky_pubsub_node_list_subscribers_finish (WockyPubsubNode *self
,GAsyncResult *result
,GList **subscribers
,GError **error
);
Completes a call to wocky_pubsub_node_list_subscribers_async()
. The list
returned in subscribers
should be freed with
wocky_pubsub_subscription_list_free()
when it is no longer needed.
|
a pubsub node |
|
the result passed to a callback |
|
location at which to store a list of WockyPubsubSubscription
pointers, or NULL
|
|
location at which to store an error, or NULL
|
Returns : |
TRUE if the list of subscribers was successfully retrieved; FALSE
and sets error if an error occured.
|
WockyXmppStanza * wocky_pubsub_node_make_list_affiliates_stanza (WockyPubsubNode *self
,WockyXmppNode **pubsub_node
,WockyXmppNode **affiliations_node
);
|
|
|
|
|
|
Returns : |
WockyXmppStanza * wocky_pubsub_node_make_list_subscribers_stanza (WockyPubsubNode *self
,WockyXmppNode **pubsub_node
,WockyXmppNode **subscriptions_node
);
|
|
|
|
|
|
Returns : |
GList * wocky_pubsub_node_parse_affiliations (WockyPubsubNode *self
,WockyXmppNode *affiliations_node
);
|
|
|
|
Returns : |
#define WOCKY_TYPE_PUBSUB_AFFILIATION_STATE (wocky_pubsub_affiliation_state_get_type())
typedef struct { WockyPubsubNode *node; gchar *jid; WockyPubsubAffiliationState state; } WockyPubsubAffiliation;
typedef enum { WOCKY_PUBSUB_AFFILIATION_OWNER, WOCKY_PUBSUB_AFFILIATION_PUBLISHER, WOCKY_PUBSUB_AFFILIATION_PUBLISH_ONLY, WOCKY_PUBSUB_AFFILIATION_MEMBER, WOCKY_PUBSUB_AFFILIATION_NONE, WOCKY_PUBSUB_AFFILIATION_OUTCAST } WockyPubsubAffiliationState;
WockyPubsubAffiliation * wocky_pubsub_affiliation_copy (WockyPubsubAffiliation *aff
);
|
|
Returns : |
void wocky_pubsub_affiliation_free (WockyPubsubAffiliation *aff
);
|
GList * wocky_pubsub_affiliation_list_copy (GList *affs
);
|
|
Returns : |
WockyPubsubAffiliation * wocky_pubsub_affiliation_new (WockyPubsubNode *node
,const gchar *jid
,WockyPubsubAffiliationState state
);
|
|
|
|
|
|
Returns : |
"name"
property"name" gchar* : Read / Write / Construct Only
The name of the pubsub node.
Default value: NULL
"service"
property"service" WockyPubsubService* : Read / Write / Construct Only
the Wocky Pubsub service associated with this pubsub node.
"deleted"
signalvoid user_function (WockyPubsubNode *node, WockyXmppStanza *stanza, gpointer event_node, gpointer delete_node, gpointer user_data) : Run Last
Emitted when a notification of this node's deletion is received from the server.
|
a pubsub node |
|
the message/event stanza in its entirety |
|
the event node from stanza
|
|
the delete node from stanza
|
|
user data set when the signal handler was connected. |
"event-received"
signalvoid user_function (WockyPubsubNode *node, WockyXmppStanza *event_stanza, gpointer event_node, gpointer items_node, gpointer items, gpointer user_data)
|
a pubsub node |
|
the message/event stanza in its entirity |
|
the event node from the stanza |
|
the items node from the stanza |
|
a list of WockyXmppNode *s for each item child of items_node
|
|
user data set when the signal handler was connected. |
"subscription-state-changed"
signalvoid user_function (WockyPubsubNode *node, WockyXmppStanza *stanza, gpointer event_node, gpointer subscription_node, WockyPubsubSubscription *subscription, gpointer user_data) : Run Last
|
a pubsub node |
|
the message/event stanza in its entirety |
|
the event node from stanza
|
|
the subscription node from stanza
|
|
subscription information parsed from subscription_node
|
|
user data set when the signal handler was connected. |