iceoryx2
C++ Bindings
Loading...
Searching...
No Matches
iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S > Class Template Reference

Builder to create new [MessagingPattern::PublishSubscribe] based [Service]s. More...

#include <service_builder_publish_subscribe.hpp>

Public Member Functions

auto payload_alignment (const uint64_t value) -> decltype(auto)
auto enable_safe_overflow (const bool value) -> decltype(auto)
auto subscriber_max_borrowed_samples (const uint64_t value) -> decltype(auto)
auto history_size (const uint64_t value) -> decltype(auto)
auto subscriber_max_buffer_size (const uint64_t value) -> decltype(auto)
auto max_subscribers (const uint64_t value) -> decltype(auto)
auto max_publishers (const uint64_t value) -> decltype(auto)
auto max_nodes (const uint64_t value) -> decltype(auto)
 ServiceBuilderPublishSubscribe (ServiceBuilderPublishSubscribe &&rhs) noexcept
auto operator= (ServiceBuilderPublishSubscribe &&rhs) noexcept -> ServiceBuilderPublishSubscribe &
 ~ServiceBuilderPublishSubscribe ()
 ServiceBuilderPublishSubscribe (const ServiceBuilderPublishSubscribe &)=delete
auto operator= (const ServiceBuilderPublishSubscribe &) -> ServiceBuilderPublishSubscribe &=delete
template<typename U = Payload, typename = std::enable_if_t<has_flatbuffer_marker<U>(), void>>
auto flatbuffer_schema_path (const bb::FilePath &value) &&-> ServiceBuilderPublishSubscribe< U, UserHeader, S > &&
template<typename NewHeader>
auto user_header () &&-> ServiceBuilderPublishSubscribe< Payload, NewHeader, S > &&
 Sets the user header type of the [Service].
auto resume_build () &-> ServiceBuilderPublishSubscribe< Payload, UserHeader, S > &&
auto open_or_create () &&-> bb::Expected< PortFactoryPublishSubscribe< S, Payload, UserHeader >, PublishSubscribeOpenOrCreateError >
auto open_or_create_with_attributes (const AttributeVerifier &required_attributes) &&-> bb::Expected< PortFactoryPublishSubscribe< S, Payload, UserHeader >, PublishSubscribeOpenOrCreateError >
auto open () &&-> bb::Expected< PortFactoryPublishSubscribe< S, Payload, UserHeader >, PublishSubscribeOpenError >
 Opens an existing [Service].
auto open_with_attributes (const AttributeVerifier &required_attributes) &&-> bb::Expected< PortFactoryPublishSubscribe< S, Payload, UserHeader >, PublishSubscribeOpenError >
auto create () &&-> bb::Expected< PortFactoryPublishSubscribe< S, Payload, UserHeader >, PublishSubscribeCreateError >
 Creates a new [Service].
auto create_with_attributes (const AttributeSpecifier &attributes) &&-> bb::Expected< PortFactoryPublishSubscribe< S, Payload, UserHeader >, PublishSubscribeCreateError >
 Creates a new [Service] with a set of attributes.

Friends

template<ServiceType>
class ServiceBuilder
template<typename P, typename U, ServiceType St>
auto set_payload_type_details (ServiceBuilderPublishSubscribe< P, U, St > &builder, const TypeDetail &value) -> std::enable_if_t< std::is_same< P, bb::Slice< CustomPayloadMarker > >::value >
template<typename P, typename U, ServiceType St>
auto set_user_header_type_details (ServiceBuilderPublishSubscribe< P, U, St > &builder, const TypeDetail &value) -> std::enable_if_t< std::is_same< U, CustomHeaderMarker >::value >

Detailed Description

template<typename Payload, typename UserHeader, ServiceType S>
class iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >

Builder to create new [MessagingPattern::PublishSubscribe] based [Service]s.

Definition at line 69 of file service_builder_publish_subscribe.hpp.

Constructor & Destructor Documentation

◆ ServiceBuilderPublishSubscribe() [1/2]

template<typename Payload, typename UserHeader, ServiceType S>
iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::ServiceBuilderPublishSubscribe ( ServiceBuilderPublishSubscribe< Payload, UserHeader, S > && rhs)
inlinenoexcept

◆ ~ServiceBuilderPublishSubscribe()

template<typename Payload, typename UserHeader, ServiceType S>
iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::~ServiceBuilderPublishSubscribe ( )
inline

Definition at line 267 of file service_builder_publish_subscribe.hpp.

◆ ServiceBuilderPublishSubscribe() [2/2]

template<typename Payload, typename UserHeader, ServiceType S>
iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::ServiceBuilderPublishSubscribe ( const ServiceBuilderPublishSubscribe< Payload, UserHeader, S > & )
delete

