Module: FrOData::Query::Criteria::StringFunctions

Included in:
FrOData::Query::Criteria
Defined in:
lib/frodata/query/criteria/string_functions.rb

Instance Method Summary collapse

Instance Method Details

#contains(str) ⇒ self

Sets up a ‘contains` function criterium.

Parameters:

Returns:

  • (self)


8
9
10
# File 'lib/frodata/query/criteria/string_functions.rb', line 8

def contains(str)
  set_function_and_argument(:contains, str)
end

#endswith(str) ⇒ self

Sets up a ‘endswith` function criterium.

Parameters:

Returns:

  • (self)


22
23
24
# File 'lib/frodata/query/criteria/string_functions.rb', line 22

def endswith(str)
  set_function_and_argument(:endswith, str)
end

#startswith(str) ⇒ self

Sets up a ‘startswith` function criterium.

Parameters:

Returns:

  • (self)


15
16
17
# File 'lib/frodata/query/criteria/string_functions.rb', line 15

def startswith(str)
  set_function_and_argument(:startswith, str)
end

#tolowerself

Applies the ‘tolower` function to the property.

Returns:

  • (self)


28
29
30
# File 'lib/frodata/query/criteria/string_functions.rb', line 28

def tolower
  set_function_and_argument(:tolower, nil)
end

#toupperself

Applies the ‘toupper` function to the property.

Returns:

  • (self)


34
35
36
# File 'lib/frodata/query/criteria/string_functions.rb', line 34

def toupper
  set_function_and_argument(:toupper, nil)
end