Class TypeSystemDescriptionFactory

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

public final class TypeSystemDescriptionFactory extends Object
  • Method Details

    • createTypeSystemDescription

      public static org.apache.uima.resource.metadata.TypeSystemDescription createTypeSystemDescription(String... descriptorNames)
      Creates a TypeSystemDescription from descriptor names.
      Parameters:
      descriptorNames - The fully qualified, Java-style, dotted descriptor names.
      Returns:
      A TypeSystemDescription that includes the types from all of the specified files.
    • createTypeSystemDescriptionFromPath

      public static org.apache.uima.resource.metadata.TypeSystemDescription createTypeSystemDescriptionFromPath(String... descriptorURIs)
      Creates a TypeSystemDescription from a descriptor file
      Parameters:
      descriptorURIs - The descriptor file paths.
      Returns:
      A TypeSystemDescription that includes the types from all of the specified files.
    • createTypeSystemDescription

      public static org.apache.uima.resource.metadata.TypeSystemDescription createTypeSystemDescription() throws org.apache.uima.resource.ResourceInitializationException
      Creates a TypeSystemDescription from all type descriptions that can be found via the default import pattern or via the META-INF/org.apache.uima.fit/types.txt files in the classpath.
      Returns:
      the auto-scanned type system.
      Throws:
      org.apache.uima.resource.ResourceInitializationException - if the collected type system descriptions cannot be merged.
    • scanTypeDescriptors

      public static String[] scanTypeDescriptors() throws org.apache.uima.resource.ResourceInitializationException
      Get all currently accessible type system descriptor locations. A scan is actually only performed on the first call and the locations are cached. To force a re-scan use forceTypeDescriptorsScan().
      Returns:
      an array of locations.
      Throws:
      org.apache.uima.resource.ResourceInitializationException - if the locations could not be resolved.
    • forceTypeDescriptorsScan

      public static void forceTypeDescriptorsScan()
      Force rescan of type descriptors. The next call to scanTypeDescriptors() will rescan all auto-import locations.