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

api-platform / core / 7142557150

08 Dec 2023 02:28PM UTC coverage: 36.003% (-1.4%) from 37.36%
7142557150

push

github

web-flow
fix(jsonld): remove link to ApiDocumentation when doc is disabled (#6029)

0 of 1 new or added line in 1 file covered. (0.0%)

2297 existing lines in 182 files now uncovered.

9992 of 27753 relevant lines covered (36.0%)

147.09 hits per line

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

0.0
/src/Metadata/IriConverterInterface.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\InvalidArgumentException;
17
use ApiPlatform\Metadata\Exception\ItemNotFoundException;
18
use ApiPlatform\Metadata\Exception\RuntimeException;
19

UNCOV
20
if (interface_exists(\ApiPlatform\Api\IriConverterInterface::class)) {
×
UNCOV
21
    class_alias(
×
UNCOV
22
        \ApiPlatform\Api\IriConverterInterface::class,
×
UNCOV
23
        __NAMESPACE__.'\IriConverterInterface'
×
UNCOV
24
    );
×
25

UNCOV
26
    if (false) { // @phpstan-ignore-line
×
27
        interface IriConverterInterface extends \ApiPlatform\Api\IriConverterInterface
28
        {
29
        }
30
    }
31
} else {
32
    /**
33
     * Converts item and resources to IRI and vice versa.
34
     *
35
     * @author Kévin Dunglas <dunglas@gmail.com>
36
     */
37
    interface IriConverterInterface
38
    {
39
        /**
40
         * Retrieves an item from its IRI.
41
         *
42
         * @throws InvalidArgumentException
43
         * @throws ItemNotFoundException
44
         */
45
        public function getResourceFromIri(string $iri, array $context = [], Operation $operation = null): object;
46

47
        /**
48
         * Gets the IRI associated with the given item.
49
         *
50
         * @param object|class-string $resource
51
         *
52
         * @throws InvalidArgumentException
53
         * @throws RuntimeException
54
         */
55
        public function getIriFromResource(object|string $resource, int $referenceType = UrlGeneratorInterface::ABS_PATH, Operation $operation = null, array $context = []): ?string;
56
    }
57
}
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

© 2026 Coveralls, Inc