org.apache.hadoop.registry.client.types
Class RegistryPathStatus

java.lang.Object
  extended by org.apache.hadoop.registry.client.types.RegistryPathStatus

@InterfaceAudience.Public
@InterfaceStability.Evolving
public final class RegistryPathStatus
extends Object

Output of a RegistryOperations.stat() call


Field Summary
 int children
          Number of child nodes
 String path
          Short path in the registry to this entry
 long size
          Entry size in bytes, as returned by the storage infrastructure.
 long time
          Timestamp
 
Constructor Summary
RegistryPathStatus(String path, long time, long size, int children)
          Construct an instance
 
Method Summary
 boolean equals(Object other)
          Equality operator checks size, time and path of the entries.
 int hashCode()
          The hash code is derived from the path.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

path

public final String path
Short path in the registry to this entry


time

public final long time
Timestamp


size

public final long size
Entry size in bytes, as returned by the storage infrastructure. In zookeeper, even "empty" nodes have a non-zero size.


children

public final int children
Number of child nodes

Constructor Detail

RegistryPathStatus

public RegistryPathStatus(String path,
                          long time,
                          long size,
                          int children)
Construct an instance

Parameters:
path - full path
time - time
size - entry size
children - number of children
Method Detail

equals

public boolean equals(Object other)
Equality operator checks size, time and path of the entries. It does not check children.

Overrides:
equals in class Object
Parameters:
other - the other entry
Returns:
true if the entries are considered equal.

hashCode

public int hashCode()
The hash code is derived from the path.

Overrides:
hashCode in class Object
Returns:
hash code for storing the path in maps.

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2014 Apache Software Foundation. All Rights Reserved.