incubator-sling-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cziege...@apache.org
Subject svn commit: r918065 - /sling/trunk/bundles/jcr/resource/src/main/java/org/apache/sling/jcr/resource/internal/helper/starresource/StarResource.java
Date Tue, 02 Mar 2010 15:03:28 GMT
Author: cziegeler
Date: Tue Mar  2 15:03:27 2010
New Revision: 918065

URL: http://svn.apache.org/viewvc?rev=918065&view=rev
Log:
SLING-1420 : Remove FakeNode and FakeNodeType

Modified:
    sling/trunk/bundles/jcr/resource/src/main/java/org/apache/sling/jcr/resource/internal/helper/starresource/StarResource.java

Modified: sling/trunk/bundles/jcr/resource/src/main/java/org/apache/sling/jcr/resource/internal/helper/starresource/StarResource.java
URL: http://svn.apache.org/viewvc/sling/trunk/bundles/jcr/resource/src/main/java/org/apache/sling/jcr/resource/internal/helper/starresource/StarResource.java?rev=918065&r1=918064&r2=918065&view=diff
==============================================================================
--- sling/trunk/bundles/jcr/resource/src/main/java/org/apache/sling/jcr/resource/internal/helper/starresource/StarResource.java
(original)
+++ sling/trunk/bundles/jcr/resource/src/main/java/org/apache/sling/jcr/resource/internal/helper/starresource/StarResource.java
Tue Mar  2 15:03:27 2010
@@ -76,6 +76,15 @@
         return resourceSuperType;
     }
 
+    @Override
+    @SuppressWarnings("unchecked")
+    public <Type> Type adaptTo(Class<Type> type) {
+        if ( type == String.class ) {
+            return (Type)"";
+        }
+        return super.adaptTo(type);
+    }
+
     /** Get our ResourceMetadata for given path */
     static ResourceMetadata getResourceMetadata(String path) {
     	ResourceMetadata result = new ResourceMetadata();



Mime
View raw message