Enum Class ExtraMetadataPolicy

java.lang.Object
java.lang.Enum<ExtraMetadataPolicy>
org.incenp.obofoundry.sssom.ExtraMetadataPolicy
All Implemented Interfaces:
Serializable, Comparable<ExtraMetadataPolicy>, Constable

public enum ExtraMetadataPolicy extends Enum<ExtraMetadataPolicy>
Represents the behaviour to adopt regarding non-standard metadata slots.
  • Enum Constant Details

    • NONE

      public static final ExtraMetadataPolicy NONE
      No non-standard metadata is ever allowed.

      When reading a mapping set, this policy instructs the parser to discard any non-standard metadata slot. When writing, this policy instructs the writer never to write the contents of the extra_metadata field.

    • DEFINED

      public static final ExtraMetadataPolicy DEFINED
      Requires that non-standard metadata slots be defined.

      When reading a mapping set, this policy instructs the parser to discard any non-standard metadata slot except those defined in the set-level extension_definitions slot.

      When writing, this policy instructs the writer to write all available non-standard metadata and to make sure the non-standard metadata are defined.

    • UNDEFINED

      public static final ExtraMetadataPolicy UNDEFINED
      Accepts all non-standard metadata without requiring a definition.

      When reading a mapping set, this policy instructs the parser to accept any non-standard metadata slot whether it is defined or not.

      When writing, this policy instructs the writer to write all non-standard metadata slots without defining them.

  • Method Details

    • values

      public static ExtraMetadataPolicy[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static ExtraMetadataPolicy valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null