Class: Expressir::Express::Visitor::SimpleCtx

Inherits:
Object
  • Object
show all
Defined in:
lib/expressir/express/visitor.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(data, name) ⇒ SimpleCtx

Returns a new instance of SimpleCtx.



68
69
70
71
# File 'lib/expressir/express/visitor.rb', line 68

def initialize(data,name)
  @data = data
  @name = name
end

Instance Attribute Details

#dataObject (readonly)

Returns the value of attribute data.



67
68
69
# File 'lib/expressir/express/visitor.rb', line 67

def data
  @data
end

#nameObject (readonly)

Returns the value of attribute name.



66
67
68
# File 'lib/expressir/express/visitor.rb', line 66

def name
  @name
end

Instance Method Details

#textObject



73
74
75
# File 'lib/expressir/express/visitor.rb', line 73

def text
  @data.to_s
end