trait Armada

Methods

HTTP
httpResponse($code = '200')

Wrap the Jaxon response into an HTTP response and send it back to the browser.

Response
ajaxResponse()

Get the Jaxon response.

void
addViewRenderer(string $sId, Closure $xClosure)

Add a view renderer with an id

Facade
view()

Get the view renderer

Session
session()

Get the session manager

void
register(array $aOptions = array())

Register the Jaxon classes.

object
request(string $classname)

Get a Jaxon request to a given class.

object
plugin(string $name)

Get a plugin instance.

void
registerClass(string $sClassName, array $aOptions = array())

Register a specified Jaxon class.

string
script($bIncludeJs = false, $bIncludeCss = false)

Get the javascript code to be sent to the browser.

string
js()

Get the HTML tags to include Jaxon javascript files into the page.

string
css()

Get the HTML tags to include Jaxon CSS code and files into the page.

void
onInit(callable $callable)

Set the init callback, used to initialise controllers.

void
onBefore(callable $callable)

Set the pre-request processing callback.

void
onAfter(callable $callable)

Set the post-request processing callback.

void
onInvalid(callable $callable)

Set the processing error callback.

void
onError(callable $callable)

Set the processing exception callback.

boolean
canProcessRequest()

Check if the current request is a Jaxon request.

void
processRequest()

Process the current Jaxon request.

array
getUploadedFiles()

Get the uploaded files

Details

at line line 34
abstract HTTP httpResponse($code = '200')

Wrap the Jaxon response into an HTTP response and send it back to the browser.

Parameters

$code The HTTP Response code

Return Value

HTTP Response

at line line 41
Response ajaxResponse()

Get the Jaxon response.

Return Value

Response

at line line 54
void addViewRenderer(string $sId, Closure $xClosure)

Add a view renderer with an id

Parameters

string $sId The unique identifier of the view renderer
Closure $xClosure A closure to create the view instance

Return Value

void

at line line 123
Facade view()

Get the view renderer

Return Value

Facade

at line line 134
Session session()

Get the session manager

Return Value

Session

at line line 147
void register(array $aOptions = array())

Register the Jaxon classes.

Parameters

array $aOptions The options to register the classes with

Return Value

void

at line line 179
object request(string $classname)

Get a Jaxon request to a given class.

Parameters

string $classname the class name

Return Value

object The request to the class

at line line 191
object plugin(string $name)

Get a plugin instance.

Parameters

string $name the plugin name

Return Value

object The plugin instance

at line line 204
void registerClass(string $sClassName, array $aOptions = array())

Register a specified Jaxon class.

Parameters

string $sClassName The name of the class to be registered
array $aOptions The options to register the class with

Return Value

void

at line line 215
string script($bIncludeJs = false, $bIncludeCss = false)

Get the javascript code to be sent to the browser.

Parameters

$bIncludeJs
$bIncludeCss

Return Value

string the javascript code

at line line 226
string js()

Get the HTML tags to include Jaxon javascript files into the page.

Return Value

string the javascript code

at line line 237
string css()

Get the HTML tags to include Jaxon CSS code and files into the page.

Return Value

string the javascript code

at line line 249
void onInit(callable $callable)

Set the init callback, used to initialise controllers.

Parameters

callable $callable The callback function

Return Value

void

at line line 260
void onBefore(callable $callable)

Set the pre-request processing callback.

Parameters

callable $callable The callback function

Return Value

void

at line line 272
void onAfter(callable $callable)

Set the post-request processing callback.

Parameters

callable $callable The callback function

Return Value

void

at line line 284
void onInvalid(callable $callable)

Set the processing error callback.

Parameters

callable $callable The callback function

Return Value

void

at line line 296
void onError(callable $callable)

Set the processing exception callback.

Parameters

callable $callable The callback function

Return Value

void

at line line 306
boolean canProcessRequest()

Check if the current request is a Jaxon request.

Return Value

boolean True if the request is Jaxon, false otherwise.

at line line 317
void processRequest()

Process the current Jaxon request.

Return Value

void

at line line 329
array getUploadedFiles()

Get the uploaded files

Return Value

array