|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ConfigurationDeclaration
A ConfigurationDeclaration
holds metadata information
about a Configuration
like its name and ConfigurationDeclaration.DeclarationType
but it also acts as a parser for the actual declaration and
is able to retrieve defined fallback settings
or default values.
Note that a Configuration
itself is responsible
to initialize its ConfigurationBackend
according
to the ConfigurationDeclaration
during its creation,
the latter only holds the declarative information about
what to do, not how to accomplish this.
Thus if the ConfigurationDeclaration
specifies, for
instance, the type Configuration.Type.FALLBACK_DEFAULT
then it's up to the Configuration
to instantiate
a corresponding ConfigurationBackend
and the
ConfigurationDeclaration
only supports the
the default values and fallback ISetting
s.
Nested Class Summary | |
---|---|
static class |
ConfigurationDeclaration.DeclarationType
Defines the different types of String declarations
possible. |
Method Summary | |
---|---|
ConfigurationBackend |
getDefaults()
Returns a ConfigurationBackend that holds all
default values defined in this ConfigurationDeclaration ,
if no such default values are defined an emtpy
ConfigurationBackend will be returned. |
java.util.Map<java.lang.String,java.lang.String> |
getFallbacks()
Returns the fallback ISetting s defined by this
ConfigurationDeclaration , if no such fallbacks
are present an emtpy Map will be returned. |
java.lang.String |
getName()
Returns the name of the Configuration associated with
this ConfigurationDeclaration . |
java.util.Set<java.lang.String> |
getSettingNames()
Returns a List of declared ISetting names. |
Configuration.Type |
getType()
Returns the ConfigurationDeclaration.DeclarationType of the Configuration associated
with this ConfigurationDeclaration . |
Method Detail |
---|
java.lang.String getName()
Configuration
associated with
this ConfigurationDeclaration
.
String
.Configuration.Type getType()
ConfigurationDeclaration.DeclarationType
of the Configuration
associated
with this ConfigurationDeclaration
.
ConfigurationDeclaration.DeclarationType
, never null
.java.util.Set<java.lang.String> getSettingNames()
List
of declared ISetting
names.
List
of
ISetting
names.java.util.Map<java.lang.String,java.lang.String> getFallbacks()
ISetting
s defined by this
ConfigurationDeclaration
, if no such fallbacks
are present an emtpy Map
will be returned.
Map
instance, never null
.ConfigurationBackend getDefaults()
ConfigurationBackend
that holds all
default values defined in this ConfigurationDeclaration
,
if no such default values are defined an emtpy
ConfigurationBackend
will be returned.
ConfigurationBackend
instance,
never null
.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |