Validators
extends IteratorIterator
in package
Collection of Validator objects from the stellar.toml file.
Provides an iterable collection for managing multiple validator entries from the [[VALIDATORS]] section of the stellar.toml file.
Table of Contents
Methods
- __construct() : mixed
- add() : void
- Adds a Validator to the collection.
- count() : int
- Returns the number of validators in the collection.
- current() : Validator
- Returns the current Validator in the iteration.
- toArray() : array<string|int, Validator>
Methods
__construct()
public
__construct(Validator ...$validators) : mixed
Parameters
- $validators : Validator
add()
Adds a Validator to the collection.
public
add(Validator $validator) : void
Parameters
- $validator : Validator
-
The validator to add
count()
Returns the number of validators in the collection.
public
count() : int
Return values
int —The count of validators
current()
Returns the current Validator in the iteration.
public
current() : Validator
Return values
Validator —The current validator object
toArray()
public
toArray() : array<string|int, Validator>