• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

api-platform / core / 16531587208

25 Jul 2025 09:05PM UTC coverage: 0.0% (-22.1%) from 22.07%
16531587208

Pull #7225

github

web-flow
Merge 23f449a58 into 02a764950
Pull Request #7225: feat: json streamer

0 of 294 new or added lines in 31 files covered. (0.0%)

11514 existing lines in 375 files now uncovered.

0 of 51976 relevant lines covered (0.0%)

0.0 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/Metadata/HttpOperation.php
1
<?php
2

3
/*
4
 * This file is part of the API Platform project.
5
 *
6
 * (c) Kévin Dunglas <dunglas@gmail.com>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11

12
declare(strict_types=1);
13

14
namespace ApiPlatform\Metadata;
15

16
use ApiPlatform\Metadata\Exception\ProblemExceptionInterface;
17
use ApiPlatform\OpenApi\Attributes\Webhook;
18
use ApiPlatform\OpenApi\Model\Operation as OpenApiOperation;
19
use ApiPlatform\State\OptionsInterface;
20
use Symfony\Component\WebLink\Link as WebLink;
21

22
class HttpOperation extends Operation
23
{
24
    public const METHOD_GET = 'GET';
25
    public const METHOD_POST = 'POST';
26
    public const METHOD_PUT = 'PUT';
27
    public const METHOD_PATCH = 'PATCH';
28
    public const METHOD_DELETE = 'DELETE';
29
    public const METHOD_HEAD = 'HEAD';
30
    public const METHOD_OPTIONS = 'OPTIONS';
31

32
    /** @var array<int|string, string|string[]>|null */
33
    protected $formats;
34
    /** @var array<int|string, string|string[]>|null */
35
    protected $inputFormats;
36
    /** @var array<int|string, string|string[]>|null */
37
    protected $outputFormats;
38

39
    /**
40
     * @param string[]|null                                  $types         the RDF types of this property
41
     * @param array<int|string, string|string[]>|string|null $formats       {@see https://api-platform.com/docs/core/content-negotiation/#configuring-formats-for-a-specific-resource-or-operation}
42
     * @param array<int|string, string|string[]>|string|null $inputFormats  {@see https://api-platform.com/docs/core/content-negotiation/#configuring-formats-for-a-specific-resource-or-operation}
43
     * @param array<int|string, string|string[]>|string|null $outputFormats {@see https://api-platform.com/docs/core/content-negotiation/#configuring-formats-for-a-specific-resource-or-operation}
44
     * @param array<string,array{
45
     *     0: string,
46
     *     1: string
47
     * }|array{
48
     *     from_property?: string,
49
     *     to_property?: string,
50
     *     from_class?: string,
51
     *     to_class?: string,
52
     *     identifiers?: string[],
53
     *     composite_identifier?: bool,
54
     *     expanded_value?: string,
55
     * }|Link>|string[]|string|null $uriVariables {@see https://api-platform.com/docs/core/subresources/}
56
     * @param string|null     $routePrefix {@see https://api-platform.com/docs/core/operations/#prefixing-all-routes-of-all-operations}
57
     * @param string|null     $sunset      {@see https://api-platform.com/docs/core/deprecations/#setting-the-sunset-http-header-to-indicate-when-a-resource-or-an-operation-will-be-removed}
58
     * @param string|int|null $status      {@see https://api-platform.com/docs/core/operations/#configuring-operations}
59
     * @param array{
60
     *     max_age?: int,
61
     *     vary?: string|string[],
62
     *     public?: bool,
63
     *     shared_max_age?: int,
64
     *     stale_while_revalidate?: int,
65
     *     stale_if_error?: int,
66
     *     must_revalidate?: bool,
67
     *     proxy_revalidate?: bool,
68
     *     no_cache?: bool,
69
     *     no_store?: bool,
70
     *     no_transform?: bool,
71
     *     immutable?: bool,
72
     * }|null $cacheHeaders {@see https://api-platform.com/docs/core/performance/#setting-custom-http-cache-headers}
73
     * @param array<string, string>|null $headers
74
     * @param array{
75
     *     field: string,
76
     *     direction: string,
77
     * }|null $paginationViaCursor {@see https://api-platform.com/docs/core/pagination/#cursor-based-pagination}
78
     * @param array|null $normalizationContext   {@see https://api-platform.com/docs/core/serialization/#using-serialization-groups}
79
     * @param array|null $denormalizationContext {@see https://api-platform.com/docs/core/serialization/#using-serialization-groups}
80
     * @param array|null $hydraContext           {@see https://api-platform.com/docs/core/extending-jsonld-context/#hydra}
81
     * @param array{
82
     *     class?: string|null,
83
     *     name?: string,
84
     * }|string|false|null $input {@see https://api-platform.com/docs/core/dto/#specifying-an-input-or-an-output-data-representation}
85
     * @param array{
86
     *     class?: string|null,
87
     *     name?: string,
88
     * }|string|false|null $output {@see https://api-platform.com/docs/core/dto/#specifying-an-input-or-an-output-data-representation}
89
     * @param string|array|bool|null                              $mercure   {@see https://api-platform.com/docs/core/mercure}
90
     * @param string|bool|null                                    $messenger {@see https://api-platform.com/docs/core/messenger/#dispatching-a-resource-through-the-message-bus}
91
     * @param string|callable|null                                $provider  {@see https://api-platform.com/docs/core/state-providers/#state-providers}
92
     * @param string|callable|null                                $processor {@see https://api-platform.com/docs/core/state-processors/#state-processors}
93
     * @param WebLink[]|null                                      $links
94
     * @param array<class-string<ProblemExceptionInterface>>|null $errors
95
     */
