|
Samchon Framework for CPP
1.0.0
|
A boundary class interacting with a Chief system. More...
#include <ChiefDriver.hpp>

Public Member Functions | |
| ChiefDriver (IProtocol *master, int port) | |
| Construct from master and port number. More... | |
| virtual void | addClient (Socket *socket) override |
| Handling connection of a physical client. More... | |
Public Member Functions inherited from samchon::protocol::IServer | |
| IServer () | |
| Default Constructor. More... | |
| virtual void | open () |
| Open the server. More... | |
| virtual void | close () |
| Close the server. More... | |
Public Member Functions inherited from samchon::protocol::IClient | |
| IClient () | |
| Default Constructor. More... | |
| virtual void | listen () |
| Listens message from a related system. More... | |
| virtual void | sendData (std::shared_ptr< Invoke >) |
| Sends message to a related system. More... | |
Public Member Functions inherited from samchon::protocol::IProtocol | |
| IProtocol () | |
| Default Constructor. More... | |
| virtual void | replyData (std::shared_ptr< Invoke >) |
| Reply a message. More... | |
Protected Member Functions | |
| virtual auto | PORT () const -> int override |
| Port number of the server. More... | |
Protected Member Functions inherited from samchon::protocol::IServer | |
| virtual auto | MY_IP () const -> std::string |
| (optional) Server's IP More... | |
Protected Member Functions inherited from samchon::protocol::IClient | |
| virtual auto | BUFFER_SIZE () const -> size_t |
| Buffer size of network I/O. More... | |
| virtual void | _replyData (std::shared_ptr< Invoke >) |
| A method for pre-processing replied Invoke message. More... | |
Protected Attributes | |
| IProtocol * | master |
| A Master object containing the ChiefDriver. More... | |
| int | port |
| A port number to open for the Chief system. More... | |
| mutex | mtx |
| A mutex for realizing 1:1 server. More... | |
Protected Attributes inherited from samchon::protocol::IServer | |
| Acceptor * | acceptor |
| An acceptor for clients. More... | |
Protected Attributes inherited from samchon::protocol::IClient | |
| Socket * | socket |
| Socket for network I/O. More... | |
| std::mutex * | sendMtx |
| A mutex for sending message. More... | |
A boundary class interacting with a Chief system.
ChiefDriver is a boundary class interacting with a chief system as a server. However, the ChiefDriver represents a weird server that accepts only a client, the chief system.
The ChiefDriver is built for providing a guidance for designing a boundary class which is representing an unusual system within framework of OOD, handling a network system like a software class of Object-Oriented Design.
Definition at line 46 of file ChiefDriver.hpp.
|
inline |
Construct from master and port number.
| master | A master object associated with the chief system. |
| port | A port number to open for chief system. |
Definition at line 76 of file ChiefDriver.hpp.
|
inlineoverridevirtual |
Handling connection of a physical client.
Implements samchon::protocol::IServer.
Reimplemented in samchon::example::interaction::Reporter.
Definition at line 85 of file ChiefDriver.hpp.
References samchon::protocol::IProtocol::replyData().

|
inlineoverrideprotectedvirtual |
Port number of the server.
Reimplemented from samchon::protocol::IServer.
Definition at line 99 of file ChiefDriver.hpp.
|
protected |
A Master object containing the ChiefDriver.
Definition at line 57 of file ChiefDriver.hpp.
|
protected |
A port number to open for the Chief system.
Definition at line 62 of file ChiefDriver.hpp.
|
protected |
A mutex for realizing 1:1 server.
Definition at line 67 of file ChiefDriver.hpp.