An expression object that represents a SQL BETWEEN snippet
$_from protected mixed$_to protected mixed$_type protected mixedIterates over each part of the expression recursively for every level of the expressions tree and executes the $visitor callable passing as first parameter the instance of the expression currently being iterated.
__construct( string|Cake\Database\ExpressionInterface $field , mixed $from , mixed $to , string|null $type null )
Constructor
Cake\Database\ExpressionInterface $field $from $to $type optional null _bindValue( mixed $value , Cake\Database\ValueBinder $generator , string $type )
Registers a value in the placeholder generator and returns the generated placeholder
$value $generator $type sql( Cake\Database\ValueBinder $generator )
Converts the expression to its string representation
$generator Cake\Database\ExpressionInterface::sql() traverse( callable $callable )
Iterates over each part of the expression recursively for every level of the expressions tree and executes the $visitor callable passing as first parameter the instance of the expression currently being iterated.
$callable Cake\Database\ExpressionInterface::traverse() _castToExpression( mixed $value , string $type )
Conditionally converts the passed value to an ExpressionInterface object if the type class implements the ExpressionTypeInterface. Otherwise, returns the value unmodified.
$value $type _requiresToExpressionCasting( array $types )
Returns an array with the types that require values to be casted to expressions, out of the list of type names passed as parameter.
$types getField( )
Returns the field name
Cake\Database\ExpressionInterfacesetField( string|Cake\Database\ExpressionInterface $field )
Sets the field name
Cake\Database\ExpressionInterface $field
© 2005–2018 The Cake Software Foundation, Inc.
Licensed under the MIT License.
CakePHP is a registered trademark of Cake Software Foundation, Inc.
We are not endorsed by or affiliated with CakePHP.
https://api.cakephp.org/3.5/class-Cake.Database.Expression.BetweenExpression.html