- class TMSiSDK.sample_data_server.sample_data_server.SampleDataServer(*args, **kwargs)#
Bases:
object
- __init__()#
Methods
__init__
()Gets the list of available consumer.
Gets the list of available event consumer.
put_event_data
(id, data)Puts event in the corresponding event consumer.
put_sample_data
(id, data)Puts data in the corresponding consumer.
register_consumer
(id, q)Creates the new consumer and registers it to the list of consumers.
register_event_consumer
(id, q)Creates the new event consumer and registers it to the list of event consumers.
unregister_consumer
(id, q)Unregister the queue from the list of consumers.
unregister_event_consumer
(id, q)Unregister the queue from the list of event consumers.
- get_consumer_list() list #
Gets the list of available consumer.
- Returns:
list of available consumers.
- Return type:
list[SampleDataConsumer]
- get_event_consumer_list() list #
Gets the list of available event consumer.
- Returns:
list of available event consumers.
- Return type:
list[EventDataConsumer]
- put_event_data(id: int, data: EventData)#
Puts event in the corresponding event consumer.
- Parameters:
id (int) – id of the provider the event consumer is reading.
data (EventData) – event to deliver to the event consumer.
- put_sample_data(id: int, data: SampleData)#
Puts data in the corresponding consumer.
- Parameters:
id (int) – id of the provider the consumer is reading.
data (SampleData) – data to deliver to the consumer.
- register_consumer(id: int, q: Queue)#
Creates the new consumer and registers it to the list of consumers.
- Parameters:
id (int) – id of the provider.
q (Queue) – queue of the consumer.
- register_event_consumer(id: int, q: Queue)#
Creates the new event consumer and registers it to the list of event consumers.
- Parameters:
id (int) – id of the provider.
q (Queue) – queue of the event consumer.
- unregister_consumer(id: int, q: Queue)#
Unregister the queue from the list of consumers.
- Parameters:
id (int) – id of the provider.
q (Queue) – queue of the consumer.
- unregister_event_consumer(id: int, q: Queue)#
Unregister the queue from the list of event consumers.
- Parameters:
id (int) – id of the provider.
q (Queue) – queue of the event consumer.