Infinity.CommunicationRegistry¶
| Subclasses: | None | 
|---|
Methods¶
| Inherited: | GObject.Object (37) | 
|---|---|
| Structs: | GObject.ObjectClass (5) | 
| cancel_messages(group, connection) | |
| is_registered(group, connection) | |
| register(group, method, connection) | |
| send(group, connection, xml) | |
| unregister(group, connection) | 
Virtual Methods¶
| Inherited: | GObject.Object (7) | 
|---|
Properties¶
None
Signals¶
| Inherited: | GObject.Object (1) | 
|---|
Class Details¶
- 
class Infinity.CommunicationRegistry(**kwargs)¶
- Bases: - GObject.Object- Abstract: - No - Structure: - Infinity.CommunicationRegistryClass- Infinity.CommunicationRegistryis an opaque data type. You should only access it via the public API functions.- 
cancel_messages(group, connection)¶
- Parameters: - group (Infinity.CommunicationGroup) – The group for which to cancel messages.
- connection (Infinity.XmlConnection) – A registeredInfinity.XmlConnection.
 - Stops all messages scheduled to be sent to connection in group from being sent. 
- group (
 - 
is_registered(group, connection)¶
- Parameters: - group (Infinity.CommunicationGroup) – The group for which to check whether connection is registered.
- connection (Infinity.XmlConnection) – The connection to check for registration.
 - Returns: - Return type: - Returns whether connection has been registered for group with - Infinity.CommunicationRegistry.register().
- group (
 - 
register(group, method, connection)¶
- Parameters: - group (Infinity.CommunicationGroup) – The group for which to register a connection.
- method (Infinity.CommunicationMethod) – TheInfinity.CommunicationMethodused.
- connection (Infinity.XmlConnection) – The connection to register.
 - Registers connection with group. This allows sending messages to connection via - Infinity.CommunicationRegistry.send(). For received messages,- Infinity.CommunicationMethod.received() is called on method.- connection must have status - Infinity.XmlConnectionStatus.OPEN.
- group (
 - 
send(group, connection, xml)¶
- Parameters: - group (Infinity.CommunicationGroup) – The group for which to send the messageInfinity.CommunicationGroup.
- connection (Infinity.XmlConnection) – A registeredInfinity.XmlConnection.
- xml (libxml2.NodePtr) – The message to send.
 - Sends an XML message to connection. connection must have been registered with - Infinity.CommunicationRegistry.register() before. If the message has been sent,- Infinity.CommunicationMethod.sent() is called on the method the connection was registered with.- Infinity.CommunicationMethod.enqueued() is called when sending the message can no longer be cancelled via- Infinity.CommunicationRegistry.cancel_messages().- This function takes ownership of xml. 
- group (
 - 
unregister(group, connection)¶
- Parameters: - group (Infinity.CommunicationGroup) – The group for which to unregister a connection.
- connection (Infinity.XmlConnection) – The connection to unregister.
 - Unregisters connection from group. Incoming messages are no longer reported to group’s method, and - Infinity.CommunicationRegistry.send() can no longer be called for connection.
- group (
 
-