1 | <?php namespace Arcanedev\Composer\Entities\PackageTraits; |
||
13 | trait RepositoriesTrait |
||
14 | { |
||
15 | /* ------------------------------------------------------------------------------------------------ |
||
16 | | Properties |
||
17 | | ------------------------------------------------------------------------------------------------ |
||
18 | */ |
||
19 | /** @var \Arcanedev\Composer\Utilities\Logger $logger */ |
||
20 | protected $logger; |
||
21 | |||
22 | /** @var array $json */ |
||
23 | protected $json; |
||
24 | |||
25 | /* ------------------------------------------------------------------------------------------------ |
||
26 | | Getters & Setters |
||
27 | | ------------------------------------------------------------------------------------------------ |
||
28 | */ |
||
29 | /** |
||
30 | * Get composer. |
||
31 | * |
||
32 | * @return \Composer\Composer |
||
33 | */ |
||
34 | abstract public function getComposer(); |
||
35 | |||
36 | /* ------------------------------------------------------------------------------------------------ |
||
37 | | Main Functions |
||
38 | | ------------------------------------------------------------------------------------------------ |
||
39 | */ |
||
40 | /** |
||
41 | * Add a collection of repositories described by the given configuration |
||
42 | * to the given package and the global repository manager. |
||
43 | * |
||
44 | * @param \Composer\Package\RootPackageInterface $root |
||
45 | * @param \Arcanedev\Composer\Entities\PluginState $state |
||
46 | */ |
||
47 | private function addRepositories(RootPackageInterface $root, PluginState $state) |
||
67 | |||
68 | /* ------------------------------------------------------------------------------------------------ |
||
69 | | Other Functions |
||
70 | | ------------------------------------------------------------------------------------------------ |
||
71 | */ |
||
72 | /** |
||
73 | * Add a repository to collection of repositories. |
||
74 | * |
||
75 | * @param \Composer\Repository\RepositoryManager $repoManager |
||
76 | * @param array $repositories |
||
77 | * @param array $repoJson |
||
78 | * @param bool $prepend |
||
79 | */ |
||
80 | private function addRepository( |
||
97 | } |
||
98 |