T - the generic type for the instances built.public class ObjectBuilderValueResolver<T> extends org.mule.runtime.api.component.AbstractComponent implements ValueResolver<T>, org.mule.runtime.api.lifecycle.Initialisable, ParameterValueResolver
ValueResolver which wraps an ObjectBuilder and calls ObjectBuilder.build(ValueResolvingContext) on
each resolve(ValueResolvingContext).
It implements Lifecycle and propagates all lifecycle events to the underlying builder| Constructor and Description |
|---|
ObjectBuilderValueResolver(ObjectBuilder<T> builder,
MuleContext muleContext) |
| Modifier and Type | Method and Description |
|---|---|
Map<String,ValueResolver<? extends Object>> |
getParameters() |
Object |
getParameterValue(String parameterName) |
void |
initialise() |
boolean |
isDynamic()
Returns
false if subsequent invocations to ValueResolver.resolve(ValueResolvingContext) will return the same value. |
T |
resolve(ValueResolvingContext context)
Delegates to
builder |
public ObjectBuilderValueResolver(ObjectBuilder<T> builder, MuleContext muleContext)
public T resolve(ValueResolvingContext context) throws org.mule.runtime.api.exception.MuleException
builderresolve in interface ValueResolver<T>context - a ValueResolvingContextbuilder's output objectorg.mule.runtime.api.exception.MuleExceptionpublic boolean isDynamic()
ValueResolverfalse if subsequent invocations to ValueResolver.resolve(ValueResolvingContext) will return the same value. Notice
that if it returns true, then it might return different values per invocation but that's not guaranteed.isDynamic in interface ValueResolver<T>true if builder is dynamicpublic void initialise()
throws org.mule.runtime.api.lifecycle.InitialisationException
initialise in interface org.mule.runtime.api.lifecycle.Initialisableorg.mule.runtime.api.lifecycle.InitialisationExceptionpublic Object getParameterValue(String parameterName) throws ValueResolvingException
getParameterValue in interface ParameterValueResolverValueResolvingException - if the resolution failspublic Map<String,ValueResolver<? extends Object>> getParameters() throws ValueResolvingException
getParameters in interface ParameterValueResolverValueResolvers as values.ValueResolvingExceptionCopyright © 2003–2025 MuleSoft, Inc.. All rights reserved.