public abstract class TakeOptions extends java.lang.Object implements SpaceOptions<TakeOptions>
take
operations. TakeOptions is used as a parameter to the following
methods of Space
:
Space.take(Tuple, TakeOptions)
Space.takeAll(Collection, TakeOptions)
Space.compareAndTake(Tuple, TakeOptions)
Space.compareAndTakeAll(Collection, TakeOptions)
create()
.Constructor and Description |
---|
TakeOptions() |
Modifier and Type | Method and Description |
---|---|
abstract java.lang.Object |
clone()
Method to create a clone of this TakeOptions object.
|
static TakeOptions |
create()
Method used to instantiate an instance of a TakeOptions object.
|
abstract long |
getLockWait()
Retrieve the current setting for the amount of time a
take operation
should wait for the lock to be cleared on an existing locked tuple. |
abstract boolean |
isForget()
Retrieve the current setting for whether or not to return the tuple taken from
a space using this TakeOptions object.
|
abstract boolean |
isLock()
Retrieve the current setting for whether or not to lock the key of a tuple after
it is removed from a space.
|
abstract boolean |
isRoute()
Retrieve whether the
take operation is routed. |
abstract boolean |
isUnlock()
Retrieve the current setting for whether or not to unlock the key of a tuple
after it is removed from a space.
|
abstract TakeOptions |
setForget(boolean doForget)
Specify whether or not to return the tuple taken from a space using this
TakeOptions object.
|
abstract TakeOptions |
setLock(boolean doLock)
Specify whether or not to lock the key of a tuple after it is removed from a space.
|
abstract TakeOptions |
setLockWait(long lockWait)
Specify the amount of time to wait to acquire the lock on an
existing locked tuple.
|
abstract TakeOptions |
setRoute(boolean doRoute)
Specifies whether the
take operation should be routed. |
abstract TakeOptions |
setUnlock(boolean doUnlock)
Specify whether or not to unlock the key of a tuple after it is removed from a space.
|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getClosure, getResultHandler, setClosure, setResultHandler
public static TakeOptions create()
public abstract java.lang.Object clone()
clone
in class java.lang.Object
public abstract TakeOptions setLockWait(long lockWait)
lockWait
- Number of milliseconds to wait for a lock.public abstract TakeOptions setLock(boolean doLock)
doLock
- true - lock the key. false - do not lock the key.public abstract TakeOptions setUnlock(boolean doUnlock)
doUnlock
- true - Unlock the key. false - Do not unlock they key.public abstract TakeOptions setForget(boolean doForget)
doForget
- true - Do not return the tuple taken from the space.
false - Return the tuple taken from the space.public abstract long getLockWait()
take
operation
should wait for the lock to be cleared on an existing locked tuple.public abstract boolean isLock()
public abstract boolean isUnlock()
public abstract boolean isForget()
public abstract TakeOptions setRoute(boolean doRoute)
take
operation should be routed.doRoute
- true - Route the operation. false - Do not route the operation.public abstract boolean isRoute()
take
operation is routed.Copyright (c) 2014 Cloud Software Group, Inc. All rights reserved.