Class XmlValidator
java.lang.Object
lt.viko.eif.jguscia.services.XmlValidator
Service responsible for validating XML documents against an XSD schema.
Ensures that the XML structure matches the rules defined in
data.xsd.-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
XmlValidator
public XmlValidator()
-
-
Method Details
-
validate
Validates the provided XML string using the XSD schema located in application resources.- Parameters:
xml- XML content to validate- Throws:
IllegalArgumentException- if the XML input is null or blankIllegalStateException- if the schema file cannot be foundException- if the XML does not conform to the schema or validation fails
-