Contents

Editor\Classes\ExtensionManager

Overview

Manages Editor extensions.


Protected Properties

protected array $extensionClassNames

extensionClassNames is a collection of registered extensions

protected array $extensions

extensions registered by this class

protected string $context

context is the editor context extensions are listed for


Public Methods

public __construct()

public __construct(): void

__construct this class

public getContext()

public getContext(): string 

getContext returns the current editor context.

public getExtensionByNamespace()

public getExtensionByNamespace($namespace): void

getExtensionByNamespace looks up an extension by namespace across ALL registered extensions, regardless of the current context

public static instance()

public static instance(): static 

instance creates a new instance of this singleton

public listExtensions()

public listExtensions(): void

listExtensions returns the registered extensions belonging to the current context

public listJsFiles()

public listJsFiles(): void

listJsFiles returns the JS files for extensions in the current context.

public listVueComponents()

public listVueComponents(): void

listVueComponents returns the Vue components for extensions in the current context.

public runCommand()

public runCommand($namespace, $command, $controller): void

public setContext()

public setContext($context): void

setContext scopes subsequent list calls to a single editor context, so a host page shows only the extensions registered in it

Protected Methods

protected getExtension()

protected getExtension($className): void

getExtension will create and validate an extension object

protected makeExtension()

protected makeExtension($className): void

makeExtension will create an extension object from a class name

protected registerExtensions()

protected registerExtensions(): void

registerExtensions will build a collection of registered extensions