Member Function Documentation

◆ create()

template<typename Payload, typename UserHeader, ServiceType S>
auto iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::create ( ) &&->bb::Expected< PortFactoryPublishSubscribe< S, Payload, UserHeader >, PublishSubscribeCreateError >
inline

Creates a new [Service].

Definition at line 472 of file service_builder_publish_subscribe.hpp.

References iox2::bb::err(), and iox2::bb::into().

◆ create_with_attributes()

template<typename Payload, typename UserHeader, ServiceType S>
auto iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::create_with_attributes ( const AttributeSpecifier & attributes) &&->bb::Expected< PortFactoryPublishSubscribe< S, Payload, UserHeader >, PublishSubscribeCreateError >
inline

Creates a new [Service] with a set of attributes.

Definition at line 526 of file service_builder_publish_subscribe.hpp.

References iox2::bb::err(), and iox2::bb::into().

◆ enable_safe_overflow()

template<typename Payload, typename UserHeader, ServiceType S>
auto iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::enable_safe_overflow ( const bool value) ->decltype(auto)

If the [Service] is created, defines the overflow behavior of the service. If an existing [Service] is opened it requires the service to have the defined overflow behavior.

References enable_safe_overflow().

Referenced by enable_safe_overflow().

◆ flatbuffer_schema_path()

template<typename Payload, typename UserHeader, ServiceType S>
template<typename U, typename>
auto iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::flatbuffer_schema_path ( const bb::FilePath & value) &&->ServiceBuilderPublishSubscribe< U, UserHeader, S > &&
inline

Sets the path to the flatbuffer schema file. If this is not explicitly defined, iceoryx2 will try to find the best fitting schema file in the configured flatbuffer schema paths defined in the config.

Definition at line 413 of file service_builder_publish_subscribe.hpp.

References ServiceBuilderPublishSubscribe().

◆ history_size()

template<typename Payload, typename UserHeader, ServiceType S>
auto iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::history_size ( const uint64_t value) ->decltype(auto)

If the [Service] is created it defines the maximum history size a [Subscriber] can request on connection. If an existing [Service] is opened it defines the minimum required.

References history_size().

Referenced by history_size().

◆ max_nodes()

template<typename Payload, typename UserHeader, ServiceType S>
auto iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::max_nodes ( const uint64_t value) ->decltype(auto)

If the [Service] is created it defines how many [Node]s shall be able to open it in parallel. If an existing [Service] is opened it defines how many [Node]s must be at least supported.

References max_nodes(), and ServiceBuilderPublishSubscribe().

Referenced by max_nodes().

◆ max_publishers()

template<typename Payload, typename UserHeader, ServiceType S>
auto iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::max_publishers ( const uint64_t value) ->decltype(auto)

If the [Service] is created it defines how many [Publisher] shall be supported at most. If an existing [Service] is opened it defines how many [Publisher] must be at least supported.

References max_publishers().

Referenced by max_publishers().

◆ max_subscribers()

template<typename Payload, typename UserHeader, ServiceType S>
auto iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::max_subscribers ( const uint64_t value) ->decltype(auto)

If the [Service] is created it defines how many [Subscriber] shall be supported at most. If an existing [Service] is opened it defines how many [Subscriber] must be at least supported.

References max_subscribers().

Referenced by max_subscribers().

◆ open()

template<typename Payload, typename UserHeader, ServiceType S>
auto iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::open ( ) &&->bb::Expected< PortFactoryPublishSubscribe< S, Payload, UserHeader >, PublishSubscribeOpenError >
inline

Opens an existing [Service].

Definition at line 456 of file service_builder_publish_subscribe.hpp.

References iox2::bb::err(), and iox2::bb::into().

◆ open_or_create()

template<typename Payload, typename UserHeader, ServiceType S>
auto iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::open_or_create ( ) &&->bb::Expected< PortFactoryPublishSubscribe< S, Payload, UserHeader >, PublishSubscribeOpenOrCreateError >
inline

If the [Service] exists, it will be opened otherwise a new [Service] will be created.

Definition at line 440 of file service_builder_publish_subscribe.hpp.

References iox2::bb::err(), and iox2::bb::into().

◆ open_or_create_with_attributes()

template<typename Payload, typename UserHeader, ServiceType S>
auto iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::open_or_create_with_attributes ( const AttributeVerifier & required_attributes) &&->bb::Expected< PortFactoryPublishSubscribe< S, Payload, UserHeader >, PublishSubscribeOpenOrCreateError >
inline

