PHP 클래스 Airship\Engine\Continuum\Installer

This facilitates the installation process of a new Cabin, Gadget, or Motif.
상속: use trait SupplierBolt, use trait LogBolt
파일 보기 프로젝트 열기: paragonie/airship 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$bypassSecurityAndJustInstall boolean
$continuumLogger Log
$ext
$hail Hail
$localInstallFile InstallFile
$package string
$supplier Supplier
$type string

공개 메소드들

메소드 설명
__construct ( Hail $hail = null, string $supplier = '', string $package = '' ) Installer constructor.
bypassSecurityAndJustInstall ( boolean $set = false ) : self This is for manual installations and update scripts. It should never be invoked automatically.
clearCache ( ) : boolean We just need to clear the template caches and the cabin data.
download ( array $update = [] ) : InstallFile Download the file from the update server.
easyInstall ( ) : boolean Attempts to download and install in one go.
expandCabinName ( string $cabinName ) : string Is this a special Airship cabin? Return just the name.
getLogContext ( InstallFile $installFile ) : array Get information for logging purposes
getPackageData ( string $minVersion = '' ) : array Get metadata about the package we're installing.
install ( InstallFile $fileInfo ) : boolean Install the file. This is type-specific, so we leave it abstract here.
markPackageInstalled ( InstallFile $install ) : boolean Somewhat self-explanatory. This just sets the 'installed' column in the database to 'TRUE' so our web UI knows that it's installed.
useLocalInstallFile ( string $path, string $version = '' ) : self For CLI usage: Bypass the download process, use a local file instead.
verifyChecksum ( InstallFile $file ) : boolean Verify that the file has not modified since it was stored
verifyMerkleRoot ( InstallFile $file ) : boolean Verifies that the Merkle root exists, matches this package and version, and has the same checksum as the one we calculated.
verifySignature ( InstallFile $file ) : boolean Verify that the signature matches

보호된 메소드들

메소드 설명
getChannel ( string $name ) : Channel Get the channels (cache across all instances of Installer)

메소드 상세

__construct() 공개 메소드

Installer constructor.
public __construct ( Hail $hail = null, string $supplier = '', string $package = '' )
$hail Hail
$supplier string
$package string

bypassSecurityAndJustInstall() 공개 메소드

This is for manual installations and update scripts. It should never be invoked automatically.
public bypassSecurityAndJustInstall ( boolean $set = false ) : self
$set boolean
리턴 self

clearCache() 공개 메소드

We just need to clear the template caches and the cabin data.
public clearCache ( ) : boolean
리턴 boolean

download() 공개 메소드

Download the file from the update server.
public download ( array $update = [] ) : InstallFile
$update array
리턴 InstallFile

easyInstall() 공개 메소드

Attempts to download and install in one go.
public easyInstall ( ) : boolean
리턴 boolean Was it successful?

expandCabinName() 공개 메소드

Otherwise, return the namespace.
public expandCabinName ( string $cabinName ) : string
$cabinName string
리턴 string

getChannel() 보호된 메소드

Get the channels (cache across all instances of Installer)
protected getChannel ( string $name ) : Channel
$name string
리턴 Channel

getLogContext() 공개 메소드

Get information for logging purposes
public getLogContext ( InstallFile $installFile ) : array
$installFile InstallFile
리턴 array

getPackageData() 공개 메소드

Get metadata about the package we're installing.
public getPackageData ( string $minVersion = '' ) : array
$minVersion string
리턴 array

install() 추상적인 공개 메소드

Install the file. This is type-specific, so we leave it abstract here.
abstract public install ( InstallFile $fileInfo ) : boolean
$fileInfo InstallFile
리턴 boolean

markPackageInstalled() 공개 메소드

Somewhat self-explanatory. This just sets the 'installed' column in the database to 'TRUE' so our web UI knows that it's installed.
public markPackageInstalled ( InstallFile $install ) : boolean
$install InstallFile
리턴 boolean

useLocalInstallFile() 공개 메소드

For CLI usage: Bypass the download process, use a local file instead.
public useLocalInstallFile ( string $path, string $version = '' ) : self
$path string
$version string
리턴 self

verifyChecksum() 공개 정적인 메소드

Verify that the file has not modified since it was stored
public static verifyChecksum ( InstallFile $file ) : boolean
$file InstallFile
리턴 boolean

verifyMerkleRoot() 공개 메소드

Verifies that the Merkle root exists, matches this package and version, and has the same checksum as the one we calculated.
public verifyMerkleRoot ( InstallFile $file ) : boolean
$file InstallFile
리턴 boolean

verifySignature() 공개 정적인 메소드

Verify that the signature matches
public static verifySignature ( InstallFile $file ) : boolean
$file InstallFile
리턴 boolean

프로퍼티 상세

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

protected bool $bypassSecurityAndJustInstall
리턴 boolean

$continuumLogger 보호되어 있는 정적으로 프로퍼티

protected static Log,Airship\Engine\Continuum $continuumLogger
리턴 Log

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

protected $ext

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

protected Hail $hail
리턴 Hail

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

protected InstallFile $localInstallFile
리턴 InstallFile

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

protected string $package
리턴 string

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

protected Supplier,Airship\Engine\Continuum $supplier
리턴 Supplier

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

protected string $type
리턴 string