ModeRegistry implements SingletonInterface
Registers and holds t3editor modes
Table of Contents
Interfaces
- SingletonInterface
- "empty" interface for singletons (marker interface pattern)
Properties
- $defaultMode : Mode
- $registeredModes : array<string|int, Mode>
Methods
- getByFileExtension() : Mode
- getByFormatCode() : Mode
- getDefaultMode() : Mode
- isRegistered() : bool
- register() : ModeRegistry
- Registers modes for t3editor
- unregister() : ModeRegistry
- Removes registered modes
Properties
$defaultMode
protected
Mode
$defaultMode
$registeredModes
protected
array<string|int, Mode>
$registeredModes
= []
Methods
getByFileExtension()
public
getByFileExtension(string $fileExtension) : Mode
Parameters
- $fileExtension : string
Tags
Return values
ModegetByFormatCode()
public
getByFormatCode(string $formatCode) : Mode
Parameters
- $formatCode : string
Tags
Return values
ModegetDefaultMode()
public
getDefaultMode() : Mode
Return values
ModeisRegistered()
public
isRegistered(string $formatCode) : bool
Parameters
- $formatCode : string
Return values
boolregister()
Registers modes for t3editor
public
register(Mode $mode) : ModeRegistry
Parameters
- $mode : Mode
Return values
ModeRegistryunregister()
Removes registered modes
public
unregister(string $formatCode) : ModeRegistry
Parameters
- $formatCode : string