public abstract class FactoryBase extends Object implements ObjectFactory
Constructor and Description |
---|
FactoryBase() |
Modifier and Type | Method and Description |
---|---|
protected abstract ObjectFactory |
getDefaultFactory(Reference ref)
If a default factory is available for the given reference type, create
the default factory.
|
protected abstract Object |
getLinked(Reference ref)
If this reference is a link to another JNDI object, obtain that object.
|
Object |
getObjectInstance(Object obj,
Name name,
Context nameCtx,
Hashtable<?,?> environment)
Creates a new object instance.
|
protected abstract boolean |
isReferenceTypeSupported(Object obj)
Determines if this factory supports processing the provided reference
object.
|
public final Object getObjectInstance(Object obj, Name name, Context nameCtx, Hashtable<?,?> environment) throws Exception
getObjectInstance
in interface ObjectFactory
obj
- The reference object describing the object to createException
protected abstract boolean isReferenceTypeSupported(Object obj)
obj
- The object to be processedtrue
if this factory can process the object,
otherwise false
protected abstract ObjectFactory getDefaultFactory(Reference ref) throws NamingException
ref
- The reference object to be processednull
if no default factory exists.NamingException
- If the default factory cannot be craetedprotected abstract Object getLinked(Reference ref) throws NamingException
ref
- The reference object to be processednull
if linked objects are
not supported by or not configured for this reference objectNamingException
- Error accessing linked objectCopyright © 2000-2016 Apache Software Foundation. All Rights Reserved.