Samchon Framework for CPP  1.0.0
samchon::protocol::ClientDriver Class Reference

#include <ClientDriver.hpp>

Collaboration diagram for samchon::protocol::ClientDriver:

Public Member Functions

void listen (IProtocol *listener)
 
- Public Member Functions inherited from samchon::protocol::Communicator
virtual void close ()
 
virtual void replyData (std::shared_ptr< Invoke > invoke)
 
virtual void sendData (std::shared_ptr< Invoke > invoke)
 

Detailed Description

A communicator with remote client.

The ClientDriver class is a type of Communicator, specified for communication with remote client who has connected in a Server object who follows the protocol of Samchon Framework's own. The ClientDriver takes full charge of network communication with the remote client.

The ClientDriver object is always created by the Server class. When you got a ClientDriver object from the Server.addClient(), then specify listener with the ClientDriver.listen() method. Below code is an example specifying and managing the listener objects.

Protocol Derived Type Created By
Samchon Framework's own ClientDriver Server
Web-socket protocol WebClientDriver WebServer
Basic Components
See also
Server, IProtocol Protocol - Basic Components
Author
Jeongho Nam http://samchon.org

Definition at line 37 of file ClientDriver.hpp.

Member Function Documentation

void samchon::protocol::ClientDriver::listen ( IProtocol listener)
inline

Listen message from the newly connected client.

Starts listening message from the newly connected client. Replied message from the connected client will be converted to Invoke classes and shifted to the listener's replyData() method.

Parameters
listenerA listener object to listen replied message from newly connected client in replyData() as an Invoke object.

Definition at line 58 of file ClientDriver.hpp.


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