Documentation

RootPackageLoader extends ArrayLoader
in package

ArrayLoader built for the sole purpose of loading the root package

Sets additional defaults and loads repositories

Tags
author

Jordi Boggiano j.boggiano@seld.be

Table of Contents

$loadOptions  : mixed
$versionParser  : mixed
$config  : Config
$io  : IOInterface
$manager  : RepositoryManager
$versionGuesser  : VersionGuesser
__construct()  : mixed
getBranchAlias()  : string|null
Retrieves a branch alias (dev-master => 1.0.x-dev for example) if it exists
load()  : RootPackageInterface
Converts a package from an array to a real instance
parseLinks()  : array<string|int, Link>
extractAliases()  : mixed
extractReferences()  : mixed
extractStabilityFlags()  : mixed

Properties

Methods

getBranchAlias()

Retrieves a branch alias (dev-master => 1.0.x-dev for example) if it exists

public getBranchAlias(array<string|int, mixed> $config) : string|null
Parameters
$config : array<string|int, mixed>

the entire package config

Return values
string|null

normalized version of the branch alias or null if there is none

load()

Converts a package from an array to a real instance

public load(array<string|int, mixed> $config[, string $class = 'Composer\Package\RootPackage' ][, string $cwd = null ]) : RootPackageInterface
Parameters
$config : array<string|int, mixed>

package data

$class : string = 'Composer\Package\RootPackage'

FQCN to be instantiated

$cwd : string = null

cwd of the root package to be used to guess the version if it is not provided

Return values
RootPackageInterface
public parseLinks(string $source, string $sourceVersion, string $description, array<string|int, mixed> $links) : array<string|int, Link>
Parameters
$source : string

source package name

$sourceVersion : string

source package version (pretty version ideally)

$description : string

link description (e.g. requires, replaces, ..)

$links : array<string|int, mixed>

array of package name => constraint mappings

Return values
array<string|int, Link>

extractAliases()

private extractAliases(array<string|int, mixed> $requires, array<string|int, mixed> $aliases) : mixed
Parameters
$requires : array<string|int, mixed>
$aliases : array<string|int, mixed>
Return values
mixed

extractReferences()

private extractReferences(array<string|int, mixed> $requires, array<string|int, mixed> $references) : mixed
Parameters
$requires : array<string|int, mixed>
$references : array<string|int, mixed>
Return values
mixed

extractStabilityFlags()

private extractStabilityFlags(array<string|int, mixed> $requires, array<string|int, mixed> $stabilityFlags, mixed $minimumStability) : mixed
Parameters
$requires : array<string|int, mixed>
$stabilityFlags : array<string|int, mixed>
$minimumStability : mixed
Return values
mixed

Search results