class Conglomerate::BuilderCall

Attributes

array[RW]
block[RW]
builder[RW]
iterates[RW]
name[RW]
opts[RW]

Public Class Methods

new(options = {}) click to toggle source
# File lib/conglomerate/builder_call.rb, line 5
def initialize(options = {})
  self.name = options.fetch(:name, nil)
  self.opts = options.fetch(:opts, {})
  self.block = options.fetch(:block)
  self.builder = options.fetch(:builder)
  self.array = options.fetch(:array)
  self.iterates = options.fetch(:iterates)

rescue KeyError => e
  raise ArgumentError, e.message.gsub("key not found", "missing argument")
end

Public Instance Methods

run(context, objects, attrs, attr_name) click to toggle source
# File lib/conglomerate/builder_call.rb, line 17
def run(context, objects, attrs, attr_name)
  BuilderCallInstance.new(self, context, objects, attrs, attr_name).run
end