iceoryx2
C++ Language Bindings
Loading...
Searching...
No Matches
iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S > Class Template Reference

#include <service_builder_request_response.hpp>

Public Member Functions

auto request_payload_alignment (const uint64_t value) -> decltype(auto)
 
auto response_payload_alignment (const uint64_t value) -> decltype(auto)
 
auto enable_safe_overflow_for_requests (const bool value) -> decltype(auto)
 
auto enable_safe_overflow_for_responses (const bool value) -> decltype(auto)
 
auto max_active_requests_per_client (const uint64_t value) -> decltype(auto)
 
auto max_response_buffer_size (const uint64_t value) -> decltype(auto)
 
auto max_servers (const uint64_t value) -> decltype(auto)
 
auto max_clients (const uint64_t value) -> decltype(auto)
 
auto max_nodes (const uint64_t value) -> decltype(auto)
 
auto max_borrowed_responses_per_pending_response (const uint64_t value) -> decltype(auto)
 
auto max_loaned_requests (const uint64_t value) -> decltype(auto)
 
auto enable_fire_and_forget_requests (const bool value) -> decltype(auto)
 If the [Service] is created, defines the fire-and-forget behavior of the service for requests.
 
template<typename NewRequestUserHeader >
auto request_user_header () &&-> ServiceBuilderRequestResponse< RequestPayload, NewRequestUserHeader, ResponsePayload, ResponseUserHeader, S > &&
 Sets the request user header type of the [Service].
 
template<typename NewResponseUserHeader >
auto response_user_header () &&-> ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, NewResponseUserHeader, S > &&
 Sets the response user header type of the [Service].
 
auto resume_build () &-> ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S > &&
 
auto open_or_create () &&-> bb::Expected< PortFactoryRequestResponse< S, RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader >, RequestResponseOpenOrCreateError >
 
auto open_or_create_with_attributes (const AttributeVerifier &required_attributes) &&-> bb::Expected< PortFactoryRequestResponse< S, RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader >, RequestResponseOpenOrCreateError >
 
auto open () &&-> bb::Expected< PortFactoryRequestResponse< S, RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader >, RequestResponseOpenError >
 Opens an existing [Service].
 
auto open_with_attributes (const AttributeVerifier &required_attributes) &&-> bb::Expected< PortFactoryRequestResponse< S, RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader >, RequestResponseOpenError >
 
auto create () &&-> bb::Expected< PortFactoryRequestResponse< S, RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader >, RequestResponseCreateError >
 Creates a new [Service].
 
auto create_with_attributes (const AttributeSpecifier &attributes) &&-> bb::Expected< PortFactoryRequestResponse< S, RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader >, RequestResponseCreateError >
 Creates a new [Service] with a set of attributes.
 

Friends

template<ServiceType >
class ServiceBuilder
 
template<typename ReqP , typename ReqH , typename ResP , typename ResH , ServiceType St>
auto set_request_header_type_details (ServiceBuilderRequestResponse< ReqP, ReqH, ResP, ResH, St > &builder, const TypeDetail &value) -> std::enable_if_t< std::is_same< ReqH, CustomHeaderMarker >::value >
 
template<typename ReqP , typename ReqH , typename ResP , typename ResH , ServiceType St>
auto set_response_header_type_details (ServiceBuilderRequestResponse< ReqP, ReqH, ResP, ResH, St > &builder, const TypeDetail &value) -> std::enable_if_t< std::is_same< ResH, CustomHeaderMarker >::value >
 
template<typename ReqP , typename ReqH , typename ResP , typename ResH , ServiceType St>
auto set_request_payload_type_details (ServiceBuilderRequestResponse< ReqP, ReqH, ResP, ResH, St > &builder, const TypeDetail &value) -> std::enable_if_t< std::is_same< ReqP, bb::Slice< CustomPayloadMarker > >::value >
 
template<typename ReqP , typename ReqH , typename ResP , typename ResH , ServiceType St>
auto set_response_payload_type_details (ServiceBuilderRequestResponse< ReqP, ReqH, ResP, ResH, St > &builder, const TypeDetail &value) -> std::enable_if_t< std::is_same< ResP, bb::Slice< CustomPayloadMarker > >::value >
 

Detailed Description

template<typename RequestPayload, typename RequestUserHeader, typename ResponsePayload, typename ResponseUserHeader, ServiceType S>
class iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S >

Definition at line 122 of file service_builder_request_response.hpp.

Member Function Documentation

◆ create()

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
auto iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S >::create ( ) && -> bb::Expected< PortFactoryRequestResponse<S, RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader>, RequestResponseCreateError>
inline

Creates a new [Service].

Definition at line 487 of file service_builder_request_response.hpp.

References iox2::bb::err().

◆ create_with_attributes()

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
auto iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S >::create_with_attributes ( const AttributeSpecifier attributes) && -> bb::Expected< PortFactoryRequestResponse<S, RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader>, RequestResponseCreateError>
inline

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

Definition at line 509 of file service_builder_request_response.hpp.

References iox2::bb::err().

◆ enable_fire_and_forget_requests()

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
auto iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S >::enable_fire_and_forget_requests ( const bool  value) -> decltype(auto)

If the [Service] is created, defines the fire-and-forget behavior of the service for requests.

◆ enable_safe_overflow_for_requests()

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
auto iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S >::enable_safe_overflow_for_requests ( const bool  value) -> decltype(auto)

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

◆ enable_safe_overflow_for_responses()

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
auto iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S >::enable_safe_overflow_for_responses ( const bool  value) -> decltype(auto)

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

◆ max_active_requests_per_client()

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
auto iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S >::max_active_requests_per_client ( const uint64_t  value) -> decltype(auto)

