From: Richard Millet Date: Thu, 30 Apr 2009 22:34:10 +0000 (+0000) Subject: CSPACE-84: Adding JAX-RS specific CollectionSpace service provider node. X-Git-Url: https://git.aero2k.de/?a=commitdiff_plain;h=90dabfb55eb4b8ad937e1a8b481e0f8c26742469;p=tmp%2Fjakarta-migration.git CSPACE-84: Adding JAX-RS specific CollectionSpace service provider node. --- diff --git a/JaxRsServiceProvider/build.xml b/JaxRsServiceProvider/build.xml index cdba8639c..4fd6f9f47 100644 --- a/JaxRsServiceProvider/build.xml +++ b/JaxRsServiceProvider/build.xml @@ -6,7 +6,7 @@ - + diff --git a/JaxRsServiceProvider/src/main/java/org/collectionspace/services/jaxrs/CollectionSpaceJaxRsApplication.java b/JaxRsServiceProvider/src/main/java/org/collectionspace/services/jaxrs/CollectionSpaceJaxRsApplication.java new file mode 100644 index 000000000..5ba58f0ac --- /dev/null +++ b/JaxRsServiceProvider/src/main/java/org/collectionspace/services/jaxrs/CollectionSpaceJaxRsApplication.java @@ -0,0 +1,29 @@ +package org.collectionspace.services.jaxrs; + +import org.collectionspace.services.CollectionObjectResource; +import javax.ws.rs.core.Application; +import java.util.HashSet; +import java.util.Set; + +public class CollectionSpaceJaxRsApplication extends Application { + + private Set singletons = new HashSet(); + private Set> empty = new HashSet>(); + + public CollectionSpaceJaxRsApplication() { + singletons.add(new CollectionObjectResource()); +// singletons.add(new DomainIdentifierResource()); +// singletons.add(new PingResource()); + } + + @Override + public Set> getClasses() { + return empty; + } + + @Override + public Set getSingletons() { + return singletons; + } +} + diff --git a/JaxRsServiceProvider/src/main/webapp/WEB-INF/web.xml b/JaxRsServiceProvider/src/main/webapp/WEB-INF/web.xml index 0c188a4fb..6777d8f8e 100644 --- a/JaxRsServiceProvider/src/main/webapp/WEB-INF/web.xml +++ b/JaxRsServiceProvider/src/main/webapp/WEB-INF/web.xml @@ -1,16 +1,16 @@ - HelloworldNuxeo + CollectionSpace javax.ws.rs.Application - org.collectionspace.hello.services.HelloworldNuxeoApplication + org.collectionspace.services.jaxrs.CollectionSpaceJaxRsApplication resteasy.servlet.mapping.prefix - /cspace-nuxeo + /nuxeo-rest @@ -28,7 +28,7 @@ Resteasy - /cspace-nuxeo/* + /nuxeo-rest/*