Abstract base class for a UI5 module definition.
A module represents a self-contained unit of business logic and artifacts,
and is registered via config/ui5.php under the 'modules' key.
Each module is assigned a unique route-level slug used in all URL constructions.
It may provide one App or one Library (not both), and related sub-artifacts
such as Cards, Reports, Tiles, and Actions. All artifact instances are expected
to be fully constructed and ready to register at boot time.
| Methods |
public
|
__construct(Ui5SourceStrategyInterface $strategy)
Create a new UI5 module instance.
Create a new UI5 module instance.
Parameters
| $strategy |
Physical path where this module resides in
|
|
#
|
public
|
getApp(): ?Ui5AppInterface
Returns the application artifact, if present.
Returns the application artifact, if present.
Implements
|
#
|
public
|
hasApp(): bool
Returns true if this module provides a UI5 application.
Returns true if this module provides a UI5 application.
Implements
|
#
|
public
|
getLibrary(): ?Ui5LibraryInterface
Returns the library artifact, if present.
Returns the library artifact, if present.
Implements
|
#
|
public
|
hasLibrary(): bool
Returns true if this module provides a UI5 library.
Returns true if this module provides a UI5 library.
Implements
|
#
|
public
|
getArtifactRoot(): Ui5AppInterface|Ui5LibraryInterface
Returns the root artifact of the module — either the application or the library,
depending on the module type.
Returns the root artifact of the module — either the application or the library,
depending on the module type.
This method allows consumers to access the primary artifact in a generic way,
without checking whether the module is app- or library-based.
Returns
The root artifact (App or Library)
Implements
|
#
|
public
|
getNamespace(): string
A module reflects its root artifact's namespace (single source of truth);
it does not declare one of its own. Rootless…
A module reflects its root artifact's namespace (single source of truth);
it does not declare one of its own. Rootless modules (test doubles) may
override with a literal.
Returns
Implements
|
#
|
public
|
requiresAuth(): bool
Indicates whether this module requires an authenticated user
in order to be served.
Indicates whether this module requires an authenticated user
in order to be served.
Returning true means the module is only accessible to
authenticated users. Public modules should return false.
Implements
|
#
|
public
|
getSourceStrategy(): Ui5SourceStrategyInterface
Returns the Ui5SourceStrategy used to resolve UI5 source artifacts
for this module.
Returns the Ui5SourceStrategy used to resolve UI5 source artifacts
for this module.
The source strategy defines how and from where UI5 resources
(manifest, preload bundles, i18n files, descriptors) are accessed,
depending on the module's origin (e.g. workspace-based or packaged).
The returned value is resolved by the Ui5Registry.
The strategy itself is responsible for:
- determining the runtime UI5 resource path,
- and optionally providing introspection capabilities.
Important:
- This method does NOT perform any filesystem access.
- It only declares which strategy applies to this module.
Returns
Strategy for resolving Ui5Source artifacts.
Implements
|
#
|
public
|
getCharts(): array
Returns an array of all charts provided by this module.
Returns an array of all charts provided by this module.
Charts are embedded primitives like tiles — listed alongside tiles
and cards in a Dashboard Group's getChildNamespaces(). The
default {@see \LaravelUi5\Core\Ui5\AbstractUi5Module} implementation
returns [] so existing modules that predate the Chart artifact
type continue to satisfy the contract without modification.
Implements
|
#
|
public
|
getValueHelps(): array
Default so modules that predate the ValueHelp artifact type (LUX Weave
Facet D) satisfy the contract without…
Default so modules that predate the ValueHelp artifact type (LUX Weave
Facet D) satisfy the contract without modification — mirrors getCharts().
Implements
|
#
|
public
|
getAllArtifacts(): array
Returns all artifacts belonging to this module (app, library, tiles, cards,
kpis, actions, resources, dashboards,…
Returns all artifacts belonging to this module (app, library, tiles, cards,
kpis, actions, resources, dashboards, reports, dialogs, etc.)
Implements
|
#
|