Reference
C
Class

ApiPlatform\Elasticsearch\State\CollectionProvider

Collection provider for Elasticsearch.

class ApiPlatform\Elasticsearch\State\CollectionProvider implements `<a href="/docs/reference/State/ProviderInterface">ApiPlatform\State\ProviderInterface</a>`
{
    public __construct(Elasticsearch\Client $client, ApiPlatform\Elasticsearch\Metadata\Document\Factory\DocumentMetadataFactoryInterface $documentMetadataFactory, Symfony\Component\Serializer\Normalizer\DenormalizerInterface $denormalizer, ApiPlatform\State\Pagination\Pagination $pagination, array&lt;int, ApiPlatform\Elasticsearch\Extension\RequestBodySearchCollectionExtensionInterface&gt; $collectionExtensions)
    public provide(ApiPlatform\Metadata\Operation $operation, array $uriVariables, array $context): ApiPlatform\Elasticsearch\Paginator
}
class ApiPlatform\Elasticsearch\State\CollectionProvider implements `<a href="/docs/reference/State/ProviderInterface">ApiPlatform\State\ProviderInterface</a>`
{
    public __construct(Elasticsearch\Client $client, ApiPlatform\Elasticsearch\Metadata\Document\Factory\DocumentMetadataFactoryInterface $documentMetadataFactory, Symfony\Component\Serializer\Normalizer\DenormalizerInterface $denormalizer, ApiPlatform\State\Pagination\Pagination $pagination, array&lt;int, ApiPlatform\Elasticsearch\Extension\RequestBodySearchCollectionExtensionInterface&gt; $collectionExtensions)
    public provide(ApiPlatform\Metadata\Operation $operation, array $uriVariables, array $context): ApiPlatform\Elasticsearch\Paginator
}

Methods

__construct

public __construct(Elasticsearch\Client $client, ApiPlatform\Elasticsearch\Metadata\Document\Factory\DocumentMetadataFactoryInterface $documentMetadataFactory, Symfony\Component\Serializer\Normalizer\DenormalizerInterface $denormalizer, ApiPlatform\State\Pagination\Pagination $pagination, array&lt;int, ApiPlatform\Elasticsearch\Extension\RequestBodySearchCollectionExtensionInterface&gt; $collectionExtensions)
public __construct(Elasticsearch\Client $client, ApiPlatform\Elasticsearch\Metadata\Document\Factory\DocumentMetadataFactoryInterface $documentMetadataFactory, Symfony\Component\Serializer\Normalizer\DenormalizerInterface $denormalizer, ApiPlatform\State\Pagination\Pagination $pagination, array&lt;int, ApiPlatform\Elasticsearch\Extension\RequestBodySearchCollectionExtensionInterface&gt; $collectionExtensions)

Parameters

clientElasticsearch\Client
documentMetadataFactoryApiPlatform\Elasticsearch\Metadata\Document\Factory\DocumentMetadataFactoryInterface
denormalizerSymfony\Component\Serializer\Normalizer\DenormalizerInterface
paginationApiPlatform\State\Pagination\Pagination
collectionExtensionsarray<int, ApiPlatform\Elasticsearch\Extension\RequestBodySearchCollectionExtensionInterface>

provide

Provides data.

public provide(ApiPlatform\Metadata\Operation $operation, array $uriVariables, array $context): ApiPlatform\Elasticsearch\Paginator
public provide(ApiPlatform\Metadata\Operation $operation, array $uriVariables, array $context): ApiPlatform\Elasticsearch\Paginator

Parameters

operationApiPlatform\Metadata\Operation
uriVariablesarray
contextarray

Returns

ApiPlatform\Elasticsearch\Paginator

Copyright © 2023 Kévin Dunglas

Sponsored by Les-Tilleuls.coop