public class ChangeExtension extends Object
GigaSpace.change(com.gigaspaces.query.ISpaceQuery, ChangeSet, ChangeModifiers, long)
API which simplify common usage patterns.Constructor and Description |
---|
ChangeExtension() |
Modifier and Type | Method and Description |
---|---|
static <T,D extends Number> |
addAndGet(GigaSpace gigaSpace,
IdQuery<T> idQuery,
String path,
D delta)
Atomically adds the given value to the current value of an entry's property.
|
static <T,D extends Number> |
addAndGet(GigaSpace gigaSpace,
IdQuery<T> idQuery,
String path,
D delta,
ChangeModifiers modifiers,
long timeout,
TimeUnit timeUnit)
Atomically adds the given value to the current value of an entry's property.
|
static <T,D extends Number> |
addAndGet(GigaSpace gigaSpace,
IdQuery<T> idQuery,
String path,
D delta,
long timeout,
TimeUnit timeUnit)
Atomically adds the given value to the current value of an entry's property.
|
static <T> T |
getSingleChangeOperationResult(ChangeResult<?> changeResult)
Gets the result of a single change operation which that was applied on a single entry, otherwise an exception will be thrown.
|
public static <T,D extends Number> D addAndGet(GigaSpace gigaSpace, IdQuery<T> idQuery, String path, D delta)
gigaSpace
- the gigaspace which stores the entry.idQuery
- id the query which is used to locate the entry.path
- the path to the number property which is being modified.delta
- the value to add.NullPointerException
if no entry was found.public static <T,D extends Number> D addAndGet(GigaSpace gigaSpace, IdQuery<T> idQuery, String path, D delta, long timeout, TimeUnit timeUnit)
gigaSpace
- the gigaspace which stores the entry.idQuery
- id the query which is used to locate the entry.path
- the path to the number property which is being modified.delta
- the value to add.timeout
- time to wait if the entry is locked under a transaction.timeUnit
- units for the timeout.NullPointerException
if no entry was found.public static <T,D extends Number> D addAndGet(GigaSpace gigaSpace, IdQuery<T> idQuery, String path, D delta, ChangeModifiers modifiers, long timeout, TimeUnit timeUnit)
gigaSpace
- the gigaspace which stores the entry.idQuery
- id the query which is used to locate the entry.path
- the path to the number property which is being modified.delta
- the value to add.modifiers
- the change modifiers to use.timeout
- time to wait if the entry is locked under a transaction.timeUnit
- units for the timeout.NullPointerException
if no entry was found.public static <T> T getSingleChangeOperationResult(ChangeResult<?> changeResult)
changeResult
- the result of the change operationCopyright © GigaSpaces.