Package org.rapidcontext.core.js
Class JsCompileInterceptor
java.lang.Object
org.rapidcontext.core.storage.StorableObject
org.rapidcontext.core.type.Interceptor
org.rapidcontext.core.proc.ReserveInterceptor
org.rapidcontext.core.js.JsCompileInterceptor
A JavaScript procedure compile interceptor. This interceptor ensures that
all JavaScript procedures are compiled during the resource reservation
phase, prior to executing any calling procedure (i.e. fail early)
-
Field Summary
Fields inherited from class org.rapidcontext.core.type.Interceptor
KEY_DESCRIPTION, KEY_PRIO, PATHFields inherited from class org.rapidcontext.core.storage.StorableObject
dict, KEY_ACTIVATED_TIME, KEY_CLASSNAME, KEY_ID, KEY_TYPE, PREFIX_COMPUTED, PREFIX_HIDDEN -
Constructor Summary
ConstructorsConstructorDescriptionJsCompileInterceptor(String id, String type, Dict dict) Creates a new interceptor from a serialized representation. -
Method Summary
Modifier and TypeMethodDescriptionvoidreserve(CallContext cx, Procedure proc) Reserves all resources needed for executing a procedure.Methods inherited from class org.rapidcontext.core.proc.ReserveInterceptor
get, releaseAllMethods inherited from class org.rapidcontext.core.type.Interceptor
chain, description, get, init, next, next, prio, setNext
-
Constructor Details
-
JsCompileInterceptor
Creates a new interceptor from a serialized representation.- Parameters:
id- the object identifiertype- the object type namedict- the serialized representation
-
-
Method Details
-
reserve
Reserves all resources needed for executing a procedure. All resources needed by sub-procedures will also be reserved.- Overrides:
reservein classReserveInterceptor- Parameters:
cx- the procedure contextproc- the procedure definition- Throws:
ProcedureException- if some resource couldn't be reserved
-