helics  2.8.1
Namespaces | Functions
TcpCommsCommon.h File Reference
#include "TcpHelperClasses.h"
#include <chrono>
#include <string>

Go to the source code of this file.

Namespaces

 helics
 the main namespace for the helics co-simulation library User functions will be in the helics namespace with internal functions possible in a lower level namespace
 

Functions

TcpConnection::pointer helics::tcp::makeConnection (asio::io_context &io_context, const std::string &connection, const std::string &port, size_t bufferSize, std::chrono::milliseconds timeOut)
 
bool helics::tcp::commErrorHandler (CommsInterface *comm, TcpConnection *, const std::error_code &error)
 

Detailed Description

function in this file are common function used between the different TCP comms

Function Documentation

◆ commErrorHandler()

bool helics::tcp::commErrorHandler ( CommsInterface comm,
TcpConnection connection,
const std::error_code &  error 
)

do some checking and logging about errors if the interface is connected

◆ makeConnection()

TcpConnection::pointer helics::tcp::makeConnection ( asio::io_context &  io_context,
const std::string &  connection,
const std::string &  port,
size_t  bufferSize,
std::chrono::milliseconds  timeOut 
)

establish a connection to a server by as associated timeout