bval-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mben...@apache.org
Subject svn commit: r1766546 [7/7] - in /bval/trunk: bval-core/src/main/java/org/apache/bval/ bval-core/src/main/java/org/apache/bval/model/ bval-core/src/main/java/org/apache/bval/util/ bval-core/src/main/java/org/apache/bval/util/reflection/ bval-core/src/te...
Date Tue, 25 Oct 2016 15:34:38 GMT
Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/example/SizeTestEntity.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/example/SizeTestEntity.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/example/SizeTestEntity.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/example/SizeTestEntity.java Tue Oct 25 15:34:35 2016
@@ -26,31 +26,31 @@ import java.util.Map;
  * Description: <br/>
  */
 public class SizeTestEntity {
-    @Size(max=2)
-    public Map<String,String> map;
-    @Size(max=2)
+    @Size(max = 2)
+    public Map<String, String> map;
+    @Size(max = 2)
     public Collection<String> coll;
-    @Size(max=2)
+    @Size(max = 2)
     public String text;
 
-    @Size(max=2)
+    @Size(max = 2)
     public Object[] oa;
-    @Size(max=2)
+    @Size(max = 2)
     public byte[] ba;
-    @Size(max=2)
+    @Size(max = 2)
     public int[] it;
-    @Size(max=2)
+    @Size(max = 2)
     public Integer[] oa2;
-    @Size(max=2)
+    @Size(max = 2)
     public boolean[] boa;
-    @Size(max=2)
+    @Size(max = 2)
     public char[] ca;
-    @Size(max=2)
+    @Size(max = 2)
     public double[] da;
-    @Size(max=2)
+    @Size(max = 2)
     public float[] fa;
-    @Size(max=2)
+    @Size(max = 2)
     public long[] la;
-    @Size(max=2)
+    @Size(max = 2)
     public short[] sa;
 }

Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/example/ZipCodeCityCarrier.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/example/ZipCodeCityCarrier.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/example/ZipCodeCityCarrier.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/example/ZipCodeCityCarrier.java Tue Oct 25 15:34:35 2016
@@ -23,5 +23,6 @@ package org.apache.bval.jsr.example;
  */
 public interface ZipCodeCityCarrier {
     String getZipCode();
+
     String getCity();
 }

Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/extensions/ExampleMethodService.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/extensions/ExampleMethodService.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/extensions/ExampleMethodService.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/extensions/ExampleMethodService.java Tue Oct 25 15:34:35 2016
@@ -18,7 +18,6 @@
  */
 package org.apache.bval.jsr.extensions;
 
-
 import org.apache.bval.constraints.NotEmpty;
 
 import javax.validation.Valid;
