public final class Values extends Object
Modifier and Type | Field and Description |
---|---|
static List<Value<?>> |
EMPTY_LIST
The empty value list.
|
static List<? extends Value<Class<?>>> |
EMPTY_TYPE_LIST
The empty value type list.
|
Modifier and Type | Method and Description |
---|---|
static <T> Value<T> |
asSuperclass(Value<? extends T> value)
Safely re-cast a value as its superclass.
|
static <T> Value<T> |
cached(Value<T> value)
Get a cached value for some opaque value.
|
static <T> List<Value<? extends T>> |
emptyList()
The empty value list.
|
static <T> Value<List<T>> |
emptyListValue()
A value which yields the empty list.
|
static Object[] |
getValues(Iterable<? extends Value<?>> i)
Get an object array from the result of an iterable series of values.
|
static <T> T[] |
getValues(Iterable<? extends Value<? extends T>> i,
Class<T> clazz)
Get a typed object array from the result of an iterable series of values.
|
static <T> T[] |
getValues(Iterable<? extends Value<? extends T>> i,
T[] array)
Get a typed object array from the result of an iterable series of values.
|
static <T> Value<T> |
immediateValue(T value)
Get an immediate value.
|
static <T> List<Value<? extends T>> |
immediateValues(List<T> values) |
static <T> List<Value<? extends T>> |
immediateValues(T... values) |
static ThreadLocalValue<Object> |
injectedValue()
The special value representing the value of an injection operation.
|
static <T> Value<T> |
nullValue()
Get the null value.
|
static ThreadLocalValue<Object> |
thisValue()
The special value representing
this (the object being invoked upon). |
public static Object[] getValues(Iterable<? extends Value<?>> i)
i
- the iterable seriespublic static <T> T[] getValues(Iterable<? extends Value<? extends T>> i, Class<T> clazz)
i
- the iterable seriesclazz
- the resultant array typepublic static <T> T[] getValues(Iterable<? extends Value<? extends T>> i, T[] array)
i
- the iterable seriesarray
- the array to populatepublic static <T> Value<T> nullValue()
T
- the value typenull
public static <T> Value<T> cached(Value<T> value)
T
- the value typevalue
- the value to wrappublic static <T> List<Value<? extends T>> emptyList()
T
- the value typepublic static <T> Value<T> immediateValue(T value)
T
- the value typevalue
- the value to returnpublic static <T> Value<List<T>> emptyListValue()
T
- the list member typepublic static <T> Value<T> asSuperclass(Value<? extends T> value)
T
- the value typevalue
- the value to re-castpublic static ThreadLocalValue<Object> thisValue()
this
(the object being invoked upon).this
public static ThreadLocalValue<Object> injectedValue()
Copyright © 2017 JBoss by Red Hat. All rights reserved.