class Teacher::Scope
Attributes
published_variables[R]
symbols[R]
Public Class Methods
new(parent = nil)
click to toggle source
# File lib/teacher/scope.rb, line 6 def initialize(parent = nil) @parent = parent || {} @symbols = {} @published_variables = {} end
Public Instance Methods
[](name)
click to toggle source
# File lib/teacher/scope.rb, line 12 def [](name) @symbols[name] || @parent[name] end
[]=(name, value)
click to toggle source
# File lib/teacher/scope.rb, line 16 def []=(name, value) @symbols[name] = value end