Class WebUtil
- java.lang.Object
-
- org.apache.cayenne.configuration.web.WebUtil
-
public class WebUtil extends Object
A helper class to retrieve and storeCayenneRuntimein theServletContext. All Cayenne web configuration objects, such asCayenneFilterandorg.apache.cayenne.rop.ROPServlet, are using this class to access runtime.- Since:
- 3.1
-
-
Constructor Summary
Constructors Constructor Description WebUtil()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static CayenneRuntimegetCayenneRuntime(javax.servlet.ServletContext context)Retrieves CayenneRuntime previously stored in provided context viasetCayenneRuntime(ServletContext, CayenneRuntime).static voidsetCayenneRuntime(javax.servlet.ServletContext context, CayenneRuntime runtime)StoresCayenneRuntimein the servlet context.
-
-
-
Method Detail
-
getCayenneRuntime
public static CayenneRuntime getCayenneRuntime(javax.servlet.ServletContext context)
Retrieves CayenneRuntime previously stored in provided context viasetCayenneRuntime(ServletContext, CayenneRuntime). May return null if no runtime was stored.
-
setCayenneRuntime
public static void setCayenneRuntime(javax.servlet.ServletContext context, CayenneRuntime runtime)StoresCayenneRuntimein the servlet context. It can be later retrieve viagetCayenneRuntime(ServletContext).
-
-