EmailCollection

Extends \AbstractCollection Implements \EmailCollectionInterface

Class EmailCollection

Used by operations that consider multiple email objects.

category

System

package

Email

subpackage

Collections

Methods

Initialize the collection instance.

__construct(array|mixed|null $argumentsArray = null) 
inherited
Throws
\InvalidArgumentException

Arguments

$argumentsArray

array|mixed|null

Adds a new email to the collection.

add(\EmailInterface $email) 

Arguments

$email

\EmailInterface

E-Mail.

Removes all emails of collection.

clear() 

Get collection item count.

count() : integer
inherited

Response

integer

Get the collection as an array.

getArray() : array
inherited

Response

array

Get specific collection item by index.

getItem( $p_index) : mixed
inherited
Throws
\InvalidArgumentException

if index is not numeric | OutOfBoundsException if index is out of bounds

Arguments

$p_index

Response

mixed

getIterator

getIterator() 
inherited

Determine whether the collection is empty or not.

isEmpty() : boolean
inherited

Response

boolean

Removes an email from collection.

remove(\EmailInterface $email) 
Throws
\Exception

If email cannot be found.

Arguments

$email

\EmailInterface

E-Mail.

Properties