Class: MemDB::Field::Negative

Inherits:
Object
  • Object
show all
Includes:
MemDB::Field
Defined in:
lib/mem_db/field/negative.rb

Defined Under Namespace

Classes: NegativeMatching

Instance Method Summary collapse

Methods included from MemDB::Field

#downcase, #may_missing, #negative, #query

Constructor Details

#initialize(original) ⇒ Negative

Returns a new instance of Negative.



23
24
25
# File 'lib/mem_db/field/negative.rb', line 23

def initialize(original)
  @original = original
end

Instance Method Details

#fieldObject



27
28
29
# File 'lib/mem_db/field/negative.rb', line 27

def field
  @original.field
end

#field_value(obj) ⇒ Object



39
40
41
# File 'lib/mem_db/field/negative.rb', line 39

def field_value(obj)
  @original.field_value(obj)
end

#new_matching(value) ⇒ Object



35
36
37
# File 'lib/mem_db/field/negative.rb', line 35

def new_matching(value)
  NegativeMatching.new(@original.new_matching(value))
end

#prepare_query(obj) ⇒ Object



43
44
45
# File 'lib/mem_db/field/negative.rb', line 43

def prepare_query(obj)
  @original.prepare_query(obj)
end

#query_fieldObject



31
32
33
# File 'lib/mem_db/field/negative.rb', line 31

def query_field
  @original.query_field
end