Properties

$url

$url : string

Type

string

$originUrl

$originUrl : string

Type

string

$repoConfig

$repoConfig : array

Type

array

$infoCache

$infoCache : array

Type

array

$owner

$owner : 

Type

$repository

$repository : 

Type

$hasIssues

$hasIssues : 

Type

$rootIdentifier

$rootIdentifier : 

Type

$tags

$tags : 

Type

$branches

$branches : 

Type

$branchesUrl

$branchesUrl : 

Type

$tagsUrl

$tagsUrl : 

Type

$homeUrl

$homeUrl : 

Type

$website

$website : 

Type

$cloneHttpsUrl

$cloneHttpsUrl : 

Type

$vcsType

$vcsType : string|null

Type

string|null — if set either git or hg

Methods

__construct()

__construct(array  $repoConfig, \Composer\IO\IOInterface  $io, \Composer\Config  $config, \Composer\Util\ProcessExecutor  $process = null, \Composer\Util\RemoteFilesystem  $remoteFilesystem = null) 

Constructor.

Parameters

array $repoConfig

The repository configuration

\Composer\IO\IOInterface $io

The IO instance

\Composer\Config $config

The composer configuration

\Composer\Util\ProcessExecutor $process

Process instance, injectable for mocking

\Composer\Util\RemoteFilesystem $remoteFilesystem

Remote Filesystem, injectable for mocking

getComposerInformation()

getComposerInformation(string  $identifier) : array

Return the composer.json file information

Parameters

string $identifier

Any identifier to a specific branch/tag/commit

Returns

array —

containing all infos from the composer.json file

hasComposerFile()

hasComposerFile(string  $identifier) : boolean

Return true if the repository has a composer file for a given identifier, false otherwise.

Parameters

string $identifier

Any identifier to a specific branch/tag/commit

Returns

boolean —

Whether the repository has a composer file for a given identifier.

cleanup()

cleanup() 

Performs any cleanup necessary as the driver is not longer needed

initialize()

initialize() 

{@inheritDoc}

getUrl()

getUrl() 

{@inheritDoc}

getFileContent()

getFileContent(  $file,   $identifier) 

{@inheritdoc}

Parameters

$file
$identifier

getChangeDate()

getChangeDate(  $identifier) 

{@inheritdoc}

Parameters

$identifier

getSource()

getSource(  $identifier) 

{@inheritDoc}

Parameters

$identifier

getDist()

getDist(  $identifier) 

{@inheritDoc}

Parameters

$identifier

getTags()

getTags() 

{@inheritDoc}

getBranches()

getBranches() 

{@inheritDoc}

shouldCache()

shouldCache(string  $identifier) : boolean

Returns whether or not the given $identifier should be cached or not.

Parameters

string $identifier

Returns

boolean

getBaseComposerInformation()

getBaseComposerInformation(  $identifier) 

Parameters

$identifier

getScheme()

getScheme() : string

Get the https or http protocol depending on SSL support.

Call this only if you know that the server supports both.

Returns

string —

The correct type of protocol

getContents()

getContents(string  $url) : mixed

Get the remote content.

Parameters

string $url

The URL of content

Returns

mixed —

The result

getRepoData()

getRepoData() : boolean

Attempts to fetch the repository data via the BitBucket API and sets some parameters which are used in other methods

Returns

boolean

getContentsWithOAuthCredentials()

getContentsWithOAuthCredentials(string  $url, boolean  $fetchingRepoData = false) : mixed

Get the remote content.

Parameters

string $url

The URL of content

boolean $fetchingRepoData

Returns

mixed —

The result

generateSshUrl()

generateSshUrl() : string

Generate an SSH URL

Returns

string

attemptCloneFallback()

attemptCloneFallback() 

setupFallbackDriver()

setupFallbackDriver(string  $url) : void

Parameters

string $url

parseCloneUrls()

parseCloneUrls(array  $cloneLinks) : void

Parameters

array $cloneLinks

getMainBranchData()

getMainBranchData() : array|null

Returns

array|null