Sha256: 50c7abaa49a787b0757b5e9bccdb56f19cd2e3fbb5700ca4bb92f32bbab91106

Contents?: true

Size: 393 Bytes

Versions: 1

Compression:

Stored size: 393 Bytes

Contents

module ROM
  module Commands
    # Common behavior for Create and Update commands
    #
    # TODO: find a better name for this module
    module WithOptions
      attr_reader :validator, :input

      # @api private
      def initialize(relation, options)
        super

        @validator = options[:validator] || proc {}
        @input = options[:input] || Hash
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
rom-0.5.0 lib/rom/commands/with_options.rb