Sha256: ebee724dcf3bd3fa150bc4bddeb1e1acbf54a2d18378551e1e8661c0cd44c750

Contents?: true

Size: 676 Bytes

Versions: 6

Compression:

Stored size: 676 Bytes

Contents

module Maid
  autoload :App, 'maid/app'
  autoload :Maid, 'maid/maid'
  autoload :Tools, 'maid/tools'
  autoload :NumericExtensions, 'maid/numeric_extensions'
  autoload :Rule, 'maid/rule'
  autoload :VERSION, 'maid/version'

  class << self
    # Execute the block with the Maid instance set to <tt>instance</tt>.
    def with_instance(instance)
      @instance = instance
      result = yield
      @instance = nil
      result
    end

    # Define rules for the Maid instance.
    def rules(&block)
      @instance.instance_eval(&block)
    end
  end
end

class Numeric
  include Maid::NumericExtensions
end

# TODO Is there a no-conflict way of including the extensions?

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
maid-0.1.2 lib/maid.rb
maid-0.1.1 lib/maid.rb
maid-0.1.0 lib/maid.rb
maid-0.1.0.rc.1 lib/maid.rb
maid-0.1.0.beta.4 lib/maid.rb
maid-0.1.0.beta.3 lib/maid.rb