com.netflix.curator.framework.recipes.cache
Class PathChildrenCacheEvent

java.lang.Object
  extended by com.netflix.curator.framework.recipes.cache.PathChildrenCacheEvent

public class PathChildrenCacheEvent
extends java.lang.Object

POJO that abstracts a change to a path


Nested Class Summary
static class PathChildrenCacheEvent.Type
          Type of change
 
Constructor Summary
PathChildrenCacheEvent(PathChildrenCacheEvent.Type type, ChildData data)
           
 
Method Summary
 ChildData getData()
           
 java.util.List<ChildData> getInitialData()
          Special purpose method.
 PathChildrenCacheEvent.Type getType()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

PathChildrenCacheEvent

public PathChildrenCacheEvent(PathChildrenCacheEvent.Type type,
                              ChildData data)
Parameters:
type - event type
data - event data or null
Method Detail

getType

public PathChildrenCacheEvent.Type getType()
Returns:
change type

getData

public ChildData getData()
Returns:
the node's data

getInitialData

public java.util.List<ChildData> getInitialData()
Special purpose method. When an PathChildrenCacheEvent.Type.INITIALIZED event is received, you can call this method to receive the initial state of the cache.

Returns:
initial state of cache for PathChildrenCacheEvent.Type.INITIALIZED events. Otherwise, null.

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object