jackrabbit-oak-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ang...@apache.org
Subject svn commit: r1431502 - /jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/util/NodeUtil.java
Date Thu, 10 Jan 2013 17:03:25 GMT
Author: angela
Date: Thu Jan 10 17:03:25 2013
New Revision: 1431502

URL: http://svn.apache.org/viewvc?rev=1431502&view=rev
Log:
minor improvement: add nullable annotation for the default value

Modified:
    jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/util/NodeUtil.java

Modified: jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/util/NodeUtil.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/util/NodeUtil.java?rev=1431502&r1=1431501&r2=1431502&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/util/NodeUtil.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/util/NodeUtil.java
Thu Jan 10 17:03:25 2013
@@ -22,6 +22,7 @@ import java.util.GregorianCalendar;
 import java.util.List;
 import javax.annotation.CheckForNull;
 import javax.annotation.Nonnull;
+import javax.annotation.Nullable;
 import javax.jcr.RepositoryException;
 import javax.jcr.Value;
 import javax.jcr.ValueFactory;
@@ -175,7 +176,7 @@ public class NodeUtil {
     }
 
     @CheckForNull
-    public String getString(String name, String defaultValue) {
+    public String getString(String name, @Nullable String defaultValue) {
         PropertyState property = tree.getProperty(name);
         if (property != null && !property.isArray()) {
             return property.getValue(Type.STRING);
@@ -208,7 +209,7 @@ public class NodeUtil {
     }
 
     @CheckForNull
-    public String getName(String name, String defaultValue) {
+    public String getName(String name, @Nullable String defaultValue) {
         PropertyState property = tree.getProperty(name);
         if (property != null && !property.isArray()) {
             return mapper.getJcrName(property.getValue(STRING));



Mime
View raw message