Package org.ametys.web.site
Class SiteParameterParser
java.lang.Object
org.ametys.runtime.model.AbstractModelItemParser
org.ametys.runtime.model.ElementDefinitionParser
org.ametys.cms.model.ElementDefinitionParser
org.ametys.web.site.SiteParameterParser
Parser for Site parameter.
-
Field Summary
Fields inherited from class org.ametys.runtime.model.AbstractModelItemParser
_modelItemTypeExtensionPoint -
Constructor Summary
ConstructorsConstructorDescriptionSiteParameterParser(ModelItemTypeExtensionPoint elementTypeExtensionPoint, ThreadSafeComponentManager<Enumerator> enumeratorManager, ThreadSafeComponentManager<Validator> validatorManager) Creates a site parameter parser. -
Method Summary
Modifier and TypeMethodDescriptionprotected StringRetrieves the name of the configuration attribute that contains the name of the model itemparse(ServiceManager serviceManager, String pluginName, Configuration parameterConfig) Parses a site parameter from a XML configuration.Methods inherited from class org.ametys.cms.model.ElementDefinitionParser
_createModelItem, _parseContentTypeId, parseMethods inherited from class org.ametys.runtime.model.ElementDefinitionParser
_parseAndSetEnumerator, _parseAndSetValidator, _parseDefaultValue, _parseDefaultValues, _parseMultiple, lookupComponentsMethods inherited from class org.ametys.runtime.model.AbstractModelItemParser
_parseDisableConditions, _parseI18nizableText, _parseI18nizableText, _parseName, _parseType, _parseWidget, _parseWidgetParameters, parse
-
Constructor Details
-
SiteParameterParser
public SiteParameterParser(ModelItemTypeExtensionPoint elementTypeExtensionPoint, ThreadSafeComponentManager<Enumerator> enumeratorManager, ThreadSafeComponentManager<Validator> validatorManager) Creates a site parameter parser.- Parameters:
elementTypeExtensionPoint- the extension point to use to get available element typesenumeratorManager- the enumerator component manager.validatorManager- the validator component manager.
-
-
Method Details
-
_getNameConfigurationAttribute
Description copied from class:AbstractModelItemParserRetrieves the name of the configuration attribute that contains the name of the model item- Overrides:
_getNameConfigurationAttributein classAbstractModelItemParser- Returns:
- the name of the configuration attribute that contains the name of the model item
-
parse
public ElementDefinition parse(ServiceManager serviceManager, String pluginName, Configuration parameterConfig) throws ConfigurationException Parses a site parameter from a XML configuration. A site parameter has no model at parsing. Parameters are copied for each model after parsing- Parameters:
serviceManager- the service managerpluginName- the plugin name declaring this parameter.parameterConfig- the XML configuration of the parameter.- Returns:
- the parsed parameter.
- Throws:
ConfigurationException- if the configuration is not valid.
-