ProtocolRegistry
in package
implements
ProtocolRegistryInterface
FinalYes
Реестр протоколов на основе каталога OSI + пользовательские регистрации.
Tags
Table of Contents
Interfaces
- ProtocolRegistryInterface
- Реестр протоколов (OSI + socket и пр.).
Methods
- __construct() : mixed
- Создаёт реестр и загружает встроенный каталог.
- all() : Generator<string, ProtocolDefinitionInterface>
- Перечисляет все протоколы (генератор).
- count() : int
- Возвращает число зарегистрированных протоколов.
- get() : ProtocolDefinitionInterface
- Возвращает определение протокола по идентификатору.
- has() : bool
- Проверяет наличие протокола в реестре.
- register() : void
- Регистрирует или переопределяет протокол.
Methods
__construct()
Создаёт реестр и загружает встроенный каталог.
public
__construct() : mixed
all()
Перечисляет все протоколы (генератор).
public
all() : Generator<string, ProtocolDefinitionInterface>
Attributes
- #[Override]
Return values
Generator<string, ProtocolDefinitionInterface>count()
Возвращает число зарегистрированных протоколов.
public
count() : int
Attributes
- #[Override]
Return values
intget()
Возвращает определение протокола по идентификатору.
public
get(string $protocolId) : ProtocolDefinitionInterface
Parameters
- $protocolId : string
Attributes
- #[Override]
Return values
ProtocolDefinitionInterfacehas()
Проверяет наличие протокола в реестре.
public
has(string $protocolId) : bool
Parameters
- $protocolId : string
Attributes
- #[Override]
Return values
boolregister()
Регистрирует или переопределяет протокол.
public
register(ProtocolDefinitionInterface $definition) : void
Parameters
- $definition : ProtocolDefinitionInterface
Attributes
- #[Override]