Class: Ynl::Models::Enum
- Inherits:
-
Object
- Object
- Ynl::Models::Enum
- Defined in:
- ynl/lib/ynl/models.rb
Defined Under Namespace
Classes: Entry
Instance Attribute Summary collapse
-
#doc ⇒ Object
readonly
Returns the value of attribute doc.
-
#entries ⇒ Object
readonly
Returns the value of attribute entries.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
Instance Method Summary collapse
-
#initialize(name:, doc:) ⇒ Enum
constructor
A new instance of Enum.
- #resolve(f) ⇒ Object
Constructor Details
#initialize(name:, doc:) ⇒ Enum
Returns a new instance of Enum.
62 63 64 65 66 |
# File 'ynl/lib/ynl/models.rb', line 62 def initialize(name:, doc:) @name = name @entries = [] @doc = doc end |
Instance Attribute Details
#doc ⇒ Object (readonly)
Returns the value of attribute doc.
60 61 62 |
# File 'ynl/lib/ynl/models.rb', line 60 def doc @doc end |
#entries ⇒ Object (readonly)
Returns the value of attribute entries.
60 61 62 |
# File 'ynl/lib/ynl/models.rb', line 60 def entries @entries end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
60 61 62 |
# File 'ynl/lib/ynl/models.rb', line 60 def name @name end |
Instance Method Details
#resolve(f) ⇒ Object
68 69 70 |
# File 'ynl/lib/ynl/models.rb', line 68 def resolve(f) self end |