Atlas  0.7.0
Networking protocol for the Worldforge system.
Atlas::Net::StreamConnect Class Reference

#include <Stream.h>

Inheritance diagram for Atlas::Net::StreamConnect:
Collaboration diagram for Atlas::Net::StreamConnect:

Public Types

enum  State { IN_PROGRESS , SUCCEEDED , FAILED }
 

Public Member Functions

 StreamConnect (std::string name, std::istream &inStream, std::ostream &outStream)
 
void poll () override
 
State getState () override
 
std::unique_ptr< Atlas::CodecgetCodec (Atlas::Bridge &) override
 FIXME We should pass in the Bridge here, not at construction time. More...
 

Detailed Description

Negotiation of clients building a connection to a remote system.

Used once a stream connection has been established to the server. This class offers the server a list of Atlas::Codec types that the client can understand, and then listens for the servers decision. Once the server has told the client which Atlas::Codec to use, negotiation is flagged as complete, and this object can be deleted.

Definition at line 58 of file Stream.h.

Member Function Documentation

◆ getCodec()

std::unique_ptr< Atlas::Codec > Atlas::Net::StreamConnect::getCodec ( Atlas::Bridge bridge)
overridevirtual

FIXME We should pass in the Bridge here, not at construction time.

Implements Atlas::Negotiate.

Definition at line 190 of file Stream.cpp.


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