org.apache.curator.framework.recipes.cache
Class ChildData

java.lang.Object
  extended by org.apache.curator.framework.recipes.cache.ChildData
All Implemented Interfaces:
Comparable<ChildData>

public class ChildData
extends Object
implements Comparable<ChildData>


Constructor Summary
ChildData(String path, org.apache.zookeeper.data.Stat stat, byte[] data)
           
 
Method Summary
 int compareTo(ChildData rhs)
           Note: this class has a natural ordering that is inconsistent with equals.
 boolean equals(Object o)
           
 byte[] getData()
          Returns the node data for this child when the cache mode is set to cache data.
 String getPath()
          Returns the full path of the this child
 org.apache.zookeeper.data.Stat getStat()
          Returns the stat data for this child
 int hashCode()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ChildData

public ChildData(String path,
                 org.apache.zookeeper.data.Stat stat,
                 byte[] data)
Method Detail

compareTo

public int compareTo(ChildData rhs)
Note: this class has a natural ordering that is inconsistent with equals.

Specified by:
compareTo in interface Comparable<ChildData>

equals

public boolean equals(Object o)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

getPath

public String getPath()
Returns the full path of the this child

Returns:
full path

getStat

public org.apache.zookeeper.data.Stat getStat()
Returns the stat data for this child

Returns:
stat or null

getData

public byte[] getData()

Returns the node data for this child when the cache mode is set to cache data.

NOTE: the byte array returned is the raw reference of this instance's field. If you change the values in the array any other callers to this method will see the change.

Returns:
node data or null

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2011–2014 The Apache Software Foundation. All rights reserved.