Robot Raconteur Companion C++ Library
Loading...
Searching...
No Matches
RobotRaconteur::Companion::Util::DeviceConnectorDetails Struct Reference

Device connection information for use with DeviceConnector class. More...

#include <DeviceConnector.h>

Public Member Functions

 DeviceConnectorDetails ()=default
 Construct an empty DeviceConnectorDetails.
 DeviceConnectorDetails (const std::string &device_nickname)
 Construct a new DeviceConnectorDetails with nickname.
 DeviceConnectorDetails (const std::string &device_nickname, const com::robotraconteur::identifier::IdentifierPtr &device, const std::vector< std::string > &root_object_type, const std::vector< com::robotraconteur::identifier::IdentifierPtr > &tags={}, const std::vector< RobotRaconteur::ServiceSubscriptionFilterNodePtr > &service_nodes={})
 Construct a new DeviceConnectorDetails for use with "device" identifier.
 DeviceConnectorDetails (const std::string &device_nickname, const std::string &url, const RobotRaconteur::ServiceSubscriptionFilterNodePtr &url_auth=nullptr)
 Construct a new DeviceConnectorDetails for use with URL connection.
 DeviceConnectorDetails (const std::string &device_nickname, const std::vector< std::string > &root_object_type, const RobotRaconteur::ServiceSubscriptionFilterPtr &subscription_filter)
 Construct a new DeviceConnectorDetails for use with Robot Raconteur subscription filter.

Public Attributes

std::string DeviceNickname
 The nickname of the device.
com::robotraconteur::identifier::IdentifierPtr Device
 The device identifier (name, uuid) of the device. null if not used.
std::string SerialNumber
 The serial number of the device. Empty if not used.
std::vector< com::robotraconteur::identifier::IdentifierPtr > Tags
 The tags of the device. Empty if not used.
std::vector< RobotRaconteur::ServiceSubscriptionFilterNodePtr > ServiceNodes
 The service nodes of the device. Empty if not used.
std::vector< std::string > Urls
 A list of URLs to use for direct connection to the device. Empty if not used.
std::vector< std::string > RootObjectType
 The root object type of the device. Empty if not used. May be necessary when "device" is used.
RobotRaconteur::ServiceSubscriptionFilterPtr SubscriptionFilter
 The subscription filter to use when connecting to the device. Not used with Url or "device".
std::vector< std::string > TransportSchemes
 The transport schemes to use when connecting to the device. Not used with Url or Filter.
RobotRaconteur::ServiceSubscriptionFilterNodePtr UrlAuth
 The URL auth to use when connecting to the device. Not used with Filter or "device".
int32_t MaxConnections = 10
 The maximum number of connections to the device. 0 for unlimited. Defaults to 10.
RobotRaconteur::ServiceSubscriptionFilterAttributeGroupOperation TagMatchOperation
 The tag match operation to use with Tags. Defaults to "AND".

Detailed Description

Device connection information for use with DeviceConnector class.

The DeviceConnectorDetails contains information that is used by the DeviceConnector class to connect to devices. The DeviceConnector can connect to devicues using three different methods:

  1. Discovery devices using device identifier (name, uuid) in combination with optional serial number and/or device tags
  2. Connection using a list of URLs. Using URLs is the most direct way to connect to a device.
  3. Connection using specified list of service root object types and optional subscription filter.

Different combinations of fields are valid depending on the connection method used. See the DeviceConnector documentation for more information on how to use the DeviceConnectorDetails class.

Constructor & Destructor Documentation

◆ DeviceConnectorDetails() [1/4]

RobotRaconteur::Companion::Util::DeviceConnectorDetails::DeviceConnectorDetails ( const std::string & device_nickname)

Construct a new DeviceConnectorDetails with nickname.

Parameters
device_nicknameThe nickname of the device

◆ DeviceConnectorDetails() [2/4]

RobotRaconteur::Companion::Util::DeviceConnectorDetails::DeviceConnectorDetails ( const std::string & device_nickname,
const com::robotraconteur::identifier::IdentifierPtr & device,
const std::vector< std::string > & root_object_type,
const std::vector< com::robotraconteur::identifier::IdentifierPtr > & tags = {},
const std::vector< RobotRaconteur::ServiceSubscriptionFilterNodePtr > & service_nodes = {} )

Construct a new DeviceConnectorDetails for use with "device" identifier.

Parameters
device_nicknameThe nickname of the device
deviceThe identifier of the desired device
root_object_typeThe root object type of the device. Defaults to com::robotraconteur::device::Device. In most cases it will be necessary to specify this, otherwise only the Device object will be available.
tagsAn optional list of tags to match when connecting to the device with "AND" operation.
service_nodesAn optional list of service nodes to match including authentication information.

◆ DeviceConnectorDetails() [3/4]

RobotRaconteur::Companion::Util::DeviceConnectorDetails::DeviceConnectorDetails ( const std::string & device_nickname,
const std::string & url,
const RobotRaconteur::ServiceSubscriptionFilterNodePtr & url_auth = nullptr )

Construct a new DeviceConnectorDetails for use with URL connection.

Parameters
device_nicknameThe nickname of the device
urlThe URL to connect to
url_authAuthentication information for the URL connection

◆ DeviceConnectorDetails() [4/4]

RobotRaconteur::Companion::Util::DeviceConnectorDetails::DeviceConnectorDetails ( const std::string & device_nickname,
const std::vector< std::string > & root_object_type,
const RobotRaconteur::ServiceSubscriptionFilterPtr & subscription_filter )

Construct a new DeviceConnectorDetails for use with Robot Raconteur subscription filter.

Parameters
device_nicknameThe nickname of the device
root_object_typeThe desired root object types
subscription_filterThe subscription filter

The documentation for this struct was generated from the following file: