Interface ConfigurationParameterDeclarations

    • Field Detail

      • SEARCH_STRATEGY_NONE

        static final String SEARCH_STRATEGY_NONE
        A value for the searchStrategy property indicating that there is no fallback. If a request is made for the value of a parameter in a group and there is no such value in that exact group, null will be returned.
        See Also:
        Constant Field Values
      • SEARCH_STRATEGY_DEFAULT_FALLBACK

        static final String SEARCH_STRATEGY_DEFAULT_FALLBACK
        A value for the searchStrategy property indicating that if there is no value declared in a group, look in the default group.
        See Also:
        Constant Field Values
      • SEARCH_STRATEGY_LANGUAGE_FALLBACK

        static final String SEARCH_STRATEGY_LANGUAGE_FALLBACK
        A value for the searchStrategy property that is useful when ISO language and country codes are used as configuration group names. If there is no value declared in a group, look in more general groups. The fallback sequence is lang-country-region -%gt; lang-country -%gt; lang -%gt; default. For example, if a request is made for the value of a parameter in the "en-GB" group and no such group exists, the value from the "en" group will be used instead.
        See Also:
        Constant Field Values
    • Method Detail

      • getConfigurationParameters

        ConfigurationParameter[] getConfigurationParameters()
        Gets the configuration parameters for this Resource. This gets configuration parameters that are not defined within a group - see also getConfigurationGroups().
        Returns:
        an array containing ConfigurationParameter objects, each of which describes a configuration parameter for this Resource.
      • addConfigurationParameter

        void addConfigurationParameter​(ConfigurationParameter aConfigurationParameter)
        Adds a Configuration Parameter that is not in any group.
        Parameters:
        aConfigurationParameter - the Configuration Parameter to add
        Throws:
        UIMA_UnsupportedOperationException - if this object is not modifiable
      • removeConfigurationParameter

        void removeConfigurationParameter​(ConfigurationParameter aConfigurationParameter)
        Removes an Configuration Parameter that is not in any group.
        Parameters:
        aConfigurationParameter - the Configuration Parameter to remove (must be == with an ConfigurationParameter in this collection, or this method will do nothing).
        Throws:
        UIMA_UnsupportedOperationException - if this object is not modifiable
      • getConfigurationGroups

        ConfigurationGroup[] getConfigurationGroups()
        Gets the configuration parameter groups for this Resource.
        Returns:
        an array containing ConfigurationGroup objects, each of which describes a configuration parameter group for this Resource.
      • setConfigurationGroups

        void setConfigurationGroups​(ConfigurationGroup[] aGroups)
        Sets the configuration parameter groups for this Resource.
        Parameters:
        aGroups - an array containing ConfigurationGroup objects, each of which describes a configuration parameter group for this Resource.
        Throws:
        UIMA_UnsupportedOperationException - if this object is not modifiable
      • addConfigurationGroup

        void addConfigurationGroup​(ConfigurationGroup aConfigurationGroup)
        Adds a Configuration Group.
        Parameters:
        aConfigurationGroup - the Configuration Group to add
        Throws:
        UIMA_UnsupportedOperationException - if this object is not modifiable
      • removeConfigurationGroup

        void removeConfigurationGroup​(ConfigurationGroup aConfigurationGroup)
        Removes an Configuration Group
        Parameters:
        aConfigurationGroup - the Configuration Group to remove (must be == with an ConfigurationGroup defined on this resource, or this method will do nothing).
        Throws:
        UIMA_UnsupportedOperationException - if this object is not modifiable
      • getCommonParameters

        ConfigurationParameter[] getCommonParameters()
        Gets the configuration parameters that are common to all groups. This property is only meaningful if at least one group is defined.
        Returns:
        an array containing ConfigurationParameter objects, each of which describes a parameter common to all groups.
      • setCommonParameters

        void setCommonParameters​(ConfigurationParameter[] aParams)
        Sets the configuration parameters that are common to all groups. This property is only meaningful if at least one group is defined.
        Parameters:
        aParams - an array containing ConfigurationParameter objects, each of which describes a parameter common to all groups.
      • addCommonParameter

        void addCommonParameter​(ConfigurationParameter aConfigurationParameter)
        Adds a Configuration Parameter that is common to all groups.
        Parameters:
        aConfigurationParameter - the Configuration Parameter to add
        Throws:
        UIMA_UnsupportedOperationException - if this object is not modifiable
      • removeCommonParameter

        void removeCommonParameter​(ConfigurationParameter aConfigurationParameter)
        Removes an Configuration Parameter that is common to all groups.
        Parameters:
        aConfigurationParameter - the Configuration Parameter to remove (must be == with an ConfigurationParameter in this collection, or this method will do nothing).
        Throws:
        UIMA_UnsupportedOperationException - if this object is not modifiable
      • getDefaultGroupName

        String getDefaultGroupName()
        Gets the name of the default configuration group. This must refer to the names of the configuration groups.
        Returns:
        the name of the default configuration group
      • setDefaultGroupName

        void setDefaultGroupName​(String aGroupName)
        Sets the name of the default configuration group. This must refer to the names of the configuration groups.
        Parameters:
        aGroupName - the name of the default configuration group
      • getSearchStrategy

        String getSearchStrategy()
        Gets the configuration parameter search strategy. Valid values for this property are defined by constants on this interface.
        Returns:
        the configuration parameter search strategy
      • setSearchStrategy

        void setSearchStrategy​(String aStrategy)
        Sets the configuration parameter search strategy. Valid values for this property are defined by constants on this interface.
        Parameters:
        aStrategy - the configuration parameter search strategy
      • getConfigurationParameter

        ConfigurationParameter getConfigurationParameter​(String aGroupName,
                                                         String aParamName)
        Gets a configuration parameter.
        Parameters:
        aGroupName - the name of a group, or null for no group
        aParamName - the name of the parameter
        Returns:
        the specified parameter, null if it does not exist
      • getConfigurationGroupDeclarations

        ConfigurationGroup[] getConfigurationGroupDeclarations​(String aGroupName)
        Gets the declarations of a named configuration group. There may be more than one declaration for a single group name; in this case, all parameters contained in each of these declarations are considered part of the named group.
        Parameters:
        aGroupName - the name of a group
        Returns:
        an array of ConfigurationGroup declarations having the name aGroupName. If there are no such groups, an empty array is returned.