Skip to content

TServiceBuilderPublishSubscribe<TPayload, TUserHeader>

Builder to create new TMessagingPattern.PublishSubscribe based services

Definition

Unit: Neslib.Iceoryx2.PublishSubscribe

type TServiceBuilderPublishSubscribe<TPayload, TUserHeader> = record ... end;

Type Parameters

TPayload:

TUserHeader:

Methods

Name Description
_Init
Create Creates a new service.
CreateWithAttributes Creates a new service with a set of attributes.
EnableSafeOverflow 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.
HistorySize 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.
MaxNodes If the service is created it defines how many nodes shall be able to open it in parallel. If an existing service is opened it defines how many nodes must be at least supported.
MaxPublishers If the service is created it defines how many publishers shall be supported at most. If an existing service is opened it defines how many publishers must be at least supported.
MaxSubscribers If the service is created it defines how many subscribers shall be supported at most. If an existing service is opened it defines how many subscribers must be at least supported.
Open Opens an existing service.
OpenOrCreate If the service exists, it will be opened otherwise a new service will be created.
OpenOrCreateWithAttributes 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.
OpenWithAttributes Opens an existing service with attribute requirements. If the defined attribute requirements are not satisfied the open process will fail.
PayloadAlignment 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.
ResumeBuild Returns the builder as an r-value so the fluent chain can be resumed after a free function, such as SetPayloadTypeDetails or SetUserHeaderTypeDetails, has been applied to the named builder.
SubscriberMaxBorrowedSamples If the service is created it defines how many samples a subscriber can borrow at most in parallel. If an existing service is opened it defines the minimum required.
SubscriberMaxBufferSize If the service is created it defines how many samples a subscriber can store in its internal buffer. If an existing service is opened it defines the minimum required.
UserHeader<TNewHeader> Sets the user header type of the service.

Method Descriptions

_Init(_iox2_service_builder_h, TServiceType)

procedure _Init(const AHandle: _iox2_service_builder_h; const AServiceType: TServiceType); inline

Parameters

AHandle: _iox2_service_builder_h

AServiceType: TServiceType


Create

Creates a new service.

function Create: TResult<TPortFactoryPublishSubscribe<TPayload>, TPublishSubscribeCreateError>; inline

Returns

TResult<TPortFactoryPublishSubscribe<TPayload>, TPublishSubscribeCreateError>


CreateWithAttributes(TAttributeSpecifier)

Creates a new service with a set of attributes.

function CreateWithAttributes(const AAttributes: TAttributeSpecifier): TResult<TPortFactoryPublishSubscribe<TPayload>, TPublishSubscribeCreateError>; inline

Parameters

AAttributes: TAttributeSpecifier

Returns

TResult<TPortFactoryPublishSubscribe<TPayload>, TPublishSubscribeCreateError>


EnableSafeOverflow(Boolean)

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.

function EnableSafeOverflow(const AValue: Boolean): TServiceBuilderPublishSubscribe<TPayload, TUserHeader>; inline

Parameters

AValue: Boolean

Returns

TServiceBuilderPublishSubscribe<TPayload, TUserHeader>


HistorySize(UInt64)

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.

function HistorySize(const AValue: UInt64): TServiceBuilderPublishSubscribe<TPayload, TUserHeader>; inline

Parameters

AValue: UInt64

Returns

TServiceBuilderPublishSubscribe<TPayload, TUserHeader>


MaxNodes(UInt64)

If the service is created it defines how many nodes shall be able to open it in parallel. If an existing service is opened it defines how many nodes must be at least supported.

function MaxNodes(const AValue: UInt64): TServiceBuilderPublishSubscribe<TPayload, TUserHeader>; inline

Parameters

AValue: UInt64

Returns

TServiceBuilderPublishSubscribe<TPayload, TUserHeader>


MaxPublishers(UInt64)

If the service is created it defines how many publishers shall be supported at most. If an existing service is opened it defines how many publishers must be at least supported.

