Manager
in package
implements
ArrayAccess, Countable, IteratorAggregate
Module manager class
Tags
Table of Contents
Interfaces
- ArrayAccess
- Countable
- IteratorAggregate
Properties
- $modules : array<string|int, mixed>
- Modules
Methods
- __construct() : mixed
- Constructor
- __get() : mixed
- Get a registered module
- __isset() : bool
- Determine if a module is registered with the manager object
- __set() : void
- Register a module with the manager
- __unset() : void
- Unregister a module with the manager
- count() : int
- Return count
- get() : mixed
- Get a module
- getIterator() : ArrayIterator
- Get iterator
- getModuleName() : string
- Get a module object's registered name
- hasModule() : bool
- Determine if a module object is registered with the manager by $module object comparison
- isRegistered() : bool
- Determine if a module object is registered with the manager by $name
- offsetExists() : bool
- Determine if a module is registered with the manager object
- offsetGet() : mixed
- Get a registered module
- offsetSet() : void
- Register a module with the manager
- offsetUnset() : void
- Unregister a module with the manager
- register() : static
- Register a module object
- registerModules() : static
- Register module objects
- unregister() : static
- Unregister a module
Properties
$modules
Modules
protected
array<string|int, mixed>
$modules
= []
Methods
__construct()
Constructor
public
__construct([array<string|int, mixed>|null $modules = null ]) : mixed
Instantiate the module manager object.
Parameters
- $modules : array<string|int, mixed>|null = null
Tags
__get()
Get a registered module
public
__get(string $name) : mixed
Parameters
- $name : string
__isset()
Determine if a module is registered with the manager object
public
__isset(string $name) : bool
Parameters
- $name : string
Return values
bool__set()
Register a module with the manager
public
__set(string $name, mixed $value) : void
Parameters
- $name : string
- $value : mixed
Tags
__unset()
Unregister a module with the manager
public
__unset(string $name) : void
Parameters
- $name : string
count()
Return count
public
count() : int
Return values
intget()
Get a module
public
get(string $name) : mixed
Parameters
- $name : string
getIterator()
Get iterator
public
getIterator() : ArrayIterator
Return values
ArrayIteratorgetModuleName()
Get a module object's registered name
public
getModuleName(ModuleInterface $module) : string
Parameters
- $module : ModuleInterface
Return values
stringhasModule()
Determine if a module object is registered with the manager by $module object comparison
public
hasModule(ModuleInterface $module) : bool
Parameters
- $module : ModuleInterface
Return values
boolisRegistered()
Determine if a module object is registered with the manager by $name
public
isRegistered(string $name) : bool
Parameters
- $name : string
Return values
booloffsetExists()
Determine if a module is registered with the manager object
public
offsetExists(mixed $offset) : bool
Parameters
- $offset : mixed
Return values
booloffsetGet()
Get a registered module
public
offsetGet(mixed $offset) : mixed
Parameters
- $offset : mixed
offsetSet()
Register a module with the manager
public
offsetSet(mixed $offset, mixed $value) : void
Parameters
- $offset : mixed
- $value : mixed
Tags
offsetUnset()
Unregister a module with the manager
public
offsetUnset(mixed $offset) : void
Parameters
- $offset : mixed
register()
Register a module object
public
register(ModuleInterface $module) : static
Parameters
- $module : ModuleInterface
Return values
staticregisterModules()
Register module objects
public
registerModules(array<string|int, mixed> $modules) : static
Parameters
- $modules : array<string|int, mixed>
Tags
Return values
staticunregister()
Unregister a module
public
unregister(string $name) : static
Parameters
- $name : string