incubator-sling-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cziege...@apache.org
Subject svn commit: r601323 - in /incubator/sling/trunk/api/src/main/java/org/apache/sling/api/resource: ResourceManager.java ResourceResolver.java
Date Wed, 05 Dec 2007 13:02:07 GMT
Author: cziegeler
Date: Wed Dec  5 05:02:05 2007
New Revision: 601323

URL: http://svn.apache.org/viewvc?rev=601323&view=rev
Log:
Fix javadoc according to latest changes of the resource interface.

Modified:
    incubator/sling/trunk/api/src/main/java/org/apache/sling/api/resource/ResourceManager.java
    incubator/sling/trunk/api/src/main/java/org/apache/sling/api/resource/ResourceResolver.java

Modified: incubator/sling/trunk/api/src/main/java/org/apache/sling/api/resource/ResourceManager.java
URL: http://svn.apache.org/viewvc/incubator/sling/trunk/api/src/main/java/org/apache/sling/api/resource/ResourceManager.java?rev=601323&r1=601322&r2=601323&view=diff
==============================================================================
--- incubator/sling/trunk/api/src/main/java/org/apache/sling/api/resource/ResourceManager.java
(original)
+++ incubator/sling/trunk/api/src/main/java/org/apache/sling/api/resource/ResourceManager.java
Wed Dec  5 05:02:05 2007
@@ -24,7 +24,8 @@
  * The <code>ResourceManager</code> interface extends the
  * {@link ResourceResolver} in case the Sling Framework supports Object Content
  * Mapping of some sort and thus able to manage the
- * {@link Resource#getObject() data field of the resource}.
+ * {@link Resource#adaptTo(Class) data field of the resource} (The class argument
+ * for the {@link Resource#adaptTo(Class)} method would be <code>Object.class</code.
  * <p>
  * Any data modification operations executed through objects of this interface
  * must be persisted explicitly by calling the {@link #save()} method. Likewise
@@ -33,13 +34,14 @@
  * Implementations of this interface will (of course) also implement the methods
  * of the base interface. In addition to just loading the {@link Resource}
  * instances, though, implementations of this interface are expected to also try
- * to set the {@link Resource#getObject() data field} of the resource if possible.
+ * to provide the {@link Resource#adaptTo(Class) Resource.adaptTo(Object.class) data field}
+ * of the resource if possible.
  */
 public interface ResourceManager extends ResourceResolver {
 
     /**
-     * Stores the {@link Resource#getObject() resource data} mapping the Java
-     * object back into the underlying persistence structure.
+     * Stores the {@link Resource#adaptTo(Class) Resource.adaptTo(Object.class) resource
data}
+     * mapping the Java object back into the underlying persistence structure.
      * <p>
      * This method may be used to update existing data or to create new data in
      * the persistence. The implementation of the method must make care to
@@ -58,7 +60,8 @@
 
     /**
      * Returns a <code>Resource</code> object whose
-     * {@link Resource#getObject() data field} is mapped from the persistent data
+     * {@link Resource#adaptTo(Class) Resource.adaptTo(Object.class) data field}
+     * is mapped from the persistent data
      * to an instance of the given <code>type</code>. If persistent data can
      * be found at the requested path which cannot be mapped into an object of
      * the requested type a <code>ResourceNotFoundException</code> is thrown

Modified: incubator/sling/trunk/api/src/main/java/org/apache/sling/api/resource/ResourceResolver.java
URL: http://svn.apache.org/viewvc/incubator/sling/trunk/api/src/main/java/org/apache/sling/api/resource/ResourceResolver.java?rev=601323&r1=601322&r2=601323&view=diff
==============================================================================
--- incubator/sling/trunk/api/src/main/java/org/apache/sling/api/resource/ResourceResolver.java
(original)
+++ incubator/sling/trunk/api/src/main/java/org/apache/sling/api/resource/ResourceResolver.java
Wed Dec  5 05:02:05 2007
@@ -41,9 +41,9 @@
      * {@link Resource} object is returned whose
      * {@link Resource#getResourceType() resource type} is set to
      * {@link Resource#RESOURCE_TYPE_NON_EXISTING} and the
-     * {@link Resource#getURI() resource URI} set to the request URI. Both the
-     * {@link Resource#getRawData() raw data} and
-     * {@link Resource#getObject() object} fields will be <code>null</code>.
+     * {@link Resource#getURI() resource URI} set to the request URI.
+     * {@link Resource#adaptTo(Class) object} returns <code>null</code>
+     * for all classes.
      *
      * @param request The servlet request object used to resolve the resource
      *            for.



Mime
View raw message