vendor/api-platform/core/src/Metadata/Post.php line 17

Open in your IDE?
  1. <?php
  2. /*
  3.  * This file is part of the API Platform project.
  4.  *
  5.  * (c) Kévin Dunglas <[email protected]>
  6.  *
  7.  * For the full copyright and license information, please view the LICENSE
  8.  * file that was distributed with this source code.
  9.  */
  10. declare(strict_types=1);
  11. namespace ApiPlatform\Metadata;
  12. #[\Attribute(\Attribute::TARGET_CLASS \Attribute::IS_REPEATABLE)]
  13. final class Post extends HttpOperation
  14. {
  15.     private $itemUriTemplate;
  16.     public function __construct(
  17.         string $uriTemplate null,
  18.         array $types null,
  19.         $formats null,
  20.         $inputFormats null,
  21.         $outputFormats null,
  22.         $uriVariables null,
  23.         string $routePrefix null,
  24.         string $routeName null,
  25.         array $defaults null,
  26.         array $requirements null,
  27.         array $options null,
  28.         bool $stateless null,
  29.         string $sunset null,
  30.         string $acceptPatch null,
  31.         $status null,
  32.         string $host null,
  33.         array $schemes null,
  34.         string $condition null,
  35.         string $controller null,
  36.         array $cacheHeaders null,
  37.         array $hydraContext null,
  38.         array $openapiContext null,
  39.         bool $openapi null,
  40.         array $exceptionToStatus null,
  41.         bool $queryParameterValidationEnabled null,
  42.         // abstract operation arguments
  43.         string $shortName null,
  44.         string $class null,
  45.         bool $paginationEnabled null,
  46.         string $paginationType null,
  47.         int $paginationItemsPerPage null,
  48.         int $paginationMaximumItemsPerPage null,
  49.         bool $paginationPartial null,
  50.         bool $paginationClientEnabled null,
  51.         bool $paginationClientItemsPerPage null,
  52.         bool $paginationClientPartial null,
  53.         bool $paginationFetchJoinCollection null,
  54.         bool $paginationUseOutputWalkers null,
  55.         array $paginationViaCursor null,
  56.         array $order null,
  57.         string $description null,
  58.         array $normalizationContext null,
  59.         array $denormalizationContext null,
  60.         string $security null,
  61.         string $securityMessage null,
  62.         string $securityPostDenormalize null,
  63.         string $securityPostDenormalizeMessage null,
  64.         string $securityPostValidation null,
  65.         string $securityPostValidationMessage null,
  66.         string $deprecationReason null,
  67.         array $filters null,
  68.         array $validationContext null,
  69.         $input null,
  70.         $output null,
  71.         $mercure null,
  72.         $messenger null,
  73.         bool $elasticsearch null,
  74.         int $urlGenerationStrategy null,
  75.         bool $read null,
  76.         bool $deserialize null,
  77.         bool $validate null,
  78.         bool $write null,
  79.         bool $serialize null,
  80.         bool $fetchPartial null,
  81.         bool $forceEager null,
  82.         int $priority null,
  83.         string $name null,
  84.         $provider null,
  85.         $processor null,
  86.         array $extraProperties = [],
  87.         string $itemUriTemplate null
  88.     ) {
  89.         parent::__construct(self::METHOD_POST, ...\func_get_args());
  90.         $this->itemUriTemplate $itemUriTemplate;
  91.     }
  92.     public function getItemUriTemplate(): ?string
  93.     {
  94.         return $this->itemUriTemplate;
  95.     }
  96.     public function withItemUriTemplate(string $itemUriTemplate): self
  97.     {
  98.         $self = clone $this;
  99.         $self->itemUriTemplate $itemUriTemplate;
  100.         return $self;
  101.     }
  102. }