Nextcloud PHP API (stable19)

SystemTagsEntityEvent extends Event

Class SystemTagsEntityEvent

Typically this class isn't instantiated directly but sub classed for specific event types

Tags
since
9.1.0

Table of Contents

EVENT_ENTITY  = 'OCP\SystemTag\ISystemTagManager::registerEntity'
$collections  : \Closure[]
$event  : string
__construct()  : mixed
SystemTagsEntityEvent constructor.
addEntityCollection()  : mixed
getEntityCollections()  : \Closure[]

Constants

Properties

Methods

__construct()

SystemTagsEntityEvent constructor.

public __construct(string $event) : mixed

In Nextcloud 17.0.0 this event class used a now deprecated/removed Symfony base class that had a constructor (with default arguments). To lower the risk of a breaking change (PHP won't allow parent constructor calls if there is none), this empty constructor's only purpose is to hopefully not break existing sub- classes of this class.

Parameters
$event : string
Tags
since
9.1.0
Return values
mixed

addEntityCollection()

public addEntityCollection(string $name, Closure $entityExistsFunction) : mixed
Parameters
$name : string
$entityExistsFunction : Closure

The closure should take one argument, which is the id of the entity, that tags should be handled for. The return should then be bool, depending on whether tags are allowed (true) or not.

Tags
throws
OutOfBoundsException

when the entity name is already taken

since
9.1.0
Return values
mixed

getEntityCollections()

public getEntityCollections() : \Closure[]
Tags
since
9.1.0
Return values
\Closure[]

Search results