Class GlobalParamsLookup

  • All Implemented Interfaces:
    Function<Map<Object,​Object>,​GlobalParamsLookup.ParameterAccessor>

    public class GlobalParamsLookup
    extends Object
    implements Function<Map<Object,​Object>,​GlobalParamsLookup.ParameterAccessor>
    Accessor class for looking up global parameters.

    Profile specific parameters are stored under the "global-parameters" selector (see ResourceConfig). The parameter values are stored in the <param> elements within this Content Delivery Resource definition. This class iterates over the list of ResourceConfig elements targeted at the ExecutionContext profile. It looks for a definition of the named parameter. If the <param> has a type attribute the ParameterDecoder for that type can be applied to the attribute value through the #getParameterObject(String, ContentDeliveryConfig) method, returning whatever Java type defined by the ParameterDecoder implementation. As an example, see TokenizedStringParameterDecoder.

    Author:
    tfennelly