 |
helics
3.0.1
|
38 enum class ServerModeOptions : char {
40 SERVER_DEFAULT_ACTIVE = 1,
41 SERVER_DEFAULT_DEACTIVATED = 2,
43 SERVER_DEACTIVATED = 4,
70 ServerModeOptions
server_mode{ServerModeOptions::UNSPECIFIED};
79 std::shared_ptr<helicsCLI11App>
commandLineParser(
const std::string& localAddress,
80 bool enableConfig =
true);
87 void checkAndUpdateBrokerAddress(
const std::string& localAddress);
98 std::string
makePortAddress(
const std::string& networkInterface,
int portNumber);
120 std::string
stripProtocol(
const std::string& networkAddress);
133 bool isipv6(
const std::string& address);
143 std::vector<std::string> low);
InterfaceNetworks
Definition: NetworkBrokerData.hpp:16
@ ALL
use all external ports
@ IPV6
use external ipv6 ports
void removeProtocol(std::string &networkAddress)
Definition: NetworkBrokerData.cpp:266
std::pair< std::string, std::string > extractInterfaceandPortString(const std::string &address)
Definition: NetworkBrokerData.cpp:251
int connectionPort
the port number for connecting
Definition: NetworkBrokerData.hpp:53
bool use_os_port
Definition: NetworkBrokerData.hpp:61
static std::shared_ptr< AsioContextManager > getContextPointer(const std::string &contextName=std::string())
Definition: AsioContextManager.cpp:38
int maxMessageSize
maximum message size
Definition: NetworkBrokerData.hpp:56
std::string getLocalExternalAddress(const std::string &server)
Definition: NetworkBrokerData.cpp:575
std::pair< std::string, int > extractInterfaceandPort(const std::string &address)
Definition: NetworkBrokerData.cpp:227
std::shared_ptr< Broker > findBroker(const std::string &brokerName)
Definition: BrokerFactory.cpp:182
std::string localInterface
the interface to use for the local connection
Definition: NetworkBrokerData.hpp:48
std::vector< std::string > prioritizeExternalAddresses(std::vector< std::string > high, std::vector< std::string > low)
Definition: NetworkBrokerData.cpp:330
int maxMessageCount
maximum message count
Definition: NetworkBrokerData.hpp:57
bool appendNameToAddress
flag indicating that the name should be appended to the address
Definition: NetworkBrokerData.hpp:64
@ UDP
using udp ports for communication
bool autobroker
flag for specifying an automatic broker generation
Definition: NetworkBrokerData.hpp:63
Definition: NetworkBrokerData.hpp:36
@ IP
using both types of ports (tcp/or udp) for communication
bool observer
specify that the network connection is used for observation only
Definition: NetworkBrokerData.hpp:69
int brokerPort
the port number to use for the main broker interface
Definition: NetworkBrokerData.hpp:52
@ TCP
using tcp ports for communication
std::string addProtocol(const std::string &networkAddress, InterfaceTypes interfaceT)
Definition: NetworkBrokerData.cpp:274
std::string generateMatchingInterfaceAddress(const std::string &server, InterfaceNetworks network)
Definition: NetworkBrokerData.cpp:583
std::string brokerInitString
a string containing arguments for the broker initialization
Definition: NetworkBrokerData.hpp:49
@ IPV4
use external ipv4 ports
std::string brokerAddress
the address or domain name of the broker
Definition: NetworkBrokerData.hpp:47
bool noAckConnection
Definition: NetworkBrokerData.hpp:66
bool reuse_address
allow reuse of binding address
Definition: NetworkBrokerData.hpp:60
@ INPROC
using inproc sockets for communications
int portStart
the starting port for automatic port definitions
Definition: NetworkBrokerData.hpp:55
void insertProtocol(std::string &networkAddress, InterfaceTypes interfaceT)
Definition: NetworkBrokerData.cpp:292
std::string getLocalExternalAddressV6()
Definition: NetworkBrokerData.cpp:481
NetworkBrokerData(InterfaceTypes type)
Definition: NetworkBrokerData.hpp:74
std::shared_ptr< helicsCLI11App > commandLineParser(const std::string &localAddress, bool enableConfig=true)
Definition: NetworkBrokerData.cpp:28
std::string getLocalExternalAddressV4()
Definition: NetworkBrokerData.cpp:371
the main namespace for the helics co-simulation library User functions will be in the helics namespac...
Definition: AsyncFedCallInfo.hpp:14
bool isipv6(const std::string &address)
Definition: NetworkBrokerData.cpp:313
std::string makePortAddress(const std::string &networkInterface, int portNumber)
Definition: NetworkBrokerData.cpp:217
ServerModeOptions server_mode
setup a server mode
Definition: NetworkBrokerData.hpp:70
std::string connectionAddress
the address for connecting
Definition: NetworkBrokerData.hpp:50
void setInterfaceType(InterfaceTypes type)
Definition: NetworkBrokerData.hpp:83
std::string stripProtocol(const std::string &networkAddress)
Definition: NetworkBrokerData.cpp:257
int portNumber
the port number for the local interface
Definition: NetworkBrokerData.hpp:51
bool useJsonSerialization
for message serialization use JSON
Definition: NetworkBrokerData.hpp:68
int maxRetries
the maximum number of retries to establish a network connection
Definition: NetworkBrokerData.hpp:58
InterfaceTypes
Definition: NetworkBrokerData.hpp:24
std::string brokerName
the identifier for the broker
Definition: NetworkBrokerData.hpp:46
HelicsConfigJSON * addJsonConfig(CLI::App *app)
Add the HELICS JSON configuration processor to the app.
Definition: helicsCLI11JsonConfig.cpp:96
@ LOCAL
just open local ports