public class DefaultMetadataEnvironmentFactory extends MetadataEnvironmentFactory
MetadataEnvironmentFactory
.CONTEXT_PARAMETER_PREFIX
Constructor and Description |
---|
DefaultMetadataEnvironmentFactory()
Constructs a default factory.
|
Modifier and Type | Method and Description |
---|---|
protected void |
configureCurrentADFSessionOptions(MetadataEnvironment env) |
protected java.lang.String |
getContextParameter(ADFContext context,
java.lang.String name)
Returns the value of a parameter of a context for this factory to create
a new metadata environment.
|
boolean |
isCustomMetadataEnvironment(MetadataEnvironment e)
Returns
true if the given instance is a custom instance. |
MetadataEnvironment |
newInstance(java.util.Map<java.lang.String,java.lang.Object> config)
Creates a new instance of
MetadataEnvironment based on the
current user context and the configuration. |
protected boolean |
supportsUnifiedEnvironments()
Returns
true if the metadata environments created by this
factory are unified environments. |
configureCurrentADFSessionOptions, getContextParameter, isUnified
public DefaultMetadataEnvironmentFactory()
public MetadataEnvironment newInstance(java.util.Map<java.lang.String,java.lang.Object> config)
MetadataEnvironmentFactory
MetadataEnvironment
based on the
current user context and the configuration.newInstance
in class MetadataEnvironmentFactory
config
- the configuration of the new instance; null
if
the default configuration should be usedMetadataEnvironment
based on the
current user context and the configuration if suppliedpublic boolean isCustomMetadataEnvironment(MetadataEnvironment e)
MetadataEnvironmentFactory
true
if the given instance is a custom instance. A
custom instance is an instance that is not created by this factory.isCustomMetadataEnvironment
in class MetadataEnvironmentFactory
e
- the instance to be checkedtrue
if the given instance is a custom instanceMetadataEnvironmentFactory.newInstance(java.util.Map<java.lang.String, java.lang.Object>)
protected boolean supportsUnifiedEnvironments()
MetadataEnvironmentFactory
true
if the metadata environments created by this
factory are unified environments.
A unified environment supports multiple repositories. A non-unified
environment supports only one single MDS repository. By default this
method returns true
. The implementation may allow this
method to return false
in a system that is not ready to
be transitioned into a unified environment but the new code is already
in place.
supportsUnifiedEnvironments
in class MetadataEnvironmentFactory
true
if the metadata environment is unified;
false
otherwiseprotected void configureCurrentADFSessionOptions(MetadataEnvironment env)
configureCurrentADFSessionOptions
in class MetadataEnvironmentFactory
env
- the MetadataEnvironment
object according to which
the current ADFSessionOptions
should be configuredprotected java.lang.String getContextParameter(ADFContext context, java.lang.String name)
MetadataEnvironmentFactory
getContextParameter
in class MetadataEnvironmentFactory
context
- the context for this factory to create a new metadata
environmentname
- the name of the parameternull
if the
value is null or the parameter does not exist