[hibernate-commits] Hibernate SVN: r19637 - in validator/trunk/hibernate-validator/src/main/docbook/en-US: modules and 1 other directory.

hibernate-commits at lists.jboss.org hibernate-commits at lists.jboss.org
Mon May 31 10:55:27 EDT 2010


Author: hardy.ferentschik
Date: 2010-05-31 10:55:26 -0400 (Mon, 31 May 2010)
New Revision: 19637

Added:
   validator/trunk/hibernate-validator/src/main/docbook/en-US/modules/extensions.xml
   validator/trunk/hibernate-validator/src/main/docbook/en-US/modules/programmaticapi.xml
Modified:
   validator/trunk/hibernate-validator/src/main/docbook/en-US/master.xml
   validator/trunk/hibernate-validator/src/main/docbook/en-US/modules/annotationprocessor.xml
   validator/trunk/hibernate-validator/src/main/docbook/en-US/modules/furtherreading.xml
Log:
HV-274 restructured docs to allow new section for programmatic API

Modified: validator/trunk/hibernate-validator/src/main/docbook/en-US/master.xml
===================================================================
--- validator/trunk/hibernate-validator/src/main/docbook/en-US/master.xml	2010-05-31 14:31:14 UTC (rev 19636)
+++ validator/trunk/hibernate-validator/src/main/docbook/en-US/master.xml	2010-05-31 14:55:26 UTC (rev 19637)
@@ -68,7 +68,7 @@
     <xi:include href="modules/integration.xml"
                 xmlns:xi="http://www.w3.org/2001/XInclude"/>
 
-    <xi:include href="modules/annotationprocessor.xml"
+    <xi:include href="modules/extensions.xml"
                 xmlns:xi="http://www.w3.org/2001/XInclude"/>
 
     <xi:include href="modules/furtherreading.xml"

Modified: validator/trunk/hibernate-validator/src/main/docbook/en-US/modules/annotationprocessor.xml
===================================================================
--- validator/trunk/hibernate-validator/src/main/docbook/en-US/modules/annotationprocessor.xml	2010-05-31 14:31:14 UTC (rev 19636)
+++ validator/trunk/hibernate-validator/src/main/docbook/en-US/modules/annotationprocessor.xml	2010-05-31 14:55:26 UTC (rev 19637)
@@ -21,8 +21,8 @@
 <!ENTITY % BOOK_ENTITIES SYSTEM "../hv.ent">
 %BOOK_ENTITIES;
 ]>
-<chapter>
-  <title id="chapter-annotation-processor">Hibernate Validator Annotation
+<section>
+  <title id="annotation-processor">Hibernate Validator Annotation
   Processor (EXPERIMENTAL)</title>
 
   <para>Have you ever caught yourself by unintentionally doing things
@@ -482,4 +482,4 @@
       </listitem>
     </itemizedlist>
   </section>
-</chapter>
+</section>

Added: validator/trunk/hibernate-validator/src/main/docbook/en-US/modules/extensions.xml
===================================================================
--- validator/trunk/hibernate-validator/src/main/docbook/en-US/modules/extensions.xml	                        (rev 0)
+++ validator/trunk/hibernate-validator/src/main/docbook/en-US/modules/extensions.xml	2010-05-31 14:55:26 UTC (rev 19637)
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- $Id$ -->
+<!--
+	~ JBoss, Home of Professional Open Source
+	~ Copyright 2009, Red Hat, Inc. and/or its affiliates, and individual contributors
+	~ by the @authors tag. See the copyright.txt in the distribution for a
+	~ full listing of individual contributors.
+	~
+	~ Licensed under the Apache License, Version 2.0 (the "License");
+	~ you may not use this file except in compliance with the License.
+	~ You may obtain a copy of the License at
+	~ http://www.apache.org/licenses/LICENSE-2.0
+	~ Unless required by applicable law or agreed to in writing, software
+	~ distributed under the License is distributed on an "AS IS" BASIS,
+	~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+	~ See the License for the specific language governing permissions and
+	~ limitations under the License.
+-->
+<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
+"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
+<!ENTITY % BOOK_ENTITIES SYSTEM "../hv.ent">
+%BOOK_ENTITIES;
+]>
+<chapter id="extensions">
+  <title>Hibernate Validator Specific Extensions</title>
+
+  <para>Hibernate Validator offers on top of the Bean Validation requirements additional extensions which are described in the following sections.</para>
+
+  <xi:include href="programmaticapi.xml"
+              xmlns:xi="http://www.w3.org/2001/XInclude"/>
+  <xi:include href="annotationprocessor.xml"
+              xmlns:xi="http://www.w3.org/2001/XInclude"/>
+ 
+</chapter>


