incubator-sling-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cziege...@apache.org
Subject svn commit: r1357133 - in /sling/trunk/contrib/extensions/gwt/sample: pom.xml src/main/java/org/apache/sling/extensions/gwt/sample/server/NotesServiceImpl.java
Date Wed, 04 Jul 2012 07:47:33 GMT
Author: cziegeler
Date: Wed Jul  4 07:47:32 2012
New Revision: 1357133

URL: http://svn.apache.org/viewvc?rev=1357133&view=rev
Log:
SLING-2363 : Replace JavaDoc SCR annotations with Java SCR annotations

Modified:
    sling/trunk/contrib/extensions/gwt/sample/pom.xml
    sling/trunk/contrib/extensions/gwt/sample/src/main/java/org/apache/sling/extensions/gwt/sample/server/NotesServiceImpl.java

Modified: sling/trunk/contrib/extensions/gwt/sample/pom.xml
URL: http://svn.apache.org/viewvc/sling/trunk/contrib/extensions/gwt/sample/pom.xml?rev=1357133&r1=1357132&r2=1357133&view=diff
==============================================================================
--- sling/trunk/contrib/extensions/gwt/sample/pom.xml (original)
+++ sling/trunk/contrib/extensions/gwt/sample/pom.xml Wed Jul  4 07:47:32 2012
@@ -156,6 +156,10 @@
             <groupId>javax.servlet</groupId>
             <artifactId>servlet-api</artifactId>
         </dependency>
+        <dependency>
+            <groupId>org.apache.felix</groupId>
+            <artifactId>org.apache.felix.scr.annotations</artifactId>
+        </dependency>
     </dependencies>
 
 </project>

Modified: sling/trunk/contrib/extensions/gwt/sample/src/main/java/org/apache/sling/extensions/gwt/sample/server/NotesServiceImpl.java
URL: http://svn.apache.org/viewvc/sling/trunk/contrib/extensions/gwt/sample/src/main/java/org/apache/sling/extensions/gwt/sample/server/NotesServiceImpl.java?rev=1357133&r1=1357132&r2=1357133&view=diff
==============================================================================
--- sling/trunk/contrib/extensions/gwt/sample/src/main/java/org/apache/sling/extensions/gwt/sample/server/NotesServiceImpl.java
(original)
+++ sling/trunk/contrib/extensions/gwt/sample/src/main/java/org/apache/sling/extensions/gwt/sample/server/NotesServiceImpl.java
Wed Jul  4 07:47:32 2012
@@ -25,6 +25,10 @@ import javax.jcr.NodeIterator;
 import javax.jcr.RepositoryException;
 import javax.jcr.Session;
 
+import org.apache.felix.scr.annotations.Component;
+import org.apache.felix.scr.annotations.Property;
+import org.apache.felix.scr.annotations.Reference;
+import org.apache.felix.scr.annotations.Service;
 import org.apache.sling.extensions.gwt.sample.service.Note;
 import org.apache.sling.extensions.gwt.sample.service.NotesService;
 import org.apache.sling.extensions.gwt.user.server.rpc.SlingRemoteServiceServlet;
@@ -37,7 +41,7 @@ import org.slf4j.LoggerFactory;
  * This class implements a servlet-based RPC remote service for handling RPC calls from the
GWT client application.
  * <p/>
  * It registers as an OSGi service and component, under the <code>javax.servlet.Servlet</code>
interface. It thus
- * acts as a servlet, registered under the path specified  by the <code>sling.servlet.paths</code>
@scr.property.
+ * acts as a servlet, registered under the path specified  by the <code>sling.servlet.paths</code>
scr property.
  * The path under which the servlet is registered must correspond to the GWT module's base
url.
  * <p/>
  * The NotesServiceImpl class handles the creation, retrieval and deletion of {@link Note}s,
as POJOs and as
@@ -47,10 +51,10 @@ import org.slf4j.LoggerFactory;
  * GWT RPC calls in a Sling environment. The servlet must be registered with the GWT client
application in the
  * <code>Notes.gwt.xml</code> module configuration file.
  *
- * @scr.component metatype="false"
- * @scr.service interface="javax.servlet.Servlet"
- * @scr.property name="sling.servlet.paths" values="/gwt/org.apache.sling.extensions.gwt.sample.Notes/notesservice"
  */
+@Component
+@Service(value=javax.servlet.Servlet.class)
+@Property(name="sling.servlet.paths", value="/gwt/org.apache.sling.extensions.gwt.sample.Notes/notesservice")
 public class NotesServiceImpl extends SlingRemoteServiceServlet implements NotesService {
 
     /**
@@ -80,8 +84,8 @@ public class NotesServiceImpl extends Sl
      * This is the <code>SlingRepository</code> as provided by the Sling environment.
It is used for repository
      * access/operations.
      *
-     * @scr.reference
      */
+    @Reference
     private SlingRepository repository;
 
     /**



Mime
View raw message