class Icss::Meta::EnumSchema
An EnumSchema
escribes an Enum type.
Enums use the type name “enum” and support the following attributes:
name: a string providing the name of the enum (required). namespace: a string that qualifies the name; doc: a string providing documentation to the user of this schema (optional). symbols: an array, listing symbols, as strings or ruby symbols (required). All
symbols in an enum must be unique; duplicates are prohibited.
For example, playing card suits might be defined with:
{ “type”: “enum”,
"name": "Suit", "symbols" : ["SPADES", "HEARTS", "DIAMONDS", "CLUBS"]
}
Public Instance Methods
type()
click to toggle source
# File lib/icss/type/structured_schema.rb, line 228 def type() :enum ; end