Repository navigation
Internals Runtime RuntimeFlagHandler
Framework Internals · Subsystem overview · Developer guide
Source: awt_src/classes/runtime/RuntimeFlagHandler.php · Snapshot 8411f4287706.
Runtime state, package API classes, loader, executor and orchestrator have separate responsibilities. Dependency validation precedes package code and nested execution restores context.
use runtime\enums\ERuntimeFlags;
use runtime\interface\IRuntimeFlagHandler;final class RuntimeFlagHandler implements IRuntimeFlagHandlerNo own constants, enum cases, traits or property declarations. Inherited members are documented on the parent reference page.
| Method | Signature |
|---|---|
| normalize | public function normalize(array $flags): array |
public function normalize(array $flags): array| Parameter | Type, modifiers and default | Purpose |
|---|---|---|
$flags |
array $flags |
List of runtime flag cases; invalid non-enum entries fail normalization. |
Validate and deduplicate native runtime flags.
Return expressions (including local callbacks): array_values($normalized).
Explicit exceptions: \InvalidArgumentException. The guards in the implementation below show when each is raised; exceptions from collaborators also propagate unless caught.
Implementation, validation guards and interaction order
/** Validate and deduplicate native runtime flags. */
public function normalize(array $flags): array
{
$normalized = [];
foreach ($flags as $flag) {
if (!$flag instanceof ERuntimeFlags) {
throw new \InvalidArgumentException('Runtime flags must be ERuntimeFlags cases.');
}
$normalized[$flag->name] = $flag;
}
return array_values($normalized);
}AWT Framework Wiki · Home · Installation Guide · Developer Guide · Framework Internals
Philosophy · Architecture · Known discrepancies · Verification
Installation Guide
Developer Guide
- Learning sequence
- First package
- Package structure
- Lifecycle
- Runtimes
- Events and objects
- Routing and controllers
- Views and resources
- Database and models
- Storage and caching
- Configuration and CLI
- Responses and errors
- Extension points
Framework Internals
- Architecture
- Bootstrap
- Packages
- Runtime
- Events and context
- Objects
- HTTP routing and controllers
- Rendering
- Blade integration
- Database
- Models
- Storage and caching
- Settings
- CLI
- Identity and sessions
- Responses
- Errors
- Complete source inventory
Documentation notes