class Troy::Context

Public Class Methods

new(options = {}) click to toggle source
# File lib/troy/context.rb, line 5
    def initialize(options = {})
      options.each do |name, value|
        instance_variable_set("@#{name}", value)

        instance_eval <<-RUBY
          def #{name}   # def name
            @#{name}    #   @name
          end           # end
        RUBY
      end
    end

Public Instance Methods

to_binding() click to toggle source
# File lib/troy/context.rb, line 17
def to_binding
  binding
end