Class ConfigModel
java.lang.Object
org.springframework.extensions.webscripts.ConfigModel
- Direct Known Subclasses:
ScriptConfigModel,TemplateConfigModel
Abstract base class used for objects that represent configuration
as a root object in a script or template model.
- Author:
- gavinc
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionclassMap to allow access to scoped config in a unified way for scripts and templates. -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected org.springframework.extensions.config.ConfigServiceprotected String -
Constructor Summary
ConstructorsConstructorDescriptionConfigModel(org.springframework.extensions.config.ConfigService configService, String scriptConfig) -
Method Summary
Modifier and TypeMethodDescriptionRetrieves the global configuration as a Map.Retrieves scoped configuration as a Map.abstract ObjectRetrieves the script configuration.
It's up to the subclass what is returned to represent script config.
-
Field Details
-
configService
protected org.springframework.extensions.config.ConfigService configService -
globalConfig
-
scriptConfig
-
-
Constructor Details
-
ConfigModel
public ConfigModel(org.springframework.extensions.config.ConfigService configService, String scriptConfig)
-
-
Method Details
-
getGlobal
Retrieves the global configuration as a Map.- Returns:
- Map of the global config
-
getScoped
Retrieves scoped configuration as a Map.- Returns:
- Map of the scoped config
-
getScript
Retrieves the script configuration.
It's up to the subclass what is returned to represent script config.- Returns:
- script configuration
-