public class WadlGeneratorDescription
extends java.lang.Object
WadlGenerator implementation with
the specified getGeneratorClass(). The WadlGenerator properties
are populated with the provided properties like this:
org.example.Foo and the
provided property value is of type org.example.FooInputStream: The stream is loaded from the
property value (provided by the WadlGeneratorDescription) via
ClassLoader.getResourceAsStream(String). It will be closed after WadlGenerator.init() was called.
File and the provided property value is a String:File is created via
new File( generator.getClass().getResource( strippedFilename ).toURI() )
Notice that the filename is loaded from the classpath in this case, e.g. classpath:test.xml
refers to a file in the package of the class (getGeneratorClass()). The
file reference classpath:/test.xml refers to a file that is in the root of the classpath.
| Modifier and Type | Field and Description |
|---|---|
private java.lang.Class<?> |
configuratorClass |
private java.lang.Class<? extends WadlGenerator> |
generatorClass |
private java.util.Properties |
properties |
| Constructor and Description |
|---|
WadlGeneratorDescription() |
WadlGeneratorDescription(java.lang.Class<? extends WadlGenerator> generatorClass,
java.util.Properties properties) |
| Modifier and Type | Method and Description |
|---|---|
java.lang.Class<?> |
getConfiguratorClass()
Return
WadlGeneratorConfig that was used to produce current description instance. |
java.lang.Class<? extends WadlGenerator> |
getGeneratorClass() |
java.util.Properties |
getProperties() |
(package private) void |
setConfiguratorClass(java.lang.Class<?> configuratorClass)
Set
WadlGeneratorConfig class to be associated with current instance. |
void |
setGeneratorClass(java.lang.Class<? extends WadlGenerator> generatorClass) |
void |
setProperties(java.util.Properties properties) |
private java.lang.Class<? extends WadlGenerator> generatorClass
private java.util.Properties properties
private java.lang.Class<?> configuratorClass
public WadlGeneratorDescription()
public WadlGeneratorDescription(java.lang.Class<? extends WadlGenerator> generatorClass, java.util.Properties properties)
public java.lang.Class<? extends WadlGenerator> getGeneratorClass()
public void setGeneratorClass(java.lang.Class<? extends WadlGenerator> generatorClass)
generatorClass - the generatorClass to setpublic java.util.Properties getProperties()
public void setProperties(java.util.Properties properties)
properties - the properties to setpublic java.lang.Class<?> getConfiguratorClass()
WadlGeneratorConfig that was used to produce current description instance.
The result could be null if the config was not set on this instance.void setConfiguratorClass(java.lang.Class<?> configuratorClass)
WadlGeneratorConfig class to be associated with current instance.configuratorClass -