Defines how many active requests a [Server] can hold in parallel per [Client]. The objects are used to send answers to a request that was received earlier from a [Client]

◆ max_borrowed_responses_per_pending_response()

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
auto iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S >::max_borrowed_responses_per_pending_response ( const uint64_t  value) -> decltype(auto)

If the [Service] is created it defines how many [Response]s shall be able to be borrowed in parallel per [PendingResponse]. If an existing [Service] is opened it defines how many borrows must be at least supported.

◆ max_clients()

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
auto iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S >::max_clients ( const uint64_t  value) -> decltype(auto)

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

◆ max_loaned_requests()

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
auto iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S >::max_loaned_requests ( const uint64_t  value) -> decltype(auto)

If the [Service] is created it defines how many [RequestMut] a [Client] can loan in parallel.

◆ max_nodes()

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
auto iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, 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.

◆ max_response_buffer_size()

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
auto iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S >::max_response_buffer_size ( const uint64_t  value) -> decltype(auto)

If the [Service] is created it defines how many responses fit in the [Clients]s buffer. If an existing [Service] is opened it defines the minimum required.

◆ max_servers()

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
auto iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S >::max_servers ( const uint64_t  value) -> decltype(auto)

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

◆ open()

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
auto iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S >::open ( ) && -> bb::Expected< PortFactoryRequestResponse<S, RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader>, RequestResponseOpenError>
inline

Opens an existing [Service].

Definition at line 442 of file service_builder_request_response.hpp.

References iox2::bb::err().

◆ open_or_create()

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
auto iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S >::open_or_create ( ) && -> bb::Expected< PortFactoryRequestResponse<S, RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader>, RequestResponseOpenOrCreateError>
inline

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

Definition at line 397 of file service_builder_request_response.hpp.

References iox2::bb::err().

◆ open_or_create_with_attributes()

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
auto iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S >::open_or_create_with_attributes ( const AttributeVerifier required_attributes) && -> bb::Expected< PortFactoryRequestResponse<S, RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader>, RequestResponseOpenOrCreateError>
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, and service payload type must be the same, otherwise the open process will fail. If the [Service] does not exist the required attributes will be defined in the [Service].

Definition at line 419 of file service_builder_request_response.hpp.

References iox2::bb::err().

◆ open_with_attributes()

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
auto iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S >::open_with_attributes ( const AttributeVerifier required_attributes) && -> bb::Expected< PortFactoryRequestResponse<S, RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader>, RequestResponseOpenError>
inline

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

Definition at line 464 of file service_builder_request_response.hpp.

References iox2::bb::err().

◆ request_payload_alignment()

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
auto iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S >::request_payload_alignment ( const uint64_t  value) -> decltype(auto)

If the [Service] is created, it defines the request [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.

◆ request_user_header()

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
template<typename NewRequestUserHeader >
auto iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S >::request_user_header ( ) && -> ServiceBuilderRequestResponse<RequestPayload, NewRequestUserHeader, ResponsePayload, ResponseUserHeader, S>&&
inline

Sets the request user header type of the [Service].

Definition at line 340 of file service_builder_request_response.hpp.

◆ response_payload_alignment()

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
auto iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S >::response_payload_alignment ( const uint64_t  value) -> decltype(auto)

If the [Service] is created, it defines the response [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.

◆ response_user_header()

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
template<typename NewResponseUserHeader >
auto iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S >::response_user_header ( ) && -> ServiceBuilderRequestResponse<RequestPayload, RequestUserHeader, ResponsePayload, NewResponseUserHeader, S>&&
inline

Sets the response user header type of the [Service].

Definition at line 362 of file service_builder_request_response.hpp.

◆ resume_build()

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
auto iox2::ServiceBuilderRequestResponse< RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S >::resume_build ( ) & -> ServiceBuilderRequestResponse<RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader, S>&&
inline

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

Definition at line 383 of file service_builder_request_response.hpp.

Friends And Related Symbol Documentation

◆ ServiceBuilder

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
template<ServiceType >
friend class ServiceBuilder
friend

Definition at line 296 of file service_builder_request_response.hpp.

◆ set_request_header_type_details

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
template<typename ReqP , typename ReqH , typename ResP , typename ResH , ServiceType St>
auto set_request_header_type_details ( ServiceBuilderRequestResponse< ReqP, ReqH, ResP, ResH, St > &  builder,
const TypeDetail value 
) -> std::enable_if_t< std::is_same< ReqH, CustomHeaderMarker >::value >
friend

◆ set_request_payload_type_details

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
template<typename ReqP , typename ReqH , typename ResP , typename ResH , ServiceType St>
auto set_request_payload_type_details ( ServiceBuilderRequestResponse< ReqP, ReqH, ResP, ResH, St > &  builder,
const TypeDetail value 
) -> std::enable_if_t< std::is_same< ReqP, bb::Slice< CustomPayloadMarker > >::value >
friend

◆ set_response_header_type_details

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
template<typename ReqP , typename ReqH , typename ResP , typename ResH , ServiceType St>
auto set_response_header_type_details ( ServiceBuilderRequestResponse< ReqP, ReqH, ResP, ResH, St > &  builder,
const TypeDetail value 
) -> std::enable_if_t< std::is_same< ResH, CustomHeaderMarker >::value >
friend

◆ set_response_payload_type_details

template<typename RequestPayload , typename RequestUserHeader , typename ResponsePayload , typename ResponseUserHeader , ServiceType S>
template<typename ReqP , typename ReqH , typename ResP , typename ResH , ServiceType St>
auto set_response_payload_type_details ( ServiceBuilderRequestResponse< ReqP, ReqH, ResP, ResH, St > &  builder,
const TypeDetail value 
) -> std::enable_if_t< std::is_same< ResP, bb::Slice< CustomPayloadMarker > >::value >
friend

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