Sha256: 30cf7b1ad5b397ca0e33ee6727e2c0da09ff927663cbcdcb968adec2da961104

Contents?: true

Size: 371 Bytes

Versions: 7

Compression:

Stored size: 371 Bytes

Contents

module Blueprints
  # Class that blueprint blocks are evaluated against. Allows you to access options that were passed to build method.
  class Context
    attr_accessor :options, :attributes

    # Method that allows building one blueprint inside of another. Simply delegates to root namespace.
    def build(*names)
      Namespace.root.build(*names)
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
blueprints-0.8.2 lib/blueprints/context.rb
blueprints-0.8.1 lib/blueprints/context.rb
blueprints-0.8.0 lib/blueprints/context.rb
blueprints-0.7.3 lib/blueprints/context.rb
blueprints-0.7.2 lib/blueprints/context.rb
blueprints-0.7.1 lib/blueprints/context.rb
blueprints-0.6.3 lib/blueprints/context.rb