WPILibC++  unspecified
nt::NetworkConnection Class Reference
Inheritance diagram for nt::NetworkConnection:
Collaboration diagram for nt::NetworkConnection:

Public Types

typedef std::function< bool(NetworkConnection &conn, std::function< std::shared_ptr< Message >)> get_msg
 
typedef std::function< bool(NetworkConnection &conn, std::function< std::shared_ptr< Message >)> std::function< void(wpi::ArrayRef< std::shared_ptr< Message >>)> send_msgs HandshakeFunc
 
typedef std::function< void(std::shared_ptr< Message > msg, NetworkConnection *conn)> ProcessIncomingFunc
 
typedef std::vector< std::shared_ptr< Message > > Outgoing
 
typedef wpi::ConcurrentQueue< Outgoing > OutgoingQueue
 
- Public Types inherited from nt::INetworkConnection
enum  State {
  kCreated, kInit, kHandshake, kSynchronized,
  kActive, kDead
}
 

Public Member Functions

 NetworkConnection (unsigned int uid, std::unique_ptr< wpi::NetworkStream > stream, IConnectionNotifier &notifier, wpi::Logger &logger, HandshakeFunc handshake, Message::GetEntryTypeFunc get_entry_type)
 
void set_process_incoming (ProcessIncomingFunc func)
 
void Start ()
 
void Stop ()
 
ConnectionInfo info () const override
 
bool active () const
 
wpi::NetworkStreamstream ()
 
void QueueOutgoing (std::shared_ptr< Message > msg) override
 
void PostOutgoing (bool keep_alive) override
 
unsigned int uid () const
 
unsigned int proto_rev () const override
 
void set_proto_rev (unsigned int proto_rev) override
 
State state () const override
 
void set_state (State state) override
 
std::string remote_id () const
 
void set_remote_id (StringRef remote_id)
 
uint64_t last_update () const
 
 NetworkConnection (const NetworkConnection &)=delete
 
NetworkConnectionoperator= (const NetworkConnection &)=delete
 
- Public Member Functions inherited from nt::INetworkConnection
 INetworkConnection (const INetworkConnection &)=delete
 
INetworkConnectionoperator= (const INetworkConnection &)=delete
 

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