Class SchemaConfigValidator
- java.lang.Object
-
- com.hybris.cockpitng.core.util.jaxb.SchemaConfigValidator
-
public class SchemaConfigValidator extends java.lang.ObjectDefines schema based validator for marshaling/unmarshalling xml based configuration. Note: Please seeCockpitConfigurationService,WidgetPersistenceServicefor details.
-
-
Constructor Summary
Constructors Constructor Description SchemaConfigValidator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected SchemaValidationStatusprocessParseException(org.xml.sax.SAXParseException e, java.lang.String fileType)voidsetSchemaLocationRegistry(SchemaLocationRegistry schemaLocationRegistry)voidsetWidgetResourceReader(CockpitResourceLoader widgetResourceReader)SchemaValidationStatusvalidate(java.io.InputStream content, javax.xml.bind.JAXBContext context)Checks whether given xml content is valid against all schemas available from schemaLocationRegistry
-
-
-
Method Detail
-
validate
public SchemaValidationStatus validate(java.io.InputStream content, javax.xml.bind.JAXBContext context)
Checks whether given xml content is valid against all schemas available from schemaLocationRegistry- Parameters:
content- xml config that is being validatedcontext- context that is being used- Returns:
- true if the given content is valid otherwise false
-
processParseException
protected SchemaValidationStatus processParseException(org.xml.sax.SAXParseException e, java.lang.String fileType)
-
setSchemaLocationRegistry
public void setSchemaLocationRegistry(SchemaLocationRegistry schemaLocationRegistry)
-
setWidgetResourceReader
public void setWidgetResourceReader(CockpitResourceLoader widgetResourceReader)
-
-