Class SystemPropertyParameterResolver

java.lang.Object
com.tangosol.config.expression.SystemPropertyParameterResolver
All Implemented Interfaces:
ParameterResolver

public class SystemPropertyParameterResolver extends Object implements ParameterResolver
A SystemPropertyParameterResolver is a ParameterResolver that is based on property methods on System.

Replaces

invalid @link
{@link com.tangosol.config.expression.PropertiesParameterResolver(java.util.Map)
} since it required read and write access for all Properties for simple property access. resolve(String) only requires read access for property specified.
Since:
Coherence 12.2.1
Author:
jf 2015.04.15
  • Field Details

  • Constructor Details

    • SystemPropertyParameterResolver

      public SystemPropertyParameterResolver()
  • Method Details

    • resolve

      public Parameter resolve(String sName)
      Resolve Coherence system property sName
      Specified by:
      resolve in interface ParameterResolver
      Parameters:
      sName - system property name
      Returns:
      a Parameter representing the value of sName or null if system property not found or if SecurityException was handled.
    • resolve

      public <T> T resolve(String sName, Class<T> clzTypeValue)
      Return property's value as requested type.
      Type Parameters:
      T - property value's target type
      Parameters:
      sName - property name
      clzTypeValue - coerce system property's value from string to instance of this class
      Returns:
      null if property has no value or return property's value coerced from string to requested type. Throws exceptions listed in Value.as(Class) when coercion fails.