Skip to content

Template Class IExchangeBackend

Template Class IExchangeBackend

  • Defined in File ExchangeBackend.h

Inheritance Relationships

Base Type

template <typename In, typename Out>
class IExchangeBackend : public IProtobufBackend

Source: Source/Schola/Protobuf/Public/ProtobufBackends/ExchangeBackend.h A Generic Interface for any service that can be used to exchange messages of type In and Out asynchronously.

Template Parameters:

  • In – The type of message that will be input to this interface

  • Out – The type of message that will be output by this interface


Public Functions

SymbolDetails
ReceiveInitiate an Exchange with the Client.
RespondRespond to a message from the client.
Respond
ResetReset the backend to clear any stale exchange state from previous connections.
ReceiveDo an exchange before converting the protomessage into the specified type.

Receive

virtual TFuture<const In *> Receive() = 0

Initiate an Exchange with the Client.

Returns:

A future that will be fulfilled with the result of the exchange. The value ptr from the future is valid until the next time exchange is called.

Attributes: pure virtual

Source: Source/Schola/Protobuf/Public/ProtobufBackends/ExchangeBackend.h

Respond

virtual void Respond(Out *Response) = 0

Respond to a message from the client.

Parameters

Response – [in] The message to send to the client

#DirectionNameTypeDescription
1ResponseOut *The message to send to the client

Attributes: pure virtual

Source: Source/Schola/Protobuf/Public/ProtobufBackends/ExchangeBackend.h

Respond

template <typename UnrealType>
inline void Respond(const UnrealType &InUnrealObject)
#DirectionNameTypeDescription
1ResponseOut *The message to send to the client

Attributes: pure virtual

Source: Source/Schola/Protobuf/Public/ProtobufBackends/ExchangeBackend.h

Reset

virtual void Reset() = 0

Reset the backend to clear any stale exchange state from previous connections.

Attributes: pure virtual

Source: Source/Schola/Protobuf/Public/ProtobufBackends/ExchangeBackend.h

Receive

template <typename UnrealType> inline TFuture<UnrealType *> Receive()

Do an exchange before converting the protomessage into the specified type.

Template Parameters:

T – The type to deserialize the message into

Returns:

A proto message that has been deserialized from In into type T

Attributes: pure virtual

Source: Source/Schola/Protobuf/Public/ProtobufBackends/ExchangeBackend.h