org.objectweb.jonas.security.realm.factory
Class JResourceFactory

java.lang.Object
  extended by org.objectweb.jonas.security.realm.factory.JResourceFactory
All Implemented Interfaces:
javax.naming.spi.ObjectFactory
Direct Known Subclasses:
JResourceDSFactory, JResourceLDAPFactory, JResourceMemoryFactory

public abstract class JResourceFactory
extends java.lang.Object
implements javax.naming.spi.ObjectFactory

This class provides an implementation of the abstract JResource factory for managing users

Author:
Florent Benoit

Constructor Summary
JResourceFactory()
           
 
Method Summary
static org.objectweb.util.monolog.api.Logger getLogger()
           
abstract  java.lang.Object getObjectInstance(java.lang.Object obj, javax.naming.Name name, javax.naming.Context nameCtx, java.util.Hashtable environment)
          Creates a object using the location or reference information specified.
static void setLogger(org.objectweb.util.monolog.api.Logger logger)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JResourceFactory

public JResourceFactory()
Method Detail

getObjectInstance

public abstract java.lang.Object getObjectInstance(java.lang.Object obj,
                                                   javax.naming.Name name,
                                                   javax.naming.Context nameCtx,
                                                   java.util.Hashtable environment)
                                            throws java.lang.Exception
Creates a object using the location or reference information specified.

Specified by:
getObjectInstance in interface javax.naming.spi.ObjectFactory
Parameters:
obj - the possibly null object containing location or reference information that can be used in creating an object.
name - the name of this object relative to nameCtx, or null if no name is specified.
nameCtx - the context relative to which the name parameter is specified, or null if name is relative to the default initial context.
environment - the possibly null environment that is used in creating the object.
Returns:
a newly created object with the specific configuration; null if an object cannot be created.
Throws:
java.lang.Exception - if this object factory encountered an exception while attempting to create an object, and no other object factories are to be tried.

getLogger

public static org.objectweb.util.monolog.api.Logger getLogger()
Returns:
Returns the logger.

setLogger

public static void setLogger(org.objectweb.util.monolog.api.Logger logger)
Parameters:
logger - The logger to set.