Class: Chelsy::Type::Enum

Inherits:
Taggable show all
Defined in:
lib/chelsy/ast.rb

Instance Attribute Summary collapse

Attributes inherited from Taggable

#tag

Attributes inherited from Element

#fragments, #post_fragments

Instance Method Summary collapse

Methods inherited from Base

#const?, #qualified?, #volatile?

Constructor Details

#initialize(tag, members = nil, **rest) ⇒ Enum

Returns a new instance of Enum.



473
474
475
476
# File 'lib/chelsy/ast.rb', line 473

def initialize(tag, members=nil, **rest)
  @members = EnumMemberList.new(members) if members
  super tag, **rest
end

Instance Attribute Details

#membersObject (readonly)

Returns the value of attribute members.



471
472
473
# File 'lib/chelsy/ast.rb', line 471

def members
  @members
end