EventSubscription
in package
implements
CreateableInterface
Uses
Creator, Deletor
An event name to class binding that represents that class listening for that event.
Tags
Interfaces, Classes and Traits
- CreateableInterface
- Interface for createable models.
Table of Contents
- $class : mixed
- $fillable : array<string|int, mixed>
- $library : mixed
- $pattern : mixed
- create() : CreateableInterface
- Creates and returns an entity instance and fills values.
- delete() : mixed
- Deletes the entity.
- getClass() : string
- Returns the class name subscribed to this event.
- getLibrary() : string
- Returns the library that this subscription is part of, in vendor/module format.
- getPattern() : string
- Returns the pattern used to match against event names for this subscription.
- setClass() : mixed
- Sets the class name subscribed to this event.
- setLibrary() : mixed
- Sets the library that this subscription is part of, in vendor/module format.
- setPattern() : mixed
- Set the pattern used to match against event names.
Properties
$class
private
mixed
$class
Tags
$fillable
private
static array<string|int, mixed>
$fillable
= ["pattern", "class", "library"]
$library
private
mixed
$library
Tags
$pattern
private
mixed
$pattern
Tags
Methods
create()
Creates and returns an entity instance and fills values.
public
static create(array<string|int, mixed> $arguments) : CreateableInterface
Parameters
- $arguments : array<string|int, mixed>
-
The values the instance should get
Tags
Return values
CreateableInterface —The created Entity
delete()
Deletes the entity.
public
delete(EntityManagerInterface $em) : mixed
Parameters
- $em : EntityManagerInterface
Return values
mixed —getClass()
Returns the class name subscribed to this event.
public
getClass() : string
Return values
string —getLibrary()
Returns the library that this subscription is part of, in vendor/module format.
public
getLibrary() : string
Return values
string —getPattern()
Returns the pattern used to match against event names for this subscription.
public
getPattern() : string
Format is PHP regular expressions.
Return values
string —setClass()
Sets the class name subscribed to this event.
public
setClass(string $class) : mixed
Parameters
- $class : string
Return values
mixed —setLibrary()
Sets the library that this subscription is part of, in vendor/module format.
public
setLibrary(string $library) : mixed
Parameters
- $library : string
Return values
mixed —setPattern()
Set the pattern used to match against event names.
public
setPattern(string $pattern) : mixed
Format is PHP regular expressions.
Parameters
- $pattern : string