Neos\Flow\Persistence\Generic\Query::lessThanOrEqual PHP Method

lessThanOrEqual() public method

Returns a less or equal than criterion used for matching objects against a query
public lessThanOrEqual ( string $propertyName, mixed $operand ) : Comparison
$propertyName string The name of the property to compare against
$operand mixed The value to compare with
return Neos\Flow\Persistence\Generic\Qom\Comparison
    public function lessThanOrEqual($propertyName, $operand)
    {
        if ($this->classSchema->isMultiValuedProperty($propertyName)) {
            throw new InvalidQueryException('Property "' . $propertyName . '" must not be multi-valued', 1276784943);
        }
        if (!$operand instanceof \DateTimeInterface && !TypeHandling::isLiteral(gettype($operand))) {
            throw new InvalidQueryException('Operand must be a literal or DateTime, was ' . gettype($operand), 1276784944);
        }
        return $this->qomFactory->comparison($this->qomFactory->propertyValue($propertyName, '_entity'), QueryInterface::OPERATOR_LESS_THAN_OR_EQUAL_TO, $operand);
    }