Public Member Functions

GridClient Class Reference

#include <gridclient.hpp>

Inheritance diagram for GridClient:
GridClientImpl

List of all members.

Public Member Functions

virtual ~GridClient ()
virtual GridClientUuid id () const =0
virtual TGridClientDataPtr data ()=0
virtual TGridClientDataPtr data (const std::string &cacheName)=0
virtual TGridClientComputePtr compute ()=0
virtual void addTopologyListener (TGridClientTopologyListenerPtr lsnr)=0
virtual void removeTopologyListener (TGridClientTopologyListenerPtr lsnr)=0
virtual
TGridClientTopologyListenerListPtr 
topologyListeners () const =0

Detailed Description

C++ client API.


Constructor & Destructor Documentation

virtual GridClient::~GridClient (  )  [inline, virtual]

Destructor.


Member Function Documentation

virtual void GridClient::addTopologyListener ( TGridClientTopologyListenerPtr  lsnr  )  [pure virtual]

Adds topology listener. Remote grid topology is refreshed every GridClientConfiguration#getTopologyRefreshFrequency() milliseconds. If any node was added or removed, a listener will be notified.

Parameters:
lsnr Listener to add.
virtual TGridClientComputePtr GridClient::compute (  )  [pure virtual]

Gets a default compute projection. Default compute projection will include all nodes in remote grid. Selection of node that will be connected to perform operations will be done according to GridClientLoadBalancer provided in client configuration or according to affinity if projection call involves affinity key.

More restricted projection configurations may be created with GridClientCompute methods.

Returns:
Default compute projection.
See also:
GridClientCompute
virtual TGridClientDataPtr GridClient::data (  )  [pure virtual]

Gets a data projection for a default grid cache with null name.

Returns:
Data projection for grid cache with null name.
Exceptions:
GridClientException If client was closed.
virtual TGridClientDataPtr GridClient::data ( const std::string &  cacheName  )  [pure virtual]

Gets a data projection for grid cache with name cacheName. If no data configuration with given name was provided at client startup, an exception will be thrown.

Parameters:
cacheName Grid cache name for which data projection should be obtained.
Returns:
Data projection for grid cache with name cacheName.
Exceptions:
GridClientException If client was closed or no configuration with given name was provided.
virtual GridClientUuid GridClient::id (  )  const [pure virtual]

Gets a unique client identifier. This identifier is generated by factory on client creation and used in identification and authentication procedure on server node.

Returns:
Generated client id.
virtual void GridClient::removeTopologyListener ( TGridClientTopologyListenerPtr  lsnr  )  [pure virtual]

Removes previously added topology listener.

Parameters:
lsnr Listener to remove.
virtual TGridClientTopologyListenerListPtr GridClient::topologyListeners (  )  const [pure virtual]
Returns:
Copy of the topology listeners list.

The documentation for this class was generated from the following file:
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends