RelaySet
in package
implements
RelaySetInterface
Table of Contents
Interfaces
Properties
- $isConnected : bool
- Are all relays connected in this relay set?
- $relays : array<string|int, mixed>
- Array with Relay objects.
- $message : MessageInterface
- The message to be sent to all relays.
Methods
- addRelay() : void
- Add relay to this set.
- connect() : bool
- Connect to all relays in this set.
- createFromUrls() : void
- Create a relay set from a list of relay URLs.
- disconnect() : bool
- Disconnect all relays in this set.
- getRelays() : array<string|int, mixed>
- Get all relays.
- isConnected() : bool
- All are relays connected?
- removeRelay() : void
- Remove relay from this set.
- send() : CommandResultInterface
- Sends the message to all the relays in this set.
- setMessage() : void
- The message to be sent to the relays.
- setRelays() : void
- Set relays in this set.
Properties
$isConnected
Are all relays connected in this relay set?
public
bool
$isConnected
$relays
Array with Relay objects.
protected
array<string|int, mixed>
$relays
$message
The message to be sent to all relays.
private
MessageInterface
$message
Methods
addRelay()
Add relay to this set.
public
addRelay(Relay $relay) : void
Parameters
- $relay : Relay
Tags
connect()
Connect to all relays in this set.
public
connect() : bool
Tags
Return values
boolcreateFromUrls()
Create a relay set from a list of relay URLs.
public
createFromUrls(array<string|int, mixed>|string $urls) : void
Parameters
- $urls : array<string|int, mixed>|string
Tags
disconnect()
Disconnect all relays in this set.
public
disconnect() : bool
Tags
Return values
boolgetRelays()
Get all relays.
public
getRelays() : array<string|int, mixed>
Tags
Return values
array<string|int, mixed>isConnected()
All are relays connected?
public
isConnected() : bool
Tags
Return values
boolremoveRelay()
Remove relay from this set.
public
removeRelay(Relay $relay) : void
Parameters
- $relay : Relay
Tags
send()
Sends the message to all the relays in this set.
public
send() : CommandResultInterface
Tags
Return values
CommandResultInterfacesetMessage()
The message to be sent to the relays.
public
setMessage(MessageInterface $message) : void
Parameters
- $message : MessageInterface
Tags
setRelays()
Set relays in this set.
public
setRelays(array<string|int, mixed> $relays) : void
Parameters
- $relays : array<string|int, mixed>