jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ang...@apache.org
Subject svn commit: r761690 - /jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/value/ValueFormat.java
Date Fri, 03 Apr 2009 14:27:09 GMT
Author: angela
Date: Fri Apr  3 14:27:09 2009
New Revision: 761690

URL: http://svn.apache.org/viewvc?rev=761690&view=rev
Log:
redundant try/catch block

Modified:
    jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/value/ValueFormat.java

Modified: jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/value/ValueFormat.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/value/ValueFormat.java?rev=761690&r1=761689&r2=761690&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/value/ValueFormat.java
(original)
+++ jackrabbit/trunk/jackrabbit-spi-commons/src/main/java/org/apache/jackrabbit/spi/commons/value/ValueFormat.java
Fri Apr  3 14:27:09 2009
@@ -17,7 +17,6 @@
 package org.apache.jackrabbit.spi.commons.value;
 
 import org.apache.jackrabbit.spi.commons.conversion.NamePathResolver;
-import org.apache.jackrabbit.spi.commons.conversion.NameException;
 import org.apache.jackrabbit.spi.Name;
 import org.apache.jackrabbit.spi.Path;
 import org.apache.jackrabbit.spi.QValue;
@@ -116,20 +115,12 @@
                 qValue = factory.create(jcrValue.getBytes());
                 break;
             case PropertyType.NAME:
-                try {
-                    Name qName = resolver.getQName(jcrValue);
-                    qValue = factory.create(qName);
-                } catch (NameException e) {
-                    throw new RepositoryException(e);
-                }
+                Name qName = resolver.getQName(jcrValue);
+                qValue = factory.create(qName);
                 break;
             case PropertyType.PATH:
-                try {
-                    Path qPath = resolver.getQPath(jcrValue).getNormalizedPath();
-                    qValue = factory.create(qPath);
-                } catch (NameException e) {
-                    throw new RepositoryException(e);
-                }
+                Path qPath = resolver.getQPath(jcrValue).getNormalizedPath();
+                qValue = factory.create(qPath);
                 break;
             default:
                 throw new IllegalArgumentException("Invalid property type.");



Mime
View raw message