lucee.Component coldbox.system.core.events.EventPool coldbox.system.web.context.InterceptorState
Copyright Since 2005 ColdBox Framework by Luis Majano and Ortus Solutions, Corp www.ortussolutions.com --- This object models an interception state
Property Summary | ||||
---|---|---|---|---|
type | property | default | serializable | required |
any
|
controller
Controller reference.
|
true
|
false
|
|
any
|
metadataMap
Metadata map for objects.
|
true
|
false
|
Constructor Summary | |
---|---|
init(any state, any logbox, any controller)
Constructor. |
Method Summary | |
---|---|
any
|
exists(any interceptorKey)
Checks if the passed interceptor key already exists. |
string
|
getController()
|
any
|
getInterceptor(any interceptorKey)
Get an interceptor from this state. |
any
|
getInterceptors()
Get the interceptors linked hash map. |
any
|
getMetadataMap([any interceptorKey])
Return the state's metadata map for it's registered interecptors. |
private any
|
invoker(any interceptor, any event, any interceptData, any interceptorKey, any buffer)
Execute an interceptor execution point asynchronously. |
private any
|
invokerAsync(any event, any interceptData, any interceptorKey, [any asyncPriority='NORMAL'], any buffer)
Execute an interceptor execution point asynchronously. |
boolean
|
isExecutable(any target, any event, any targetKey)
Checks if an interceptor is executable or not. |
any
|
process(any event, any interceptData, [boolean async='false'], [boolean asyncAll='false'], [boolean asyncAllJoin='true'], [string asyncPriority='NORMAL'], [numeric asyncJoinTimeout='0'], any buffer)
Process this state's interceptors. |
any
|
processAsync(any event, any interceptData, [string asyncPriority='NORMAL'], any buffer)
Process an execution asynchronously. |
any
|
processAsyncAll(any event, any interceptData, [boolean asyncAllJoin='true'], [string asyncPriority='NORMAL'], [numeric asyncJoinTimeout='0'], any buffer)
Process an execution asynchronously. |
any
|
processSync(any event, any interceptData, any buffer)
Process an execution synchronously. |
any
|
register(any interceptorKey, any interceptor, any interceptorMD)
Register an interceptor class with this state. |
any
|
setController(any controller)
|
any
|
setMetadataMap(any metadataMap)
|
any
|
unregister(any interceptorKey)
Unregister an interceptor class from this state. |
Methods inherited from class coldbox.system.core.events.EventPool |
---|
getObject, getPool, getState, setPool, setState |
Methods inherited from class lucee.Component |
---|
None |
Constructor Detail |
---|
Constructor
state
- The interception state to modellogbox
- LogBox referencecontroller
- The ColdBox ControllerProperty Detail |
---|
Controller reference
access
- publicrequired
- falsereturntype
- anyserializable
- trueMetadata map for objects
access
- publicrequired
- falsereturntype
- anyserializable
- trueMethod Detail |
---|
Checks if the passed interceptor key already exists
exists
in class
EventPool
interceptorKey
- The interceptor key class to verify it existsGet an interceptor from this state. Else return a blank structure if not found
interceptorKey
- The interceptor key class to retrieveGet the interceptors linked hash map
Return the state's metadata map for it's registered interecptors
interceptorKey
- Pass a key and retrieve that interceptor's metadata map onlyExecute an interceptor execution point asynchronously
invoker
in class
EventPool
interceptor
- The interceptorevent
- The event context object.interceptData
- A data structure used to pass intercepted information.interceptorKey
- The interceptor key to invokebuffer
- hint="The request buffer object that can be used to produce output from interceptor chainsExecute an interceptor execution point asynchronously
event
- The event context object.interceptData
- A data structure used to pass intercepted information.interceptorKey
- The interceptor key to invokeasyncPriority
- The thread priority for executionbuffer
- hint="The request buffer object that can be used to produce output from interceptor chainsChecks if an interceptor is executable or not. Boolean
target
- The target interceptor to checkevent
- The event contexttargetKey
- The target interceptor keyProcess this state's interceptors. If you use the asynchronous facilities, you will get a thread structure report as a result
process
in class
EventPool
event
- The event context object.interceptData
- A data structure used to pass intercepted information.async
- If true, the entire interception chain will be ran in a separate thread.asyncAll
- If true, each interceptor in the interception chain will be ran in a separate thread and then joined together at the end.asyncAllJoin
- If true, each interceptor in the interception chain will be ran in a separate thread and joined together at the end by default. If you set this flag to false then there will be no joining and waiting for the threads to finalize.asyncPriority
- The thread priority to be used. Either LOW, NORMAL or HIGH. The default value is NORMALasyncJoinTimeout
- The timeout in milliseconds for the join thread to wait for interceptor threads to finish. By default there is no timeout.buffer
- hint="The request buffer object that can be used to produce output from interceptor chainsProcess an execution asynchronously
event
- The event context object.interceptData
- A data structure used to pass intercepted information.asyncPriority
- The thread priority to be used. Either LOW, NORMAL or HIGH. The default value is NORMALbuffer
- hint="The request buffer object that can be used to produce output from interceptor chainsProcess an execution asynchronously
event
- The event context object.interceptData
- A data structure used to pass intercepted information.asyncAllJoin
- If true, each interceptor in the interception chain will be ran in a separate thread and joined together at the end by default. If you set this flag to false then there will be no joining and waiting for the threads to finalize.asyncPriority
- The thread priority to be used. Either LOW, NORMAL or HIGH. The default value is NORMALasyncJoinTimeout
- The timeout in milliseconds for the join thread to wait for interceptor threads to finish. By default there is no timeout.buffer
- hint="The request buffer object that can be used to produce output from interceptor chainsProcess an execution synchronously
event
- The event context object.interceptData
- A data structure used to pass intercepted information.buffer
- hint="The request buffer object that can be used to produce output from interceptor chainsRegister an interceptor class with this state
register
in class
EventPool
interceptorKey
- The interceptor key class to registerinterceptor
- The interceptor reference from the cache.interceptorMD
- The interceptor state metadata.controller
metadataMap
Unregister an interceptor class from this state
unregister
in class
EventPool
interceptorKey
- The interceptor key class to register