PHP 클래스 Airship\Engine\Continuum\Channel

Abstracts a lot of the Channel features away from other code
파일 보기 프로젝트 열기: paragonie/airship

보호된 프로퍼티들

프로퍼티 타입 설명
$ext string
$name string
$parent Continuum | Keyggdrasil
$peers Peer[]
$publicKey ParagonIE\Halite\Asymmetric\SignaturePublicKey
$urls string[]

공개 메소드들

메소드 설명
__construct ( object $parent, string $name, array $config = [] ) Channel constructor.
createSupplier ( array $data ) : Supplier Create a new supplier.
getAllSuppliers ( ) : array Get all suppliers for a particular channel
getAllURLs ( boolean $doNotShuffle = false ) : array Get all URLs
getAppropriatePeerSize ( integer $sizeOfList ) : integer The natural log of the size of the peer list, rounded up.
getName ( ) : string
getPeerList ( boolean $forceFlush = false ) : array Get a list of peers for a given channel
getPublicKey ( ) : SignaturePublicKey
getSupplier ( string $name, boolean $flush = false ) : Supplier Get a supplier
getURL ( ) : string Get a random URL

메소드 상세

__construct() 공개 메소드

Channel constructor.
public __construct ( object $parent, string $name, array $config = [] )
$parent object (Continuum or Keyggdrasil)
$name string
$config array

createSupplier() 공개 메소드

Create a new supplier.
public createSupplier ( array $data ) : Supplier
$data array
리턴 Supplier

getAllSuppliers() 공개 메소드

Get all suppliers for a particular channel
public getAllSuppliers ( ) : array
리턴 array

getAllURLs() 공개 메소드

By default, this shuffles them randomly. If you're in tor-only mode, it prioritizes .onion domains first.
public getAllURLs ( boolean $doNotShuffle = false ) : array
$doNotShuffle boolean
리턴 array

getAppropriatePeerSize() 공개 메소드

The natural log of the size of the peer list, rounded up.
public getAppropriatePeerSize ( integer $sizeOfList ) : integer
$sizeOfList integer
리턴 integer

getName() 공개 메소드

public getName ( ) : string
리턴 string

getPeerList() 공개 메소드

Get a list of peers for a given channel
public getPeerList ( boolean $forceFlush = false ) : array
$forceFlush boolean
리턴 array

getPublicKey() 공개 메소드

public getPublicKey ( ) : SignaturePublicKey
리턴 ParagonIE\Halite\Asymmetric\SignaturePublicKey

getSupplier() 공개 메소드

Get a supplier
public getSupplier ( string $name, boolean $flush = false ) : Supplier
$name string
$flush boolean
리턴 Supplier

getURL() 공개 메소드

Get a random URL
public getURL ( ) : string
리턴 string

프로퍼티 상세

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

protected string $ext
리턴 string

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

protected string $name
리턴 string

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

protected Continuum|Keyggdrasil $parent
리턴 Continuum | Keyggdrasil

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

protected Peer[] $peers
리턴 Peer[]

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

protected SignaturePublicKey,ParagonIE\Halite\Asymmetric $publicKey
리턴 ParagonIE\Halite\Asymmetric\SignaturePublicKey

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

protected string[] $urls
리턴 string[]