__construct() public method

Checks whether a value selected from the evaluated value matches an expression.
public __construct ( Webmozart\Expression\Expression $expr )
$expr Webmozart\Expression\Expression The expression to evaluate for the selected value.
Ejemplo n.º 1
0
 /**
  * Creates the expression.
  *
  * @param string     $methodName The name of the method to call.
  * @param array      $arguments  The arguments to pass to the method.
  * @param Expression $expr       The expression to evaluate for the result.
  */
 public function __construct($methodName, array $arguments, Expression $expr)
 {
     parent::__construct($expr);
     $this->methodName = $methodName;
     $this->arguments = $arguments;
 }
Ejemplo n.º 2
0
 /**
  * Creates the expression.
  *
  * @param int        $count The minimum number of entries that must match
  *                          the expression.
  * @param Expression $expr  The expression to evaluate with each entry.
  */
 public function __construct($count, Expression $expr)
 {
     parent::__construct($expr);
     $this->count = (int) $count;
 }
Ejemplo n.º 3
0
 /**
  * Creates the expression.
  *
  * @param string     $propertyName The name of the property.
  * @param Expression $expr         The expression to evaluate for the result.
  */
 public function __construct($propertyName, Expression $expr)
 {
     parent::__construct($expr);
     $this->propertyName = $propertyName;
 }
Ejemplo n.º 4
0
 /**
  * Creates the expression.
  *
  * @param string|int $key  The array key.
  * @param Expression $expr The expression to evaluate for the key.
  */
 public function __construct($key, Expression $expr)
 {
     parent::__construct($expr);
     $this->key = (string) $key;
 }