org.apache.uima.resource.metadata

## Interface Import

- All Superinterfaces:
    Cloneable, MetaDataObject, Serializable, XMLizable

      public interface Import
      extends MetaDataObject

  An import declaration. These are currently used to import type systems, indexes, and type priorities. Imports may be by location (relative URL) or name (a Java-style compound name, looked up in the classpath), but not both.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static Import[]` | `EMPTY_IMPORTS`

  - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `URL` | `findAbsoluteUrl(ResourceManager aResourceManager)` Computes the absolute URL for this import, using the relative location or name, whichever is specified by this import object.
    `String` | `getLocation()` Gets the location of this import's target.
    `String` | `getName()` Gets the name of this import's target.
    `void` | `setLocation(String aUri)` Sets the location of this import's target.
    `void` | `setName(String aName)` Sets the name of this import's target.

    - ### Methods inherited from interface org.apache.uima.resource.metadata.MetaDataObject

      `clone, equals, getAttributeValue, getSourceUrl, getSourceUrlString, isModifiable, listAttributes, setAttributeValue, setSourceUrl`

    - ### Methods inherited from interface org.apache.uima.util.XMLizable

      `buildFromXMLElement, buildFromXMLElement, toXML, toXML, toXML, toXML`

- - ### Field Detail

    - #### EMPTY_IMPORTS

          static final Import[] EMPTY_IMPORTS

  - ### Method Detail

    - #### getName

          String getName()

      Gets the name of this import's target.
      Returns:
        a Java-style compound name which specifies the target of this import. This will be located by appending ".xml" to the name and searching the classpath.

    - #### setName

          void setName(String aName)

      Sets the name of this import's target.
      Parameters:
        `aName` - a Java-style compound name which specifies the target of this import. This will be located by appending ".xml" to the name and searching the classpath.

    - #### getLocation

          String getLocation()

      Gets the location of this import's target.
      Returns:
        a URI specifying the location of this import's target.

    - #### setLocation

          void setLocation(String aUri)

      Sets the location of this import's target.
      Parameters:
        `aUri` - a URI specifying the location of this import's target.

    - #### findAbsoluteUrl

          URL findAbsoluteUrl(ResourceManager aResourceManager)
                       throws InvalidXMLException

      Computes the absolute URL for this import, using the relative location or name, whichever is specified by this import object.
      Parameters:
        `aResourceManager` - resource manager to use to do name lookups
      Returns:
        the absolute URL for this import
      Throws:
        `InvalidXMLException` - if the import could not be resolved

Copyright © 2006–2019 The Apache Software Foundation. All rights reserved.