public class ValueResolver<T> extends java.lang.Object implements DeferredSupplier<T>
Tasks or a DeferredSupplier then get its contents
 deep(boolean) is requested, it applies resolution to contents
 Fluent-style API exposes a number of other options.
| Modifier and Type | Class and Description | 
|---|---|
| static class  | ValueResolver.ResolverBuilderPretype | 
| Modifier and Type | Method and Description | 
|---|---|
| ValueResolver<T> | clone()returns a copy of this resolver which can be queried, even if the original (single-use instance) has already been copied | 
| ValueResolver<T> | context(ExecutionContext exec)execution context to use when resolving; required if resolving unsubmitted tasks or running with a time limit | 
| ValueResolver<T> | deep(boolean forceDeep)causes nested structures (maps, lists) to be descended and nested unresolved values resolved | 
| ValueResolver<T> | defaultValue(T defaultValue)sets a default value which will be returned on a call to  get()if the task does not complete
 or completes with an error | 
| ValueResolver<T> | description(java.lang.String description)sets a message which will be displayed in status reports while it waits (e.g. | 
| ValueResolver<T> | embedResolutionInTask(java.lang.Boolean embedResolutionInTask)if true, forces execution of a deferred supplier to be run in a task;
 if false, it prevents it (meaning time limits may not be applied);
 if null, the default, it runs in a task if a time limit is applied. | 
| T | get() | 
| Maybe<T> | getDefault() | 
| Maybe<T> | getMaybe() | 
| ValueResolver<T> | noDefaultValue()indicates that no default value should be returned on a call to  get(), and instead it should throw
 (this is the default; this method is provided to undo a call todefaultValue(Object)) | 
| ValueResolver<T> | swallowExceptions()indicates that exceptions in resolution should not be thrown on a call to  getMaybe(), 
 but rather used as part of theMaybe.get()if it's absent, 
 and swallowed altogether on a call toget()in the presence of adefaultValue(Object) | 
| ValueResolver<T> | timeout(Duration timeout)sets a time limit on executions | 
public ValueResolver<T> clone()
clone in class java.lang.Objectpublic ValueResolver<T> context(ExecutionContext exec)
public ValueResolver<T> description(java.lang.String description)
public ValueResolver<T> defaultValue(T defaultValue)
get() if the task does not complete
 or completes with an error
 
 note that getMaybe() returns an absent object even in the presence of
 a default, so that any error can still be accessed
public ValueResolver<T> noDefaultValue()
get(), and instead it should throw
 (this is the default; this method is provided to undo a call to defaultValue(Object))public ValueResolver<T> swallowExceptions()
getMaybe(), 
 but rather used as part of the Maybe.get() if it's absent, 
 and swallowed altogether on a call to get() in the presence of a defaultValue(Object)public ValueResolver<T> deep(boolean forceDeep)
public ValueResolver<T> embedResolutionInTask(java.lang.Boolean embedResolutionInTask)
 running inside a task is required for some DeferredSupplier
 instances which look up a task ExecutionContext.
public ValueResolver<T> timeout(Duration timeout)
 used for Task and DeferredSupplier instances.
 may require an execution context at runtime.
public T get()
get in interface DeferredSupplier<T>get in interface com.google.common.base.Supplier<T>