96
    public function __construct(
97
        protected string $method = 'GET',
98
        protected ?string $uriTemplate = null,
99
        protected ?array $types = null,
100
        $formats = null,
101
        $inputFormats = null,
102
        $outputFormats = null,
103
        protected $uriVariables = null,
104
        protected ?string $routePrefix = null,
105
        protected ?string $routeName = null,
106
        protected ?array $defaults = null,
107
        protected ?array $requirements = null,
108
        protected ?array $options = null,
109
        protected ?bool $stateless = null,
110
        /**
111
         * The `sunset` option indicates when a deprecated operation will be removed.
112
         *
113
         * <div data-code-selector>
114
         *
115
         * ```php
116
         * <?php
117
         * // api/src/Entity/Parchment.php
118
         * use ApiPlatform\Metadata\Get;
119
         *
120
         * #[Get(deprecationReason: 'Create a Book instead', sunset: '01/01/2020')]
121
         * class Parchment
122
         * {
123
         *     // ...
124
         * }
125
         * ```
126
         *
127
         * ```yaml
128
         * # api/config/api_platform/resources.yaml
129
         * resources:
130
         *     App\Entity\Parchment:
131
         *         - operations:
132
         *               ApiPlatform\Metadata\Get:
133
         *                   deprecationReason: 'Create a Book instead'
134
         *                   sunset: '01/01/2020'
135
         * ```
136
         *
137
         * ```xml
138
         * <?xml version="1.0" encoding="UTF-8" ?>
139
         * <!-- api/config/api_platform/resources.xml -->
140
         *
141
         * <resources
142
         *         xmlns="https://api-platform.com/schema/metadata/resources-3.0"
143
         *         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
144
         *         xsi:schemaLocation="https://api-platform.com/schema/metadata/resources-3.0
145
         *         https://api-platform.com/schema/metadata/resources-3.0.xsd">
146
         *     <resource class="App\Entity\Parchment">
147
         *         <operations>
148
         *             <operation class="ApiPlatform\Metadata\Get" deprecationReason="Create a Book instead" sunset="01/01/2020" />
149
         *         <operations>
150
         *     </resource>
151
         * </resources>
152
         * ```
153
         *
154
         * </div>
155
         */
156
        protected ?string $sunset = null,
157
        protected ?string $acceptPatch = null,
158
        protected $status = null,
159
        protected ?string $host = null,
160
        protected ?array $schemes = null,
161
        protected ?string $condition = null,
162
        protected ?string $controller = null,
163
        protected ?array $headers = null,
164
        protected ?array $cacheHeaders = null,
165
        protected ?array $paginationViaCursor = null,
166
        protected ?array $hydraContext = null,
167
        protected bool|OpenApiOperation|Webhook|null $openapi = null,
168
        protected ?array $exceptionToStatus = null,
169
        protected ?array $links = null,
170
        protected ?array $errors = null,
171
        protected ?bool $strictQueryParameterValidation = null,
172
        protected ?bool $hideHydraOperation = null,
173

174
        ?string $shortName = null,
175
        ?string $class = null,
176
        ?bool $paginationEnabled = null,
177
        ?string $paginationType = null,
178
        ?int $paginationItemsPerPage = null,
179
        ?int $paginationMaximumItemsPerPage = null,
180
        ?bool $paginationPartial = null,
181
        ?bool $paginationClientEnabled = null,
182
        ?bool $paginationClientItemsPerPage = null,
183
        ?bool $paginationClientPartial = null,
184
        ?bool $paginationFetchJoinCollection = null,
185
        ?bool $paginationUseOutputWalkers = null,
186
        ?array $order = null,
187
        ?string $description = null,
188
        ?array $normalizationContext = null,
189
        ?array $denormalizationContext = null,
190
        ?bool $collectDenormalizationErrors = null,
191
        string|\Stringable|null $security = null,
192
        ?string $securityMessage = null,
193
        string|\Stringable|null $securityPostDenormalize = null,
194
        ?string $securityPostDenormalizeMessage = null,
195
        string|\Stringable|null $securityPostValidation = null,
196
        ?string $securityPostValidationMessage = null,
197
        ?string $deprecationReason = null,
198
        ?array $filters = null,
199
        ?array $validationContext = null,
200
        $input = null,
201
        $output = null,
202
        $mercure = null,
203
        $messenger = null,
204
        ?int $urlGenerationStrategy = null,
205
        ?bool $read = null,
206
        ?bool $deserialize = null,
207
        ?bool $validate = null,
208
        ?bool $write = null,
209
        ?bool $serialize = null,
210
        ?bool $fetchPartial = null,
211
        ?bool $forceEager = null,
212
        ?int $priority = null,
213
        ?string $name = null,
214
        $provider = null,
215
        $processor = null,
216
        ?OptionsInterface $stateOptions = null,
217
        array|Parameters|null $parameters = null,
218
        array|string|null $rules = null,
219
        ?string $policy = null,
220
        array|string|null $middleware = null,
221
        ?bool $queryParameterValidationEnabled = null,
222
        ?bool $jsonStream = null,
223
        array $extraProperties = [],
224
    ) {
UNCOV
225
        $this->formats = (null === $formats || \is_array($formats)) ? $formats : [$formats];
×
UNCOV
226
        $this->inputFormats = (null === $inputFormats || \is_array($inputFormats)) ? $inputFormats : [$inputFormats];
×
UNCOV
227
        $this->outputFormats = (null === $outputFormats || \is_array($outputFormats)) ? $outputFormats : [$outputFormats];
×
228

UNCOV
229
        parent::__construct(
×
UNCOV
230
            shortName: $shortName,
×
UNCOV
231
            class: $class,
×
UNCOV
232
            paginationEnabled: $paginationEnabled,
×
UNCOV
233
            paginationType: $paginationType,
×
UNCOV
234
            paginationItemsPerPage: $paginationItemsPerPage,
×
UNCOV
235
            paginationMaximumItemsPerPage: $paginationMaximumItemsPerPage,
×
UNCOV
236
            paginationPartial: $paginationPartial,
×
UNCOV
237
            paginationClientEnabled: $paginationClientEnabled,
×
UNCOV
238
            paginationClientItemsPerPage: $paginationClientItemsPerPage,
×
UNCOV
239
            paginationClientPartial: $paginationClientPartial,
×
UNCOV
240
            paginationFetchJoinCollection: $paginationFetchJoinCollection,
×
UNCOV
241
            paginationUseOutputWalkers: $paginationUseOutputWalkers,
×
UNCOV
242
            order: $order,
×
UNCOV
243
            description: $description,
×
UNCOV
244
            normalizationContext: $normalizationContext,
×
UNCOV
245
            denormalizationContext: $denormalizationContext,
×
UNCOV
246
            collectDenormalizationErrors: $collectDenormalizationErrors,
×
UNCOV
247
            security: $security,
×
UNCOV
248
            securityMessage: $securityMessage,
×
UNCOV
249
            securityPostDenormalize: $securityPostDenormalize,
×
UNCOV
250
            securityPostDenormalizeMessage: $securityPostDenormalizeMessage,
×
UNCOV
251
            securityPostValidation: $securityPostValidation,
×
UNCOV
252
            securityPostValidationMessage: $securityPostValidationMessage,
×
UNCOV
253
            deprecationReason: $deprecationReason,
×
UNCOV
254
            filters: $filters,
×
UNCOV
255
            validationContext: $validationContext,
×
UNCOV
256
            input: $input,
×
UNCOV
257
            output: $output,
×
UNCOV
258
            mercure: $mercure,
×
UNCOV
259
            messenger: $messenger,
×
UNCOV
260
            urlGenerationStrategy: $urlGenerationStrategy,
×
UNCOV
261
            read: $read,
×
UNCOV
262
            deserialize: $deserialize,
×
UNCOV
263
            validate: $validate,
×
UNCOV
264
            write: $write,
×
UNCOV
265
            serialize: $serialize,
×
UNCOV
266
            fetchPartial: $fetchPartial,
×
UNCOV
267
            forceEager: $forceEager,
×
UNCOV
268
            priority: $priority,
×
UNCOV
269
            name: $name,
×
UNCOV
270
            provider: $provider,
×
UNCOV
271
            processor: $processor,
×
UNCOV
272
            stateOptions: $stateOptions,
×
UNCOV
273
            parameters: $parameters,
×
UNCOV
274
            rules: $rules,
×
UNCOV
275
            policy: $policy,
×
UNCOV
276
            middleware: $middleware,
×
UNCOV
277
            queryParameterValidationEnabled: $queryParameterValidationEnabled,
×
UNCOV
278
            strictQueryParameterValidation: $strictQueryParameterValidation,
×
UNCOV
279
            hideHydraOperation: $hideHydraOperation,
×
NEW
280
            jsonStream: $jsonStream,
×
UNCOV
281
            extraProperties: $extraProperties
×
UNCOV
282
        );
×
283
    }
