jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From alex...@apache.org
Subject svn commit: r668857 - in /jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value: DoubleValue.java LongValue.java NameValue.java PathValue.java ReferenceValue.java
Date Tue, 17 Jun 2008 22:16:35 GMT
Author: alexkli
Date: Tue Jun 17 15:16:35 2008
New Revision: 668857

URL: http://svn.apache.org/viewvc?rev=668857&view=rev
Log:
JCR-1652 Better 'invalid format' exception messages for value classes

Modified:
    jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/DoubleValue.java
    jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/LongValue.java
    jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/NameValue.java
    jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/PathValue.java
    jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/ReferenceValue.java

Modified: jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/DoubleValue.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/DoubleValue.java?rev=668857&r1=668856&r2=668857&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/DoubleValue.java
(original)
+++ jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/DoubleValue.java
Tue Jun 17 15:16:35 2008
@@ -66,7 +66,7 @@
         try {
             return new DoubleValue(Double.parseDouble(s));
         } catch (NumberFormatException e) {
-            throw new ValueFormatException("invalid format", e);
+            throw new ValueFormatException("not a valid double format: " + s, e);
         }
     }
 

Modified: jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/LongValue.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/LongValue.java?rev=668857&r1=668856&r2=668857&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/LongValue.java
(original)
+++ jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/LongValue.java
Tue Jun 17 15:16:35 2008
@@ -66,7 +66,7 @@
         try {
             return new LongValue(Long.parseLong(s));
         } catch (NumberFormatException e) {
-            throw new ValueFormatException("invalid format", e);
+            throw new ValueFormatException("not a valid long format: " + s, e);
         }
     }
 

Modified: jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/NameValue.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/NameValue.java?rev=668857&r1=668856&r2=668857&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/NameValue.java
(original)
+++ jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/NameValue.java
Tue Jun 17 15:16:35 2008
@@ -81,7 +81,7 @@
             }
             return new NameValue(s);
         } else {
-            throw new ValueFormatException("not a valid name format");
+            throw new ValueFormatException("not a valid name format: " + s);
         }
     }
 

Modified: jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/PathValue.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/PathValue.java?rev=668857&r1=668856&r2=668857&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/PathValue.java
(original)
+++ jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/PathValue.java
Tue Jun 17 15:16:35 2008
@@ -57,7 +57,7 @@
             }
             return new PathValue(s);
         } else {
-            throw new ValueFormatException("not a valid path format");
+            throw new ValueFormatException("not a valid path format: " + s);
         }
     }
 

Modified: jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/ReferenceValue.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/ReferenceValue.java?rev=668857&r1=668856&r2=668857&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/ReferenceValue.java
(original)
+++ jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/value/ReferenceValue.java
Tue Jun 17 15:16:35 2008
@@ -71,11 +71,11 @@
             try {
                 UUID.fromString(s);
             } catch (IllegalArgumentException iae) {
-                throw new ValueFormatException("not a valid UUID format");
+                throw new ValueFormatException("not a valid UUID format: " + s);
             }
             return new ReferenceValue(s);
         } else {
-            throw new ValueFormatException("not a valid UUID format");
+            throw new ValueFormatException("not a valid UUID format: " + s);
         }
     }
 



Mime
View raw message