Property changes on: validator/trunk/hibernate-validator/src/main/docbook/en-US/modules/extensions.xml
___________________________________________________________________
Name: svn:keywords
   + Id
Name: svn:eol-style
   + native

Modified: validator/trunk/hibernate-validator/src/main/docbook/en-US/modules/furtherreading.xml
===================================================================
--- validator/trunk/hibernate-validator/src/main/docbook/en-US/modules/furtherreading.xml	2010-05-31 14:31:14 UTC (rev 19636)
+++ validator/trunk/hibernate-validator/src/main/docbook/en-US/modules/furtherreading.xml	2010-05-31 14:55:26 UTC (rev 19637)
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<!-- $Id: bootstrapping.xml 17523 2009-09-16 15:51:58Z hardy.ferentschik $ -->
+<!-- $Id$ -->
 <!--
 	~ JBoss, Home of Professional Open Source
 	~ Copyright 2009, Red Hat, Inc. and/or its affiliates, and individual contributors


Property changes on: validator/trunk/hibernate-validator/src/main/docbook/en-US/modules/furtherreading.xml
___________________________________________________________________
Name: svn:keywords
   + Id

Added: validator/trunk/hibernate-validator/src/main/docbook/en-US/modules/programmaticapi.xml
===================================================================
--- validator/trunk/hibernate-validator/src/main/docbook/en-US/modules/programmaticapi.xml	                        (rev 0)
+++ validator/trunk/hibernate-validator/src/main/docbook/en-US/modules/programmaticapi.xml	2010-05-31 14:55:26 UTC (rev 19637)
@@ -0,0 +1,51 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- $Id$ -->
+<!--
+	~ JBoss, Home of Professional Open Source
+	~ Copyright 2009, Red Hat, Inc. and/or its affiliates, and individual contributors
+	~ by the @authors tag. See the copyright.txt in the distribution for a
+	~ full listing of individual contributors.
+	~
+	~ Licensed under the Apache License, Version 2.0 (the "License");
+	~ you may not use this file except in compliance with the License.
+	~ You may obtain a copy of the License at
+	~ http://www.apache.org/licenses/LICENSE-2.0
+	~ Unless required by applicable law or agreed to in writing, software
+	~ distributed under the License is distributed on an "AS IS" BASIS,
+	~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+	~ See the License for the specific language governing permissions and
+	~ limitations under the License.
+-->
+<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
+"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
+<!ENTITY % BOOK_ENTITIES SYSTEM "../hv.ent">
+%BOOK_ENTITIES;
+]>
+<section id="programmaticapi">
+  <title>Programmatic constraint definitions</title>
+
+  <para><example>
+      <title>Creating a Hibernate Validator specific configuration</title>
+
+      <programlisting>HibernateValidatorConfiguration config = Validation.byProvider( HibernateValidator.class ).configure();</programlisting>
+    </example></para>
+
+  <para><example>
+      <title>Programmatic constraint definition</title>
+
+      <programlisting>ConstraintMapping mapping = new ConstraintMapping();
+mapping.type( Marathon.class )
+    .property( "name", METHOD )
+        .constraint( NotNullDef.class )
+    .property( "numberOfHelpers", FIELD )
+        .constraint( MinDef.class ).value( 1 );
+
+
+HibernateValidatorConfiguration config = Validation.byProvider( HibernateValidator.class ).configure();
+ValidatorFactory factory = config.buildValidatorFactory();
+Validator validator = factory.getValidator();
+validator.validate( new Marathon() );</programlisting>
+
+      <para></para>
+    </example></para>
+</section>


Property changes on: validator/trunk/hibernate-validator/src/main/docbook/en-US/modules/programmaticapi.xml
___________________________________________________________________
Name: svn:keywords
   + Id
Name: svn:eol-style
   + native



More information about the hibernate-commits mailing list