Helpers are procedural functions using global namespace, located in helpers folder, loaded manually by event listeners or view resolvers. Some are useful for subsequent models while others are useful for views, their entire purpose being to simplify calls and hide complexity underneath.
A side-effect of event listeners is their ability to require functions that may become helpful in other models. Framework Skeleton API bundles following:
Function | Arguments | Returns | Description | Loader |
SQL | string $query, array $parameters=[], string $serverName="" |
Lucinda\SQL\StatementResults | Executes SQL prepared statement execution and returns results (see: Tutorials) | Lucinda\Project\EventListeners\SQLDataSource |
NoSQL | string $serverName="" | Lucinda\NoSQL\Driver | Gets NoSQL driver to perform key-value store operations on (see: Tutorials) | Lucinda\Project\EventListeners\NoSQLDataSource |
A side-effect of both event listeners and view resolvers is their ability to require functions that may become helpful in views. Framework Skeleton API bundles following:
Function | Arguments | Returns | Description | Loader |
translate | string $key, string $domain="", ...$parameters |
string | Translates text into preferred or default locale (Tutorials) | Lucinda\Project\EventListeners\Localization |