PHP Класс Airship\Engine\Continuum\Channel

Abstracts a lot of the Channel features away from other code
Показать файл Открыть проект

Защищенные свойства (Protected)

Свойство Тип Описание
$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[]