Keeps track of the clients multiple calls to subscribe.
Chooses the most appropriate settings to send messages
Method | __init__ |
Create a subscription for the specified client on the specified topic, with callback publish |
Method | is |
Return true if there are no subscriptions currently |
Method | on |
Raw callback called by subscription manager for all incoming messages. |
Method | subscribe |
Add another client's subscription request |
Method | unregister |
Unsubscribes this subscription and cleans up resources |
Method | unsubscribe |
Unsubscribe this particular client's subscription |
Method | update |
Determine the 'lowest common denominator' params to satisfy all subscribed clients. |
Instance Variable | client |
Undocumented |
Instance Variable | clients |
Undocumented |
Instance Variable | compression |
Undocumented |
Instance Variable | fragment |
Undocumented |
Instance Variable | handler |
Undocumented |
Instance Variable | handler |
Undocumented |
Instance Variable | publish |
Undocumented |
Instance Variable | queue |
Undocumented |
Instance Variable | throttle |
Undocumented |
Instance Variable | topic |
Undocumented |
Method | _publish |
Internal method to propagate published messages to the registered publish callback |
Create a subscription for the specified client on the specified topic, with callback publish
Keyword arguments: client_id -- the ID of the client making this subscription topic -- the name of the topic to subscribe to publish -- the callback function for incoming messages
Raw callback called by subscription manager for all incoming messages.
Incoming messages are passed to the message handler which may drop, buffer, or propagate the message
Add another client's subscription request
If there are multiple calls to subscribe, the values actually used for queue_length, fragment_size, compression and throttle_rate are chosen to encompass all subscriptions' requirements
Keyword arguments: sid -- the subscription id from the client msg_type -- the type of the message to subscribe to throttle_rate -- the minimum time (in ms) allowed between messages being sent. If multiple subscriptions, the lower of these is used queue_length -- the number of messages that can be buffered. If multiple subscriptions, the lower of these is used fragment_size -- None if no fragmentation, or the maximum length of allowed outgoing messages compression -- "none" if no compression, or some other value if compression is to be used (current valid values are 'png')
Unsubscribe this particular client's subscription
Keyword arguments: sid -- the individual subscription id. If None, all are unsubscribed