| Package | Description |
|---|---|
| org.gridgain.grid.util |
System-wide utility routine and helper classes.
|
| org.gridgain.grid.util.lang | |
| org.gridgain.grid.util.typedef |
Contains typedefs definitions for frequently used classes.
|
| Modifier and Type | Method and Description |
|---|---|
static <R> R |
GridUtils.wrapThreadLoader(ClassLoader ldr,
GridOutClosure<R> c)
Sets thread context class loader to the given loader, executes the closure, and then
resets thread context class loader to its initial value.
|
| Constructor and Description |
|---|
GridThreadLocal(GridOutClosure<T> initializer) |
GridThreadLocalEx(GridOutClosure<T> initializer) |
| Modifier and Type | Interface and Description |
|---|---|
interface |
GridReducer2<E1,E2,R>
Defines generic
for-all or reduce type of closure. |
interface |
GridReducer3<E1,E2,E3,R>
Defines generic
for-all or reduce type of closure. |
| Modifier and Type | Class and Description |
|---|---|
class |
GridOutClosureX<T>
Convenient out-closure subclass that allows for thrown grid exception.
|
class |
GridReducer2X<E1,E2,R>
Convenient reducer subclass that allows for thrown grid exception.
|
class |
GridReducer3X<E1,E2,E3,R>
Convenient reducer subclass that allows for thrown grid exception.
|
| Modifier and Type | Method and Description |
|---|---|
static <T> GridOutClosure |
GridFunc.as(Future<T> fut)
Converts given future into the closure.
|
static GridOutClosure<Boolean> |
GridFunc.as(GridAbsPredicate p)
Converts given predicate to closure.
|
static <R> GridOutClosure<R> |
GridFunc.as0(Callable<R> c)
Converts given callable to an out-closure.
|
static <R> GridOutClosure<R> |
GridFunc.coInvoke(Class<?> cls,
String mtdName,
Object... args)
Creates out closure that will reflectively call a static method with the given name
and return result of that call.
|
static <R> GridOutClosure<R> |
GridFunc.coInvoke(Object o,
String mtdName,
Object... args)
Creates out closure that will reflectively call a method with the given name on provided
object and return result of that call.
|
static <R> GridOutClosure<R> |
GridFunc.constant(R val)
Gets closure that returns constant value.
|
static <T,R> GridOutClosure<R> |
GridFunc.curry(GridClosure<? super T,R> f,
T e)
Curries given closure.
|
static <T> GridOutClosure<T> |
GridFunc.factory(Class<T> cls)
Creates and returns new factory closure for the given type.
|
static <T> GridOutClosure<T> |
GridFunc.nill()
Returns out closure that always returns
null. |
| Modifier and Type | Method and Description |
|---|---|
static <T> GridClosure<Callable<T>,GridOutClosure<T>> |
GridFunc.c2c()
Returns closure that converts
Callable to GridOutClosure. |
static <T,R> Collection<GridOutClosure<R>> |
GridFunc.curry(Collection<? extends GridClosure<? super T,R>> closures,
Collection<? extends T> args)
Curries collection of closures with given collection of arguments.
|
static <T,R> Collection<GridOutClosure<R>> |
GridFunc.curry(Collection<? extends GridClosure<? super T,R>> iter,
T arg)
Curries collection of closures with given argument.
|
static <T,R> Collection<GridOutClosure<R>> |
GridFunc.curry(GridClosure<? super T,R> c,
Collection<? extends T> args)
Curries collection of closures with given collection of arguments.
|
static <T,R> Collection<GridOutClosure<R>> |
GridFunc.curry(int cnt,
GridClosure<? super T,R> c,
GridOutClosure<T> pdc)
Curries collection of closures with given collection of arguments.
|
static <T,R> Collection<GridOutClosure<R>> |
GridFunc.yield(Collection<? extends T> c,
GridClosure<? super T,R> f)
Given collection of items and a closure this method returns
read only collection of closures where each closure is closed on an element
of the initial collection.
|
static <T,R> Collection<GridOutClosure<R>> |
GridFunc.yield(T[] c,
GridClosure<? super T,R> f)
Given array of items and a closure this method returns collection
of closures where each closure is closed on a element of the array.
|
| Modifier and Type | Method and Description |
|---|---|
static <T,R> Collection<GridOutClosure<R>> |
GridFunc.curry(int cnt,
GridClosure<? super T,R> c,
GridOutClosure<T> pdc)
Curries collection of closures with given collection of arguments.
|
static <T> Collection<GridAbsClosure> |
GridFunc.curry(int cnt,
GridInClosure<? super T> c,
GridOutClosure<T> pdc)
Curries collection of closures with given collection of arguments.
|
| Modifier and Type | Interface and Description |
|---|---|
interface |
CO<T>
Defines
alias for GridOutClosure by extending it. |
interface |
R2<E1,E2,R>
Defines
alias for GridReducer2 by extending it. |
interface |
R3<E1,E2,E3,R>
Defines
alias for GridReducer3 by extending it. |
| Modifier and Type | Class and Description |
|---|---|
class |
COX<T>
Defines
alias for GridOutClosureX by extending it. |
class |
RX2<E1,E2,R>
Defines
alias for GridReducer2X by extending it. |
class |
RX3<E1,E2,E3,R>
Defines
alias for GridReducer3X by extending it. |
Copyright © 2014. All rights reserved.