Simo 0.0.1
Loading...
Searching...
No Matches
Simo::Ports::CallbackContractOutPort< Payload, ReturnType, Contract > Class Template Reference

#include <Port.h>

Inheritance diagram for Simo::Ports::CallbackContractOutPort< Payload, ReturnType, Contract >:
Simo::Ports::CallbackOutPort< Payload, ReturnType > Simo::Ports::ContractInterface< Contract > Simo::Port

Public Member Functions

bool connect (Port *other) override
Public Member Functions inherited from Simo::Ports::CallbackOutPort< Payload, ReturnType >
bool connect (Port *other) override
template<typename Arg>
std::optional< ReturnType > send (Arg &&payload)
template<typename Arg>
void send (Arg &&payload)
Public Member Functions inherited from Simo::Port
template<typename Self>
TypeId get_type_id (this Self &)
 Utility to the get type of class. Need the type at compile time.
std::string_view name () const
void name (const std::string_view name)
Public Member Functions inherited from Simo::Ports::ContractInterface< Contract >
std::optional< Contract > contract ()
void contract (Contract contract)
void connected_port (ContractInterface *port)
void connected_port_contract_predicate (std::function< bool(Contract)> predicate)
std::expected< bool, VERIFY_CONTRACT_ERROR > verify_connected_port_contract ()

Additional Inherited Members

Public Types inherited from Simo::Port
using TypeId = boost::typeindex::type_index
Protected Attributes inherited from Simo::Ports::CallbackOutPort< Payload, ReturnType >
CallbackInPort< Payload, ReturnType > * connecting_port = nullptr
Protected Attributes inherited from Simo::Port
std::string name_
Protected Attributes inherited from Simo::Ports::ContractInterface< Contract >
std::optional< Contract > contract_
ContractInterfaceconnected_port_ = nullptr
std::function< bool(Contract)> connected_port_contract_predicate_ {}

Detailed Description

template<typename Payload, typename ReturnType, typename Contract>
class Simo::Ports::CallbackContractOutPort< Payload, ReturnType, Contract >

Callback out port with contract logic.

See CallbackOutPort and ContractInterface classes

Member Function Documentation

◆ connect()

template<typename Payload, typename ReturnType, typename Contract>
bool Simo::Ports::CallbackContractOutPort< Payload, ReturnType, Contract >::connect ( Port * other)
nodiscardoverridevirtual

Implements Simo::Port.


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