libSmalldb
v2.0.2
|
Public Member Functions | |
__construct (array $extensions) | |
ExtensibleDefinition constructor. More... | |
hasExtension (string $extensionClassName) | |
Return true if an extension of given type is defined for this element. More... | |
getExtension (string $extensionClassName) | |
Get an extension of given type. More... | |
findExtension (string $extensionClassName) | |
Get an extension of given type. More... | |
getExtensionClassNames () | |
Get a list of existing extensions. More... | |
jsonSerialize () | |
__construct | ( | array | $extensions | ) |
ExtensibleDefinition constructor.
Note: $extensions is an array of objects indexed by their respective class names.
ExtensionInterface[] | $extensions |
hasExtension | ( | string | $extensionClassName | ) |
Return true if an extension of given type is defined for this element.
getExtension | ( | string | $extensionClassName | ) |
Get an extension of given type.
Throws UndefinedExtensionException if the extension is not found.
It would be nice to write getExtension<T>(): T ...
class-string<ExtensionInterface> | $extensionClassName |
findExtension | ( | string | $extensionClassName | ) |
Get an extension of given type.
Just like getExtension(), but returns null if the extension is not found.
It would be nice to write getExtension<T>(): T ...
class-string<ExtensionInterface> | $extensionClassName |
getExtensionClassNames | ( | ) |
Get a list of existing extensions.
jsonSerialize | ( | ) |