function MaxPublishers(const AValue: UInt64): TServiceBuilderPublishSubscribe<TPayload, TUserHeader>; inline

Parameters

AValue: UInt64

Returns

TServiceBuilderPublishSubscribe<TPayload, TUserHeader>


MaxSubscribers(UInt64)

If the service is created it defines how many subscribers shall be supported at most. If an existing service is opened it defines how many subscribers must be at least supported.

function MaxSubscribers(const AValue: UInt64): TServiceBuilderPublishSubscribe<TPayload, TUserHeader>; inline

Parameters

AValue: UInt64

Returns

TServiceBuilderPublishSubscribe<TPayload, TUserHeader>


Open

Opens an existing service.

function Open: TResult<TPortFactoryPublishSubscribe<TPayload>, TPublishSubscribeOpenError>; inline

Returns

TResult<TPortFactoryPublishSubscribe<TPayload>, TPublishSubscribeOpenError>


OpenOrCreate

If the service exists, it will be opened otherwise a new service will be created.

function OpenOrCreate: TResult<TPortFactoryPublishSubscribe<TPayload>, TPublishSubscribeOpenOrCreateError>; inline

Returns

TResult<TPortFactoryPublishSubscribe<TPayload>, TPublishSubscribeOpenOrCreateError>


OpenOrCreateWithAttributes(TAttributeVerifier)

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.

function OpenOrCreateWithAttributes(const ARequiredAttributes: TAttributeVerifier): TResult<TPortFactoryPublishSubscribe<TPayload>, TPublishSubscribeOpenOrCreateError>; inline

Parameters

ARequiredAttributes: TAttributeVerifier

Returns

TResult<TPortFactoryPublishSubscribe<TPayload>, TPublishSubscribeOpenOrCreateError>


OpenWithAttributes(TAttributeVerifier)

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

function OpenWithAttributes(const ARequiredAttributes: TAttributeVerifier): TResult<TPortFactoryPublishSubscribe<TPayload>, TPublishSubscribeOpenError>; inline

Parameters

ARequiredAttributes: TAttributeVerifier

Returns

TResult<TPortFactoryPublishSubscribe<TPayload>, TPublishSubscribeOpenError>


PayloadAlignment(UInt64)

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.

function PayloadAlignment(const AValue: UInt64): TServiceBuilderPublishSubscribe<TPayload, TUserHeader>; inline

Parameters

AValue: UInt64

Returns

TServiceBuilderPublishSubscribe<TPayload, TUserHeader>


ResumeBuild

Returns the builder as an r-value so the fluent chain can be resumed after a free function, such as SetPayloadTypeDetails or SetUserHeaderTypeDetails, has been applied to the named builder.

function ResumeBuild: TServiceBuilderPublishSubscribe<TPayload, TUserHeader>; inline

Returns

TServiceBuilderPublishSubscribe<TPayload, TUserHeader>


SubscriberMaxBorrowedSamples(UInt64)

If the service is created it defines how many samples a subscriber can borrow at most in parallel. If an existing service is opened it defines the minimum required.

function SubscriberMaxBorrowedSamples(const AValue: UInt64): TServiceBuilderPublishSubscribe<TPayload, TUserHeader>; inline

Parameters

AValue: UInt64

Returns

TServiceBuilderPublishSubscribe<TPayload, TUserHeader>


SubscriberMaxBufferSize(UInt64)

If the service is created it defines how many samples a subscriber can store in its internal buffer. If an existing service is opened it defines the minimum required.

function SubscriberMaxBufferSize(const AValue: UInt64): TServiceBuilderPublishSubscribe<TPayload, TUserHeader>; inline

Parameters

AValue: UInt64

Returns

TServiceBuilderPublishSubscribe<TPayload, TUserHeader>


UserHeader<TNewHeader>

Sets the user header type of the service.

function UserHeader<TNewHeader>: TServiceBuilderPublishSubscribe<TPayload, TNewHeader>; inline

Type Parameters

TNewHeader:

Returns

TServiceBuilderPublishSubscribe<TPayload, TNewHeader>