[
https://issues.jboss.org/browse/SHRINKDESC-130?page=com.atlassian.jira.pl...
]
Ralf Battenfeld commented on SHRINKDESC-130:
--------------------------------------------
Some proposals
--------------
The current schema-validator is currently a standalone feature and is not integrated into
the metadata-parser plugin. It supports all schemas which are located in the gen module.
The usage is:
final XmlValidator validator = new XmlValidator(SchemaType.XSD);
validator.loadGrammar("application_6.xsd");
validator.validate("src/test/resources/test-invalid-application-6.xml");
You can see that the user has to give the top level descriptor XSD and in addition, to
specify a XML file to validate against.
Proposal:
We could simplify this by doing this:
1) add a flag in the descriptor section of the metada-plugin for each specified XSD:
<keepAsResource>true</keepAsResource>
2) if true, the the metadata-plugin copies the XSD into the impl package
3) the source code generater add then a method validate() for each descriptor. This method
executes the validation as described above by knowing all the details.
What you think? May you want to integrate it this into the SPI level and not directly into
the generated descriptors. Let me know your view on this.
Provide a way to validate an imported or created descriptor content
-------------------------------------------------------------------
Key: SHRINKDESC-130
URL:
https://issues.jboss.org/browse/SHRINKDESC-130
Project: ShrinkWrap Descriptors
Issue Type: Feature Request
Reporter: Ralf Battenfeld
Assignee: Ralf Battenfeld
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:
http://www.atlassian.com/software/jira