Sha256: e0bfcbfde9fce2ed23610a559f15c0532f67c162bb86933e861b2defa333a25a

Contents?: true

Size: 399 Bytes

Versions: 1

Compression:

Stored size: 399 Bytes

Contents

module Martyr
  class BaseSliceDefinition
    include ActiveModel::Model

    def initialize(*)
      super
      compile_operators
    end

    def null?
      !!@null
    end

    def self.null
      obj = new
      obj.send(:set_null) and return obj
    end

    protected

    def set_null
      @null = true
    end

    def compile_operators
      raise NotImplementedError
    end

  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
martyr-0.1.74.pre lib/martyr/runtime/slices/slice_definitions/base_slice_definition.rb