Menu

## ModelExtender
in package

ModelExtender.php : 15

Contains method to help the extension of a model.

### Table of Contents

$classes : array<string|int, mixed>
$reader : AnnotationReader
__construct() : mixed
  ModelExtender constructor.
add() : void
addMore() : void
get() : callable|null
  Returns a callback registered in the model extender globally.

### Properties

#### $classes

ModelExtender.php : 20
`private static array<string|int, mixed> $classes = []`

#### $reader

ModelExtender.php : 18
`private AnnotationReader $reader`

### Methods

#### __construct()

ModelExtender.php : 25

ModelExtender constructor.

`public __construct() : mixed`

##### Return values

mixed —

#### add()

ModelExtender.php : 44
`public add(string $class) : void`

##### Parameters

$class : string

##### Tags

throws
  ArgumentException

  if the given class is not properly annotated.

##### Return values

void —

#### addMore()

ModelExtender.php : 33
`public addMore(array<string|int, string> $classes) : void`

##### Parameters

$classes : array<string|int, string>

##### Return values

void —

#### get()

ModelExtender.php : 82

Returns a callback registered in the model extender globally.

`public static get(string $modelClassName, string $methodName) : callable|null`

##### Parameters

$modelClassName : string
$methodName : string

##### Return values

callable|null —

## Search results