Class FOFModelFieldNumber
FrameworkOnFramework model behavior class
-
FOFModelField
-
FOFModelFieldNumber
Methods summary
public
string
|
#
partial( mixed $value )
The partial match is mapped to an exact match
The partial match is mapped to an exact match
Parameters
- $value
mixed - $value The value to compare to
Returns
string - The SQL where clause for this search
|
public
string
|
#
between( mixed $from, mixed $to, boolean $include = true )
Perform a between limits match. When $include is true the condition tested
is: $from <= VALUE <= $to When $include is false the condition tested is:
$from < VALUE < $to
Perform a between limits match. When $include is true the condition tested
is: $from <= VALUE <= $to When $include is false the condition tested is:
$from < VALUE < $to
Parameters
- $from
mixed - $from The lowest value to compare to
- $to
mixed - $to The higherst value to compare to
- $include
boolean - $include Should we include the boundaries in the search?
Returns
string - The SQL where clause for this search
|
public
string
|
#
outside( mixed $from, mixed $to, boolean $include = false )
Perform an outside limits match. When $include is true the condition tested
is: (VALUE <= $from) || (VALUE >= $to) When $include is false the
condition tested is: (VALUE < $from) || (VALUE > $to)
Perform an outside limits match. When $include is true the condition tested
is: (VALUE <= $from) || (VALUE >= $to) When $include is false the
condition tested is: (VALUE < $from) || (VALUE > $to)
Parameters
- $from
mixed - $from The lowest value of the excluded range
- $to
mixed - $to The higherst value of the excluded range
- $include
boolean - $include Should we include the boundaries in the search?
Returns
string - The SQL where clause for this search
|
public
string
|
#
interval( integer|float $value, integer|float $interval, boolean $include = true )
Perform an interval match. It's similar to a 'between' match, but the from
and to values are calculated based on $value and $interval: $value - $interval
< VALUE < $value + $interval
Perform an interval match. It's similar to a 'between' match, but the from
and to values are calculated based on $value and $interval: $value - $interval
< VALUE < $value + $interval
Parameters
- $value
integer|float - $value The center value of the search space
- $interval
integer|float - $interval The width of the search space
- $include
boolean - $include Should I include the boundaries in the search?
Returns
string - The SQL where clause
|
public
string
|
#
range( mixed $from, mixed $to, boolean $include = true )
Perform a range limits match. When $include is true the condition tested is:
$from <= VALUE <= $to When $include is false the condition tested is:
$from < VALUE < $to
Perform a range limits match. When $include is true the condition tested is:
$from <= VALUE <= $to When $include is false the condition tested is:
$from < VALUE < $to
Parameters
- $from
mixed - $from The lowest value to compare to
- $to
mixed - $to The higherst value to compare to
- $include
boolean - $include Should we include the boundaries in the search?
Returns
string - The SQL where clause for this search
|
public
string
|
#
modulo( integer|float $value, integer|float $interval, boolean $include = true )
Perform an interval match. It's similar to a 'between' match, but the from
and to values are calculated based on $value and $interval: $value - $interval
< VALUE < $value + $interval
Perform an interval match. It's similar to a 'between' match, but the from
and to values are calculated based on $value and $interval: $value - $interval
< VALUE < $value + $interval
Parameters
- $value
integer|float - $value The starting value of the search space
- $interval
integer|float - $interval The interval period of the search space
- $include
boolean - $include Should I include the boundaries in the search?
Returns
string - The SQL where clause
|
__construct()
,
exact()
,
getDefaultSearchMethod()
,
getField()
,
getFieldName()
,
getFieldType()
,
getSearchMethods()
,
isEmpty()
,
search()
Magic methods summary
Properties summary
$_db
,
$name
,
$null_value
,
$table_alias
,
$type