Class EnumRecord


  • public class EnumRecord
    extends java.lang.Object
    Implements a custom enumeration record.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String UNDEFINED_LITERAL
      Placeholder for undefined literals.
      static long UNDEFINED_ORDINAL
      Placeholder for undefined ordinal.
    • Constructor Summary

      Constructors 
      Constructor Description
      EnumRecord​(java.lang.String literal, java.lang.Long ordinal, java.lang.String description)
      Constructs a new instance.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean equals​(java.lang.Object o)  
      java.lang.String getDescription()
      Gets the record description.
      java.lang.String getLiteral()
      Gets the text literal.
      java.lang.Long getOrdinal()
      Gets the numeric ordinal.
      int hashCode()  
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
    • Field Detail

      • UNDEFINED_LITERAL

        public static final java.lang.String UNDEFINED_LITERAL
        Placeholder for undefined literals.
        See Also:
        Constant Field Values
      • UNDEFINED_ORDINAL

        public static final long UNDEFINED_ORDINAL
        Placeholder for undefined ordinal.
        See Also:
        Constant Field Values
    • Constructor Detail

      • EnumRecord

        public EnumRecord​(java.lang.String literal,
                          java.lang.Long ordinal,
                          java.lang.String description)
        Constructs a new instance.
        Parameters:
        literal - the text literal
        ordinal - the numeric ordinal
        description - the record description
    • Method Detail

      • getLiteral

        public java.lang.String getLiteral()
        Gets the text literal.
        Returns:
        a string
      • getOrdinal

        public java.lang.Long getOrdinal()
        Gets the numeric ordinal.
        Returns:
        an integer
      • getDescription

        public java.lang.String getDescription()
        Gets the record description.
        Returns:
        a string
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object