PHP 클래스 Pyrech\ComposerChangelogs\UrlGenerator\GitBasedUrlGenerator

상속: implements Pyrech\ComposerChangelogs\UrlGenerator\UrlGenerator
파일 보기 프로젝트 열기: pyrech/composer-changelogs

공개 메소드들

메소드 설명
supports ( $sourceUrl )

보호된 메소드들

메소드 설명
extractRepositoryInformation ( string $sourceUrl ) : array Extracts information like user and repository from the http url.
generateBaseUrl ( string $sourceUrl ) : string Generates the canonical http url for a repository.
getCompareVersion ( Version $version ) : string Get the version to use for the compare url.
getDomain ( ) : string Returns the domain of the service, like "example.org".

비공개 메소드들

메소드 설명
isSshUrl ( string $url ) : string Returns whether an url uses a ssh git protocol.
transformSshUrlIntoHttp ( string $url ) : string Transform an ssh git url into an http one.

메소드 상세

extractRepositoryInformation() 보호된 메소드

Extracts information like user and repository from the http url.
protected extractRepositoryInformation ( string $sourceUrl ) : array
$sourceUrl string
리턴 array

generateBaseUrl() 보호된 메소드

It ensures there is no .git part in http url. It also supports ssh urls by converting them in their http equivalent format.
protected generateBaseUrl ( string $sourceUrl ) : string
$sourceUrl string
리턴 string

getCompareVersion() 보호된 메소드

For dev versions, it returns the commit short hash in full pretty version.
protected getCompareVersion ( Version $version ) : string
$version Pyrech\ComposerChangelogs\Version
리턴 string

getDomain() 추상적인 보호된 메소드

Returns the domain of the service, like "example.org".
abstract protected getDomain ( ) : string
리턴 string

supports() 공개 메소드

public supports ( $sourceUrl )