Author: jharting
Date: 2009-12-03 05:20:11 -0500 (Thu, 03 Dec 2009)
New Revision: 11716
Modified:
branches/community/Seam_2_2/build/resteasy.pom.xml
branches/community/Seam_2_2/build/root.pom.xml
branches/community/Seam_2_2/examples/build.xml
branches/community/Seam_2_2/src/resteasy/org/jboss/seam/resteasy/ResourceHome.java
Log:
JBSEAM-4492 JBSEAM-4491 Upgraded to RESTEasy 1.2.1.GA
Modified: branches/community/Seam_2_2/build/resteasy.pom.xml
===================================================================
--- branches/community/Seam_2_2/build/resteasy.pom.xml 2009-12-02 11:41:03 UTC (rev
11715)
+++ branches/community/Seam_2_2/build/resteasy.pom.xml 2009-12-03 10:20:11 UTC (rev
11716)
@@ -30,6 +30,11 @@
<groupId>org.jboss.resteasy</groupId>
<artifactId>resteasy-jaxb-provider</artifactId>
</dependency>
+
+ <dependency>
+ <groupId>org.jboss.resteasy</groupId>
+ <artifactId>resteasy-jettison-provider</artifactId>
+ </dependency>
<dependency>
<groupId>org.jboss.resteasy</groupId>
Modified: branches/community/Seam_2_2/build/root.pom.xml
===================================================================
--- branches/community/Seam_2_2/build/root.pom.xml 2009-12-02 11:41:03 UTC (rev 11715)
+++ branches/community/Seam_2_2/build/root.pom.xml 2009-12-03 10:20:11 UTC (rev 11716)
@@ -42,6 +42,7 @@
<version.wicket>1.3.5.jboss1</version.wicket>
<version.drools>5.0.1</version.drools>
<version.testng>5.9</version.testng>
+ <version.resteasy>1.2.1.GA</version.resteasy>
</properties>
<dependencyManagement>
@@ -301,7 +302,7 @@
<dependency>
<groupId>org.jboss.resteasy</groupId>
<artifactId>resteasy-jaxrs</artifactId>
- <version>1.1-RC2</version>
+ <version>${version.resteasy}</version>
<exclusions>
<exclusion>
<groupId>commons-codec</groupId>
@@ -341,19 +342,29 @@
<dependency>
<groupId>org.jboss.resteasy</groupId>
<artifactId>resteasy-jaxb-provider</artifactId>
- <version>1.1-RC2</version>
+ <version>${version.resteasy}</version>
<exclusions>
<exclusion>
<groupId>com.sun.xml.bind</groupId>
<artifactId>jaxb-impl</artifactId>
</exclusion>
+ <exclusion>
+ <groupId>com.sun.xml.stream</groupId>
+ <artifactId>sjsxp</artifactId>
+ </exclusion>
</exclusions>
</dependency>
+
+ <dependency>
+ <groupId>org.jboss.resteasy</groupId>
+ <artifactId>resteasy-jettison-provider</artifactId>
+ <version>${version.resteasy}</version>
+ </dependency>
<dependency>
- <groupId>org.jboss.resteasy</groupId>
- <artifactId>resteasy-atom-provider</artifactId>
- <version>1.1-RC2</version>
+ <groupId>org.jboss.resteasy</groupId>
+ <artifactId>resteasy-atom-provider</artifactId>
+ <version>${version.resteasy}</version>
</dependency>
<dependency>
Modified: branches/community/Seam_2_2/examples/build.xml
===================================================================
--- branches/community/Seam_2_2/examples/build.xml 2009-12-02 11:41:03 UTC (rev 11715)
+++ branches/community/Seam_2_2/examples/build.xml 2009-12-03 10:20:11 UTC (rev 11716)
@@ -242,6 +242,8 @@
<include name="jaxrs-api.jar" if="seam.resteasy.lib" />
<include name="resteasy-jaxrs.jar" if="seam.resteasy.lib" />
<include name="resteasy-jaxb-provider.jar"
if="seam.resteasy.lib" />
+ <include name="resteasy-jettison-provider.jar"
if="seam.resteasy.lib" />
+ <include name="jettison.jar" if="seam.resteasy.lib" />
<include name="resteasy-atom-provider.jar"
if="seam.resteasy.lib" />
<include name="slf4j-api.jar" if="seam.resteasy.lib" />
<include name="slf4j-log4j12.jar" if="seam.resteasy.lib" />
Modified:
branches/community/Seam_2_2/src/resteasy/org/jboss/seam/resteasy/ResourceHome.java
===================================================================
---
branches/community/Seam_2_2/src/resteasy/org/jboss/seam/resteasy/ResourceHome.java 2009-12-02
11:41:03 UTC (rev 11715)
+++
branches/community/Seam_2_2/src/resteasy/org/jboss/seam/resteasy/ResourceHome.java 2009-12-03
10:20:11 UTC (rev 11716)
@@ -24,6 +24,7 @@
import java.io.InputStream;
import java.lang.reflect.ParameterizedType;
import java.lang.reflect.Type;
+import java.lang.annotation.Annotation;
import java.net.URI;
import javax.ws.rs.DELETE;
@@ -73,6 +74,8 @@
private Class entityIdClass = null;
private boolean readonly;
+
+ private static final PathParamAnnotation pathParamAnnotation = new
PathParamAnnotation();
/**
* Called at component instantiation. EntityHome component must be set in
@@ -289,7 +292,7 @@
*/
private T2 unmarshallId(String id)
{
- StringParameterInjector injector = new StringParameterInjector(getEntityIdClass(),
getEntityIdClass(), "id", PathParam.class, null, null,
SeamResteasyProviderFactory.getInstance());
+ StringParameterInjector injector = new StringParameterInjector(getEntityIdClass(),
getEntityIdClass(), "id", PathParam.class, null, null, new Annotation[]
{pathParamAnnotation}, SeamResteasyProviderFactory.getInstance());
return (T2) injector.extractValue(id);
}
@@ -369,4 +372,20 @@
{
this.entityIdClass = entityIdClass;
}
+
+ /**
+ * Annotation implementation (@PathParam("id")) for providing RESTEasy with
metadata.
+ */
+ static class PathParamAnnotation implements PathParam {
+
+ public String value()
+ {
+ return "id";
+ }
+
+ public Class<? extends Annotation> annotationType()
+ {
+ return PathParam.class;
+ }
+ }
}
Show replies by date