olabusayoT commented on code in PR #1517:
URL: https://github.com/apache/daffodil/pull/1517#discussion_r2245529898


##########
daffodil-core/src/main/java/org/apache/daffodil/api/validation/package-info.java:
##########
@@ -16,97 +16,64 @@
  */
 
 /**
- * We provide 4 different types of built-in validators for use with
- * {@link 
org.apache.daffodil.api.DataProcessor#withValidator(org.apache.daffodil.api.validation.Validator)}:
- * <ul>
- *   <li>{@link org.apache.daffodil.validation.NoValidator} - for no 
validation</li>
- *   <li>{@link org.apache.daffodil.validation.DaffodilLimitedValidator} - for 
limited/daffodil schema constraints validation</li>
- *   <li>{@link org.apache.daffodil.validation.XercesValidator} - for full 
validation using Xerces schema validation</li>
- *   <li>see org.apache.daffodil.validation.schematron.SchematronValidator - 
for schematron validation</li>
- * </ul>
+ * Daffodil provides a number of built-in validators for use with {@link
+ * org.apache.daffodil.api.DataProcessor#withValidation(String, URI)}. The
+ * following list contain the names of the available validators (provided as
+ * the {@code String} parameter), a short description, and properties used by
+ * the validator. If the URI parameter ends in <i>.conf</i> or
+ * <i>.properties</i> then it is treated as a {@link java.util.Properties} file
+ * that provides the necessary properties. Otherwise, the URI is set to a
+ * property with the same name as the validator. If a validator does not
+ * require properties, the URI parameter can be set to {@code null}.
+ *
+ * <h2>off</h2>
+ * <p><b>Description:</b> disable validation</p>
+ * <p><b>Properties:</b> none</p>
+ *
+ * <h2>limited</h2>
+ * <p><b>Description:</b> XML schema validation using Daffodil</p>
+ * <p><b>Properties:</b> none</p>
+ *
+ * <h2>xerces</h2>
+ * <p><b>Description:</b> XML Schema validation using Xerces library</p>
+ * <p><b>Properties:</b></p>
+ * <dl>
+ *   <dt>{@code xerces}</dt>
+ *   <dd>absolute URI to a XSD file</dd>
+ * </dl>
+ *
+ * <h2>schematron</h2>
+ * <p><b>Description:</b> schematron validation using Saxon-HE library</p>
+ * <p><b>Properties:</b></p>
+ * <dl>
+ *   <dt>{@code schematron}</dt>
+ *   <dd>
+ *     absolute URI to a file containing schematron rules. If the URI
+ *     ends with .sch then the file is treated as a schematron file.
+ *     Otherwise, it is treated as an XSD file containing embedded
+ *     schematron rules.
+ *   </dd>
+ *   <dt>{@code schematron.svrl.file}</dt>
+ *   <dd>
+ *     absolute URI to a file to write the results of schematron
+ *     validation in SVRL format. This property is not thread safe and
+ *     will overwrite existing files--it is intended primarily for
+ *     debugging with single file validation.
+ *   </dd>
+ * </dl>
+ *
+ * <h2>Custom Validators</h2>
  * <p>
- * It is also possible to create a custom validator by doing the following:
+ * Daffodil also supports custom validators. To make a custom validator 
available to Daffodil, follow these steps:
  * <ol>
- *  <li>create a custom Validator class that implements the
+ *  <li>Create a custom class that implements the
  *  {@link org.apache.daffodil.api.validation.Validator} interface</li>
- *  <li>create a custom ValidatorFactory class that implements the
- *  {@link org.apache.daffodil.api.validation.ValidatorFactory} interface, 
whose make method
- *  returns the custom validator from the previous step</li>
- *  <li>Register the created custom Validator Factory by creating a {@link 
org.apache.daffodil.api.validation.ValidatorFactory}
+ *  <li>Create a custom class that implements the
+ *  {@link org.apache.daffodil.api.validation.ValidatorFactory} interface, 
whose {@code make} method
+ *  returns the custom Validator from the previous step</li>
+ *  <li>Register the custom ValidatorFactory by creating a {@link 
org.apache.daffodil.api.validation.ValidatorFactory}
  *  file in {@code META-INF/services/}, its contents being the fully qualified 
name of the custom validator factory</li>
  * </ol>

Review Comment:
   an example of using the new code to validate the schema might be nice.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to