|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.nanocontainer.script.ScriptedContainerBuilderFactory
public class ScriptedContainerBuilderFactory
The main class for configuration of PicoContainer with various scripting languages. When using the constructors taking a file, the extensions must be one of the following:
Field Summary | |
---|---|
static java.lang.String |
BEANSHELL
Deprecated. Since NanoContainer RC-2. (14-Dec-2005). Use ScriptBuilderResolver.BEANSHELL instead. |
static java.lang.String |
GROOVY
Deprecated. Since NanoContainer RC-2. (14-Dec-2005). Use ScriptBuilderResolver.GROOVY instead. |
static java.lang.String |
JAVASCRIPT
Deprecated. Since NanoContainer RC-2. (14-Dec-2005). Use ScriptBuilderResolver.JAVASCRIPT instead. |
static java.lang.String |
JYTHON
Deprecated. Since NanoContainer RC-2. (14-Dec-2005). Use ScriptBuilderResolver.JYTHON instead. |
static java.lang.String |
XML
Deprecated. Since NanoContainer RC-2. (14-Dec-2005). Use ScriptBuilderResolver.XML instead. |
Constructor Summary | |
---|---|
ScriptedContainerBuilderFactory(java.io.File compositionFile)
|
|
ScriptedContainerBuilderFactory(java.io.File compositionFile,
java.lang.ClassLoader classLoader)
|
|
ScriptedContainerBuilderFactory(java.io.File compositionFile,
java.lang.ClassLoader classLoader,
ScriptBuilderResolver builderClassResolver)
Added since Nano RC-2. |
|
ScriptedContainerBuilderFactory(java.io.Reader composition,
java.lang.String builderClass)
|
|
ScriptedContainerBuilderFactory(java.io.Reader composition,
java.lang.String builderClass,
java.lang.ClassLoader classLoader)
Allows you to create a factory that isntantiats the builder class you desire. |
|
ScriptedContainerBuilderFactory(java.net.URL compositionURL)
|
|
ScriptedContainerBuilderFactory(java.net.URL compositionURL,
java.lang.ClassLoader classLoader,
ScriptBuilderResolver builderClassResolver)
Added since Nano RC-2. |
|
ScriptedContainerBuilderFactory(java.net.URL compositionURL,
java.lang.String builderClassName,
java.lang.ClassLoader contextClassLoader)
|
Method Summary | |
---|---|
static java.lang.String |
getBuilderClassName(java.lang.String extension)
Deprecated. Since NanoContainer 1.0 RC-2. Use the class ScriptBuilderResolver for this functionality. |
ScriptedContainerBuilder |
getContainerBuilder()
Retrieve the created container builder instance. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String GROOVY
public static final java.lang.String BEANSHELL
public static final java.lang.String JAVASCRIPT
public static final java.lang.String JYTHON
public static final java.lang.String XML
Constructor Detail |
---|
public ScriptedContainerBuilderFactory(java.io.File compositionFile, java.lang.ClassLoader classLoader) throws java.io.IOException, java.lang.ClassNotFoundException
java.io.IOException
java.lang.ClassNotFoundException
public ScriptedContainerBuilderFactory(java.io.File compositionFile, java.lang.ClassLoader classLoader, ScriptBuilderResolver builderClassResolver) throws java.io.IOException, java.lang.ClassNotFoundException, UnsupportedScriptTypeException
compositionFile
- File The script file.classLoader
- ClassLoader for class resolution once we resolve what the name of the
builder should be..builderClassResolver
- ScriptBuilderResolver the resolver for figuring out
file names to container builder class names.
java.io.IOException
- upon java.io.File name resolution error.
java.lang.ClassNotFoundException
- If there is an error loading
the specified builder using the specified classloader.
UnsupportedScriptTypeException
- if the extension of the file
does not match that of any known script.public ScriptedContainerBuilderFactory(java.io.File compositionFile) throws java.io.IOException, java.lang.ClassNotFoundException
java.io.IOException
java.lang.ClassNotFoundException
public ScriptedContainerBuilderFactory(java.net.URL compositionURL) throws java.lang.ClassNotFoundException
java.lang.ClassNotFoundException
public ScriptedContainerBuilderFactory(java.net.URL compositionURL, java.lang.ClassLoader classLoader, ScriptBuilderResolver builderClassResolver) throws java.lang.ClassNotFoundException, UnsupportedScriptTypeException
compositionURL
- The script URL.builderClassResolver
- ScriptBuilderResolver the resolver for figuring out
file names to container builder class names.classLoader
- ClassLoader for class resolution once we resolve what the name of the
builder should be..
java.lang.ClassNotFoundException
- If there is an error loading
the specified builder using the specified classloader.
UnsupportedScriptTypeException
- if the extension of the file
does not match that of any known script.public ScriptedContainerBuilderFactory(java.net.URL compositionURL, java.lang.String builderClassName, java.lang.ClassLoader contextClassLoader) throws java.lang.ClassNotFoundException
java.lang.ClassNotFoundException
public ScriptedContainerBuilderFactory(java.io.Reader composition, java.lang.String builderClass) throws java.lang.ClassNotFoundException
java.lang.ClassNotFoundException
public ScriptedContainerBuilderFactory(java.io.Reader composition, java.lang.String builderClass, java.lang.ClassLoader classLoader) throws java.lang.ClassNotFoundException
composition
- Reader the script you wish to create the builder for.builderClass
- String the builder class that instantiate.classLoader
- ClassLoader the classloader to use for instantiation.
java.lang.ClassNotFoundException
- if the specified class cannot be found.Method Detail |
---|
public static java.lang.String getBuilderClassName(java.lang.String extension)
extension
- String the file extension to res
public ScriptedContainerBuilder getContainerBuilder()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |