public class MemoryUserDatabaseFactory
extends java.lang.Object
implements javax.naming.spi.ObjectFactory
JNDI object creation factory for MemoryUserDatabase
instances. This makes it convenient to configure a user database
in the global JNDI resources associated with this Catalina instance,
and then link to that resource for web applications that administer
the contents of the user database.
The MemoryUserDatabase
instance is configured based
on the following parameter values:
catalina.base
system property)
pathname to the XML file from which our user information is loaded,
and to which it is stored. [conf/tomcat-users.xml]Constructor and Description |
---|
MemoryUserDatabaseFactory() |
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
getObjectInstance(java.lang.Object obj,
javax.naming.Name name,
javax.naming.Context nameCtx,
java.util.Hashtable<?,?> environment)
Create and return a new
MemoryUserDatabase instance
that has been configured according to the properties of the
specified Reference . |
public java.lang.Object getObjectInstance(java.lang.Object obj, javax.naming.Name name, javax.naming.Context nameCtx, java.util.Hashtable<?,?> environment) throws java.lang.Exception
Create and return a new MemoryUserDatabase
instance
that has been configured according to the properties of the
specified Reference
. If you instance can be created,
return null
instead.
getObjectInstance
in interface javax.naming.spi.ObjectFactory
obj
- The possibly null object containing location or
reference information that can be used in creating an objectname
- The name of this object relative to nameCtx
nameCtx
- The context relative to which the name
parameter is specified, or null
if name
is relative to the default initial contextenvironment
- The possibly null environment that is used in
creating this objectjava.lang.Exception
Copyright © 2000-2018 Apache Software Foundation. All Rights Reserved.