The international conference on the API Platform Framework
Learn more about the event, register for the conference, and get ready for two days of inspiration, ideas, and knowledge-sharing with our incredible lineup of renowned specialists and advocates.
Register nowTrait for filtering the collection by boolean values.
Filters collection on equality of boolean properties. The value is specified as one of ( “true” | “false” | “1” | “0” ) in the query.
For each property passed, if the resource does not have such property or if the value is not one of ( “true” | “false” | “1” | “0” ) the property is ignored.
trait ApiPlatform\Doctrine\Common\Filter\BooleanFilterTrait
{
public getDescription(string $resourceClass): array
protected getProperties(): array
protected getLogger(): Psr\Log\LoggerInterface
protected normalizePropertyName(string $property): string
protected isBooleanField(string $property, string $resourceClass): bool
protected getClassMetadata(string $resourceClass): Doctrine\Persistence\Mapping\ClassMetadata
protected isPropertyMapped(string $property, string $resourceClass, bool $allowAssociation): bool
protected isPropertyNested(string $property, string $resourceClass): bool
protected isPropertyEmbedded(string $property, string $resourceClass): bool
protected splitPropertyParts(string $property, string $resourceClass): array
protected getDoctrineFieldType(string $property, string $resourceClass): string
protected getNestedMetadata(string $resourceClass, array<int, string> $associations): Doctrine\Persistence\Mapping\ClassMetadata
}
public getDescription(string $resourceClass): array
resourceClass | string |
array
protected getProperties(): array
array
protected getLogger(): Psr\Log\LoggerInterface
Psr\Log\LoggerInterface
protected normalizePropertyName(string $property): string
property | string |
string
Determines whether the given property refers to a boolean field.
protected isBooleanField(string $property, string $resourceClass): bool
property | string | |
resourceClass | string |
bool
Gets class metadata for the given resource.
protected getClassMetadata(string $resourceClass): Doctrine\Persistence\Mapping\ClassMetadata
resourceClass | string |
Doctrine\Persistence\Mapping\ClassMetadata
Determines whether the given property is mapped.
protected isPropertyMapped(string $property, string $resourceClass, bool $allowAssociation): bool
property | string | |
resourceClass | string | |
allowAssociation | bool |
bool
Determines whether the given property is nested.
protected isPropertyNested(string $property, string $resourceClass): bool
property | string | |
resourceClass | string |
bool
Determines whether the given property is embedded.
protected isPropertyEmbedded(string $property, string $resourceClass): bool
property | string | |
resourceClass | string |
bool
Splits the given property into parts.Returns an array with the following keys:
protected splitPropertyParts(string $property, string $resourceClass): array
property | string | |
resourceClass | string |
array
Gets the Doctrine Type of a given property/resourceClass.
protected getDoctrineFieldType(string $property, string $resourceClass): string
property | string | |
resourceClass | string |
string
Gets nested class metadata for the given resource.
protected getNestedMetadata(string $resourceClass, array<int, string> $associations): Doctrine\Persistence\Mapping\ClassMetadata
resourceClass | string | |
associations | array<int, string> |
Doctrine\Persistence\Mapping\ClassMetadata
Made with love by
Les-Tilleuls.coop can help you design and develop your APIs and web projects, and train your teams in API Platform, Symfony, Next.js, Kubernetes and a wide range of other technologies.
Learn more