SequoiaDB
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Public Member Functions | Public Attributes | List of all members
sdbclient::sdbNode Class Reference

Database operation interfaces of node. This class takes the place of class "sdbReplicaNode". More...

#include <client.hpp>

Public Member Functions

 sdbNode ()
 Default constructor.
 
 ~sdbNode ()
 Destructor.
 
INT32 connect (sdb &dbConn)
 Connect to the current node.
 
sdbNodeStatus getStatus ()
 Get status of the current node.
 
const CHAR * getHostName ()
 Get host name of the current node.
 
const CHAR * getServiceName ()
 Get service name of the current node.
 
const CHAR * getNodeName ()
 Get node name of the current node.
 
INT32 getNodeID (INT32 &nodeID) const
 Get node id of the current node.
 
INT32 stop ()
 Stop the node.
 
INT32 start ()
 Start the node.
 

Public Attributes

_sdbNode * pNode
 

Detailed Description

Database operation interfaces of node. This class takes the place of class "sdbReplicaNode".

Note
We use concept "node" instead of "replica node", and change the class name "sdbReplicaNode" to "sdbNode". class "sdbReplicaNode" will be deprecated in version 2.x.

Member Function Documentation

sdbclient::sdbNode::connect ( sdb dbConn)
inline

Connect to the current node.

Parameters
[out]dbConnThe database obj of current connection
Return values
SDB_OKOperation Success
OthersOperation Fail
Deprecated:
This function is deprecated
const CHAR * sdbclient::sdbNode::getHostName ( )
inline

Get host name of the current node.

Returns
The host name.
INT32 sdbclient::sdbNode::getNodeID ( INT32 &  nodeID) const
inline

Get node id of the current node.

Returns
The node id.
const CHAR * sdbclient::sdbNode::getNodeName ( )
inline

Get node name of the current node.

Returns
The node name.
CHAR * sdbclient::sdbNode::getServiceName ( )
inline

Get service name of the current node.

Returns
The service name.
sdbNodeStatus sdbclient::sdbNode::getStatus ( )
inline

Get status of the current node.

Returns
The status of current node.
Deprecated:
Since v2.8, the status of node are invalid, never use this api again.
INT32 sdbclient::sdbNode::start ( )
inline

Start the node.

Return values
SDB_OKOperation Success
OthersOperation Fail
INT32 sdbclient::sdbNode::stop ( )
inline

Stop the node.

Return values
SDB_OKOperation Success
OthersOperation Fail

Member Data Documentation

sdbclient::sdbNode::pNode

A pointer of virtual base class _sdbNode

Class sdbNode is a shell for _sdbNode. We use pNode to call the methods in class _sdbNode.


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