Class: Stupidedi::Builder::IdentifierStack::ISA
- Inherits:
-
Object
- Object
- Stupidedi::Builder::IdentifierStack::ISA
- Defined in:
- lib/stupidedi/builder/identifier_stack.rb
Instance Attribute Summary collapse
-
#id ⇒ Object
readonly
Returns the value of attribute id.
Instance Method Summary collapse
-
#count ⇒ Object
Number of Functional Groups (GS..GE).
- #gs ⇒ Object
-
#initialize(parent, id) ⇒ ISA
constructor
A new instance of ISA.
- #pop ⇒ Object
Constructor Details
#initialize(parent, id) ⇒ ISA
Returns a new instance of ISA.
66 67 68 |
# File 'lib/stupidedi/builder/identifier_stack.rb', line 66 def initialize(parent, id) @count, @parent, @next, @id = 0, parent, id, id end |
Instance Attribute Details
#id ⇒ Object (readonly)
Returns the value of attribute id.
64 65 66 |
# File 'lib/stupidedi/builder/identifier_stack.rb', line 64 def id @id end |
Instance Method Details
#count ⇒ Object
Number of Functional Groups (GS..GE)
75 76 77 |
# File 'lib/stupidedi/builder/identifier_stack.rb', line 75 def count @count end |
#gs ⇒ Object
70 71 72 |
# File 'lib/stupidedi/builder/identifier_stack.rb', line 70 def gs GS.new(self, @next).tap { @count += 1; @next += 1 } end |
#pop ⇒ Object
79 80 81 |
# File 'lib/stupidedi/builder/identifier_stack.rb', line 79 def pop @parent end |