• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In
You are now the owner of this repo.

jojo1981 / data-resolver / 170

pending completion
170

cron

travis-ci-com

jojo1981
Fix error: `Argument 1 passed to Jojo1981\DataResolver\Resolver\Context::pushPathPart() must be of the type string, int given, called in...`

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

454 of 868 relevant lines covered (52.3%)

5.52 hits per line

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

0.0
/src/Builder/Extractor/PropertyExtractorBuilder.php
1
<?php declare(strict_types=1);
2
/*
3
 * This file is part of the jojo1981/data-resolver package
4
 *
5
 * Copyright (c) 2019 Joost Nijhuis <jnijhuis81@gmail.com>
6
 *
7
 * For the full copyright and license information, please view the LICENSE
8
 * file that was distributed in the root of the source code
9
 */
10
namespace Jojo1981\DataResolver\Builder\Extractor;
11

12
use Jojo1981\DataResolver\Builder\ExtractorBuilderInterface;
13
use Jojo1981\DataResolver\Extractor\ExtractorInterface;
14
use Jojo1981\DataResolver\Extractor\PropertyExtractor;
15
use Jojo1981\DataResolver\Handler\MergeHandlerInterface;
16
use Jojo1981\DataResolver\Handler\PropertyHandlerInterface;
17
use Jojo1981\DataResolver\NamingStrategy\NamingStrategyInterface;
18

19
/**
20
 * @internal
21
 * @package Jojo1981\DataResolver\Builder\Extractor
22
 */
23
final class PropertyExtractorBuilder implements ExtractorBuilderInterface
24
{
25
    /** @var NamingStrategyInterface */
26
    private NamingStrategyInterface $namingStrategy;
27

28
    /** @var PropertyHandlerInterface */
29
    private PropertyHandlerInterface $propertyHandler;
30

31
    /** @var MergeHandlerInterface */
32
    private MergeHandlerInterface $mergeHandler;
33

34
    /** @var string[] */
35
    private array $propertyNames;
36

37
    /**
38
     * @param NamingStrategyInterface $namingStrategy
39
     * @param PropertyHandlerInterface $propertyHandler
40
     * @param MergeHandlerInterface $mergeHandler
41
     * @param string[] $propertyNames
42
     */
43
    public function __construct(
44
        NamingStrategyInterface $namingStrategy,
45
        PropertyHandlerInterface $propertyHandler,
46
        MergeHandlerInterface $mergeHandler,
47
        array $propertyNames
48
    ) {
49
        $this->namingStrategy = $namingStrategy;
×
50
        $this->propertyHandler = $propertyHandler;
×
51
        $this->mergeHandler = $mergeHandler;
×
52
        $this->propertyNames = $propertyNames;
×
53
    }
54

55
    /**
56
     * @return PropertyExtractor
57
     */
58
    public function build(): ExtractorInterface
59
    {
60
        return new PropertyExtractor(
×
61
            $this->namingStrategy,
×
62
            $this->propertyHandler,
×
63
            $this->mergeHandler,
×
64
            $this->propertyNames
×
65
        );
×
66
    }
67
}
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