|
iceoryx2
C++ Language Bindings
|
#include <port_factory_client.hpp>
Public Member Functions | |
| auto | backpressure_strategy (const BackpressureStrategy value) -> decltype(auto) |
| auto | max_active_requests (const uint64_t value) -> decltype(auto) |
| PortFactoryClient (const PortFactoryClient &)=delete | |
| PortFactoryClient (PortFactoryClient &&)=default | |
| auto | operator= (const PortFactoryClient &) -> PortFactoryClient &=delete |
| auto | operator= (PortFactoryClient &&) -> PortFactoryClient &=default |
| ~PortFactoryClient ()=default | |
| template<typename T = RequestPayload, typename = std::enable_if_t<bb::IsSlice<T>::VALUE, void>> | |
| auto | initial_max_slice_len (uint64_t value) &&-> PortFactoryClient && |
| Sets the maximum number of elements that can be loaned in a slice. | |
| template<typename T = RequestPayload, typename = std::enable_if_t<bb::IsSlice<T>::VALUE, void>> | |
| auto | allocation_strategy (AllocationStrategy value) &&-> PortFactoryClient && |
| auto | override_request_preallocation (const OverridePreallocationCallback &callback) &&-> PortFactoryClient && |
| auto | set_request_degradation_handler (DegradationHandler *handler) &&-> PortFactoryClient && |
| auto | set_response_degradation_handler (DegradationHandler *handler) &&-> PortFactoryClient && |
| auto | set_backpressure_handler (BackpressureHandler *handler) &&-> PortFactoryClient && |
| auto | create () &&-> bb::Expected< Client< Service, RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader >, ClientCreateError > |
Creates a new [Client] or returns a [ClientCreateError] on failure. | |
Friends | |
| template<ServiceType , typename , typename , typename , typename > | |
| class | PortFactoryRequestResponse |
Factory to create a new [Client] port/endpoint for [MessagingPattern::RequestResponse] based communication.
Definition at line 36 of file port_factory_client.hpp.
|
delete |
|
default |
|
default |
|
inline |
Defines the allocation strategy that is used when the provided [PortFactoryClient::initial_max_slice_len()] is exhausted. This happens when the user acquires more than max slice len in [Client::loan_slice()] or [Client::loan_slice_uninit()].
Definition at line 160 of file port_factory_client.hpp.
| auto iox2::PortFactoryClient< Service, RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader >::backpressure_strategy | ( | const BackpressureStrategy | value | ) | -> decltype(auto) |
Sets the [BackpressureStrategy] which defines how the [Client] shall behave when a [Server] cannot receive a [RequestMut] since its internal buffer is full.
|
inline |
Creates a new [Client] or returns a [ClientCreateError] on failure.
Definition at line 204 of file port_factory_client.hpp.
References iox2::detail::backpressure_handler_delegate(), iox2::detail::degradation_handler_delegate(), iox2::bb::err(), and iox2::internal::override_callback().
|
inline |
Sets the maximum number of elements that can be loaned in a slice.
Definition at line 136 of file port_factory_client.hpp.
| auto iox2::PortFactoryClient< Service, RequestPayload, RequestUserHeader, ResponsePayload, ResponseUserHeader >::max_active_requests | ( | const uint64_t | value | ) | -> decltype(auto) |
Defines the required maximal amount of active requests the [Client] can send. Smallest possible value is 1.
|
delete |
|
default |
|
inline |
Defines a callback to reduce the number of preallocated [RequestMut]s. The input argument is the worst case number of preallocated [RequestMut]s required to guarantee that the [Client] never runs out of [RequestMut]s to loan and send. The return value is clamped between 1 and the worst case number of preallocated [RequestMut]s.
If the user reduces the number of preallocated [RequestMut]s, iceoryx2 can no longer guarantee, that the [Client] can always loan a [RequestMut] to send.
Definition at line 147 of file port_factory_client.hpp.
|
inline |
Sets the [BackpressureHandler] of the [Client]. Whenever a [RequestMut] cannot be sent to a [Server], this handler is called and depending on the returned [BackpressureAction], measures will be taken. If no handler is set, the measures will be determined by the value set in [BackpressureStrategy].
Client], including the send and receive functions, is accessed from multiple threads, the handler must be thread-safe if it captures data Definition at line 193 of file port_factory_client.hpp.
|
inline |
Sets the [DegradationHandler] for sending [RequestMut] from the [Client]. Whenever a request connection to a [Server] is corrupted, this handler is called and depending on the returned [DegradationAction] measures will be taken.
Client], including the send and receive functions, is accessed from multiple threads, the handler must be thread-safe if it captures data Definition at line 171 of file port_factory_client.hpp.
|
inline |
Sets the [DegradationHandler] for receiving [Response]s from a [Server]. Whenever a response connection to a [Server] is corrupted, this handler is called and depending on the returned [DegradationAction] measures will be taken.
Client], including the send and receive functions, is accessed from multiple threads, the handler must be thread-safe if it captures data Definition at line 182 of file port_factory_client.hpp.
|
friend |
Definition at line 117 of file port_factory_client.hpp.