PHP 클래스 Airship\Engine\Continuum\Version

This contains the version comparison logic.
파일 보기 프로젝트 열기: paragonie/airship 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$currentVersion string

공개 메소드들

메소드 설명
__construct ( string $currentVersion ) Version constructor.
getGroup ( integer $value, integer $group = self::GROUP_INCREMENT ) : integer Get the value within a group (i.e. 1.0.3 => 1000300)
getUpgrade ( integer $type = self::GROUP_PATCH ) : string Get the expected next version, based on upgrade type.
isMajorUpgrade ( string $nextVersion ) : boolean Is this a major upgrade? (Semantic versioning)
isMinorUpgrade ( string $nextVersion ) : boolean Is this a minor upgrade? (Semantic versioning)
isPatchUpgrade ( string $nextVersion ) : boolean Is this a patch upgrade? (Semantic versioning)
isUpgrade ( string $nextVersion ) : boolean Is $nextVersion newer than $this->currentVersion?

메소드 상세

__construct() 공개 메소드

Version constructor.
public __construct ( string $currentVersion )
$currentVersion string

getGroup() 공개 정적인 메소드

Get the value within a group (i.e. 1.0.3 => 1000300)
public static getGroup ( integer $value, integer $group = self::GROUP_INCREMENT ) : integer
$value integer An expanded version
$group integer
리턴 integer

getUpgrade() 공개 메소드

From '1.4.11': (self::GROUP_PATCH) -> '1.4.12' (self::GROUP_MINOR) -> '1.5.0' (self::GROUP_MAJOR) -> '2.0.0'
public getUpgrade ( integer $type = self::GROUP_PATCH ) : string
$type integer
리턴 string

isMajorUpgrade() 공개 메소드

Is this a major upgrade? (Semantic versioning)
public isMajorUpgrade ( string $nextVersion ) : boolean
$nextVersion string
리턴 boolean

isMinorUpgrade() 공개 메소드

Is this a minor upgrade? (Semantic versioning)
public isMinorUpgrade ( string $nextVersion ) : boolean
$nextVersion string
리턴 boolean

isPatchUpgrade() 공개 메소드

Is this a patch upgrade? (Semantic versioning)
public isPatchUpgrade ( string $nextVersion ) : boolean
$nextVersion string
리턴 boolean

isUpgrade() 공개 메소드

Is $nextVersion newer than $this->currentVersion?
public isUpgrade ( string $nextVersion ) : boolean
$nextVersion string
리턴 boolean

프로퍼티 상세

$currentVersion 보호되어 있는 프로퍼티

protected string $currentVersion
리턴 string