|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.sourceforge.pbeans.servlet.ServletAccess
public class ServletAccess
Utilities that facilitate usage of pBeans in servlet engines.
Constructor Summary | |
---|---|
ServletAccess()
|
Method Summary | |
---|---|
static Store |
getStore(javax.servlet.ServletConfig servletConfig,
java.lang.String storeName,
java.lang.ClassLoader classLoader)
Calls getStore(ServletContext, String, ClassLoader) by passing
a servlet context. |
static Store |
getStore(javax.servlet.ServletContext servletContext,
java.lang.String storeName,
java.lang.ClassLoader classLoader)
Gets a store based on servlet context parameters. |
static Store |
getStore(javax.servlet.Servlet servlet,
java.lang.String storeName)
Calls getStore(ServletConfig, String, ClassLoader) by passing
the servlet configuration of the servlet. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ServletAccess()
Method Detail |
---|
public static Store getStore(javax.servlet.Servlet servlet, java.lang.String storeName) throws StoreException
getStore(ServletConfig, String, ClassLoader)
by passing
the servlet configuration of the servlet. The store will use the
class loader that loaded the servlet class by default.
servlet
- A servlet.storeName
- The name of the store sought.
Store
instance.
StoreException
public static Store getStore(javax.servlet.ServletConfig servletConfig, java.lang.String storeName, java.lang.ClassLoader classLoader) throws StoreException
getStore(ServletContext, String, ClassLoader)
by passing
a servlet context.
servletConfig
- A servlet configuration instance.storeName
- The name of the store sought.classLoader
- The class loader Store will use by default to load classes.
This may be null
.
Store
instance.
javax.servlet.ServletException
StoreException
public static Store getStore(javax.servlet.ServletContext servletContext, java.lang.String storeName, java.lang.ClassLoader classLoader) throws StoreException
pbeans.stores
will
be looked up. It should contain a comma-separated list
of store names. For each store name mystorename,
there should be either a context parameter named
mystorename.jdbc.url
(defining the
JDBC URL for GenericDataSource
)
or one named mystorename.datasource.def.name
(definining a JNDI name identifying a DataSource
instance). If mystorename.jdbc.url
is defined,
mystorename.jdbc.driver
should also
be defined. Optionally, context parameters mystorename.max.connections
and mystorename.connection.timeout
may also
be provided.
servletContext
- storeName
- classLoader
-
StoreException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |