|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.torque.engine.database.model.NameFactory
public class NameFactory
A name generation factory.
| Field Summary | |
|---|---|
private Hashtable |
algorithms
The cache of NameGenerator algorithms in use for
name generation, keyed by fully qualified class name. |
static String |
CONSTRAINT_GENERATOR
The fully qualified class name of the constraint name generator. |
private static NameFactory |
instance
The single instance of this class. |
static String |
JAVA_GENERATOR
The fully qualified class name of the Java name generator. |
| Constructor Summary | |
|---|---|
protected |
NameFactory()
Creates a new instance with storage for algorithm implementations. |
| Method Summary | |
|---|---|
static String |
generateName(String algorithmName,
List inputs)
Given a list of String objects, implements an
algorithm which produces a name. |
protected NameGenerator |
getAlgorithm(String name)
Factory method which retrieves an instance of the named generator. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String JAVA_GENERATOR
public static final String CONSTRAINT_GENERATOR
private static NameFactory instance
private Hashtable algorithms
NameGenerator algorithms in use for
name generation, keyed by fully qualified class name.
| Constructor Detail |
|---|
protected NameFactory()
| Method Detail |
|---|
protected NameGenerator getAlgorithm(String name)
throws EngineException
name - The fully qualified class name of the name
generation algorithm to retrieve.
EngineException
public static String generateName(String algorithmName,
List inputs)
throws EngineException
String objects, implements an
algorithm which produces a name.
algorithmName - The fully qualified class name of the
NameGenerator
implementation to use to generate names.inputs - Inputs used to generate a name.
EngineException - an exception
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||