Interface AttributeDescription


public interface AttributeDescription
Description of an Attribute derived from its annotations.
Author:
Markus Mårtensson
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static interface 
    The producer is tasked with providing descriptions for attributes.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    An attribute is considered complex if its values can not be converted to a human and computer friendly string representation.
    boolean
    An internal attribute is not exposed to third parties via REST, SOAP, messaging or other means.
    The maximum constraint on the number value, or the maximum length a string value.
    The minimum constraint on the number value, or the minumum length a string value.
    Regular expression constraint for the string value.
    The description of how and when to use the attribute.
    The usage pattern for which the attribute is optimized.
    The class literal matching the only class valid for attribute value objects.
    Variety used to narrow down the use of a generic/primitive value class.
  • Method Details

    • purpose

      String purpose()
      The description of how and when to use the attribute.
      Returns:
      purpose of the attribute.
    • valueClass

      Class<?> valueClass()
      The class literal matching the only class valid for attribute value objects.
      Returns:
      class literal of the value class.
    • variety

      Variety variety()
      Variety used to narrow down the use of a generic/primitive value class.  @return the Variety accompanying the valueClass.
    • isComplex

      boolean isComplex()
      An attribute is considered complex if its values can not be converted to a human and computer friendly string representation.
      Returns:
      true if the attribute has complex values.
      See Also:
    • isInternal

      boolean isInternal()
      An internal attribute is not exposed to third parties via REST, SOAP, messaging or other means.
      Returns:
      true if the attribute is flagged for internal use.
      See Also:
    • scope

      Scope scope()
      The usage pattern for which the attribute is optimized.
      Returns:
      usage scope for the attribute.
    • minConstraint

      Long minConstraint()
      The minimum constraint on the number value, or the minumum length a string value.
      Returns:
      Minimum number/size, or null if no constraint.
    • maxConstraint

      Long maxConstraint()
      The maximum constraint on the number value, or the maximum length a string value.
      Returns:
      Maximum number/size, or null if no constraint.
    • patternConstraint

      String patternConstraint()
      Regular expression constraint for the string value.
      Returns:
      Regexp, or null if no constraint.