Module ringo/webapp/env

This module can be used to lookup the current JSGI request and config module in a web application.

Functions


getConfig ()

Get the config module associated with the current thread.


getConfigs ()

Get an array containing all config modules associated with the current thread.


getRequest ()

Get the request associated with the current thread.


loadMacros (context)

Parameters

context

pushConfig (config, configId)

Registers a nested config module to the configs array and sets it as the current module. This throws an Error if no request is associated with the current thread.

Parameters

config
configId

reset ()

Unregister any request and config objects previously associated with the current request.


setRequest (req)

Registers a request with the current thread

Parameters

req a JSGI request object