Exponential 5.x Kernel 7.5.40 Exponential New Stack (Symfony-based) Kernel — PHP Class Reference

Public Member Functions | List of all members
eZ\Publish\Core\FieldType\Author\AuthorCollection Class Reference

Author collection. More...

Inheritance diagram for eZ\Publish\Core\FieldType\Author\AuthorCollection:

## Public Member Functions
| __construct (array $elements=[])
| offsetSet ($offset, $value)
| Adds a new author to the collection. More...
| removeAuthorsById (array $authorIds)
| Removes authors from current collection with a list of Ids. More...

## Detailed Description

Author collection.

This collection can only hold \eZ\Publish\Core\FieldType\Author\Author objects.

Definition at line 16 of file AuthorCollection.php.

## Constructor & Destructor Documentation

## ◆ __construct()

eZ\Publish\Core\FieldType\Author\AuthorCollection::__construct | ( | array | $elements = `[]` | ) |

Parameters

  \eZ\Publish\Core\FieldType\Author\Author[] | $elements |

Definition at line 21 of file AuthorCollection.php.

References eZ\Publish\Core\FieldType\Author\AuthorCollection\offsetSet().

## Member Function Documentation

## ◆ offsetSet()

eZ\Publish\Core\FieldType\Author\AuthorCollection::offsetSet | ( |  | $offset,
|  |  | $value
| ) |  |

Adds a new author to the collection.

Exceptions

  InvalidArgumentType | When $value is not of type Author

Parameters

  int | $offset |
  \eZ\Publish\Core\FieldType\Author\Author | $value |

Definition at line 39 of file AuthorCollection.php.

Referenced by eZ\Publish\Core\FieldType\Author\AuthorCollection\__construct().

## ◆ removeAuthorsById()

eZ\Publish\Core\FieldType\Author\AuthorCollection::removeAuthorsById | ( | array | $authorIds | ) |

Removes authors from current collection with a list of Ids.

Parameters

  array | $authorIds | Author's Ids to remove from current collection

Definition at line 65 of file AuthorCollection.php.

The documentation for this class was generated from the following file:

- AuthorCollection.php

Copyright © 1998 – 2026 7x. All rights reserved. Licensed under the GNU GPLv2+.