284

285
    public function getMethod(): string
286
    {
UNCOV
287
        return $this->method;
×
288
    }
289

290
    public function withMethod(string $method): static
291
    {
UNCOV
292
        $self = clone $this;
×
UNCOV
293
        $self->method = $method;
×
294

UNCOV
295
        return $self;
×
296
    }
297

298
    public function getUriTemplate(): ?string
299
    {
UNCOV
300
        return $this->uriTemplate;
×
301
    }
302

303
    public function withUriTemplate(?string $uriTemplate = null): static
304
    {
UNCOV
305
        $self = clone $this;
×
UNCOV
306
        $self->uriTemplate = $uriTemplate;
×
307

UNCOV
308
        return $self;
×
309
    }
310

311
    public function getTypes(): ?array
312
    {
UNCOV
313
        return $this->types;
×
314
    }
315

316
    /**
317
     * @param string[]|string $types
318
     */
319
    public function withTypes($types): static
320
    {
UNCOV
321
        $self = clone $this;
×
UNCOV
322
        $self->types = (array) $types;
×
323

UNCOV
324
        return $self;
×
325
    }
326

327
    /**
328
     * @return array<int|string, string|string[]>|null
329
     */
330
    public function getFormats()
331
    {
UNCOV
332
        return $this->formats;
×
333
    }
334

335
    /**
336
     * @param array<int|string, string|string[]>|string|null $formats
337
     */
338
    public function withFormats($formats = null): static
339
    {
UNCOV
340
        $self = clone $this;
×
UNCOV
341
        $self->formats = (null === $formats || \is_array($formats)) ? $formats : [$formats];
×
342

UNCOV
343
        return $self;
×
344
    }
345

346
    /**
347
     * @return array<int|string, string|string[]>|null
348
     */
349
    public function getInputFormats()
350
    {
UNCOV
351
        return $this->inputFormats;
×
352
    }
353

354
    /**
355
     * @param array<int|string, string|string[]>|string|null $inputFormats
356
     */
357
    public function withInputFormats($inputFormats = null): static
358
    {
UNCOV
359
        $self = clone $this;
×
UNCOV
360
        $self->inputFormats = (null === $inputFormats || \is_array($inputFormats)) ? $inputFormats : [$inputFormats];
×
361

UNCOV
362
        return $self;
×
363
    }
364

365
    /**
366
     * @return array<int|string, string|string[]>|null
367
     */
368
    public function getOutputFormats()
369
    {
UNCOV
370
        return $this->outputFormats;
×
371
    }
372

373
    /**
374
     * @param array<int|string, string|string[]>|string|null $outputFormats
375
     */