@@ -42,28 +41,28 @@ public class ExampleMethodService {
     public String concat(@NotNull @NotEmpty String s1, @NotNull String s2) {
         return s1 + s2;
     }
-    
-    public void save(@Pattern(regexp="[a-f0-9]{4}") String data) {
-    	return;
+
+    public void save(@Pattern(regexp = "[a-f0-9]{4}") String data) {
+        return;
     }
-    
+
     @NotNull
-    @Size(min=3,max=10)
-    public String echo(@NotNull @Size(min=3,max=10) String str) {
-    	return str;
+    @Size(min = 3, max = 10)
+    public String echo(@NotNull @Size(min = 3, max = 10) String str) {
+        return str;
     }
-    
+
     public void personOp1(@Valid Person p) {
         return;
     }
-    
+
     public void personOp2(@NotNull @Valid Person p) {
         return;
     }
-    
+
     public static class Person {
         @NotNull
         String name;
     }
-    
+
 }

Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/extensions/MethodValidatorImplTest.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/extensions/MethodValidatorImplTest.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/extensions/MethodValidatorImplTest.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/extensions/MethodValidatorImplTest.java Tue Oct 25 15:34:35 2016
@@ -103,9 +103,9 @@ public class MethodValidatorImplTest ext
         ExampleMethodService service = new ExampleMethodService();
         ExecutableValidator mv = getValidator().unwrap(ExecutableValidator.class);
         Constructor constructor = service.getClass().getConstructor(String.class, String.class);
-        String[] params = new String[] {"Hello ", "world" };
-        
-        assertTrue(mv.<ExampleMethodService>validateConstructorParameters(constructor, params).isEmpty());
+        String[] params = new String[] { "Hello ", "world" };
+
+        assertTrue(mv.<ExampleMethodService> validateConstructorParameters(constructor, params).isEmpty());
 
         params[0] = "";
         assertEquals(1, mv.validateConstructorParameters(constructor, params).size());
@@ -154,7 +154,8 @@ public class MethodValidatorImplTest ext
         assertTrue("No violations expected", mv.validateParameters(service, personOp1, new Object[] { p }).isEmpty());
 
         // validate with null person
-        assertTrue("No violations expected", mv.validateParameters(service, personOp1, new Object[] { null }).isEmpty());
+        assertTrue("No violations expected",
+            mv.validateParameters(service, personOp1, new Object[] { null }).isEmpty());
     }
 
     public void testValidateNotNullValidParam() throws NoSuchMethodException {
@@ -164,7 +165,8 @@ public class MethodValidatorImplTest ext
         Method personOp2 = service.getClass().getMethod("personOp2", Person.class);
 
         // Validate with null person
-        assertEquals("Expected 1 violation", 1, mv.validateParameters(service, personOp2, new Object[] { null }).size());
+        assertEquals("Expected 1 violation", 1,
+            mv.validateParameters(service, personOp2, new Object[] { null }).size());
 
         // Validate with invalid person
         Person p = new ExampleMethodService.Person();
@@ -209,7 +211,6 @@ public class MethodValidatorImplTest ext
     }
 
     private Validator getValidator() {
-        return Validation.byProvider(ApacheValidationProvider.class).configure()
-            .buildValidatorFactory().getValidator();
+        return Validation.byProvider(ApacheValidationProvider.class).configure().buildValidatorFactory().getValidator();
     }
 }

Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/BillableUser.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/BillableUser.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/BillableUser.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/BillableUser.java Tue Oct 25 15:34:35 2016
@@ -32,7 +32,7 @@ public class BillableUser {
     @NotNull(groups = Default.class)
     private String lastname;
 
-    @NotNull(groups = {Billable.class, BuyInOneClick.class})
+    @NotNull(groups = { Billable.class, BuyInOneClick.class })
     private BillableCreditCard defaultCreditCard;
 
     public String getFirstname() {

Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/CyclicGroupSequence2.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/CyclicGroupSequence2.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/CyclicGroupSequence2.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/CyclicGroupSequence2.java Tue Oct 25 15:34:35 2016
@@ -23,7 +23,7 @@ import javax.validation.GroupSequence;
 /**
  * Description: <br/>
  */
-@GroupSequence( value = CyclicGroupSequence1.class)
+@GroupSequence(value = CyclicGroupSequence1.class)
 public interface CyclicGroupSequence2 {
 
 }

Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/DefaultGroupSequenceTest.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/DefaultGroupSequenceTest.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/DefaultGroupSequenceTest.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/DefaultGroupSequenceTest.java Tue Oct 25 15:34:35 2016
@@ -82,7 +82,6 @@ public class DefaultGroupSequenceTest ex
         chain.assertDefaultGroupSequenceIsExpandable(defaultSequence);
     }
 
-
     public void testAssertDefaulGroupSequenceIsExpandableWithDefaultAtBeginningOfSequence() {
         // create a dummy sequence
         Group a = new Group(GroupA.class);
@@ -104,7 +103,6 @@ public class DefaultGroupSequenceTest ex
         defaultSequence.add(new Group(GroupA.class));
         chain.assertDefaultGroupSequenceIsExpandable(defaultSequence);
 
-
         defaultSequence.clear();
         defaultSequence.add(new Group(GroupA.class));
         defaultSequence.add(Group.DEFAULT);

Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/GClass2.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/GClass2.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/GClass2.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/GClass2.java Tue Oct 25 15:34:35 2016
@@ -23,6 +23,6 @@ import javax.validation.GroupSequence;
 /**
  * Description: <br/>
  */
-@GroupSequence({GClass1.class, GClass2.class})
+@GroupSequence({ GClass1.class, GClass2.class })
 public class GClass2 extends GClass1 {
 }

Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/GClass3.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/GClass3.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/GClass3.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/GClass3.java Tue Oct 25 15:34:35 2016
@@ -23,6 +23,6 @@ import javax.validation.GroupSequence;
 /**
  * Description: <br/>
  */
-@GroupSequence({GClass3.class, GClass1.class})
+@GroupSequence({ GClass3.class, GClass1.class })
 public class GClass3 {
 }

Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/GroupSequenceIsolationTest.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/GroupSequenceIsolationTest.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/GroupSequenceIsolationTest.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/GroupSequenceIsolationTest.java Tue Oct 25 15:34:35 2016
@@ -41,7 +41,7 @@ import org.junit.Test;
  * @author Carlos Vara
  */
 public class GroupSequenceIsolationTest extends ValidationTestBase {
-    
+
     /**
      * When validating the {@link Default} group in a bean whose class doesn't
      * define a {@link GroupSequence}, all the classes in the hierarchy must be
@@ -56,7 +56,7 @@ public class GroupSequenceIsolationTest
 
         h.a1 = "good";
         assertEquals(set("a2", "b2"), violationPaths(validator.validate(h)));
-        
+
         h.b2 = "good";
         assertEquals(set("a2", "b1"), violationPaths(validator.validate(h)));
 
@@ -97,9 +97,9 @@ public class GroupSequenceIsolationTest
         return result;
     }
 
-    @GroupSequence({GroupA1.class, A.class})
+    @GroupSequence({ GroupA1.class, A.class })
     public static class A {
-        @NotNull(groups={GroupA1.class})
+        @NotNull(groups = { GroupA1.class })
         public String a1;
         @NotNull
         public String a2;
@@ -108,9 +108,9 @@ public class GroupSequenceIsolationTest
     public interface GroupA1 {
     }
 
-    @GroupSequence({B.class, GroupB1.class})
+    @GroupSequence({ B.class, GroupB1.class })
     public static class B extends A {
-        @NotNull(groups={GroupB1.class})
+        @NotNull(groups = { GroupB1.class })
         public String b1;
         @NotNull
         public String b2;
@@ -123,7 +123,7 @@ public class GroupSequenceIsolationTest
     public static class HolderWithNoGS extends B {
     }
 
-    @GroupSequence({GroupA1.class, HolderWithGS.class, GroupB1.class})
+    @GroupSequence({ GroupA1.class, HolderWithGS.class, GroupB1.class })
     public static class HolderWithGS extends B {
     }
 }

Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/GroupSequenceTest.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/GroupSequenceTest.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/GroupSequenceTest.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/GroupSequenceTest.java Tue Oct 25 15:34:35 2016
@@ -48,8 +48,7 @@ public class GroupSequenceTest extends V
     @Test
     public void testGroupSequence1() {
         MetaBean metaBean =
-              ApacheValidatorFactory.getDefault().usingContext().getMetaBeanFinder()
-                    .findForClass(GInterface1.class);
+            ApacheValidatorFactory.getDefault().usingContext().getMetaBeanFinder().findForClass(GInterface1.class);
         List<Group> gseq = metaBean.getFeature(JsrFeatures.Bean.GROUP_SEQUENCE);
         assertNotNull(gseq);
         assertEquals(1, gseq.size());
@@ -59,8 +58,7 @@ public class GroupSequenceTest extends V
     @Test
     public void testGroupSequence2() {
         MetaBean metaBean =
-              ApacheValidatorFactory.getDefault().usingContext().getMetaBeanFinder()
-                    .findForClass(GClass1.class);
+            ApacheValidatorFactory.getDefault().usingContext().getMetaBeanFinder().findForClass(GClass1.class);
         List<Group> gseq = metaBean.getFeature(JsrFeatures.Bean.GROUP_SEQUENCE);
         assertNotNull(gseq);
         assertEquals(1, gseq.size());
@@ -70,8 +68,7 @@ public class GroupSequenceTest extends V
     @Test
     public void testGroupSequence3() {
         MetaBean metaBean =
-              ApacheValidatorFactory.getDefault().usingContext().getMetaBeanFinder()
-                    .findForClass(GClass2.class);
+            ApacheValidatorFactory.getDefault().usingContext().getMetaBeanFinder().findForClass(GClass2.class);
         List<Group> gseq = metaBean.getFeature(JsrFeatures.Bean.GROUP_SEQUENCE);
         assertNotNull(gseq);
         assertEquals(2, gseq.size());
@@ -82,8 +79,7 @@ public class GroupSequenceTest extends V
     @Test
     public void testGroupSequence4() {
         MetaBean metaBean =
-              ApacheValidatorFactory.getDefault().usingContext().getMetaBeanFinder()
-                    .findForClass(GClass3.class);
+            ApacheValidatorFactory.getDefault().usingContext().getMetaBeanFinder().findForClass(GClass3.class);
         List<Group> gseq = metaBean.getFeature(JsrFeatures.Bean.GROUP_SEQUENCE);
         assertNotNull(gseq);
         assertEquals(2, gseq.size());
@@ -101,7 +97,7 @@ public class GroupSequenceTest extends V
         book.setAuthor(author);
 
         Set<ConstraintViolation<Book>> constraintViolations =
-              validator.validate(book, First.class, Second.class, Last.class);
+            validator.validate(book, First.class, Second.class, Last.class);
         assertEquals("Wrong number of constraints", 3, constraintViolations.size());
         assertNotNull(TestUtils.getViolation(constraintViolations, "title"));
         assertNotNull(TestUtils.getViolation(constraintViolations, "author.firstName"));
@@ -154,8 +150,7 @@ public class GroupSequenceTest extends V
         Book book = new Book();
         book.setAuthor(author);
 
-        Set<ConstraintViolation<Book>> constraintViolations =
-              validator.validate(book, Book.All.class);
+        Set<ConstraintViolation<Book>> constraintViolations = validator.validate(book, Book.All.class);
         assertEquals(2, constraintViolations.size());
 
         author.setFirstName("Kelvin");
@@ -190,10 +185,10 @@ public class GroupSequenceTest extends V
         assertEquals("Group1 should be evaluated first", "field1", violation.getPropertyPath().toString());
     }
 
-    @GroupSequence({Dummy.Group1.class, Dummy.class})
+    @GroupSequence({ Dummy.Group1.class, Dummy.class })
     public static class Dummy {
 
-        @NotNull(groups=Group1.class)
+        @NotNull(groups = Group1.class)
         public String field1;
 
         @NotNull

Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/GroupsComputerTest.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/GroupsComputerTest.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/GroupsComputerTest.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/GroupsComputerTest.java Tue Oct 25 15:34:35 2016
@@ -136,7 +136,6 @@ public class GroupsComputerTest extends
         assertEquals(2, chain.groups.size());
     }
 
-
     public void testSequenceResolution() {
         Set<Class<?>> groups = new HashSet<Class<?>>();
         groups.add(Address.Complete.class);

Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/implicit/Auditable.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/implicit/Auditable.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/implicit/Auditable.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/implicit/Auditable.java Tue Oct 25 15:34:35 2016
@@ -25,9 +25,15 @@ import javax.validation.constraints.NotN
  * Example 3.7. Example of interface / group hosting constraints
  */
 public interface Auditable {
-    @NotNull String getCreationDate();
+    @NotNull
+    String getCreationDate();
+
     @NotNull
     String getLastUpdate();
-    @NotNull String getLastModifier();
-    @NotNull String getLastReader();
+
+    @NotNull
+    String getLastModifier();
+
+    @NotNull
+    String getLastReader();
 }

Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/implicit/Order.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/implicit/Order.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/implicit/Order.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/implicit/Order.java Tue Oct 25 15:34:35 2016
@@ -53,7 +53,7 @@ public class Order implements Auditable
     }
 
     @NotNull
-    @Size(min=10, max=10)
+    @Size(min = 10, max = 10)
     public String getOrderNumber() {
         return this.orderNumber;
     }

Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/inheritance/BillableUser.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/inheritance/BillableUser.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/inheritance/BillableUser.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/inheritance/BillableUser.java Tue Oct 25 15:34:35 2016
@@ -18,7 +18,6 @@
  */
 package org.apache.bval.jsr.groups.inheritance;
 
-
 import org.apache.bval.jsr.groups.Billable;
 import org.apache.bval.jsr.groups.BillableCreditCard;
 
@@ -35,7 +34,7 @@ public class BillableUser {
     @NotNull(groups = Default.class)
     private String lastname;
 
-    @NotNull(groups = {Billable.class})
+    @NotNull(groups = { Billable.class })
     private BillableCreditCard defaultCreditCard;
 
     public String getFirstname() {

Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/inheritance/BuyInOneClick.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/inheritance/BuyInOneClick.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/inheritance/BuyInOneClick.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/inheritance/BuyInOneClick.java Tue Oct 25 15:34:35 2016
@@ -18,7 +18,6 @@
  */
 package org.apache.bval.jsr.groups.inheritance;
 
-
 import org.apache.bval.jsr.groups.Billable;
 
 import javax.validation.groups.Default;

Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/inheritance/GroupInheritanceTest.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/inheritance/GroupInheritanceTest.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/inheritance/GroupInheritanceTest.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/inheritance/GroupInheritanceTest.java Tue Oct 25 15:34:35 2016
@@ -47,8 +47,7 @@ public class GroupInheritanceTest extend
     public void testValidGroupBuyInOneClick() {
         BillableUser user = new BillableUser();
 
-        Set<ConstraintViolation<BillableUser>> violations =
-              validator.validate(user, BuyInOneClick.class);
+        Set<ConstraintViolation<BillableUser>> violations = validator.validate(user, BuyInOneClick.class);
         assertEquals(3, violations.size());
         assertNotNull(TestUtils.getViolation(violations, "firstname"));
         assertNotNull(TestUtils.getViolation(violations, "lastname"));

Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/redefining/Address.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/redefining/Address.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/redefining/Address.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/redefining/Address.java Tue Oct 25 15:34:35 2016
@@ -18,7 +18,6 @@
  */
 package org.apache.bval.jsr.groups.redefining;
 
-
 import org.apache.bval.constraints.ZipCodeCityCoherence;
 import org.apache.bval.jsr.example.ZipCodeCityCarrier;
 
@@ -32,28 +31,30 @@ import javax.validation.constraints.Size
  * this sequence expresses the sequence of groups that does
  * substitute Default for this class.
  */
-@GroupSequence({Address.class, Address.HighLevelCoherence.class, Address.ExtraCareful.class })
+@GroupSequence({ Address.class, Address.HighLevelCoherence.class, Address.ExtraCareful.class })
 @ZipCodeCityCoherence(groups = Address.HighLevelCoherence.class)
 public class Address implements ZipCodeCityCarrier {
-    
+
     /**
      * check coherence on the overall object
      * Needs basic checking to be green first
      */
-    public interface HighLevelCoherence {}
-    
+    public interface HighLevelCoherence {
+    }
+
     /**
      * Extra-careful validation group.
      */
-    public interface ExtraCareful {}
+    public interface ExtraCareful {
+    }
 
     @NotNull
     @Size(max = 50, min = 1, groups = ExtraCareful.class)
     private String street1;
 
-    @NotNull 
+    @NotNull
     private String zipCode;
-    
+
     @NotNull
     @Size(max = 30)
     private String city;

Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/redefining/InvalidRedefinedDefaultGroupAddress.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/redefining/InvalidRedefinedDefaultGroupAddress.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/redefining/InvalidRedefinedDefaultGroupAddress.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/redefining/InvalidRedefinedDefaultGroupAddress.java Tue Oct 25 15:34:35 2016
@@ -21,13 +21,12 @@ package org.apache.bval.jsr.groups.redef
 import javax.validation.GroupSequence;
 import javax.validation.constraints.NotNull;
 
-
 /**
  * If a @GroupSequence redefining the Default group for a class A does not
  * contain the group A, a GroupDefinitionException is raised when the class is
  * validated or when its metadata is requested.
  */
-@GroupSequence({Address.class, Address.HighLevelCoherence.class})
+@GroupSequence({ Address.class, Address.HighLevelCoherence.class })
 public class InvalidRedefinedDefaultGroupAddress {
     @NotNull(groups = Address.HighLevelCoherence.class)
     private String street;
@@ -39,6 +38,7 @@ public class InvalidRedefinedDefaultGrou
      * check coherence on the overall object
      * Needs basic checking to be green first
      */
-    public interface HighLevelCoherence {}
+    public interface HighLevelCoherence {
+    }
 
 }

Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/redefining/RedefiningDefaultGroupTest.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/redefining/RedefiningDefaultGroupTest.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/redefining/RedefiningDefaultGroupTest.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/groups/redefining/RedefiningDefaultGroupTest.java Tue Oct 25 15:34:35 2016
@@ -69,9 +69,7 @@ public class RedefiningDefaultGroupTest
          * the group sequence defined on the Address class is used.
          */
         violations = validator.validate(address);
-        assertEquals(
-              "redefined default group for Address must also validate HighLevelCoherence",
-              1, violations.size());
+        assertEquals("redefined default group for Address must also validate HighLevelCoherence", 1, violations.size());
     }
 
     @Test

Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/util/TestUtils.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/util/TestUtils.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/util/TestUtils.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/util/TestUtils.java Tue Oct 25 15:34:35 2016
@@ -103,7 +103,8 @@ public class TestUtils {
      * @param constraintFinder
      * @param types
      */
-    public static void assertConstraintTypesFound(ConstraintFinder constraintFinder, Class<? extends Annotation>... types) {
+    public static void assertConstraintTypesFound(ConstraintFinder constraintFinder,
+        Class<? extends Annotation>... types) {
         outer: for (Class<? extends Annotation> type : types) {
             for (ConstraintDescriptor<?> descriptor : constraintFinder.getConstraintDescriptors()) {
                 if (descriptor.getAnnotation().annotationType().equals(type)) {

Modified: bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/xml/ValidationParserTest.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/xml/ValidationParserTest.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/xml/ValidationParserTest.java (original)
+++ bval/trunk/bval-jsr/src/test/java/org/apache/bval/jsr/xml/ValidationParserTest.java Tue Oct 25 15:34:35 2016
@@ -62,7 +62,8 @@ public class ValidationParserTest implem
         assertNotNull(ValidationParser.getInputStream("sample-validation.xml"));
 
         // make sure there are duplicate resources on the classpath before the next checks:
-        final Enumeration<URL> resources = Reflection.getClassLoader(ValidationParser.class).getResources("META-INF/MANIFEST.MF");
+        final Enumeration<URL> resources =
+            Reflection.getClassLoader(ValidationParser.class).getResources("META-INF/MANIFEST.MF");
 
         assumeTrue(resources.hasMoreElements());
         resources.nextElement();
@@ -92,8 +93,7 @@ public class ValidationParserTest implem
     }
 
     private ValidatorFactory getFactory() {
-        ApacheValidatorConfiguration config =
-              Validation.byProvider(ApacheValidationProvider.class).configure();
+        ApacheValidatorConfiguration config = Validation.byProvider(ApacheValidationProvider.class).configure();
         config.addProperty(VALIDATION_XML_PATH, "sample-validation.xml");
         return config.buildValidatorFactory();
     }

Modified: bval/trunk/bval-tck11/src/main/java/org/apache/bval/arquillian/EJBEnricher.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-tck11/src/main/java/org/apache/bval/arquillian/EJBEnricher.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-tck11/src/main/java/org/apache/bval/arquillian/EJBEnricher.java (original)
+++ bval/trunk/bval-tck11/src/main/java/org/apache/bval/arquillian/EJBEnricher.java Tue Oct 25 15:34:35 2016
@@ -36,7 +36,8 @@ public class EJBEnricher implements Test
                     for (final Field f : field.getType().getDeclaredFields()) {
                         if (f.getAnnotation(Resource.class) != null) {
                             if (f.getType().equals(Validator.class)) {
-                                f.set(instance, Validation.byDefaultProvider().configure().buildValidatorFactory().getValidator());
+                                f.set(instance,
+                                    Validation.byDefaultProvider().configure().buildValidatorFactory().getValidator());
                             } else if (f.getType().equals(ValidatorFactory.class)) {
                                 f.set(instance, Validation.byDefaultProvider().configure().buildValidatorFactory());
                             }

Modified: bval/trunk/bval-tck11/src/main/java/org/apache/bval/arquillian/jndi/BValJndiFactory.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-tck11/src/main/java/org/apache/bval/arquillian/jndi/BValJndiFactory.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-tck11/src/main/java/org/apache/bval/arquillian/jndi/BValJndiFactory.java (original)
+++ bval/trunk/bval-tck11/src/main/java/org/apache/bval/arquillian/jndi/BValJndiFactory.java Tue Oct 25 15:34:35 2016
@@ -31,18 +31,19 @@ import java.util.Hashtable;
 public class BValJndiFactory implements InitialContextFactory {
     public Context getInitialContext(final Hashtable<?, ?> environment) throws NamingException {
         return Context.class.cast(Proxy.newProxyInstance(Thread.currentThread().getContextClassLoader(),
-                new Class<?>[] { Context.class }, new InvocationHandler() {
-            public Object invoke(final Object proxy, final Method method, final Object[] args) throws Throwable {
-                if (method.getName().equals("lookup") && args != null && args.length == 1 && String.class.isInstance(args[0])) {
-                    if ("java:comp/ValidatorFactory".equals(args[0])) {
-                        return Validation.byDefaultProvider().configure().buildValidatorFactory();
-                    }
-                    if ("java:comp/Validator".equals(args[0])) {
-                        return Validation.byDefaultProvider().configure().buildValidatorFactory().getValidator();
+            new Class<?>[] { Context.class }, new InvocationHandler() {
+                public Object invoke(final Object proxy, final Method method, final Object[] args) throws Throwable {
+                    if (method.getName().equals("lookup") && args != null && args.length == 1
+                        && String.class.isInstance(args[0])) {
+                        if ("java:comp/ValidatorFactory".equals(args[0])) {
+                            return Validation.byDefaultProvider().configure().buildValidatorFactory();
+                        }
+                        if ("java:comp/Validator".equals(args[0])) {
+                            return Validation.byDefaultProvider().configure().buildValidatorFactory().getValidator();
+                        }
                     }
+                    return null;
                 }
-                return null;
-            }
-        }));
+            }));
     }
 }

Modified: bval/trunk/bval-xstream/src/main/java/org/apache/bval/routines/EMailValidation.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-xstream/src/main/java/org/apache/bval/routines/EMailValidation.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-xstream/src/main/java/org/apache/bval/routines/EMailValidation.java (original)
+++ bval/trunk/bval-xstream/src/main/java/org/apache/bval/routines/EMailValidation.java Tue Oct 25 15:34:35 2016
@@ -16,7 +16,6 @@
  */
 package org.apache.bval.routines;
 
-
 import org.apache.bval.model.Validation;
 import org.apache.bval.model.ValidationContext;
 import org.apache.bval.model.ValidationListener;
@@ -32,7 +31,8 @@ public class EMailValidation implements
 
     @Override
     public <T extends ValidationListener> void validate(ValidationContext<T> context) {
-        if (context.getPropertyValue() == null) return;
+        if (context.getPropertyValue() == null)
+            return;
         if (!EMailValidationUtils.isValid(context.getPropertyValue(), getPattern())) {
             context.getListener().addError(Reasons.EMAIL_ADDRESS, context);
         }

Modified: bval/trunk/bval-xstream/src/main/java/org/apache/bval/routines/StandardValidation.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-xstream/src/main/java/org/apache/bval/routines/StandardValidation.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-xstream/src/main/java/org/apache/bval/routines/StandardValidation.java (original)
+++ bval/trunk/bval-xstream/src/main/java/org/apache/bval/routines/StandardValidation.java Tue Oct 25 15:34:35 2016
@@ -61,8 +61,10 @@ public class StandardValidation implemen
 
     protected <T extends ValidationListener> void validateTimeLag(ValidationContext<T> context) {
         String lag = (String) context.getMetaProperty().getFeature(TIME_LAG);
-        if (lag == null) return;
-        if (context.getPropertyValue() == null) return;
+        if (lag == null)
+            return;
+        if (context.getPropertyValue() == null)
+            return;
         long date = ((Date) context.getPropertyValue()).getTime();
         long now = System.currentTimeMillis();
         if (XMLMetaValue.TIMELAG_Future.equals(lag)) {
@@ -83,8 +85,10 @@ public class StandardValidation implemen
     protected <T extends ValidationListener> void validateRegExp(ValidationContext<T> context) {
         final MetaProperty meta = context.getMetaProperty();
         final String regExp = (String) meta.getFeature(REG_EXP);
-        if (regExp == null) return;
-        if (context.getPropertyValue() == null) return;
+        if (regExp == null)
+            return;
+        if (context.getPropertyValue() == null)
+            return;
 
         final String value = String.valueOf(context.getPropertyValue());
         try {
@@ -97,15 +101,15 @@ public class StandardValidation implemen
                 context.getListener().addError(REG_EXP, context);
             }
         } catch (PatternSyntaxException e) {
-            throw new IllegalArgumentException(
-                  "regular expression malformed. regexp " + regExp + " at " + context, e);
+            throw new IllegalArgumentException("regular expression malformed. regexp " + regExp + " at " + context, e);
         }
     }
 
     protected <T extends ValidationListener> void validateMinValue(ValidationContext<T> context) {
         @SuppressWarnings("unchecked")
         Comparable<Object> minValue = (Comparable<Object>) context.getMetaProperty().getFeature(MIN_VALUE);
-        if (minValue == null || context.getPropertyValue() == null) return;
+        if (minValue == null || context.getPropertyValue() == null)
+            return;
         if (compare(context, minValue, context.getPropertyValue()) > 0) {
             context.getListener().addError(MIN_VALUE, context);
         }
@@ -114,14 +118,15 @@ public class StandardValidation implemen
     protected <T extends ValidationListener> void validateMaxValue(ValidationContext<T> context) {
         @SuppressWarnings("unchecked")
         Comparable<Object> maxValue = (Comparable<Object>) context.getMetaProperty().getFeature(MAX_VALUE);
-        if (maxValue == null || context.getPropertyValue() == null) return;
+        if (maxValue == null || context.getPropertyValue() == null)
+            return;
         if (compare(context, maxValue, context.getPropertyValue()) < 0) {
             context.getListener().addError(MAX_VALUE, context);
         }
     }
 
     private <T extends ValidationListener> int compare(ValidationContext<T> context, Comparable<Object> constraintValue,
-                        Object currentValue) {
+        Object currentValue) {
         int r;
         if (constraintValue.getClass().isAssignableFrom(currentValue.getClass())) {
             r = constraintValue.compareTo(context.getPropertyValue());
@@ -136,10 +141,11 @@ public class StandardValidation implemen
     }
 
     protected <T extends ValidationListener> void validateMaxLength(ValidationContext<T> context) {
-        Integer maxLength = (Integer) context.getMetaProperty()
-              .getFeature(Features.Property.MAX_LENGTH);
-        if (maxLength == null) return;
-        if (context.getPropertyValue() == null) return;
+        Integer maxLength = (Integer) context.getMetaProperty().getFeature(Features.Property.MAX_LENGTH);
+        if (maxLength == null)
+            return;
+        if (context.getPropertyValue() == null)
+            return;
 
         final Object value = context.getPropertyValue();
         int length = 0;
@@ -154,10 +160,11 @@ public class StandardValidation implemen
     }
 
     protected <T extends ValidationListener> void validateMinLength(ValidationContext<T> context) {
-        Integer maxLength = (Integer) context.getMetaProperty()
-              .getFeature(Features.Property.MIN_LENGTH);
-        if (maxLength == null) return;
-        if (context.getPropertyValue() == null) return;
+        Integer maxLength = (Integer) context.getMetaProperty().getFeature(Features.Property.MIN_LENGTH);
+        if (maxLength == null)
+            return;
+        if (context.getPropertyValue() == null)
+            return;
 
         final Object value = context.getPropertyValue();
         int length = 0;

Modified: bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/MetaBeanEnricher.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/MetaBeanEnricher.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/MetaBeanEnricher.java (original)
+++ bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/MetaBeanEnricher.java Tue Oct 25 15:34:35 2016
@@ -16,7 +16,6 @@
  */
 package org.apache.bval.xml;
 
-
 import org.apache.bval.model.MetaBean;
 
 import java.util.Map;

Modified: bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLFeaturesCapable.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLFeaturesCapable.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLFeaturesCapable.java (original)
+++ bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLFeaturesCapable.java Tue Oct 25 15:34:35 2016
@@ -45,7 +45,8 @@ public class XMLFeaturesCapable implemen
 
     public void putFeature(String key, Object value) {
         XMLMetaFeature anno = findFeature(key);
-        if (features == null) features = new ArrayList<XMLMetaFeature>();
+        if (features == null)
+            features = new ArrayList<XMLMetaFeature>();
         if (anno == null) {
             features.add(new XMLMetaFeature(key, value));
         } else {
@@ -66,9 +67,11 @@ public class XMLFeaturesCapable implemen
     }
 
     private XMLMetaFeature findFeature(String key) {
-        if (features == null) return null;
+        if (features == null)
+            return null;
         for (XMLMetaFeature anno : features) {
-            if (key.equals(anno.getKey())) return anno;
+            if (key.equals(anno.getKey()))
+                return anno;
         }
         return null;
     }
@@ -82,7 +85,8 @@ public class XMLFeaturesCapable implemen
     }
 
     public void addValidator(String validatorId) {
-        if (validators == null) validators = new ArrayList<XMLMetaValidatorReference>();
+        if (validators == null)
+            validators = new ArrayList<XMLMetaValidatorReference>();
         validators.add(new XMLMetaValidatorReference(validatorId));
     }
 

Modified: bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMapper.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMapper.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMapper.java (original)
+++ bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMapper.java Tue Oct 25 15:34:35 2016
@@ -28,10 +28,9 @@ public class XMLMapper {
 
     private XMLMapper() {
         xStream = new XStream();
-        xStream.processAnnotations(new Class[] {XMLFeaturesCapable.class,
-                XMLMetaFeature.class, XMLMetaBean.class, XMLMetaBeanInfos.class,
-                XMLMetaBeanReference.class, XMLMetaElement.class, XMLMetaProperty.class,
-                XMLMetaValidator.class, XMLMetaValidatorReference.class});
+        xStream.processAnnotations(new Class[] { XMLFeaturesCapable.class, XMLMetaFeature.class, XMLMetaBean.class,
+            XMLMetaBeanInfos.class, XMLMetaBeanReference.class, XMLMetaElement.class, XMLMetaProperty.class,
+            XMLMetaValidator.class, XMLMetaValidatorReference.class });
         xStream.setMode(XStream.NO_REFERENCES);
     }
 

Modified: bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBean.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBean.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBean.java (original)
+++ bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBean.java Tue Oct 25 15:34:35 2016
@@ -75,7 +75,8 @@ public class XMLMetaBean extends XMLFeat
     }
 
     public void addProperty(XMLMetaProperty property) {
-        if (properties == null) properties = new ArrayList<XMLMetaProperty>();
+        if (properties == null)
+            properties = new ArrayList<XMLMetaProperty>();
         properties.add(property);
     }
 
@@ -102,9 +103,11 @@ public class XMLMetaBean extends XMLFeat
     }
 
     private XMLMetaProperty findProperty(String name) {
-        if (properties == null) return null;
+        if (properties == null)
+            return null;
         for (XMLMetaProperty prop : properties) {
-            if (name.equals(prop.getName())) return prop;
+            if (name.equals(prop.getName()))
+                return prop;
         }
         return null;
     }
@@ -117,9 +120,9 @@ public class XMLMetaBean extends XMLFeat
         this.beanRelations = beanRelations;
     }
 
-
     public void addBeanRef(XMLMetaBeanReference beanRelation) {
-        if (beanRelations == null) beanRelations = new ArrayList<XMLMetaBeanReference>();
+        if (beanRelations == null)
+            beanRelations = new ArrayList<XMLMetaBeanReference>();
         beanRelations.add(beanRelation);
     }
 
@@ -146,9 +149,11 @@ public class XMLMetaBean extends XMLFeat
     }
 
     private XMLMetaBeanReference findBeanRef(String name) {
-        if (beanRelations == null) return null;
+        if (beanRelations == null)
+            return null;
         for (XMLMetaBeanReference relation : beanRelations) {
-            if (name.equals(relation.getName())) return relation;
+            if (name.equals(relation.getName()))
+                return relation;
         }
         return null;
     }

Modified: bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBeanFactory.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBeanFactory.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBeanFactory.java (original)
+++ bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBeanFactory.java Tue Oct 25 15:34:35 2016
@@ -42,7 +42,7 @@ public class XMLMetaBeanFactory implemen
 
     // use LinkedHashMap to keep sequence of loaders
     private final Map<XMLMetaBeanLoader, XMLMetaBeanInfos> resources =
-          new LinkedHashMap<XMLMetaBeanLoader, XMLMetaBeanInfos>();
+        new LinkedHashMap<XMLMetaBeanLoader, XMLMetaBeanInfos>();
 
     private StandardValidation standardValidation = StandardValidation.getInstance();
 
@@ -72,11 +72,11 @@ public class XMLMetaBeanFactory implemen
 
     @Override
     public void buildMetaBean(final MetaBean metaBean) throws Exception {
-        if(metaBean.getId() == null) return;
-         visitXMLBeanMeta(metaBean.getId(), new Visitor() {
+        if (metaBean.getId() == null)
+            return;
+        visitXMLBeanMeta(metaBean.getId(), new Visitor() {
             @Override
-            public void visit(XMLMetaBean xmlMeta, XMLMetaBeanInfos xmlInfos)
-                  throws Exception {
+            public void visit(XMLMetaBean xmlMeta, XMLMetaBeanInfos xmlInfos) throws Exception {
                 enrichMetaBean(metaBean, new XMLResult(xmlMeta, xmlInfos));
             }
 
@@ -112,7 +112,7 @@ public class XMLMetaBeanFactory implemen
         if (result.xmlMeta.getName() != null) {
             meta.setName(result.xmlMeta.getName());
         }
-/*        if (meta.getBeanClass() == null && result.xmlMeta.getImpl() != null) {
+        /*        if (meta.getBeanClass() == null && result.xmlMeta.getImpl() != null) {
             meta.setBeanClass(findLocalClass(result.xmlMeta.getImpl()));
         }*/
         result.xmlMeta.mergeFeaturesInto(meta);
@@ -130,51 +130,44 @@ public class XMLMetaBeanFactory implemen
     }
 
     @SuppressWarnings("deprecation")
-    protected void enrichValidations(FeaturesCapable prop, XMLFeaturesCapable xmlProp,
-                                     XMLResult result, boolean addStandard)
-          throws Exception {
+    protected void enrichValidations(FeaturesCapable prop, XMLFeaturesCapable xmlProp, XMLResult result,
+        boolean addStandard) throws Exception {
         if (xmlProp.getValidators() != null) {
             // obsolete code? remove from here --->
             String[] func = prop.getFeature(JAVASCRIPT_VALIDATION_FUNCTIONS);
-            List<String> jsValidators = new ArrayList<String>(
-                  xmlProp.getValidators().size() + (func == null ? 0 : func.length));
+            List<String> jsValidators =
+                new ArrayList<String>(xmlProp.getValidators().size() + (func == null ? 0 : func.length));
             if (func != null && func.length > 0) {
                 jsValidators.addAll(Arrays.asList(func));
-            }  // <--- to here
+            } // <--- to here
             boolean useStandard = prop instanceof MetaProperty;
             for (XMLMetaValidatorReference valRef : xmlProp.getValidators()) {
-                if (standardValidation != null &&
-                      valRef.getRefId().equals(standardValidation.getValidationId())) {
+                if (standardValidation != null && valRef.getRefId().equals(standardValidation.getValidationId())) {
                     useStandard = false;
                 }
-                XMLMetaValidator validator =
-                      result.xmlInfos.getValidator(valRef.getRefId());
+                XMLMetaValidator validator = result.xmlInfos.getValidator(valRef.getRefId());
                 if (validator != null) {
                     if (validator.getValidation() != null) {
                         prop.addValidation(validator.getValidation());
                     }
-                    if (validator.getJsFunction() != null &&
-                          !jsValidators.contains(validator.getJsFunction())) {
+                    if (validator.getJsFunction() != null && !jsValidators.contains(validator.getJsFunction())) {
                         jsValidators.add(validator.getJsFunction());
                     }
                 }
             }
             if (!jsValidators.isEmpty()) {
-                prop.putFeature(JAVASCRIPT_VALIDATION_FUNCTIONS,
-                      jsValidators.toArray(new String[jsValidators.size()]));
+                prop.putFeature(JAVASCRIPT_VALIDATION_FUNCTIONS, jsValidators.toArray(new String[jsValidators.size()]));
             }
             if (useStandard && standardValidation != null) {
                 if (!prop.hasValidation(standardValidation))
                     prop.addValidation(standardValidation);
             }
-        } else if (addStandard && standardValidation != null &&
-              !prop.hasValidation(standardValidation)) {
+        } else if (addStandard && standardValidation != null && !prop.hasValidation(standardValidation)) {
             prop.addValidation(standardValidation);
         }
     }
 
-    protected MetaProperty enrichElement(MetaBean meta, XMLMetaElement xmlProp,
-                                         XMLResult result) throws Exception {
+    protected MetaProperty enrichElement(MetaBean meta, XMLMetaElement xmlProp, XMLResult result) throws Exception {
         MetaProperty prop = meta.getProperty(xmlProp.getName());
         if (prop == null) {
             prop = new MetaProperty();
@@ -186,10 +179,8 @@ public class XMLMetaBeanFactory implemen
         return prop;
     }
 
-
     public void visitXMLBeanMeta(String beanId, Visitor visitor) throws Exception {
-        for (Map.Entry<XMLMetaBeanLoader, XMLMetaBeanInfos> entry : resources
-              .entrySet()) {
+        for (Map.Entry<XMLMetaBeanLoader, XMLMetaBeanInfos> entry : resources.entrySet()) {
             if (entry.getValue() == null) {
                 // load when not already loaded
                 try {
@@ -217,8 +208,7 @@ public class XMLMetaBeanFactory implemen
      * @return null or the bean found from the first loader that has it.
      */
     protected XMLResult findXMLBeanMeta(String beanId) {
-        for (Map.Entry<XMLMetaBeanLoader, XMLMetaBeanInfos> entry : resources
-              .entrySet()) {
+        for (Map.Entry<XMLMetaBeanLoader, XMLMetaBeanInfos> entry : resources.entrySet()) {
             if (entry.getValue() == null) {
                 // load when not already loaded
                 try {

Modified: bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBeanInfos.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBeanInfos.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBeanInfos.java (original)
+++ bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBeanInfos.java Tue Oct 25 15:34:35 2016
@@ -89,8 +89,10 @@ public class XMLMetaBeanInfos {
     }
 
     public XMLMetaBean getBean(String id) {
-        if (beans == null) return null;
-        if (beanLookup == null) initBeanLookup();
+        if (beans == null)
+            return null;
+        if (beanLookup == null)
+            initBeanLookup();
         return beanLookup.get(id);
     }
 
@@ -106,8 +108,7 @@ public class XMLMetaBeanInfos {
         final HashMap<String, XMLMetaValidator> map = new HashMap<String, XMLMetaValidator>(validators.size());
         for (XMLMetaValidator xv : validators) {
             if (xv.getJava() != null) {
-                Validation validation =
-                        (Validation) Reflection.toClass(xv.getJava()).newInstance();
+                Validation validation = (Validation) Reflection.toClass(xv.getJava()).newInstance();
                 xv.setValidation(validation);
                 map.put(xv.getId(), xv);
             }
@@ -116,18 +117,22 @@ public class XMLMetaBeanInfos {
     }
 
     public void addBean(XMLMetaBean bean) {
-        if (beans == null) beans = new ArrayList<XMLMetaBean>();
+        if (beans == null)
+            beans = new ArrayList<XMLMetaBean>();
         beans.add(bean);
     }
 
     public XMLMetaValidator getValidator(String id) throws Exception {
-        if (validators == null) return null;
-        if (validationLookup == null) initValidationLookup();
+        if (validators == null)
+            return null;
+        if (validationLookup == null)
+            initValidationLookup();
         return validationLookup.get(id);
     }
 
     public void addValidator(XMLMetaValidator validator) {
-        if (validators == null) validators = new ArrayList<XMLMetaValidator>();
+        if (validators == null)
+            validators = new ArrayList<XMLMetaValidator>();
         validators.add(validator);
     }
 }

Modified: bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBeanManagerFactory.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBeanManagerFactory.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBeanManagerFactory.java (original)
+++ bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBeanManagerFactory.java Tue Oct 25 15:34:35 2016
@@ -26,15 +26,15 @@ import org.apache.bval.MetaBeanFinder;
  */
 public class XMLMetaBeanManagerFactory {
     private static XMLMetaBeanManager manager = new XMLMetaBeanManager();
-     /**
-     * global meta bean finder.
-     * @return
-     */
+
+    /**
+    * global meta bean finder.
+    * @return
+    */
     public static MetaBeanFinder getFinder() {
         return manager;
     }
 
-
     /**
      * set global meta bean manager, that is responsible
      * for finding, caching, xml registry and enrichment algorithm.

Modified: bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBeanReference.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBeanReference.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBeanReference.java (original)
+++ bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBeanReference.java Tue Oct 25 15:34:35 2016
@@ -50,7 +50,7 @@ public class XMLMetaBeanReference extend
 
     @Override
     public void mergeInto(MetaProperty prop) throws ClassNotFoundException {
-        super.mergeInto(prop);   // call super!
+        super.mergeInto(prop); // call super!
         if (getBeanId() != null) {
             prop.putFeature(Features.Property.REF_BEAN_ID, getBeanId());
         }

Modified: bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBeanURLLoader.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBeanURLLoader.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBeanURLLoader.java (original)
+++ bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaBeanURLLoader.java Tue Oct 25 15:34:35 2016
@@ -27,7 +27,8 @@ public class XMLMetaBeanURLLoader implem
     private final URL url;
 
     public XMLMetaBeanURLLoader(URL url) {
-        if (url == null) throw new NullPointerException("URL required");
+        if (url == null)
+            throw new NullPointerException("URL required");
         this.url = url;
     }
 
@@ -35,8 +36,7 @@ public class XMLMetaBeanURLLoader implem
     public XMLMetaBeanInfos load() throws IOException {
         InputStream stream = url.openStream();
         try {
-            XMLMetaBeanInfos beanInfos = (XMLMetaBeanInfos) XMLMapper.getInstance()
-                    .getXStream().fromXML(stream);
+            XMLMetaBeanInfos beanInfos = (XMLMetaBeanInfos) XMLMapper.getInstance().getXStream().fromXML(stream);
             beanInfos.setId(url.toExternalForm());
             return beanInfos;
         } finally {

Modified: bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaFeature.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaFeature.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaFeature.java (original)
+++ bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaFeature.java Tue Oct 25 15:34:35 2016
@@ -50,7 +50,6 @@ public class XMLMetaFeature implements S
         this.key = key;
     }
 
-
     public Object getValue() {
         return value;
     }

Modified: bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaProperty.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaProperty.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaProperty.java (original)
+++ bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaProperty.java Tue Oct 25 15:34:35 2016
@@ -53,7 +53,6 @@ public class XMLMetaProperty extends XML
     @XStreamAsAttribute()
     private String timeLag;
 
-
     public Integer getMaxValue() {
         return maxValue;
     }
@@ -88,7 +87,7 @@ public class XMLMetaProperty extends XML
 
     @Override
     public void mergeInto(MetaProperty prop) throws ClassNotFoundException {
-        super.mergeInto(prop);   // call super!
+        super.mergeInto(prop); // call super!
         if (getMaxValue() != null) {
             prop.putFeature(MAX_VALUE, getMaxValue());
         }

Modified: bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaValidator.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaValidator.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaValidator.java (original)
+++ bval/trunk/bval-xstream/src/main/java/org/apache/bval/xml/XMLMetaValidator.java Tue Oct 25 15:34:35 2016
@@ -35,7 +35,7 @@ public class XMLMetaValidator implements
     @XStreamAsAttribute
     private String id;
     @XStreamAsAttribute
-    private String java;  // implementation of Validation
+    private String java; // implementation of Validation
 
     @XStreamAsAttribute
     private String jsFunction; // name of java script function

Modified: bval/trunk/bval-xstream/src/test/java/org/apache/bval/example/BusinessEnum.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-xstream/src/test/java/org/apache/bval/example/BusinessEnum.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-xstream/src/test/java/org/apache/bval/example/BusinessEnum.java (original)
+++ bval/trunk/bval-xstream/src/test/java/org/apache/bval/example/BusinessEnum.java Tue Oct 25 15:34:35 2016
@@ -20,5 +20,5 @@ package org.apache.bval.example;
  * Description: <br/>
  */
 public enum BusinessEnum {
-    VALUE1, VALUE2, VALUE3
+                          VALUE1, VALUE2, VALUE3
 }

Modified: bval/trunk/bval-xstream/src/test/java/org/apache/bval/example/BusinessObjectBeanInfo.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-xstream/src/test/java/org/apache/bval/example/BusinessObjectBeanInfo.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-xstream/src/test/java/org/apache/bval/example/BusinessObjectBeanInfo.java (original)
+++ bval/trunk/bval-xstream/src/test/java/org/apache/bval/example/BusinessObjectBeanInfo.java Tue Oct 25 15:34:35 2016
@@ -33,16 +33,16 @@ public class BusinessObjectBeanInfo exte
     public BeanInfo[] getAdditionalBeanInfo() {
         ExplicitBeanInfo bi = new ExplicitBeanInfo();
         bi.setPropertyDescriptors(_getPropertyDescriptors());
-        return new BeanInfo[]{bi};
+        return new BeanInfo[] { bi };
     }
 
     public PropertyDescriptor[] _getPropertyDescriptors() {
         try {
-            PropertyDescriptor numericValue = new PropertyDescriptor("numericValue",
-                    targetClass, "getNumericValue", "setNumericValue");
+            PropertyDescriptor numericValue =
+                new PropertyDescriptor("numericValue", targetClass, "getNumericValue", "setNumericValue");
             numericValue.setValue(Features.Property.MAX_VALUE, new Integer(100));
             numericValue.setValue(Features.Property.MIN_VALUE, new Integer(-100));
-            return new PropertyDescriptor[]{numericValue};
+            return new PropertyDescriptor[] { numericValue };
         } catch (IntrospectionException ex) {
             ex.printStackTrace();
             return null;

Modified: bval/trunk/bval-xstream/src/test/java/org/apache/bval/routines/StandardValidationTest.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-xstream/src/test/java/org/apache/bval/routines/StandardValidationTest.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-xstream/src/test/java/org/apache/bval/routines/StandardValidationTest.java (original)
+++ bval/trunk/bval-xstream/src/test/java/org/apache/bval/routines/StandardValidationTest.java Tue Oct 25 15:34:35 2016
@@ -155,11 +155,11 @@ public class StandardValidationTest impl
         metaProperty.setName("dateValue");
         Date dt = new Date();
         metaProperty.putFeature(Features.Property.MIN_VALUE, dt);
-        dateValue = new Timestamp(dt.getTime()+1000);
+        dateValue = new Timestamp(dt.getTime() + 1000);
         validation.validateMinValue(context);
         assertTrue(reasons.isEmpty());
         context.unknownValue();
-        dateValue = new Timestamp(dt.getTime()-1000);
+        dateValue = new Timestamp(dt.getTime() - 1000);
         validation.validateMinValue(context);
         assertTrue(reasons.contains(Property.MIN_VALUE));
     }

Modified: bval/trunk/bval-xstream/src/test/java/org/apache/bval/xml/BeanValidatorTest.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-xstream/src/test/java/org/apache/bval/xml/BeanValidatorTest.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-xstream/src/test/java/org/apache/bval/xml/BeanValidatorTest.java (original)
+++ bval/trunk/bval-xstream/src/test/java/org/apache/bval/xml/BeanValidatorTest.java Tue Oct 25 15:34:35 2016
@@ -40,25 +40,22 @@ public class BeanValidatorTest {
 
     @Test
     public void testValidateMapAsBean() {
-        XMLMetaBeanManagerFactory.getRegistry().addLoader(new XMLMetaBeanURLLoader(
-              BusinessObject.class.getResource("test-beanInfos.xml")));
+        XMLMetaBeanManagerFactory.getRegistry()
+            .addLoader(new XMLMetaBeanURLLoader(BusinessObject.class.getResource("test-beanInfos.xml")));
 
-        MetaBean mb = XMLMetaBeanManagerFactory.getFinder()
-              .findForId("org.apache.bval.example.Address");
+        MetaBean mb = XMLMetaBeanManagerFactory.getFinder().findForId("org.apache.bval.example.Address");
 
         // 1. validate a bean
         BusinessObjectAddress adr = new BusinessObjectAddress();
         BeanValidator<ValidationResults> validator = new BeanValidator<ValidationResults>();
         ValidationResults results = validator.validate(adr, mb);
-        assertEquals(2,
-              results.getErrorsByReason().get(Features.Property.MANDATORY).size());
+        assertEquals(2, results.getErrorsByReason().get(Features.Property.MANDATORY).size());
 
         // 2. validate a map with the same metabean
         validator.setTreatMapsLikeBeans(true);
         results = validator.validate(new HashMap<String, Object>(), mb);
         assertFalse(results.isEmpty());
-        assertEquals(2,
-              results.getErrorsByReason().get(Features.Property.MANDATORY).size());
+        assertEquals(2, results.getErrorsByReason().get(Features.Property.MANDATORY).size());
 
         // 3. validate as empty map (jsr303 behavior)
         validator.setTreatMapsLikeBeans(false);
@@ -69,8 +66,8 @@ public class BeanValidatorTest {
     @Test
     public void testValidate() {
         MetaBeanFinder finder = XMLMetaBeanManagerFactory.getFinder();
-        XMLMetaBeanManagerFactory.getRegistry().addLoader(new XMLMetaBeanURLLoader(
-              BusinessObject.class.getResource("test-beanInfos.xml")));
+        XMLMetaBeanManagerFactory.getRegistry()
+            .addLoader(new XMLMetaBeanURLLoader(BusinessObject.class.getResource("test-beanInfos.xml")));
         MetaBean info = finder.findForClass(BusinessObject.class);
         BusinessObject object = new BusinessObject();
         object.setAddress(new BusinessObjectAddress());
@@ -81,9 +78,7 @@ public class BeanValidatorTest {
         assertTrue(results.hasError(object, null));
         assertTrue(results.hasError(object.getAddress(), null));
 
-        assertTrue(
-              validator.validateProperty(object, info.getProperty("firstName")).hasError(
-                    object, "firstName"));
+        assertTrue(validator.validateProperty(object, info.getProperty("firstName")).hasError(object, "firstName"));
 
         object.setUserId(1L);
         object.setFirstName("Hans");
@@ -104,8 +99,7 @@ public class BeanValidatorTest {
 
         // 4th address is too much!
         object.getAddresses().add(object.getAddress());
-        assertFalse(
-              validator.validate(object, info).isEmpty()); // cardinality error found
+        assertFalse(validator.validate(object, info).isEmpty()); // cardinality error found
     }
 
 }

Modified: bval/trunk/bval-xstream/src/test/java/org/apache/bval/xml/XMLMetaBeanInfosTest.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-xstream/src/test/java/org/apache/bval/xml/XMLMetaBeanInfosTest.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-xstream/src/test/java/org/apache/bval/xml/XMLMetaBeanInfosTest.java (original)
+++ bval/trunk/bval-xstream/src/test/java/org/apache/bval/xml/XMLMetaBeanInfosTest.java Tue Oct 25 15:34:35 2016
@@ -125,25 +125,19 @@ public class XMLMetaBeanInfosTest {
         infos.getBeans().add(bean2);
 
         String xml = XMLMapper.getInstance().getXStream().toXML(infos);
-        XMLMetaBeanInfos infos2 =
-              (XMLMetaBeanInfos) XMLMapper.getInstance().getXStream().fromXML(xml);
+        XMLMetaBeanInfos infos2 = (XMLMetaBeanInfos) XMLMapper.getInstance().getXStream().fromXML(xml);
         assertEquals(2, infos2.getBeans().size());
     }
 
     @Test
     public void testMaxValueParsing() {
-        String xml = "\n" +
-              "<beanInfos>  <bean id=\"org.apache.bval.test.model.Profile\">\n" +
-              "    <property name=\"activationDay\" minValue=\"1\" maxValue=\"31\"/>\n" +
-              "    <property name=\"activationMonth\" minValue=\"1\" maxValue=\"12\"/>\n" +
-              "  </bean></beanInfos>";
-        XMLMetaBeanInfos beanInfos = (XMLMetaBeanInfos) XMLMapper.getInstance()
-              .getXStream().fromXML(xml);
+        String xml = "\n" + "<beanInfos>  <bean id=\"org.apache.bval.test.model.Profile\">\n"
+            + "    <property name=\"activationDay\" minValue=\"1\" maxValue=\"31\"/>\n"
+            + "    <property name=\"activationMonth\" minValue=\"1\" maxValue=\"12\"/>\n" + "  </bean></beanInfos>";
+        XMLMetaBeanInfos beanInfos = (XMLMetaBeanInfos) XMLMapper.getInstance().getXStream().fromXML(xml);
         assertNotNull(beanInfos);
-        assertEquals(Integer.valueOf(31),
-              beanInfos.getBeans().get(0).getProperty("activationDay").getMaxValue());
-        assertEquals(Integer.valueOf(1),
-              beanInfos.getBeans().get(0).getProperty("activationDay").getMinValue());
+        assertEquals(Integer.valueOf(31), beanInfos.getBeans().get(0).getProperty("activationDay").getMaxValue());
+        assertEquals(Integer.valueOf(1), beanInfos.getBeans().get(0).getProperty("activationDay").getMinValue());
     }
 
 }

Modified: bval/trunk/bval-xstream/src/test/java/org/apache/bval/xml/XMLMetaBeanManagerTest.java
URL: http://svn.apache.org/viewvc/bval/trunk/bval-xstream/src/test/java/org/apache/bval/xml/XMLMetaBeanManagerTest.java?rev=1766546&r1=1766545&r2=1766546&view=diff
==============================================================================
--- bval/trunk/bval-xstream/src/test/java/org/apache/bval/xml/XMLMetaBeanManagerTest.java (original)
+++ bval/trunk/bval-xstream/src/test/java/org/apache/bval/xml/XMLMetaBeanManagerTest.java Tue Oct 25 15:34:35 2016
@@ -46,9 +46,8 @@ public class XMLMetaBeanManagerTest {
 
     @Test
     public void testEnrichCopies() throws Exception {
-        Map<String, MetaBean> copies =
-            mbm.enrichCopies(new XMLMetaBeanURLLoader(BusinessObject.class.getResource("test-beanInfos-custom.xml"))
-                .load());
+        Map<String, MetaBean> copies = mbm.enrichCopies(
+            new XMLMetaBeanURLLoader(BusinessObject.class.getResource("test-beanInfos-custom.xml")).load());
         assertNotNull(copies);
         MetaBean mb = copies.get(BusinessObject.class.getName());
         assertFalse(mb.getProperty("lastName").isMandatory());



Mime
View raw message