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

api-platform / core / 16705318661

03 Aug 2025 01:05PM UTC coverage: 0.0% (-21.9%) from 21.944%
16705318661

Pull #7317

github

web-flow
Merge 1ca8642ff into d06b1a0a0
Pull Request #7317: Fix/4372 skip null values in hal

0 of 14 new or added lines in 3 files covered. (0.0%)

11680 existing lines in 376 files now uncovered.

0 of 51817 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/ApiProperty.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\Util\PropertyInfoToTypeInfoHelper;
17
use Symfony\Component\PropertyInfo\Type as LegacyType;
18
use Symfony\Component\Serializer\Attribute\Context;
19
use Symfony\Component\Serializer\Attribute\Groups;
20
use Symfony\Component\Serializer\Attribute\Ignore;
21
use Symfony\Component\Serializer\Attribute\MaxDepth;
22
use Symfony\Component\Serializer\Attribute\SerializedName;
23
use Symfony\Component\Serializer\Attribute\SerializedPath;
24
use Symfony\Component\TypeInfo\Type;
25

26
/**
27
 * ApiProperty annotation.
28
 *
29
 * @author Kévin Dunglas <dunglas@gmail.com>
30
 */
31
#[\Attribute(\Attribute::TARGET_PROPERTY | \Attribute::TARGET_METHOD | \Attribute::TARGET_PARAMETER | \Attribute::TARGET_CLASS_CONSTANT | \Attribute::TARGET_CLASS | \Attribute::IS_REPEATABLE)]
32
final class ApiProperty
33
{
34
    private ?array $types;
35
    private ?array $serialize;
36
    private ?Type $nativeType;
37

38
    /**
39
     * @param bool|null                                                                                                                                   $readableLink            https://api-platform.com/docs/core/serialization/#force-iri-with-relations-of-the-same-type-parentchilds-relations
40
     * @param bool|null                                                                                                                                   $writableLink            https://api-platform.com/docs/core/serialization/#force-iri-with-relations-of-the-same-type-parentchilds-relations
41
     * @param bool|null                                                                                                                                   $required                https://api-platform.com/docs/admin/validation/#client-side-validation
42
     * @param bool|null                                                                                                                                   $identifier              https://api-platform.com/docs/core/identifiers/
43
     * @param mixed                                                                                                                                       $example                 https://api-platform.com/docs/core/openapi/#using-the-openapi-and-swagger-contexts
44
     * @param string|null                                                                                                                                 $deprecationReason       https://api-platform.com/docs/core/deprecations/#deprecating-resource-classes-operations-and-properties
45
     * @param bool|null                                                                                                                                   $fetchEager              https://api-platform.com/docs/core/performance/#eager-loading
46
     * @param array|null                                                                                                                                  $jsonldContext           https://api-platform.com/docs/core/extending-jsonld-context/#extending-json-ld-and-hydra-contexts
47
     * @param array|null                                                                                                                                  $openapiContext          https://api-platform.com/docs/core/openapi/#using-the-openapi-and-swagger-contexts
48
     * @param bool|null                                                                                                                                   $push                    https://api-platform.com/docs/core/push-relations/
49
     * @param string|\Stringable|null                                                                                                                     $security                https://api-platform.com/docs/core/security
50
     * @param string|\Stringable|null                                                                                                                     $securityPostDenormalize https://api-platform.com/docs/core/security/#executing-access-control-rules-after-denormalization
51
     * @param string[]|null                                                                                                                               $types                   the RDF types of this property
52
     * @param string[]|null                                                                                                                               $iris
53
     * @param LegacyType[]|null                                                                                                                           $builtinTypes
54
     * @param string|null                                                                                                                                 $uriTemplate             (experimental) whether to return the subRessource collection IRI instead of an iterable of IRI
55
     * @param string|null                                                                                                                                 $property                The property name
56
     * @param Context|Groups|Ignore|SerializedName|SerializedPath|MaxDepth|array<array-key, Context|Groups|Ignore|SerializedName|SerializedPath|MaxDepth> $serialize               Serializer attributes
57
     * @param Type|null                                                                                                                                   $nativeType              The internal PHP type
58
     */
59
    public function __construct(
60
        private ?string $description = null,
61
        private ?bool $readable = null,
62
        private ?bool $writable = null,
63
        private ?bool $readableLink = null,
64
        private ?bool $writableLink = null,
65
        private ?bool $required = null,
66
        private ?bool $identifier = null,
67
        private mixed $default = null,
68
        private mixed $example = null,
69
        /**
70
         * The `deprecationReason` option deprecates the current operation with a deprecation message.
71
         *
72
         * <div data-code-selector>
73
         *
74
         * ```php
75
         * <?php
76
         * // api/src/Entity/Review.php
77
         * use ApiPlatform\Metadata\ApiProperty;
78
         * use ApiPlatform\Metadata\ApiResource;
79
         *
80
         * #[ApiResource]
81
         * class Review
82
         * {
83
         *     #[ApiProperty(deprecationReason: "Use the rating property instead")]
84
         *     public string $letter;
85
         * }
86
         * ```
87
         *
88
         * ```yaml
89
         * # api/config/api_platform/properties.yaml
90
         * properties:
91
         *     App\Entity\Review:
92
         *         letter:
93
         *             deprecationReason: 'Create a Book instead'
94
         * ```
95
         *
96
         * ```xml
97
         * <?xml version="1.0" encoding="UTF-8" ?>
98
         * <!-- api/config/api_platform/properties.xml -->
99
         *
100
         * <properties
101
         *         xmlns="https://api-platform.com/schema/metadata/properties-3.0"
102
         *         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
103
         *         xsi:schemaLocation="https://api-platform.com/schema/metadata/properties-3.0
104
         *         https://api-platform.com/schema/metadata/properties-3.0.xsd">
105
         *     <property resource="App\Entity\Review" name="letter" deprecationReason="Create a Book instead" />
106
         * </properties>
107
         * ```
108
         *
109
         * </div>
110
         *
111
         * - With JSON-lD / Hydra, [an `owl:deprecated` annotation property](https://www.w3.org/TR/owl2-syntax/#Annotation_Properties) will be added to the appropriate data structure
112
         * - With Swagger / OpenAPI, [a `deprecated` property](https://swagger.io/docs/specification/2-0/paths-and-operations/) will be added
113
         * - With GraphQL, the [`isDeprecated` and `deprecationReason` properties](https://facebook.github.io/graphql/June2018/#sec-Deprecation) will be added to the schema
114
         */
115
        private ?string $deprecationReason = null,
116
        private ?bool $fetchable = null,
117
        private ?bool $fetchEager = null,
118
        private ?array $jsonldContext = null,
119
        private ?array $openapiContext = null,
120
        private ?array $jsonSchemaContext = null,
121
        private ?bool $push = null,
122
        /**
123
         * The `security` option defines the access to the current property, on normalization process, based on Symfony Security.
124
         * It receives an `object` variable related to the current object, and a `property` variable related to the current property.
125
         *
126
         * <div data-code-selector>
127
         *
128
         * ```php
129
         * <?php
130
         * // api/src/Entity/Review.php
131
         * use ApiPlatform\Metadata\ApiProperty;
132
         * use ApiPlatform\Metadata\ApiResource;
133
         *
134
         * #[ApiResource]
135
         * class Review
136
         * {
137
         *     #[ApiProperty(security: 'is_granted("ROLE_ADMIN")')]
138
         *     public string $letter;
139
         * }
140
         * ```
141
         *
142
         * ```yaml
143
         * # api/config/api_platform/properties.yaml
144
         * properties:
145
         *     App\Entity\Review:
146
         *         letter:
147
         *             security: 'is_granted("ROLE_ADMIN")'
148
         * ```
149
         *
150
         * ```xml
151
         * <?xml version="1.0" encoding="UTF-8" ?>
152
         * <!-- api/config/api_platform/properties.xml -->
153
         *
154
         * <properties
155
         *         xmlns="https://api-platform.com/schema/metadata/properties-3.0"
156
         *         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
157
         *         xsi:schemaLocation="https://api-platform.com/schema/metadata/properties-3.0
158
         *         https://api-platform.com/schema/metadata/properties-3.0.xsd">
159
         *     <property resource="App\Entity\Review" name="letter" security="is_granted('ROLE_ADMIN')" />
160
         * </properties>
161
         * ```
162
         *
163
         * </div>
164
         */
165
        private string|\Stringable|null $security = null,
166
        /**
167
         * The `securityPostDenormalize` option defines access to the current property after the denormalization process, based on Symfony Security.
168
         * It receives an `object` variable related to the current object, and a `property` variable related to the current property.
169
         *
170
         * <div data-code-selector>
171
         *
172
         * ```php
173
         * <?php
174
         * // api/src/Entity/Review.php
175
         * use ApiPlatform\Metadata\ApiProperty;
176
         * use ApiPlatform\Metadata\ApiResource;
177
         *
178
         * #[ApiResource]
179
         * class Review
180
         * {
181
         *     #[ApiProperty(securityPostDenormalize: 'is_granted("ROLE_ADMIN")')]
182
         *     public string $letter;
183
         * }
184
         * ```
185
         *
186
         * ```yaml
187
         * # api/config/api_platform/properties.yaml
188
         * properties:
189
         *     App\Entity\Review:
190
         *         letter:
191
         *             securityPostDenormalize: 'is_granted("ROLE_ADMIN")'
192
         * ```
193
         *
194
         * ```xml
195
         * <?xml version="1.0" encoding="UTF-8" ?>
196
         * <!-- api/config/api_platform/properties.xml -->
197
         *
198
         * <properties
199
         *         xmlns="https://api-platform.com/schema/metadata/properties-3.0"
200
         *         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
201
         *         xsi:schemaLocation="https://api-platform.com/schema/metadata/properties-3.0
202
         *         https://api-platform.com/schema/metadata/properties-3.0.xsd">
203
         *     <property resource="App\Entity\Review" name="letter" securityPostDenormalize="is_granted('ROLE_ADMIN')" />
204
         * </properties>
205
         * ```
206
         *
207
         * </div>
208
         */
209
        private string|\Stringable|null $securityPostDenormalize = null,
210
        array|string|null $types = null,
211
        /*
212
         * The related php types.
213
         *
214
         * deprecated since 4.2, use "nativeType" instead.
215
         */
216
        private ?array $builtinTypes = null,
217
        private ?array $schema = null,
218
        private ?bool $initializable = null,
219
        private $iris = null,
220
        private ?bool $genId = null,
221
        private ?string $uriTemplate = null,
222
        private ?string $property = null,
223
        private ?string $policy = null,
224
        array|Context|Groups|Ignore|SerializedName|SerializedPath|MaxDepth|null $serialize = null,
225
        /**
226
         * Whether to document this property as a hydra:supportedProperty.
227
         */
228
        private ?bool $hydra = null,
229
        ?Type $nativeType = null,
230
        private array $extraProperties = [],
231
    ) {
UNCOV
232
        $this->types = \is_string($types) ? (array) $types : $types;
×
UNCOV
233
        $this->serialize = (null === $serialize || \is_array($serialize)) ? $serialize : [$serialize];
×
UNCOV
234
        $this->nativeType = $nativeType;
×
235

UNCOV
236
        if ($this->builtinTypes) {
×
237
            trigger_deprecation('api_platform/metadata', '4.2', \sprintf('The "builtinTypes" argument of "%s" is deprecated, use "nativeType" instead.', __CLASS__));
×
238
            $this->nativeType ??= PropertyInfoToTypeInfoHelper::convertLegacyTypesToType($this->builtinTypes);
×
UNCOV
239
        } elseif ($this->nativeType) {
×
240
            $this->builtinTypes = PropertyInfoToTypeInfoHelper::convertTypeToLegacyTypes($this->nativeType) ?? [];
×
241
        }
242
    }
243

244
    public function getProperty(): ?string
245
    {
UNCOV
246
        return $this->property;
×
247
    }
248

249
    public function withProperty(string $property): static
250
    {
UNCOV
251
        $self = clone $this;
×
UNCOV
252
        $self->property = $property;
×
253

UNCOV
254
        return $self;
×
255
    }
256

257
    public function getDescription(): ?string
258
    {
UNCOV
259
        return $this->description;
×
260
    }
261

262
    public function withDescription(string $description): static
263
    {
UNCOV
264
        $self = clone $this;
×
UNCOV
265
        $self->description = $description;
×
266

UNCOV
267
        return $self;
×
268
    }
269

270
    public function isReadable(): ?bool
271
    {
UNCOV
272
        return $this->readable;
×
273
    }
274

275
    public function withReadable(bool $readable): static
276
    {
UNCOV
277
        $self = clone $this;
×
UNCOV
278
        $self->readable = $readable;
×
279

UNCOV
280
        return $self;
×
281
    }
282

283
    public function isWritable(): ?bool
284
    {
UNCOV
285
        return $this->writable;
×
286
    }
287

288
    public function withWritable(bool $writable): static
289
    {
UNCOV
290
        $self = clone $this;
×
UNCOV
291
        $self->writable = $writable;
×
292

UNCOV
293
        return $self;
×
294
    }
295

296
    public function isReadableLink(): ?bool
297
    {
UNCOV
298
        return $this->readableLink;
×
299
    }
300

301
    public function withReadableLink(bool $readableLink): static
302
    {
UNCOV
303
        $self = clone $this;
×
UNCOV
304
        $self->readableLink = $readableLink;
×
305

UNCOV
306
        return $self;
×
307
    }
308

309
    public function isWritableLink(): ?bool
310
    {
UNCOV
311
        return $this->writableLink;
×
312
    }
313

314
    public function withWritableLink(bool $writableLink): static
315
    {
UNCOV
316
        $self = clone $this;
×
UNCOV
317
        $self->writableLink = $writableLink;
×
318

UNCOV
319
        return $self;
×
320
    }
321

322
    public function isRequired(): ?bool
323
    {
UNCOV
324
        return $this->required;
×
325
    }
326

327
    public function withRequired(bool $required): static
328
    {
UNCOV
329
        $self = clone $this;
×
UNCOV
330
        $self->required = $required;
×
331

UNCOV
332
        return $self;
×
333
    }
334

335
    public function isIdentifier(): ?bool
336
    {
UNCOV
337
        return $this->identifier;
×
338
    }
339

340
    public function withIdentifier(bool $identifier): static
341
    {
UNCOV
342
        $self = clone $this;
×
UNCOV
343
        $self->identifier = $identifier;
×
344

UNCOV
345
        return $self;
×
346
    }
347

348
    public function getDefault(): mixed
349
    {
UNCOV
350
        return $this->default;
×
351
    }
352

353
    public function withDefault(mixed $default): static
354
    {
UNCOV
355
        $self = clone $this;
×
UNCOV
356
        $self->default = $default;
×
357

UNCOV
358
        return $self;
×
359
    }
360

361
    public function getExample(): mixed
362
    {
UNCOV
363
        return $this->example;
×
364
    }
365

366
    public function withExample(mixed $example): static
367
    {
UNCOV
368
        $self = clone $this;
×
UNCOV
369
        $self->example = $example;
×
370

UNCOV
371
        return $self;
×
372
    }
373

374
    public function getDeprecationReason(): ?string
375
    {
UNCOV
376
        return $this->deprecationReason;
×
377
    }
378

379
    public function withDeprecationReason($deprecationReason): static
380
    {
UNCOV
381
        $self = clone $this;
×
UNCOV
382
        $self->deprecationReason = $deprecationReason;
×
383

UNCOV
384
        return $self;
×
385
    }
386

387
    public function isFetchable(): ?bool
388
    {
UNCOV
389
        return $this->fetchable;
×
390
    }
391

392
    public function withFetchable($fetchable): static
393
    {
394
        $self = clone $this;
×
395
        $self->fetchable = $fetchable;
×
396

397
        return $self;
×
398
    }
399

400
    public function getFetchEager(): ?bool
401
    {
UNCOV
402
        return $this->fetchEager;
×
403
    }
404

405
    public function withFetchEager($fetchEager): static
406
    {
407
        $self = clone $this;
×
408
        $self->fetchEager = $fetchEager;
×
409

410
        return $self;
×
411
    }
412

413
    public function getJsonldContext(): ?array
414
    {
UNCOV
415
        return $this->jsonldContext;
×
416
    }
417

418
    public function withJsonldContext($jsonldContext): static
419
    {
UNCOV
420
        $self = clone $this;
×
UNCOV
421
        $self->jsonldContext = $jsonldContext;
×
422

UNCOV
423
        return $self;
×
424
    }
425

426
    public function getOpenapiContext(): ?array
427
    {
UNCOV
428
        return $this->openapiContext;
×
429
    }
430

431
    public function withOpenapiContext($openapiContext): static
432
    {
UNCOV
433
        $self = clone $this;
×
UNCOV
434
        $self->openapiContext = $openapiContext;
×
435

UNCOV
436
        return $self;
×
437
    }
438

439
    public function getJsonSchemaContext(): ?array
440
    {
UNCOV
441
        return $this->jsonSchemaContext;
×
442
    }
443

444
    public function withJsonSchemaContext($jsonSchemaContext): static
445
    {
UNCOV
446
        $self = clone $this;
×
UNCOV
447
        $self->jsonSchemaContext = $jsonSchemaContext;
×
448

UNCOV
449
        return $self;
×
450
    }
451

452
    public function getPush(): ?bool
453
    {
UNCOV
454
        return $this->push;
×
455
    }
456

457
    public function withPush($push): static
458
    {
UNCOV
459
        $self = clone $this;
×
UNCOV
460
        $self->push = $push;
×
461

UNCOV
462
        return $self;
×
463
    }
464

465
    public function getSecurity(): ?string
466
    {
UNCOV
467
        return $this->security instanceof \Stringable ? (string) $this->security : $this->security;
×
468
    }
469

470
    public function withSecurity($security): static
471
    {
UNCOV
472
        $self = clone $this;
×
UNCOV
473
        $self->security = $security;
×
474

UNCOV
475
        return $self;
×
476
    }
477

478
    public function getSecurityPostDenormalize(): ?string
479
    {
UNCOV
480
        return $this->securityPostDenormalize instanceof \Stringable ? (string) $this->securityPostDenormalize : $this->securityPostDenormalize;
×
481
    }
482

483
    public function withSecurityPostDenormalize($securityPostDenormalize): static
484
    {
UNCOV
485
        $self = clone $this;
×
UNCOV
486
        $self->securityPostDenormalize = $securityPostDenormalize;
×
487

UNCOV
488
        return $self;
×
489
    }
490

491
    public function getTypes(): ?array
492
    {
UNCOV
493
        return $this->types;
×
494
    }
495

496
    /**
497
     * @param string[]|string $types
498
     */
499
    public function withTypes(array|string $types = []): static
500
    {
UNCOV
501
        $self = clone $this;
×
UNCOV
502
        $self->types = (array) $types;
×
503

UNCOV
504
        return $self;
×
505
    }
506

507
    /**
508
     * deprecated since 4.2, use "getNativeType" instead.
509
     *
510
     * @return LegacyType[]|null
511
     */
512
    public function getBuiltinTypes(): ?array
513
    {
514
        trigger_deprecation('api-platform/metadata', '4.2', 'The "%s()" method is deprecated, use "%s::getNativeType()" instead.', __METHOD__, self::class);
×
515

516
        if (null === $this->builtinTypes && null !== $this->nativeType) {
×
517
            $this->builtinTypes = PropertyInfoToTypeInfoHelper::convertTypeToLegacyTypes($this->nativeType) ?? [];
×
518
        }
519

520
        return $this->builtinTypes;
×
521
    }
522

523
    /**
524
     * deprecated since 4.2, use "withNativeType" instead.
525
     *
526
     * @param LegacyType[] $builtinTypes
527
     */
528
    public function withBuiltinTypes(array $builtinTypes = []): static
529
    {
530
        trigger_deprecation('api-platform/metadata', '4.2', 'The "%s()" method is deprecated, use "%s::withNativeType()" instead.', __METHOD__, self::class);
×
531

532
        $self = clone $this;
×
533
        $self->builtinTypes = $builtinTypes;
×
534
        $self->nativeType = PropertyInfoToTypeInfoHelper::convertLegacyTypesToType($builtinTypes);
×
535

536
        return $self;
×
537
    }
538

539
    public function getNativeType(): ?Type
540
    {
UNCOV
541
        return $this->nativeType;
×
542
    }
543

544
    public function withNativeType(?Type $nativeType): self
545
    {
UNCOV
546
        $self = clone $this;
×
UNCOV
547
        $self->nativeType = $nativeType;
×
548

UNCOV
549
        return $self;
×
550
    }
551

552
    public function getSchema(): ?array
553
    {
UNCOV
554
        return $this->schema;
×
555
    }
556

557
    public function withSchema(array $schema = []): static
558
    {
UNCOV
559
        $self = clone $this;
×
UNCOV
560
        $self->schema = $schema;
×
561

UNCOV
562
        return $self;
×
563
    }
564

565
    public function withInitializable(?bool $initializable): static
566
    {
UNCOV
567
        $self = clone $this;
×
UNCOV
568
        $self->initializable = $initializable;
×
569

UNCOV
570
        return $self;
×
571
    }
572

573
    public function isInitializable(): ?bool
574
    {
UNCOV
575
        return $this->initializable;
×
576
    }
577

578
    public function getExtraProperties(): array
579
    {
UNCOV
580
        return $this->extraProperties;
×
581
    }
582

583
    public function withExtraProperties(array $extraProperties = []): static
584
    {
UNCOV
585
        $self = clone $this;
×
UNCOV
586
        $self->extraProperties = $extraProperties;
×
587

UNCOV
588
        return $self;
×
589
    }
590

591
    /**
592
     * Gets IRI of this property.
593
     *
594
     * @return string[]|null
595
     */
596
    public function getIris()
597
    {
UNCOV
598
        return $this->iris;
×
599
    }
600

601
    /**
602
     * Returns a new instance with the given IRI.
603
     *
604
     * @param string|string[] $iris
605
     */
606
    public function withIris(string|array $iris): static
607
    {
UNCOV
608
        $metadata = clone $this;
×
UNCOV
609
        $metadata->iris = (array) $iris;
×
610

UNCOV
611
        return $metadata;
×
612
    }
613

614
    /**
615
     * Whether to generate a skolem iri on anonymous resources.
616
     */
617
    public function getGenId(): ?bool
618
    {
UNCOV
619
        return $this->genId;
×
620
    }
621

622
    public function withGenId(bool $genId): static
623
    {
UNCOV
624
        $metadata = clone $this;
×
UNCOV
625
        $metadata->genId = $genId;
×
626

UNCOV
627
        return $metadata;
×
628
    }
629

630
    /**
631
     * Whether to return the subRessource collection IRI instead of an iterable of IRI.
632
     *
633
     * @experimental
634
     */
635
    public function getUriTemplate(): ?string
636
    {
UNCOV
637
        return $this->uriTemplate;
×
638
    }
639

640
    public function withUriTemplate(?string $uriTemplate): static
641
    {
642
        $metadata = clone $this;
×
643
        $metadata->uriTemplate = $uriTemplate;
×
644

645
        return $metadata;
×
646
    }
647

648
    public function getPolicy(): ?string
649
    {
UNCOV
650
        return $this->policy;
×
651
    }
652

653
    public function withPolicy(?string $policy): static
654
    {
655
        $self = clone $this;
×
656
        $self->policy = $policy;
×
657

658
        return $self;
×
659
    }
660

661
    public function getSerialize(): ?array
662
    {
UNCOV
663
        return $this->serialize;
×
664
    }
665

666
    /**
667
     * @param Context|Groups|Ignore|SerializedName|SerializedPath|MaxDepth|array<array-key, Context|Groups|Ignore|SerializedName|SerializedPath|MaxDepth> $serialize
668
     */
669
    public function withSerialize(array|Context|Groups|Ignore|SerializedName|SerializedPath|MaxDepth $serialize): static
670
    {
671
        $self = clone $this;
×
672
        $self->serialize = (array) $serialize;
×
673

674
        return $self;
×
675
    }
676

677
    public function getHydra(): ?bool
678
    {
UNCOV
679
        return $this->hydra;
×
680
    }
681

682
    public function withHydra(bool $hydra): static
683
    {
UNCOV
684
        $self = clone $this;
×
UNCOV
685
        $self->hydra = $hydra;
×
686

UNCOV
687
        return $self;
×
688
    }
689
}
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