376
    public function withOutputFormats($outputFormats = null): static
377
    {
UNCOV
378
        $self = clone $this;
×
UNCOV
379
        $self->outputFormats = (null === $outputFormats || \is_array($outputFormats)) ? $outputFormats : [$outputFormats];
×
380

UNCOV
381
        return $self;
×
382
    }
383

384
    /**
385
     * @return array<string, mixed>|array<int, Link>|list<string>|null
386
     */
387
    public function getUriVariables()
388
    {
UNCOV
389
        return $this->uriVariables;
×
390
    }
391

392
    /**
393
     * @param array<string, mixed>|array<int, Link>|list<string> $uriVariables
394
     */
395
    public function withUriVariables($uriVariables): static
396
    {
UNCOV
397
        $self = clone $this;
×
UNCOV
398
        $self->uriVariables = $uriVariables;
×
399

UNCOV
400
        return $self;
×
401
    }
402

403
    public function getRoutePrefix(): ?string
404
    {
UNCOV
405
        return $this->routePrefix;
×
406
    }
407

408
    public function withRoutePrefix(string $routePrefix): static
409
    {
UNCOV
410
        $self = clone $this;
×
UNCOV
411
        $self->routePrefix = $routePrefix;
×
412

UNCOV
413
        return $self;
×
414
    }
415

416
    public function getRouteName(): ?string
417
    {
UNCOV
418
        return $this->routeName;
×
419
    }
420

421
    public function withRouteName(?string $routeName): static
422
    {
423
        $self = clone $this;
×
424
        $self->routeName = $routeName;
×
425

426
        return $self;
×
427
    }
428

429
    public function getDefaults(): ?array
430
    {
UNCOV
431
        return $this->defaults;
×
432
    }
433

434
    public function withDefaults(array $defaults): static
435
    {
UNCOV
436
        $self = clone $this;
×
UNCOV
437
        $self->defaults = $defaults;
×
438

UNCOV
439
        return $self;
×
440
    }
441

442
    public function getRequirements(): ?array
443
    {
UNCOV
444
        return $this->requirements;
×
445
    }
446

447
    public function withRequirements(array $requirements): static
448
    {
UNCOV
449
        $self = clone $this;
×
UNCOV
450
        $self->requirements = $requirements;
×
451

UNCOV
452
        return $self;
×
453
    }
454

455
    public function getOptions(): ?array
456
    {
UNCOV
457
        return $this->options;
×
458
    }
459

460
    public function withOptions(array $options): static
461
    {
UNCOV
462
        $self = clone $this;
×
UNCOV
463
        $self->options = $options;
×
464

UNCOV
465
        return $self;
×
466
    }
467

468
    public function getStateless(): ?bool
469
    {
UNCOV
470
        return $this->stateless;
×
471
    }
472

473
    public function withStateless($stateless): static
474
    {
UNCOV
475
        $self = clone $this;
×
UNCOV
476
        $self->stateless = $stateless;
×
477

UNCOV
478
        return $self;
×
479
    }
480

481
    public function getSunset(): ?string
482
    {
UNCOV
483
        return $this->sunset;
×
484
    }
485

486
    public function withSunset(string $sunset): static
487
    {
UNCOV
488
        $self = clone $this;
×
UNCOV
489
        $self->sunset = $sunset;
×
490

UNCOV
491
        return $self;
×
492
    }
493

494
    public function getAcceptPatch(): ?string
495
    {
UNCOV
496
        return $this->acceptPatch;
×
497
    }
498

499
    public function withAcceptPatch(string $acceptPatch): static
500
    {
UNCOV
501
        $self = clone $this;
×
UNCOV
502
        $self->acceptPatch = $acceptPatch;
×
503

UNCOV
504
        return $self;
×
505
    }
506

507
    public function getStatus(): ?int
508
    {
UNCOV
509
        return $this->status;
×
510
    }
511

512
    public function withStatus(int $status): static
513
    {
UNCOV
514
        $self = clone $this;
×
UNCOV
515
        $self->status = $status;
×
516

UNCOV
517
        return $self;
×
518
    }
519

520
    public function getHost(): ?string
