Marker trait for ADTs representing enumerations with an associated value ("index")
The convention requires the following structure for the enumeration:
sealed trait EnumName extends ItemizedIndex { type Index = IndexType }
object EnumName {
case object Element1 extends EnumName { val index = element1Index }
case object Element2 extends EnumName { val index = element2Index }
}
Linear Supertypes
Itemized, Serializable, Serializable, Product, Equals, AnyRef, Any
Marker trait for ADTs representing enumerations with an associated value ("index")
The convention requires the following structure for the enumeration:
sealed trait EnumName extends ItemizedIndex { type Index = IndexType } object EnumName { case object Element1 extends EnumName { val index = element1Index } case object Element2 extends EnumName { val index = element2Index } }