net.sf.okapi.common.resource

## Interface IWithProperties

- All Known Subinterfaces:
    INameable, ITextUnit
  All Known Implementing Classes:
    BaseNameable, BaseReferenceable, DocumentPart, Segment, StartDocument, StartGroup, StartSubDocument, StartSubfilter, StorageList, TextContainer, TextPart, TextUnit

      public interface IWithProperties

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `Property` | `getProperty(java.lang.String name)` Gets the resource-level property for a given name.
    `java.util.Set<java.lang.String>` | `getPropertyNames()` Gets the names of all the resource-level properties for this resource.
    `boolean` | `hasProperty(java.lang.String name)` Indicates if a resource-level property exists for a given name.
    `void` | `removeProperty(java.lang.String name)` Removes a resource-level property of a given name.
    `Property` | `setProperty(Property property)` Sets a resource-level property.

- - ### Method Detail

    - #### getProperty

          Property getProperty(java.lang.String name)

      Gets the resource-level property for a given name.
      Parameters:
        `name` - Name of the property to retrieve.
      Returns:
        The property or null if it does not exist.

    - #### getPropertyNames

          java.util.Set<java.lang.String> getPropertyNames()

      Gets the names of all the resource-level properties for this resource.
      Returns:
        All the names of the resource-level properties for this resource.

    - #### hasProperty

          boolean hasProperty(java.lang.String name)

      Indicates if a resource-level property exists for a given name.
      Parameters:
        `name` - The name of the resource-level property to query.
      Returns:
        True if a resource-level property exists, false otherwise.

    - #### removeProperty

          void removeProperty(java.lang.String name)

      Removes a resource-level property of a given name. If the property does not exists nothing happens.
      Parameters:
        `name` - The name of the property to remove.

    - #### setProperty

          Property setProperty(Property property)

      Sets a resource-level property. If a property already exists it is overwritten.
      Parameters:
        `property` - The new property to set.
      Returns:
        The property that has been set.