Class: Yap::Shell::Parser::Nodes::InternalEvalNode

Inherits:
Object
  • Object
show all
Includes:
Visitor
Defined in:
lib/yap/shell/parser/nodes.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Visitor

#accept

Constructor Details

#initialize(token) ⇒ InternalEvalNode

Returns a new instance of InternalEvalNode.



184
185
186
# File 'lib/yap/shell/parser/nodes.rb', line 184

def initialize(token)
  @src = token.value
end

Instance Attribute Details

#srcObject (readonly) Also known as: command

Returns the value of attribute src.



181
182
183
# File 'lib/yap/shell/parser/nodes.rb', line 181

def src
  @src
end

Instance Method Details

#argsObject



188
189
190
# File 'lib/yap/shell/parser/nodes.rb', line 188

def args
  nil
end

#heredocObject



192
193
194
# File 'lib/yap/shell/parser/nodes.rb', line 192

def heredoc
  nil
end

#internally_evaluate?Boolean

Returns:

  • (Boolean)


196
197
198
# File 'lib/yap/shell/parser/nodes.rb', line 196

def internally_evaluate?
  true
end

#to_sObject



200
201
202
# File 'lib/yap/shell/parser/nodes.rb', line 200

def to_s
  "InternalEvalNode(#{@src.inspect})"
end