44 m_line_buffer.add( p , n ) ;
47 while( iter.
more() && onReceive(iter.
line()) )
53 m_line_buffer.expect( n ) ;
58 return m_line_buffer.eol() ;
An abstract base class for the GNet::Server's connection to a remote client.
BufferedServerPeer(Server::PeerInfo)
Constructor with an auto-detected line ending.
An iterator class for GNet::LineBuffer that extracts complete lines.
virtual void onData(const char *, ServerPeer::size_type)
Override from GNet::SocketProtocolSink.
void expect(size_t n)
Temporarily suspends line buffering so that the next 'n' bytes are accumulated without regard to line...
const std::string & line() const
Returns the current line.
virtual ~BufferedServerPeer()
Destructor.
const std::string & eol() const
Returns the line-buffer's line ending.
A structure used in GNet::Server::newPeer().
bool more()
Returns true if there is a line() to be had.