Neuron-PHP

WidgetRegistry
in package

Registry for managing widgets.

Allows registration of custom widgets and automatic integration with the shortcode parser.

Table of Contents

Properties

$_parser  : ShortcodeParser
$_widgets  : array<string, IWidget>

Methods

__construct()  : mixed
get()  : IWidget|null
Get widget by name
getAll()  : array<string, IWidget>
Get all registered widgets (for documentation)
has()  : bool
Check if widget exists
register()  : void
Register a widget
unregister()  : void
Unregister a widget

Properties

Methods

getAll()

Get all registered widgets (for documentation)

public getAll() : array<string, IWidget>
Return values
array<string, IWidget>

Array of widgets

has()

Check if widget exists

public has(string $name) : bool
Parameters
$name : string

Widget name

Return values
bool

unregister()

Unregister a widget

public unregister(string $name) : void
Parameters
$name : string

Widget name


        
On this page

Search results