Class EvictionPolicyBuilder
java.lang.Object
com.tangosol.coherence.config.builder.DefaultBuilderCustomization<ConfigurableCacheMap.EvictionPolicy>
com.tangosol.coherence.config.builder.EvictionPolicyBuilder
- All Implemented Interfaces:
BuilderCustomization<ConfigurableCacheMap.EvictionPolicy>,ParameterizedBuilder<ConfigurableCacheMap.EvictionPolicy>,ParameterizedBuilder.ReflectionSupport
public class EvictionPolicyBuilder
extends DefaultBuilderCustomization<ConfigurableCacheMap.EvictionPolicy>
implements ParameterizedBuilder<ConfigurableCacheMap.EvictionPolicy>, ParameterizedBuilder.ReflectionSupport
The
EvictionPolicyBuilder builds a ConfigurableCacheMap.EvictionPolicy.- Since:
- Coherence 12.1.2
- Author:
- pfm 2012.01.07
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.tangosol.coherence.config.builder.ParameterizedBuilder
ParameterizedBuilder.ReflectionSupport -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetEvictionType(ParameterResolver resolver) Obtains the EvictionPolicy type.realize(ParameterResolver resolver, ClassLoader loader, ParameterList listParameters) Realizes (creates if necessary) an instance of a object of type T, using the providedParameterResolverto resolve values any referencedParameters.booleanrealizes(Class<?> clzClass, ParameterResolver resolver, ClassLoader loader) Determines if theParameterizedBuilderwill realize an instance of the specified class (without requiring the builder to actually realize an object).voidsetEvictionType(Expression<String> expr) Set the EvictionPolicy type.Methods inherited from class com.tangosol.coherence.config.builder.DefaultBuilderCustomization
getCustomBuilder, setCustomBuilder
-
Constructor Details
-
EvictionPolicyBuilder
public EvictionPolicyBuilder()
-
-
Method Details
-
getEvictionType
Obtains the EvictionPolicy type.- Parameters:
resolver- theParameterResolver- Returns:
- the type of EvictionPolicy
-
setEvictionType
Set the EvictionPolicy type.- Parameters:
expr- the EvictionPolicy type
-
realizes
Determines if theParameterizedBuilderwill realize an instance of the specified class (without requiring the builder to actually realize an object).This method is synonymous with the Java keyword
instanceofbut allows dynamic runtime type querying of the types of objects a builder may realize.- Specified by:
realizesin interfaceParameterizedBuilder.ReflectionSupport- Parameters:
clzClass- the expected typeresolver- theParameterResolverto use for resolving necessaryParametersloader- theClassLoaderfor loading any necessary classes and ifnulltheClassLoaderused to load the builder will be used instead- Returns:
trueif theParameterizedBuilderwill realize an instance of the class,falseotherwise
-
realize
public ConfigurableCacheMap.EvictionPolicy realize(ParameterResolver resolver, ClassLoader loader, ParameterList listParameters) Realizes (creates if necessary) an instance of a object of type T, using the providedParameterResolverto resolve values any referencedParameters.- Specified by:
realizein interfaceParameterizedBuilder<ConfigurableCacheMap.EvictionPolicy>- Parameters:
resolver- theParameterResolverfor resolving namedParametersloader- theClassLoaderfor loading any necessary classes and ifnulltheClassLoaderused to load the builder will be used insteadlistParameters- an optionalParameterList(may benull) to be used for realizing the instance, eg: used as constructor parameters- Returns:
- an instance of T
-