Class ResourceCreationSpecifierFactory

java.lang.Object
org.apache.uima.fit.factory.ResourceCreationSpecifierFactory

public final class ResourceCreationSpecifierFactory extends Object
  • Method Summary

    Modifier and Type
    Method
    Description
    static org.apache.uima.resource.ResourceCreationSpecifier
    createResourceCreationSpecifier(String descriptorPath, Object[] parameters)
    Parse a ResourceCreationSpecifier from an XML descriptor file, setting additional configuration parameters as necessary.
    static org.apache.uima.resource.ResourceCreationSpecifier
    createResourceCreationSpecifier(URL descriptorURL, Object[] parameters)
    Parse a ResourceCreationSpecifier from the URL of an XML descriptor file, setting additional configuration parameters as necessary.
    static org.apache.uima.resource.ResourceCreationSpecifier
    createResourceCreationSpecifier(org.apache.uima.util.XMLInputSource xmlInput, Object[] parameters)
    Parse a ResourceCreationSpecifier from XML descriptor file input, setting additional configuration parameters as necessary.
    static void
    setConfigurationParameters(org.apache.uima.resource.metadata.ResourceMetaData metaData, org.apache.uima.resource.metadata.ConfigurationParameter[] configurationParameters, Object[] configurationValues)
    This method sets the configuration parameters of a resource.
    static void
    setConfigurationParameters(org.apache.uima.resource.ResourceCreationSpecifier specifier, Object... configurationData)
    Create configuration parameter declarations and settings from a list of (name, value) pairs.
    static void
    setConfigurationParameters(org.apache.uima.resource.ResourceCreationSpecifier specifier, org.apache.uima.resource.metadata.ConfigurationParameter[] configurationParameters, Object[] configurationValues)

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • createResourceCreationSpecifier

      public static org.apache.uima.resource.ResourceCreationSpecifier createResourceCreationSpecifier(URL descriptorURL, Object[] parameters) throws org.apache.uima.util.InvalidXMLException, IOException
      Parse a ResourceCreationSpecifier from the URL of an XML descriptor file, setting additional configuration parameters as necessary.
      Parameters:
      descriptorURL - The URL of the XML descriptor file.
      parameters - Any additional configuration parameters to be set. These should be supplied as (name, value) pairs, so there should always be an even number of parameters.
      Returns:
      The ResourceCreationSpecifier for the XML descriptor with all the configuration parameters set.
      Throws:
      IOException - if an I/O error occurs
      org.apache.uima.util.InvalidXMLException - if the input XML is not valid or does not specify a valid ResourceSpecifier
    • createResourceCreationSpecifier

      public static org.apache.uima.resource.ResourceCreationSpecifier createResourceCreationSpecifier(org.apache.uima.util.XMLInputSource xmlInput, Object[] parameters) throws org.apache.uima.util.InvalidXMLException
      Parse a ResourceCreationSpecifier from XML descriptor file input, setting additional configuration parameters as necessary.
      Parameters:
      xmlInput - The descriptor file as an XMLInputSource.
      parameters - Any additional configuration parameters to be set. These should be supplied as (name, value) pairs, so there should always be an even number of parameters.
      Returns:
      The ResourceCreationSpecifier for the XML descriptor with all the configuration parameters set.
      Throws:
      org.apache.uima.util.InvalidXMLException - if the input XML is not valid or does not specify a valid ResourceSpecifier
    • createResourceCreationSpecifier

      public static org.apache.uima.resource.ResourceCreationSpecifier createResourceCreationSpecifier(String descriptorPath, Object[] parameters) throws org.apache.uima.util.InvalidXMLException, IOException
      Parse a ResourceCreationSpecifier from an XML descriptor file, setting additional configuration parameters as necessary.
      Parameters:
      descriptorPath - The path to the XML descriptor file.
      parameters - Any additional configuration parameters to be set. These should be supplied as (name, value) pairs, so there should always be an even number of parameters.
      Returns:
      The ResourceCreationSpecifier for the XML descriptor with all the configuration parameters set.
      Throws:
      IOException - if an I/O error occurs
      org.apache.uima.util.InvalidXMLException - if the input XML is not valid or does not specify a valid ResourceSpecifier
    • setConfigurationParameters

      public static void setConfigurationParameters(org.apache.uima.resource.ResourceCreationSpecifier specifier, Object... configurationData)
      Create configuration parameter declarations and settings from a list of (name, value) pairs.
      Parameters:
      specifier - The ResourceCreationSpecifier whose parameters are to be set.
      configurationData - The configuration parameters to be set. These should be supplied as (name, value) pairs, so there should always be an even number of parameters.
    • setConfigurationParameters

      public static void setConfigurationParameters(org.apache.uima.resource.ResourceCreationSpecifier specifier, org.apache.uima.resource.metadata.ConfigurationParameter[] configurationParameters, Object[] configurationValues)
      Parameters:
      specifier - The ResourceCreationSpecifier whose parameters are to be set.
      configurationParameters - the configuration parameter declarations.
      configurationValues - the configuration parameter values.
    • setConfigurationParameters

      public static void setConfigurationParameters(org.apache.uima.resource.metadata.ResourceMetaData metaData, org.apache.uima.resource.metadata.ConfigurationParameter[] configurationParameters, Object[] configurationValues)
      This method sets the configuration parameters of a resource. The length of configurationParameters and configurationValues should be equal
      Parameters:
      metaData - The ResourceMetaData whose parameters are to be set.
      configurationParameters - an array of configuration parameters
      configurationValues - an array of configuration parameter values