Class: Dentaku::AST::CaseElse

Inherits:
Node
  • Object
show all
Defined in:
lib/dentaku/ast/case/case_else.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Node

#name, precedence, resolve_class, #type

Constructor Details

#initialize(node) ⇒ CaseElse

Returns a new instance of CaseElse.



6
7
8
# File 'lib/dentaku/ast/case/case_else.rb', line 6

def initialize(node)
  @node = node
end

Instance Attribute Details

#nodeObject (readonly)

Returns the value of attribute node.



4
5
6
# File 'lib/dentaku/ast/case/case_else.rb', line 4

def node
  @node
end

Class Method Details

.arityObject



18
19
20
# File 'lib/dentaku/ast/case/case_else.rb', line 18

def self.arity
  1
end

.max_param_countObject



26
27
28
# File 'lib/dentaku/ast/case/case_else.rb', line 26

def self.max_param_count
  1
end

.min_param_countObject



22
23
24
# File 'lib/dentaku/ast/case/case_else.rb', line 22

def self.min_param_count
  1
end

Instance Method Details

#accept(visitor) ⇒ Object



30
31
32
# File 'lib/dentaku/ast/case/case_else.rb', line 30

def accept(visitor)
  visitor.visit_else(self)
end

#dependencies(context = {}) ⇒ Object



14
15
16
# File 'lib/dentaku/ast/case/case_else.rb', line 14

def dependencies(context = {})
  @node.dependencies(context)
end

#value(context = {}) ⇒ Object



10
11
12
# File 'lib/dentaku/ast/case/case_else.rb', line 10

def value(context = {})
  @node.value(context)
end