#include <BasicASIOTransport.h>
|
typedef std::vector< std::string > | HostsVector |
| Used to define a vector of hosts to contact. More...
|
|
Definition at line 25 of file BasicASIOTransport.h.
◆ HostsVector
Used to define a vector of hosts to contact.
Definition at line 51 of file Transport.h.
◆ BasicASIOTransport()
◆ ~BasicASIOTransport()
madara::transport::BasicASIOTransport::~BasicASIOTransport |
( |
| ) |
|
|
pure virtual |
◆ check_transport()
int madara::transport::Base::check_transport |
( |
void |
| ) |
|
|
inlineinherited |
all subclasses should call this method at the beginning of send_data
Definition at line 17 of file Transport.inl.
◆ close()
void madara::transport::BasicASIOTransport::close |
( |
void |
| ) |
|
|
overridevirtual |
◆ get_udp_endpoints()
const std::vector<udp::endpoint>& madara::transport::BasicASIOTransport::get_udp_endpoints |
( |
void |
| ) |
|
|
inline |
◆ invalidate_transport()
void madara::transport::Base::invalidate_transport |
( |
void |
| ) |
|
|
inlineinherited |
Invalidates a transport to indicate it is shutting down.
Definition at line 31 of file Transport.inl.
◆ prep_send()
long madara::transport::Base::prep_send |
( |
const knowledge::KnowledgeMap & |
orig_updates, |
|
|
const char * |
print_prefix |
|
) |
| |
|
inherited |
Preps a message for sending.
- Parameters
-
orig_updates | updates before send filtering is applied |
print_prefix | prefix to include before every log message, e.g., "MyTransport::svc" |
- Returns
- -1 Transport is shutting down
-2 Transport is invalid
-3 Unable to allocate send buffer
0 No message to send > 0 size of buffered message
filter the updates according to the filters specified by the user in QoSTransportSettings (if applicable)
size = buffer[0] (unsigned 64 bit) transport id = buffer[8] (8 byte) domain = buffer[16] (32 byte domain name) originator = buffer[48] (64 byte originator host:port) type = buffer[112] (unsigned 32 bit type of message–usually MULTIASSIGN) updates = buffer[116] (unsigned 32 bit number of updates) quality = buffer[120] (unsigned 32 bit quality of message) clock = buffer[124] (unsigned 64 bit clock for this message) ttl = buffer[132] (the new knowledge starts here) knowledge = buffer[133] (the new knowledge starts here)
Definition at line 860 of file Transport.cpp.
◆ send_data()
◆ settings()
Getter for the transport settings.
- Returns
- the current transport settings
Definition at line 40 of file Transport.inl.
◆ setup()
int madara::transport::BasicASIOTransport::setup |
( |
void |
| ) |
|
|
overridevirtual |
◆ setup_read_socket()
int madara::transport::BasicASIOTransport::setup_read_socket |
( |
void |
| ) |
|
|
protectedvirtual |
◆ setup_read_thread()
virtual int madara::transport::BasicASIOTransport::setup_read_thread |
( |
double |
hertz, |
|
|
const std::string & |
name |
|
) |
| |
|
protectedpure virtual |
◆ setup_read_threads()
int madara::transport::BasicASIOTransport::setup_read_threads |
( |
| ) |
|
|
protectedvirtual |
◆ setup_socket()
int madara::transport::BasicASIOTransport::setup_socket |
( |
udp::socket & |
socket | ) |
|
|
protectedvirtual |
◆ setup_sockets()
int madara::transport::BasicASIOTransport::setup_sockets |
( |
void |
| ) |
|
|
protectedvirtual |
◆ setup_write_socket()
int madara::transport::BasicASIOTransport::setup_write_socket |
( |
void |
| ) |
|
|
protectedvirtual |
◆ validate_transport()
int madara::transport::Base::validate_transport |
( |
void |
| ) |
|
|
inlineinherited |
Validates a transport to indicate it is not shutting down.
Definition at line 6 of file Transport.inl.
◆ MulticastTransportReadThread
◆ UdpTransportReadThread
◆ addresses_
std::vector<udp::endpoint> madara::transport::BasicASIOTransport::addresses_ |
|
protected |
◆ buffer_
◆ context_
◆ default_read_hertz
const double madara::transport::BasicASIOTransport::default_read_hertz |
|
static |
◆ hosts
◆ id_
const std::string madara::transport::Base::id_ |
|
protectedinherited |
host:port identifier of this process
Definition at line 130 of file Transport.h.
◆ io_service_
asio::io_service madara::transport::BasicASIOTransport::io_service_ |
|
protected |
◆ is_valid_
volatile bool madara::transport::Base::is_valid_ |
|
protectedinherited |
◆ knowledge_
◆ last_toi_sent_
uint64_t madara::transport::Base::last_toi_sent_ = 0 |
|
protectedinherited |
Latest TOI the previous send operation included.
Definition at line 156 of file Transport.h.
◆ on_data_received_
data received rules, defined in Transport settings
Definition at line 139 of file Transport.h.
◆ packet_scheduler_
scheduler for dropping packets to simulate network issues
Definition at line 150 of file Transport.h.
◆ read_threads_
◆ receive_monitor_
monitor for receiving bandwidth usage
Definition at line 147 of file Transport.h.
◆ send_monitor_
monitor for sending bandwidth usage
Definition at line 144 of file Transport.h.
◆ settings_
◆ shutting_down_
volatile bool madara::transport::Base::shutting_down_ |
|
protectedinherited |
◆ socket_
udp::socket madara::transport::BasicASIOTransport::socket_ {io_service_} |
|
protected |
The documentation for this class was generated from the following files: