Package com.tangosol.util
Class ResourceResolverHelper
- java.lang.Object
-
- com.tangosol.util.ResourceResolverHelper
-
public class ResourceResolverHelper extends Object
Provides helpful methods for working withResourceResolver
s.- Since:
- Coherence 12.1.2
- Author:
- bo 2012.11.13
- See Also:
ResourceResolver
-
-
Constructor Summary
Constructors Constructor Description ResourceResolverHelper()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static ResourceResolver
resourceResolverFrom(MapBuilder.Dependencies dependencies)
Constructs and configures aResourceResolver
from aMapBuilder
dependencies.static ResourceResolver
resourceResolverFrom(ParameterResolver parameterResolver, ParameterResolver resolverForExpressionEvaluation)
Constructs aResourceResolver
based on aParameterResolver
.static ResourceResolver
resourceResolverFrom(ResourceResolver... resourceResolvers)
Constructs aResourceResolver
based on a sequence of specifiedResourceResolver
s.static <T> ResourceResolver
resourceResolverFrom(Class<T> clsResolvableResource, String sResolvableResourceName, T resolveableResource)
Constructs aResourceResolver
for a single named resource.static <T> ResourceResolver
resourceResolverFrom(Class<T> clsResolvableResource, T resolveableResource)
Constructs aResourceResolver
for a single resource.
-
-
-
Method Detail
-
resourceResolverFrom
public static ResourceResolver resourceResolverFrom(MapBuilder.Dependencies dependencies)
Constructs and configures aResourceResolver
from aMapBuilder
dependencies.When a
ConfigurableCacheFactory
is available in the dependencies, theResourceRegistry
is returns as the second part of aChainedResourceResolver
.- Parameters:
dependencies
- theMapBuilder
dependencies- Returns:
- a
ResourceResolver
-
resourceResolverFrom
public static ResourceResolver resourceResolverFrom(ParameterResolver parameterResolver, ParameterResolver resolverForExpressionEvaluation)
Constructs aResourceResolver
based on aParameterResolver
.- Parameters:
parameterResolver
- theParameterResolver
to adapt into aResourceResolver
resolverForExpressionEvaluation
- theParameterResolver
to use for evaluatingParameter
s- Returns:
- a
ResourceResolver
-
resourceResolverFrom
public static ResourceResolver resourceResolverFrom(ResourceResolver... resourceResolvers)
Constructs aResourceResolver
based on a sequence of specifiedResourceResolver
s.- Parameters:
resourceResolvers
- theResourceResolver
s- Returns:
- a
ResourceResolver
-
resourceResolverFrom
public static <T> ResourceResolver resourceResolverFrom(Class<T> clsResolvableResource, String sResolvableResourceName, T resolveableResource)
Constructs aResourceResolver
for a single named resource.- Parameters:
clsResolvableResource
- theClass
of the resourcesResolvableResourceName
- the name of the resourceresolveableResource
- the resource- Returns:
- a
ResourceResolver
for the specified resource
-
resourceResolverFrom
public static <T> ResourceResolver resourceResolverFrom(Class<T> clsResolvableResource, T resolveableResource)
Constructs aResourceResolver
for a single resource.- Parameters:
clsResolvableResource
- theClass
of the resourceresolveableResource
- the resource- Returns:
- a
ResourceResolver
for the specified resource
-
-