jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From resc...@apache.org
Subject svn commit: r702481 - in /jackrabbit/trunk: jackrabbit-jcr-server/src/main/java/org/apache/jackrabbit/webdav/jcr/nodetype/ jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/ jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/proper...
Date Tue, 07 Oct 2008 13:49:31 GMT
Author: reschke
Date: Tue Oct  7 06:49:30 2008
New Revision: 702481

URL: http://svn.apache.org/viewvc?rev=702481&view=rev
Log:
JCR-1790: change "isProtected" to "isInvisibleInAllprop", plus some Javadoc fixes (no functional
change)

Modified:
    jackrabbit/trunk/jackrabbit-jcr-server/src/main/java/org/apache/jackrabbit/webdav/jcr/nodetype/NodeTypeProperty.java
    jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/MultiStatusResponse.java
    jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/property/AbstractDavProperty.java
    jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/property/DavProperty.java
    jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/property/HrefProperty.java
    jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/version/report/ExpandPropertyReport.java
    jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/version/report/SupportedReportSetProperty.java

Modified: jackrabbit/trunk/jackrabbit-jcr-server/src/main/java/org/apache/jackrabbit/webdav/jcr/nodetype/NodeTypeProperty.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-jcr-server/src/main/java/org/apache/jackrabbit/webdav/jcr/nodetype/NodeTypeProperty.java?rev=702481&r1=702480&r2=702481&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-jcr-server/src/main/java/org/apache/jackrabbit/webdav/jcr/nodetype/NodeTypeProperty.java
(original)
+++ jackrabbit/trunk/jackrabbit-jcr-server/src/main/java/org/apache/jackrabbit/webdav/jcr/nodetype/NodeTypeProperty.java
Tue Oct  7 06:49:30 2008
@@ -71,7 +71,7 @@
      * @param property
      */
     public NodeTypeProperty(DavProperty property) {
-        super(property.getName(), property.isProtected());
+        super(property.getName(), property.isInvisibleInAllprop());
         if (property instanceof NodeTypeProperty) {
             nodetypeNames.addAll(((NodeTypeProperty)property).nodetypeNames);
         } else {

Modified: jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/MultiStatusResponse.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/MultiStatusResponse.java?rev=702481&r1=702480&r2=702481&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/MultiStatusResponse.java
(original)
+++ jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/MultiStatusResponse.java
Tue Oct  7 06:49:30 2008
@@ -185,7 +185,7 @@
                     propFindType == PROPFIND_ALL_PROP || propFindType == PROPFIND_ALL_PROP_INCLUDE;
                 boolean wasRequested = propNameSet.remove(property.getName());
                 
-                if ((allDeadPlusRfc4918LiveProperties && !property.isProtected())
|| wasRequested) {
+                if ((allDeadPlusRfc4918LiveProperties && !property.isInvisibleInAllprop())
|| wasRequested) {
                     status200.addContent(property);
                 }
             }

Modified: jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/property/AbstractDavProperty.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/property/AbstractDavProperty.java?rev=702481&r1=702480&r2=702481&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/property/AbstractDavProperty.java
(original)
+++ jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/property/AbstractDavProperty.java
Tue Oct  7 06:49:30 2008
@@ -16,6 +16,7 @@
  */
 package org.apache.jackrabbit.webdav.property;
 
+import org.apache.jackrabbit.webdav.DavConstants;
 import org.apache.jackrabbit.webdav.xml.DomUtil;
 import org.apache.jackrabbit.webdav.xml.XmlSerializable;
 import org.slf4j.Logger;
@@ -36,22 +37,20 @@
     private static Logger log = LoggerFactory.getLogger(AbstractDavProperty.class);
 
     private final DavPropertyName name;
-    private final boolean isProtected;
+    private final boolean isInvisibleInAllprop;
 
     /**
      * Create a new <code>AbstractDavProperty</code> with the given {@link DavPropertyName}
-     * and a boolean flag indicating whether this property is protected.
-     *
-     * @param name
-     * @param isProtected
+     * and a boolean flag indicating whether this property should be suppressed
+     * in PROPFIND/allprop responses.
      */
-    public AbstractDavProperty(DavPropertyName name, boolean isProtected) {
+    public AbstractDavProperty(DavPropertyName name, boolean isInvisibleInAllprop) {
         this.name = name;
-        this.isProtected = isProtected;
+        this.isInvisibleInAllprop = isInvisibleInAllprop;
     }
 
     /**
-     * Computes the hash code using this propertys name and value.
+     * Computes the hash code using this property's name and value.
      *
      * @return the hash code
      */
@@ -153,12 +152,13 @@
     }
 
     /**
-     * Returns true if this property is protected or computed.
+     * Return <code>true</code> if this property should be suppressed
+     * in a PROPFIND/{@link DavConstants#PROPFIND_ALL_PROP DAV:allprop} 
+     * response. See RFC 4918, Section 9.1.
      *
-     * @return true if this is a protected (or computed) property.
-     * @see org.apache.jackrabbit.webdav.property.DavProperty#isProtected()
+     * @see org.apache.jackrabbit.webdav.property.DavProperty#isInvisibleInAllprop()
      */
-    public boolean isProtected() {
-        return isProtected;
+    public boolean isInvisibleInAllprop() {
+        return isInvisibleInAllprop;
     }
 }
\ No newline at end of file

Modified: jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/property/DavProperty.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/property/DavProperty.java?rev=702481&r1=702480&r2=702481&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/property/DavProperty.java
(original)
+++ jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/property/DavProperty.java
Tue Oct  7 06:49:30 2008
@@ -21,9 +21,9 @@
 
 /**
  * The <code>Property</code> class represents a Property of a WebDAV
- * resource. The {@link #hashCode()} and {@link #equals(Object)} METHODS are
- * overridden in a way, that the name and value of the property are
- * respected. this means, an property is equal to another, if the names
+ * resource. The {@link #hashCode()} and {@link #equals(Object)} methods are
+ * overridden in a way, such that the name and value of the property are
+ * respected. This means, a property is equal to another if the names
  * and values are equal.<br>
  * The XML representation of a <code>DavProperty</code>:
  * <pre>
@@ -61,11 +61,11 @@
     public Object getValue();
 
     /**
-     * Return true if this property is protected. A protected property
-     * will not be returned in a {@link DavConstants#PROPFIND_ALL_PROP DAV:allprop}
-     * PROPFIND request and cannot be set/removed with a PROPPATCH request.
+     * Return <code>true</code> if this property should be suppressed
+     * in a PROPFIND/{@link DavConstants#PROPFIND_ALL_PROP DAV:allprop} 
+     * response. See RFC 4918, Section 9.1.
      *
-     * @return true, if this property is protected.
+     * @return true, if this property should be suppressed in a PROPFIND/allprop response
      */
-    public boolean isProtected();
+    public boolean isInvisibleInAllprop();
 }

Modified: jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/property/HrefProperty.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/property/HrefProperty.java?rev=702481&r1=702480&r2=702481&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/property/HrefProperty.java
(original)
+++ jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/property/HrefProperty.java
Tue Oct  7 06:49:30 2008
@@ -47,12 +47,12 @@
      *
      * @param name the name of the property
      * @param value the value of the property
-     * @param isProtected A value of true, defines this property to be protected.
+     * @param isInvisibleInAllprop A value of true, defines this property to be invisible
in PROPFIND/allprop
      * It will not be returned in a {@link org.apache.jackrabbit.webdav.DavConstants#PROPFIND_ALL_PROP
DAV:allprop}
-     * PROPFIND request and cannot be set/removed with a PROPPATCH request.
+     * PROPFIND request.
      */
-    public HrefProperty(DavPropertyName name, String value, boolean isProtected) {
-        super(name, isProtected);
+    public HrefProperty(DavPropertyName name, String value, boolean isInvisibleInAllprop)
{
+        super(name, isInvisibleInAllprop);
         this.value = new String[]{value};
     }
 
@@ -61,12 +61,12 @@
      *
      * @param name the name of the property
      * @param value the value of the property
-     * @param isProtected A value of true, defines this property to be protected.
+     * @param isInvisibleInAllprop A value of true, defines this property to be invisible
in PROPFIND/allprop
      * It will not be returned in a {@link org.apache.jackrabbit.webdav.DavConstants#PROPFIND_ALL_PROP
DAV:allprop}
-     * PROPFIND request and cannot be set/removed with a PROPPATCH request.
+     * PROPFIND request.
      */
-    public HrefProperty(DavPropertyName name, String[] value, boolean isProtected) {
-        super(name, isProtected);
+    public HrefProperty(DavPropertyName name, String[] value, boolean isInvisibleInAllprop)
{
+        super(name, isInvisibleInAllprop);
         this.value = value;
     }
 
@@ -78,7 +78,7 @@
      * @param prop
      */
     public HrefProperty(DavProperty prop) {
-        super(prop.getName(), prop.isProtected());
+        super(prop.getName(), prop.isInvisibleInAllprop());
         if (prop instanceof HrefProperty) {
             // already an HrefProperty: no parsing required
             this.value = ((HrefProperty)prop).value;
@@ -154,7 +154,7 @@
     }
 
     /**
-     * Return an array of String containg the text of those DAV:href elements
+     * Return an array of String containing the text of those DAV:href elements
      * that would be returned as child elements of this property on
      * {@link org.apache.jackrabbit.webdav.xml.XmlSerializable#toXml(Document)}
      *

Modified: jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/version/report/ExpandPropertyReport.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/version/report/ExpandPropertyReport.java?rev=702481&r1=702480&r2=702481&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/version/report/ExpandPropertyReport.java
(original)
+++ jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/version/report/ExpandPropertyReport.java
Tue Oct  7 06:49:30 2008
@@ -227,7 +227,7 @@
      * that given property (consisting of one or multiple DAV:href elements)
      * is replaced by the Xml representation of a separate
      * {@link MultiStatusResponse multistatus responses} for the
-     * resource referenced to by the given DAV.:href elements. The responses may
+     * resource referenced to by the given DAV:href elements. The responses may
      * themselves have properties, which are defined by the separate list.
      */
     private class ExpandProperty extends AbstractDavProperty {
@@ -241,7 +241,7 @@
          * @param elementIter
          */
         private ExpandProperty(DeltaVResource deltaVResource, HrefProperty hrefProperty,
ElementIterator elementIter) {
-            super(hrefProperty.getName(), hrefProperty.isProtected());
+            super(hrefProperty.getName(), hrefProperty.isInvisibleInAllprop());
             try {
                 DavResource[] refResource = deltaVResource.getReferenceResources(hrefProperty.getName());
                 for (int i = 0; i < refResource.length; i++) {

Modified: jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/version/report/SupportedReportSetProperty.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/version/report/SupportedReportSetProperty.java?rev=702481&r1=702480&r2=702481&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/version/report/SupportedReportSetProperty.java
(original)
+++ jackrabbit/trunk/jackrabbit-webdav/src/main/java/org/apache/jackrabbit/webdav/version/report/SupportedReportSetProperty.java
Tue Oct  7 06:49:30 2008
@@ -111,9 +111,9 @@
         Element elem = getName().toXml(document);
         Iterator it = reportTypes.iterator();
         while (it.hasNext()) {
-	    Element sr = DomUtil.addChildElement(elem, DeltaVConstants.XML_SUPPORTED_REPORT, DeltaVConstants.NAMESPACE);
+            Element sr = DomUtil.addChildElement(elem, DeltaVConstants.XML_SUPPORTED_REPORT,
DeltaVConstants.NAMESPACE);
             Element r = DomUtil.addChildElement(sr, DeltaVConstants.XML_REPORT, DeltaVConstants.NAMESPACE);
-	    r.appendChild(((ReportType)it.next()).toXml(document));
+            r.appendChild(((ReportType)it.next()).toXml(document));
         }
         return elem;
     }



Mime
View raw message