PHP Class ApiPlatform\Core\Bridge\Doctrine\Orm\Filter\NumericFilter

Filters collection by equality of numeric properties. For each property passed, if the resource does not have such property or if the value is not numeric, the property is ignored.
Author: Amrouche Hamza ([email protected])
Author: Teoh Han Hui ([email protected])
Inheritance: extends AbstractFilter
Datei anzeigen Open project: api-platform/core Class Usage Examples

Public Methods

Method Description
getDescription ( string $resourceClass ) : array

Protected Methods

Method Description
filterProperty ( string $property, $value, Doctrine\ORM\QueryBuilder $queryBuilder, ApiPlatform\Core\Bridge\Doctrine\Orm\Util\QueryNameGeneratorInterface $queryNameGenerator, string $resourceClass, string $operationName = null )
isNumericField ( string $property, string $resourceClass ) : boolean Determines whether the given property refers to a numeric field.

Private Methods

Method Description
getType ( string $doctrineType ) : string Gets the PHP type corresponding to this Doctrine type.

Method Details

filterProperty() protected method

protected filterProperty ( string $property, $value, Doctrine\ORM\QueryBuilder $queryBuilder, ApiPlatform\Core\Bridge\Doctrine\Orm\Util\QueryNameGeneratorInterface $queryNameGenerator, string $resourceClass, string $operationName = null )
$property string
$queryBuilder Doctrine\ORM\QueryBuilder
$queryNameGenerator ApiPlatform\Core\Bridge\Doctrine\Orm\Util\QueryNameGeneratorInterface
$resourceClass string
$operationName string

getDescription() public method

public getDescription ( string $resourceClass ) : array
$resourceClass string
return array

isNumericField() protected method

Determines whether the given property refers to a numeric field.
protected isNumericField ( string $property, string $resourceClass ) : boolean
$property string
$resourceClass string
return boolean