If the [Service] exists, it will be opened otherwise a new [Service] will be created. It defines a set of attributes. If the [Service] already exists all attribute requirements must be satisfied otherwise the open process will fail. If the [Service] does not exist the required attributes will be defined in the [Service].

Definition at line 488 of file service_builder_publish_subscribe.hpp.

References iox2::bb::err(), and iox2::bb::into().

◆ open_with_attributes()

template<typename Payload, typename UserHeader, ServiceType S>
auto iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::open_with_attributes ( const AttributeVerifier & required_attributes) &&->bb::Expected< PortFactoryPublishSubscribe< S, Payload, UserHeader >, PublishSubscribeOpenError >
inline

Opens an existing [Service] with attribute requirements. If the defined attribute requirements are not satisfied the open process will fail.

Definition at line 507 of file service_builder_publish_subscribe.hpp.

References iox2::bb::err(), and iox2::bb::into().

◆ operator=() [1/2]

template<typename Payload, typename UserHeader, ServiceType S>
auto iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::operator= ( const ServiceBuilderPublishSubscribe< Payload, UserHeader, S > & ) ->ServiceBuilderPublishSubscribe &=delete
delete

◆ operator=() [2/2]

template<typename Payload, typename UserHeader, ServiceType S>
auto iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::operator= ( ServiceBuilderPublishSubscribe< Payload, UserHeader, S > && rhs) ->ServiceBuilderPublishSubscribe &
inlinenoexcept

◆ payload_alignment()

template<typename Payload, typename UserHeader, ServiceType S>
auto iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::payload_alignment ( const uint64_t value) ->decltype(auto)

If the [Service] is created, it defines the [Alignment] of the payload for the service. If an existing [Service] is opened it requires the service to have at least the defined [Alignment]. If the Payload [Alignment] is greater than the provided [Alignment] then the Payload [Alignment] is used.

References payload_alignment().

Referenced by payload_alignment().

◆ resume_build()

template<typename Payload, typename UserHeader, ServiceType S>
auto iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::resume_build ( ) &->ServiceBuilderPublishSubscribe< Payload, UserHeader, S > &&
inline

Returns the builder as an r-value so the fluent chain can be resumed after a free function, such as [set_payload_type_details()] or [set_user_header_type_details()], has been applied to the named builder.

Definition at line 420 of file service_builder_publish_subscribe.hpp.

References ServiceBuilderPublishSubscribe().

◆ subscriber_max_borrowed_samples()

template<typename Payload, typename UserHeader, ServiceType S>
auto iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::subscriber_max_borrowed_samples ( const uint64_t value) ->decltype(auto)

If the [Service] is created it defines how many [Sample]s a [Subscriber] can borrow at most in parallel. If an existing [Service] is opened it defines the minimum required.

References subscriber_max_borrowed_samples().

Referenced by subscriber_max_borrowed_samples().

◆ subscriber_max_buffer_size()

template<typename Payload, typename UserHeader, ServiceType S>
auto iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::subscriber_max_buffer_size ( const uint64_t value) ->decltype(auto)

If the [Service] is created it defines how many [Sample] a Subscriber can store in its internal buffer. If an existing [Service] is opened it defines the minimum required.

References subscriber_max_buffer_size().

Referenced by subscriber_max_buffer_size().

◆ user_header()

template<typename Payload, typename UserHeader, ServiceType S>
template<typename NewHeader>
auto iox2::ServiceBuilderPublishSubscribe< Payload, UserHeader, S >::user_header ( ) &&->ServiceBuilderPublishSubscribe< Payload, NewHeader, S > &&
inline

Sets the user header type of the [Service].

Definition at line 403 of file service_builder_publish_subscribe.hpp.

References ServiceBuilderPublishSubscribe().

◆ ServiceBuilder

template<typename Payload, typename UserHeader, ServiceType S>
template<ServiceType>
friend class ServiceBuilder
friend

Definition at line 195 of file service_builder_publish_subscribe.hpp.

References ServiceBuilder.

Referenced by ServiceBuilder.

◆ set_payload_type_details

template<typename Payload, typename UserHeader, ServiceType S>
template<typename P, typename U, ServiceType St>
auto set_payload_type_details ( ServiceBuilderPublishSubscribe< P, U, St > & builder,
const TypeDetail & value )->std::enable_if_t< std::is_same< P, bb::Slice< CustomPayloadMarker > >::value >
friend

◆ set_user_header_type_details

template<typename Payload, typename UserHeader, ServiceType S>
template<typename P, typename U, ServiceType St>
auto set_user_header_type_details ( ServiceBuilderPublishSubscribe< P, U, St > & builder,
const TypeDetail & value )->std::enable_if_t< std::is_same< U, CustomHeaderMarker >::value >
friend

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