521
    {
UNCOV
522
        return $this->host;
×
523
    }
524

525
    public function withHost(string $host): static
526
    {
UNCOV
527
        $self = clone $this;
×
UNCOV
528
        $self->host = $host;
×
529

UNCOV
530
        return $self;
×
531
    }
532

533
    public function getSchemes(): ?array
534
    {
UNCOV
535
        return $this->schemes;
×
536
    }
537

538
    public function withSchemes(array $schemes): static
539
    {
UNCOV
540
        $self = clone $this;
×
UNCOV
541
        $self->schemes = $schemes;
×
542

UNCOV
543
        return $self;
×
544
    }
545

546
    public function getCondition(): ?string
547
    {
UNCOV
548
        return $this->condition;
×
549
    }
550

551
    public function withCondition(string $condition): static
552
    {
UNCOV
553
        $self = clone $this;
×
UNCOV
554
        $self->condition = $condition;
×
555

UNCOV
556
        return $self;
×
557
    }
558

559
    public function getController(): ?string
560
    {
UNCOV
561
        return $this->controller;
×
562
    }
563

564
    public function withController(string $controller): static
565
    {
UNCOV
566
        $self = clone $this;
×
UNCOV
567
        $self->controller = $controller;
×
568

UNCOV
569
        return $self;
×
570
    }
571

572
    public function getHeaders(): ?array
573
    {
UNCOV
574
        return $this->headers;
×
575
    }
576

577
    public function withHeaders(array $headers): static
578
    {
579
        $self = clone $this;
×
580
        $self->headers = $headers;
×
581

582
        return $self;
×
583
    }
584

585
    public function getCacheHeaders(): ?array
586
    {
UNCOV
587
        return $this->cacheHeaders;
×
588
    }
589

590
    public function withCacheHeaders(array $cacheHeaders): static
591
    {
UNCOV
592
        $self = clone $this;
×
UNCOV
593
        $self->cacheHeaders = $cacheHeaders;
×
594

UNCOV
595
        return $self;
×
596
    }
597

598
    public function getPaginationViaCursor(): ?array
599
    {
UNCOV
600
        return $this->paginationViaCursor;
×
601
    }
602

603
    public function withPaginationViaCursor(array $paginationViaCursor): static
604
    {
605
        $self = clone $this;
×
606
        $self->paginationViaCursor = $paginationViaCursor;
×
607

608
        return $self;
×
609
    }
610

611
    public function getHydraContext(): ?array
612
    {
UNCOV
613
        return $this->hydraContext;
×
614
    }
615

616
    public function withHydraContext(array $hydraContext): static
617
    {
618
        $self = clone $this;
×
619
        $self->hydraContext = $hydraContext;
×
620

621
        return $self;
×
622
    }
623

624
    public function getOpenapi(): bool|OpenApiOperation|Webhook|null
625
    {
UNCOV
626
        return $this->openapi;
×
627
    }
628

629
    public function withOpenapi(bool|OpenApiOperation|Webhook $openapi): static
630
    {
UNCOV
631
        $self = clone $this;
×
UNCOV
632
        $self->openapi = $openapi;
×
633

UNCOV
634
        return $self;
×
635
    }
636

637
    public function getExceptionToStatus(): ?array
638
    {
UNCOV
639
        return $this->exceptionToStatus;
×
640
    }
641

642
    public function withExceptionToStatus(array $exceptionToStatus): static
643
    {
644
        $self = clone $this;
×
645
        $self->exceptionToStatus = $exceptionToStatus;
×
646

647
        return $self;
×
648
    }
649

650
    public function getLinks(): ?array
651
    {
UNCOV
652
        return $this->links;
×
653
    }
654

655
    /**
656
     * @param WebLink[] $links
657
     */
658
    public function withLinks(array $links): static
659
    {
660
        $self = clone $this;
×
661
        $self->links = $links;
×
662

663
        return $self;
×
664
    }
665

666
    public function getErrors(): ?array
667
    {
UNCOV
668
        return $this->errors;
×
669
    }
670

671
    /**
672
     * @param class-string<ProblemExceptionInterface>[] $errors
673
     */
674
    public function withErrors(array $errors): static
675
    {
676
        $self = clone $this;
×
677
        $self->errors = $errors;
×
678

679
        return $self;
×
680
    }
681
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc