Pinq\Expressions\IEvaluator::evaluateWithNewThis PHP Метод

evaluateWithNewThis() публичный Метод

The default variables from the context can be overridden in the first parameter.
public evaluateWithNewThis ( object | null $thisObject, array $variableTable = null ) : mixed
$thisObject object | null
$variableTable array
Результат mixed
    public function evaluateWithNewThis($thisObject, array $variableTable = null);

Usage Example

Пример #1
0
 public function doEvaluate(IResolvedParameterRegistry $parameters)
 {
     if ($this->contextFactory === null) {
         return $this->evaluator->evaluate();
     }
     $resolvedContext = $this->contextFactory->getEvaluationContext($parameters);
     return $this->evaluator->evaluateWithNewThis($resolvedContext->getThis(), $resolvedContext->getVariableTable());
 }