|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.openjpa.lib.conf.AbstractProductDerivation
public abstract class AbstractProductDerivation
Abstract no-op product derivation for easy extension.
Field Summary |
---|
Fields inherited from interface org.apache.openjpa.lib.conf.ProductDerivation |
---|
TYPE_FEATURE, TYPE_PRODUCT |
Constructor Summary | |
---|---|
AbstractProductDerivation()
|
Method Summary | |
---|---|
boolean |
afterSpecificationSet(Configuration conf)
Called after the specification has been set. |
void |
beforeConfigurationClose(Configuration conf)
Called before the given Configuration is closed. |
boolean |
beforeConfigurationConstruct(ConfigurationProvider cp)
Provides the instance with a callback to mutate the initial properties of the ConfigurationProvider . |
boolean |
beforeConfigurationLoad(Configuration conf)
Provides the instance with the opportunity to mutate conf before the user configuration is applied. |
List |
getAnchorsInFile(File file)
Return a List file . |
List |
getAnchorsInResource(String resource)
Return a List resource . |
String |
getConfigurationPrefix()
Return the configuration prefix for properties of this product. |
String |
getDefaultResourceLocation()
Return a string identifying the default resource location for this product derivation, if one exists. |
ConfigurationProvider |
load(File file,
String anchor)
Load given file, or return null if it is not a file this receiver understands. |
ConfigurationProvider |
load(String resource,
String anchor,
ClassLoader loader)
Load the given given resource into the returned ConfigurationProvider, or return null if it is not a resource this receiver understands. |
ConfigurationProvider |
loadDefaults(ClassLoader loader)
Load defaults into the returned ConfigurationProvider, or return null if no defaults are found. |
ConfigurationProvider |
loadGlobals(ClassLoader loader)
Load globals into the returned ConfigurationProvider, or return null if no globals are found. |
void |
validate()
Ensure that this derivation is valid. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.apache.openjpa.lib.conf.ProductDerivation |
---|
getType |
Constructor Detail |
---|
public AbstractProductDerivation()
Method Detail |
---|
public String getConfigurationPrefix()
ProductDerivation
getConfigurationPrefix
in interface ProductDerivation
public void validate() throws Exception
ProductDerivation
validate
in interface ProductDerivation
Exception
public ConfigurationProvider loadGlobals(ClassLoader loader) throws Exception
ProductDerivation
loadGlobals
in interface ProductDerivation
Exception
public ConfigurationProvider loadDefaults(ClassLoader loader) throws Exception
ProductDerivation
loadDefaults
in interface ProductDerivation
Exception
public ConfigurationProvider load(String resource, String anchor, ClassLoader loader) throws Exception
ProductDerivation
load
in interface ProductDerivation
anchor
- optional named anchor within a multiple-configuration
resource
Exception
public ConfigurationProvider load(File file, String anchor) throws Exception
ProductDerivation
load
in interface ProductDerivation
anchor
- optional named anchor within a multiple-configuration file
Exception
public String getDefaultResourceLocation()
ProductDerivation
null
.
getDefaultResourceLocation
in interface ProductDerivation
public List getAnchorsInFile(File file) throws Exception
ProductDerivation
file
.
The returned names are not fully-qualified, so must be used in
conjunction with file
in calls
to ProductDerivation.load(java.io.File, String)
.
Returns null
or an empty list if no anchors could be found.
getAnchorsInFile
in interface ProductDerivation
Exception
public List getAnchorsInResource(String resource) throws Exception
ProductDerivation
resource
. The returned names are not
fully-qualified, so must be used in conjunction with
resource
in calls to ProductDerivation.load(java.io.File, String)
.
Returns null
or an empty list if no anchors could be found.
getAnchorsInResource
in interface ProductDerivation
Exception
public boolean beforeConfigurationConstruct(ConfigurationProvider cp)
ProductDerivation
ConfigurationProvider
. This is primarily to alter or
add properties that determine what type of configuration is constructed,
and therefore is typically used at runtime only.
beforeConfigurationConstruct
in interface ProductDerivation
public boolean beforeConfigurationLoad(Configuration conf)
ProductDerivation
conf
before the user configuration is applied.
beforeConfigurationLoad
in interface ProductDerivation
public boolean afterSpecificationSet(Configuration conf)
ProductDerivation
afterSpecificationSet
in interface ProductDerivation
public void beforeConfigurationClose(Configuration conf)
ProductDerivation
beforeConfigurationClose
in interface ProductDerivation
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |