net.sf.okapi.lib.xliff2.core

## Interface IWithExtAttributes

- All Known Implementing Classes:
    CTag, DataWithExtAttributes, Definition, ExtElement, GlossEntry, Item, Match, MTag, Note, Notes, Revision, Revisions, Rule, StartFileData, StartGroupData, StartXliffData, Tag, Term, TermTag, Translation, Unit, Validation

      public interface IWithExtAttributes

  Provides a common interface to all objects that can have extension attributes.
  See Also:
    `ExtAttributes`, `ExtAttribute`

- - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `ExtAttributes` | `getExtAttributes()` Gets the `ExtAttributes` object for the parent object.
    `java.lang.String` | `getExtAttributeValue(java.lang.String namespaceURI, java.lang.String localName)` Gets the value for a given extension attribute.
    `boolean` | `hasExtAttribute()` Indicates if at least one extension attribute is present.
    `void` | `setExtAttributes(ExtAttributes attributes)` Sets the `ExtAttributes` object associated with this object.

- - ### Method Detail

    - #### getExtAttributes

          ExtAttributes getExtAttributes()

      Gets the `ExtAttributes` object for the parent object. If none exists, one is created.
      Returns:
        the `ExtAttributes` object for the parent object, never null.

    - #### setExtAttributes

          void setExtAttributes(ExtAttributes attributes)

      Sets the `ExtAttributes` object associated with this object.
      Parameters:
        `attributes` - the `ExtAttributes` object associated with this object. If null, a new `ExtAttributes` object is created.

    - #### hasExtAttribute

          boolean hasExtAttribute()

      Indicates if at least one extension attribute is present.
      Returns:
        true if at least one extension attribute is present; false otherwise.

    - #### getExtAttributeValue

          java.lang.String getExtAttributeValue(java.lang.String namespaceURI,
                                              java.lang.String localName)

      Gets the value for a given extension attribute.
      Parameters:
        `namespaceURI` - the URI of the namespace for the attribute.
        `localName` - the name of the attribute.
      Returns:
        the value of the extension attribute, or null if it does not exist.