class Barn::Factory

maybe Proc already defines __FILENAME__ and __LINENUMBER__

Attributes

filename[RW]

help with debugging where something was defined

line[RW]

help with debugging where something was defined

name[R]
options[R]

Public Class Methods

new(name, options = {}, &blk) click to toggle source
# File lib/barn/factory.rb, line 9
def initialize(name, options = {}, &blk)
  @name    = name
  @options = options
  @blk     = blk
end

Public Instance Methods

call(env) click to toggle source

Returns built object

# File lib/barn/factory.rb, line 16
def call(env)
  @blk.call(env)
end