Samchon Framework for CPP
1.0.0
|
#include <DistributedSystem.hpp>
Public Member Functions | |
virtual void | replyData (std::shared_ptr< protocol::Invoke > invoke) override |
Public Member Functions inherited from samchon::templates::parallel::ParallelSystem | |
virtual | ~ParallelSystem () |
virtual void | construct (std::shared_ptr< library::XML > xml) override |
Construct data of the Entity from an XML object. More... | |
auto | getPerformance () const -> double |
void | setPerformance (double val) |
void | enforcePerformance (double val) |
virtual auto | toXML () const -> std::shared_ptr< library::XML > override |
Get an XML object represents the EntityGroup. More... | |
Public Member Functions inherited from samchon::templates::external::ExternalSystem | |
ExternalSystem () | |
ExternalSystem (base::ExternalSystemArrayBase *systemArray) | |
ExternalSystem (base::ExternalSystemArrayBase *systemArray, std::shared_ptr< protocol::ClientDriver > driver) | |
virtual | ~ExternalSystem ()=default |
virtual auto | key () const -> std::string |
auto | getName () const -> std::string |
void | close () |
virtual void | sendData (std::shared_ptr< protocol::Invoke > invoke) override |
virtual auto | CHILD_TAG () const -> std::string override |
A tag name of children. More... | |
Public Member Functions inherited from samchon::protocol::EntityGroup< Container, T, Key > | |
auto | find (const typename child_type::key_type &key) -> typename container_type::iterator |
Get iterator to element. More... | |
auto | find (const typename child_type::key_type &key) const -> typename container_type::const_iterator |
Get const iterator to element. More... | |
auto | has (const typename child_type::key_type &key) const -> bool |
Indicates whether a container has an object having the specified identifier. More... | |
auto | count (const typename child_type::key_type &key) const -> size_t |
Count elements with a specific key. More... | |
auto | get (const typename child_type::key_type &key) -> typename container_type::value_type & |
Access the element by specified identifier(key). More... | |
auto | get (const typename child_type::key_type &key) const -> const typename container_type::value_type & |
Access the const element by specified identifier(key). More... | |
Public Member Functions inherited from samchon::protocol::IProtocol | |
virtual void | replyData (std::shared_ptr< Invoke >)=0 |
virtual void | sendData (std::shared_ptr< Invoke >)=0 |
Protected Member Functions | |
virtual auto | createChild (std::shared_ptr< library::XML >) -> external::ExternalSystemRole *override |
Additional Inherited Members | |
Protected Attributes inherited from samchon::templates::external::ExternalSystem | |
std::string | name |
A driver for a distributed slave system.
The DistributedSystem is an abstract class represents a slave system in Distributed Processing System, connected with this master system. This DistributedSystem takes full charge of network communication with the remote, distributed slave system has connected.
This DistributedSystem has a performance index that indicates how much the slave system is fast. The performance index is referenced and revaluated whenever those methods are called:
Note that, this DistributedSystem class derived from the ExternalSystem class. Thus, this DistributedSystem can also have children ExternalSystemRole objects exclusively. However, the children roles objects are different with the DistributedProcess. The domestic roles are belonged to only a specific DistributedSystem object. Otherwise, the DistributedProcess objects are belonged to a DistributedSystemArray object. Furthermore, the relationship between this DistributedSystem and DistributedProcess classes are M: N Associative.
Articles | DistributedProcess | ExternalSystemRole |
---|---|---|
Belonged to | DistributedSystemArray | DistributedSystem |
Relationship | M: N Associative | 1: N Composite |
Ownership | References | Exclusive possession |
Templates - Distributed System
Definition at line 51 of file DistributedSystem.hpp.
|
inlineoverrideprotectedvirtual |
Factory method creating a child object.
In distributed module, the process class DistributedProcess is not belonged to a specific DistributedSystem object. It only belongs to a DistributedSystemArray object and has a M: N Associative Relationship between this DistributedSystem class.
By that reason, it's the normal case that the DistributedSystem object does not have any children ExternalSystemRole object. Thus, default createChild returns null
.
However, if you want a DistributedSystem to have its own domestic ExternalSystemRole objects without reference to the DistributedProcess objects, it is possible. Creates and returns the domestic ExternalSystemRole object.
null
. Implements samchon::protocol::EntityGroup< Container, T, Key >.
Definition at line 97 of file DistributedSystem.hpp.
References samchon::templates::slave::InvokeHistory::computeElapsedTime().
|
inlineoverridevirtual |
Handle an {} message has received.
invoke | An Invoke message have received. |
Reimplemented from samchon::templates::external::ExternalSystem.
Definition at line 130 of file DistributedSystem.hpp.
References samchon::templates::external::ExternalSystem::replyData().