openDAQ
Open data acquisition platform
MirroredSignalConfigPtr Class Reference

Represents configuration interface for mirrored signals. Allows selecting streaming data sources per signal. More...

+ Inheritance diagram for MirroredSignalConfigPtr:
+ Collaboration diagram for MirroredSignalConfigPtr:

Detailed Description

Represents configuration interface for mirrored signals. Allows selecting streaming data sources per signal.

Public Member Functions

daq::StringPtr getRemoteId () const
 Gets the global ID of the signal as it appears on the remote device. More...
 
daq::ListPtr< daq::IString > getStreamingSources () const
 Gets a list of connection strings of all available streaming sources of the signal. More...
 
void setActiveStreamingSource (const daq::StringPtr &streamingConnectionString) const
 Sets the active streaming source of the signal. More...
 
daq::StringPtr getActiveStreamingSource () const
 Gets a connection strings of the active streaming source of the signal. More...
 
void deactivateStreaming () const
 Stops the streaming and clears the active streaming source of the signal.
 
daq::Event< daq::MirroredSignalConfigPtr, daq::SubscriptionEventArgsPtr > getOnSubscribeComplete () const
 Gets the Event that is triggered whenever the acknowledgment for signal subscription completion is received from the streaming server. More...
 
daq::Event< daq::MirroredSignalConfigPtr, daq::SubscriptionEventArgsPtr > getOnUnsubscribeComplete () const
 Gets the Event that is triggered whenever the acknowledgment for signal unsubscription completion is received from the streaming server. More...
 
- Public Member Functions inherited from GenericSignalConfigPtr< IMirroredSignalConfig >
void setDescriptor (const daq::DataDescriptorPtr &descriptor) const
 Sets the data descriptor. More...
 
void setDomainSignal (const daq::GenericSignalPtr< daq::ISignal > &signal) const
 Sets the domain signal reference. More...
 
void setRelatedSignals (const daq::ListPtr< daq::ISignal > &signals) const
 Sets the list of related signals. More...
 
void addRelatedSignal (const daq::GenericSignalPtr< daq::ISignal > &signal) const
 Adds a related signal to the list of related signals. More...
 
void removeRelatedSignal (const daq::GenericSignalPtr< daq::ISignal > &signal) const
 Removes a signal from the list of related signal. More...
 
void clearRelatedSignals () const
 Clears the list of related signals.
 
void sendPacket (const daq::PacketPtr &packet) const
 Sends a packet through all connections of the signal. More...
 
void sendPacket (daq::PacketPtr &&packet) const
 Sends a packet through all connections of the signal. Ownership of the packet is transfered. More...
 
void sendPackets (const daq::ListPtr< daq::IPacket > &packets) const
 Sends multiple packets through all connections of the signal. More...
 
void sendPackets (daq::ListPtr< daq::IPacket > &&packets) const
 Sends multiple packets through all connections of the signal. Ownership of the packets is transfered. More...
 

Member Function Documentation

◆ getActiveStreamingSource()

daq::StringPtr getActiveStreamingSource ( ) const
inline

Gets a connection strings of the active streaming source of the signal.

Returns
The connection string of active streaming source.

◆ getOnSubscribeComplete()

daq::Event<daq::MirroredSignalConfigPtr, daq::SubscriptionEventArgsPtr> getOnSubscribeComplete ( ) const
inline

Gets the Event that is triggered whenever the acknowledgment for signal subscription completion is received from the streaming server.

Returns
The Event representing the acknowledgment of signal subscription completion.

A handler can be added to the event containing a callback function which is invoked whenever the event is triggered. The callback function requires two parameters - a MirroredSignalConfig object, as well as a "Subscription event args" object. The callback will be invoked with the MirroredSignalConfig object as the first argument, the second argument holds an event args object that contains the connection string of streaming and the event type (Subscribed).

◆ getOnUnsubscribeComplete()

daq::Event<daq::MirroredSignalConfigPtr, daq::SubscriptionEventArgsPtr> getOnUnsubscribeComplete ( ) const
inline

Gets the Event that is triggered whenever the acknowledgment for signal unsubscription completion is received from the streaming server.

Returns
The Event representing the acknowledgment of signal unsubscription completion.

A handler can be added to the event containing a callback function which is invoked whenever the event is triggered. The callback function requires two parameters - a MirroredSignalConfig object, as well as a "Subscription event args" object. The callback will be invoked with the MirroredSignalConfig object as the first argument, the second argument holds an event args object that contains the connection string of streaming and the event type (Unsubscribed).

◆ getRemoteId()

daq::StringPtr getRemoteId ( ) const
inline

Gets the global ID of the signal as it appears on the remote device.

Returns
The signal id.

◆ getStreamingSources()

daq::ListPtr<daq::IString> getStreamingSources ( ) const
inline

Gets a list of connection strings of all available streaming sources of the signal.

Returns
The list of streaming connection strings.

◆ setActiveStreamingSource()

void setActiveStreamingSource ( const daq::StringPtr &  streamingConnectionString) const
inline

Sets the active streaming source of the signal.

Parameters
streamingConnectionStringThe connection string of streaming source to be set as active.
Exceptions
NotFoundExceptionif the streaming source with the corresponding connection string is not * part of the available streaming sources for the signal.