public class DeleteBuilderImpl extends Object implements DeleteBuilder, ErrorListenerPathable<Void>
| Constructor and Description |
|---|
DeleteBuilderImpl(CuratorFrameworkImpl client,
int version,
Backgrounding backgrounding,
boolean deletingChildrenIfNeeded,
boolean guaranteed,
boolean quietly) |
| Modifier and Type | Method and Description |
|---|---|
BackgroundVersionable |
deletingChildrenIfNeeded()
Will also delete children if they exist.
|
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.
|
protected int |
getVersion() |
ChildrenDeletable |
guaranteed()
Solves edge cases where an operation may succeed on the server but connection failure occurs before a
response can be successfully returned to the client.
|
DeleteBuilderMain |
idempotent()
If the first try of this operation gets a transient error, curator will retry
the operation, and treat it as successful so long as the end state of the znode
is the same as if the operation had completed without error on the first try.
|
ErrorListenerPathable<Void> |
inBackground()
Perform the action in the background
|
ErrorListenerPathable<Void> |
inBackground(BackgroundCallback callback)
Perform the action in the background
|
ErrorListenerPathable<Void> |
inBackground(BackgroundCallback callback,
Executor executor)
Perform the action in the background
|
ErrorListenerPathable<Void> |
inBackground(BackgroundCallback callback,
Object context)
Perform the action in the background
|
ErrorListenerPathable<Void> |
inBackground(BackgroundCallback callback,
Object context,
Executor executor)
Perform the action in the background
|
ErrorListenerPathable<Void> |
inBackground(Object context)
Perform the action in the background
|
void |
performBackgroundOperation(org.apache.curator.framework.imps.OperationAndData<String> operationAndData) |
DeleteBuilderMain |
quietly() |
Pathable<Void> |
withUnhandledErrorListener(UnhandledErrorListener listener)
Set an error listener for this background operation.
|
BackgroundPathable<Void> |
withVersion(int version)
Use the given version (the default is -1)
|
public DeleteBuilderImpl(CuratorFrameworkImpl client, int version, Backgrounding backgrounding, boolean deletingChildrenIfNeeded, boolean guaranteed, boolean quietly)
public DeleteBuilderMain quietly()
quietly in interface Quietly<DeleteBuilderMain>public DeleteBuilderMain idempotent()
Idempotentableidempotent in interface Idempotentable<DeleteBuilderMain>public ChildrenDeletable guaranteed()
Guaranteeableguaranteed in interface Guaranteeable<ChildrenDeletable>GuaranteeableDeletablepublic BackgroundVersionable deletingChildrenIfNeeded()
ChildrenDeletableWill also delete children if they exist.
deletingChildrenIfNeeded in interface ChildrenDeletablepublic BackgroundPathable<Void> withVersion(int version)
VersionablewithVersion in interface Versionable<BackgroundPathable<Void>>version - version to usepublic ErrorListenerPathable<Void> inBackground(BackgroundCallback callback, Object context)
BackgroundableinBackground in interface Backgroundable<ErrorListenerPathable<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 ErrorListenerPathable<Void> inBackground(BackgroundCallback callback, Object context, Executor executor)
BackgroundableinBackground in interface Backgroundable<ErrorListenerPathable<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 ErrorListenerPathable<Void> inBackground(BackgroundCallback callback)
BackgroundableinBackground in interface Backgroundable<ErrorListenerPathable<Void>>callback - a functor that will get called when the operation has completedpublic ErrorListenerPathable<Void> inBackground(BackgroundCallback callback, Executor executor)
BackgroundableinBackground in interface Backgroundable<ErrorListenerPathable<Void>>callback - a functor that will get called when the operation has completedexecutor - executor to use for the background callpublic ErrorListenerPathable<Void> inBackground()
BackgroundableinBackground in interface Backgroundable<ErrorListenerPathable<Void>>public ErrorListenerPathable<Void> inBackground(Object context)
BackgroundableinBackground in interface Backgroundable<ErrorListenerPathable<Void>>context - context object - will be available from the event sent to the listenerpublic Pathable<Void> withUnhandledErrorListener(UnhandledErrorListener listener)
ErrorListenerPathablewithUnhandledErrorListener in interface ErrorListenerPathable<Void>listener - the listenerpublic CuratorEventType getBackgroundEventType()
public void performBackgroundOperation(org.apache.curator.framework.imps.OperationAndData<String> operationAndData) throws Exception
Exceptionpublic Void forPath(String path) throws Exception
Pathableprotected int getVersion()
Copyright © 2011–2023 The Apache Software Foundation. All rights reserved.