PHP Class Elastica\Node

Author: Nicolas Ruflin ([email protected])
Afficher le fichier Open project: ruflin/elastica Class Usage Examples

Protected Properties

Свойство Type Description
$_client Client Client.
$_id Unique node id
$_info Node info.
$_name Node name.
$_stats Node stats.

Méthodes publiques

Méthode Description
__construct ( string $id, Client $client ) Create a new node object.
getClient ( ) : Client Returns the current client object.
getId ( ) : string
getInfo ( ) : Info Return info object of the current node.
getName ( ) : string Get the name of the node.
getStats ( ) : Stats Return stats object of the current node.
refresh ( ) Refreshes all node information.
setId ( string $id )

Method Details

__construct() public méthode

Create a new node object.
public __construct ( string $id, Client $client )
$id string Node id or name
$client Client Node object

getClient() public méthode

Returns the current client object.
public getClient ( ) : Client
Résultat Client Client

getId() public méthode

public getId ( ) : string
Résultat string Unique node id. Can also be name if id not exists.

getInfo() public méthode

Return info object of the current node.
public getInfo ( ) : Info
Résultat Elastica\Node\Info Node info object

getName() public méthode

Get the name of the node.
public getName ( ) : string
Résultat string Node name

getStats() public méthode

Return stats object of the current node.
public getStats ( ) : Stats
Résultat Elastica\Node\Stats Node stats

refresh() public méthode

This should be called after updating a node to refresh all information
public refresh ( )

setId() public méthode

public setId ( string $id )
$id string Node id

Property Details

$_client protected_oe property

Client.
protected Client,Elastica $_client
Résultat Client

$_id protected_oe property

Unique node id
protected $_id

$_info protected_oe property

Node info.
protected $_info

$_name protected_oe property

Node name.
protected $_name

$_stats protected_oe property

Node stats.
protected $_stats