public class AddWatchBuilderImpl extends Object implements AddWatchBuilder, Pathable<Void>
| Constructor and Description |
|---|
AddWatchBuilderImpl(CuratorFrameworkImpl client,
Watching watching,
Backgrounding backgrounding,
org.apache.zookeeper.AddWatchMode mode) |
| Modifier and Type | Method and Description |
|---|---|
Void |
forPath(String path)
Commit the currently building operation using the given path
|
CuratorEventType |
getBackgroundEventType()
Most events are delivered by operations themselves, so they know their event types.
|
WatchableBase<Pathable<Void>> |
inBackground()
Perform the action in the background
|
WatchableBase<Pathable<Void>> |
inBackground(BackgroundCallback callback)
Perform the action in the background
|
WatchableBase<Pathable<Void>> |
inBackground(BackgroundCallback callback,
Executor executor)
Perform the action in the background
|
WatchableBase<Pathable<Void>> |
inBackground(BackgroundCallback callback,
Object context)
Perform the action in the background
|
WatchableBase<Pathable<Void>> |
inBackground(BackgroundCallback callback,
Object context,
Executor executor)
Perform the action in the background
|
WatchableBase<Pathable<Void>> |
inBackground(Object context)
Perform the action in the background
|
void |
performBackgroundOperation(org.apache.curator.framework.imps.OperationAndData<String> data) |
Pathable<Void> |
usingWatcher(CuratorWatcher watcher)
Set a watcher for the operation
|
Pathable<Void> |
usingWatcher(org.apache.zookeeper.Watcher watcher)
Set a watcher for the operation
|
AddWatchBuilder2 |
withMode(org.apache.zookeeper.AddWatchMode mode)
The mode to use.
|
public AddWatchBuilderImpl(CuratorFrameworkImpl client, Watching watching, Backgrounding backgrounding, org.apache.zookeeper.AddWatchMode mode)
public WatchableBase<Pathable<Void>> inBackground()
BackgroundableinBackground in interface Backgroundable<WatchableBase<Pathable<Void>>>public AddWatchBuilder2 withMode(org.apache.zookeeper.AddWatchMode mode)
AddWatchBuilderAddWatchMode.PERSISTENT_RECURSIVE is usedwithMode in interface AddWatchBuildermode - mode to usepublic Pathable<Void> usingWatcher(org.apache.zookeeper.Watcher watcher)
WatchableBaseusingWatcher in interface WatchableBase<Pathable<Void>>watcher - the watcherpublic Pathable<Void> usingWatcher(CuratorWatcher watcher)
WatchableBaseusingWatcher in interface WatchableBase<Pathable<Void>>watcher - the watcherpublic WatchableBase<Pathable<Void>> inBackground(Object context)
BackgroundableinBackground in interface Backgroundable<WatchableBase<Pathable<Void>>>context - context object - will be available from the event sent to the listenerpublic WatchableBase<Pathable<Void>> inBackground(BackgroundCallback callback)
BackgroundableinBackground in interface Backgroundable<WatchableBase<Pathable<Void>>>callback - a functor that will get called when the operation has completedpublic WatchableBase<Pathable<Void>> inBackground(BackgroundCallback callback, Object context)
BackgroundableinBackground in interface Backgroundable<WatchableBase<Pathable<Void>>>callback - a functor that will get called when the operation has completedcontext - context object - will be available from the event sent to the listenerpublic WatchableBase<Pathable<Void>> inBackground(BackgroundCallback callback, Executor executor)
BackgroundableinBackground in interface Backgroundable<WatchableBase<Pathable<Void>>>callback - a functor that will get called when the operation has completedexecutor - executor to use for the background callpublic WatchableBase<Pathable<Void>> inBackground(BackgroundCallback callback, Object context, Executor executor)
BackgroundableinBackground in interface Backgroundable<WatchableBase<Pathable<Void>>>callback - a functor that will get called when the operation has completedcontext - context object - will be available from the event sent to the listenerexecutor - executor to use for the background callpublic Void forPath(String path) throws Exception
Pathablepublic CuratorEventType getBackgroundEventType()
Copyright © 2011–2023 The Apache Software Foundation. All rights reserved.