Framework collects your site information based on XML files content into Application objects: Lucinda\STDOUT\Application (encapsulating data in stdout.xml) and Lucinda\STDERR\Application (encapsulating data in stderr.xml).
Both classes were done with symmetry in mind (for shared logic, methods have same signature) and available for querying in STDOUT/STDERR controllers and event listeners. Following shared methods are most useful to developers:
getVersion(): gets application version (value of version attribute of <application> tag @ stdout.xml or <application> tag @ stderr.xml), whose value should be sent to views:
$this->response->view()["version"] = $this->application->getVersion();
in order to force cache refresh for static resources, like in below example:
<link rel="stylesheet" href="public/default.css?version=${data.version}"/>
getTag(NAME): gets a SimpleXMLElement pointer to a custom tag found in respective XML (stdout.xml/stderr.xml) root. When, for example, a event listener has this statement:
$xml = $this->application->getTag("hello_world");
$xml will point to <hello_world> tag in stdout.xml root. If, however, tags point to other XML files via ref attribute:
<hello_world ref="custom">
Then $xml will point to <hello_world> tag in custom.xml root. This measure can be applied to any other tag, so XML stays uncluttered!