Samchon Framework for CPP  1.0.0
samchon::protocol::service::Service Class Reference

A service. More...

#include <Service.hpp>

Collaboration diagram for samchon::protocol::service::Service:

Public Member Functions

 Service (Client *)
 Construct from Client. More...
 
auto getClient () const -> Client *
 Get Client. More...
 
virtual void sendData (std::shared_ptr< Invoke >)
 Shift the responsibility of sending an Invoke message to Client. 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 REQUIRE_AUTHORITY () const -> int=NULL
 Required authority to access the service. More...
 

Private Attributes

Clientclient
 Client object Service is belonged to. More...
 
std::string name
 A name represents a Service. More...
 

Detailed Description

A service.

A service represents an unique functions of a web page

Most of functinos are realized in here. The Service is correspondent with a 'a service of a web page'. For a cloud Server, there can be enormous Service classes. Create Services for each functions and Define the functions detail in here.

protocol_service.png
See also
samchon::protocol
samchon::protocol::service
Author
Jeongho Nam http://samchon.org

Definition at line 44 of file Service.hpp.

Constructor & Destructor Documentation

Service::Service ( Client client)

Construct from Client.

Parameters
clientClient object Service is belonged to

Definition at line 18 of file Service.cpp.

References client, and getClient().

Here is the call graph for this function:

Member Function Documentation

virtual auto samchon::protocol::service::Service::REQUIRE_AUTHORITY ( ) const -> int=NULL
protectedvirtual

Required authority to access the service.

Referenced by samchon::protocol::service::Client::constructService().

Here is the caller graph for this function:

auto Service::getClient ( ) const -> Client*

Get Client.

Definition at line 32 of file Service.cpp.

References client.

Referenced by Service().

Here is the caller graph for this function:

void Service::sendData ( std::shared_ptr< Invoke )
virtual

Shift the responsibility of sending an Invoke message to Client.

Parameters
inAn Invoke message to be sent to the (physical) client

Reimplemented from samchon::protocol::IProtocol.

Definition at line 40 of file Service.cpp.

References client, and samchon::protocol::service::Client::sendData().

Here is the call graph for this function:

Member Data Documentation

Client* samchon::protocol::service::Service::client
private

Client object Service is belonged to.

Definition at line 62 of file Service.hpp.

Referenced by getClient(), sendData(), and Service().

std::string samchon::protocol::service::Service::name
private

A name represents a Service.

Definition at line 67 of file Service.hpp.

Referenced by samchon::protocol::service::Client::constructService().


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