| 1 |
package org.jboss.resteasy.resteasy1056; |
| 2 |
|
| 3 |
import javax.validation.constraints.Min; |
| 4 |
import javax.ws.rs.GET; |
| 5 |
import javax.ws.rs.Path; |
| 6 |
import javax.ws.rs.PathParam; |
| 7 |
import javax.ws.rs.Produces; |
| 8 |
import javax.ws.rs.core.MediaType; |
| 9 |
import javax.ws.rs.core.Response; |
| 10 |
|
| 11 |
/** |
| 12 |
* |
| 13 |
* |
| 14 |
* @author <a href="[email protected]">Ron Sigal</a> |
| 15 |
* @version $Revision: 1.1 $ |
| 16 |
* |
| 17 |
* Copyright June 7, 2014 |
| 18 |
*/ |
| 19 |
@Path("/") |
| 20 |
public class TestResource |
| 21 |
{ |
| 22 |
@GET |
| 23 |
@Path("test/{param}") |
| 24 |
@Produces(MediaType.TEXT_PLAIN) |
| 25 |
public Response test(@Min(7) @PathParam("param") int param) |
| 26 |
{ |
| 27 |
System.out.println("param: " + param); |
| 28 |
return Response.ok().entity(param).build(); |
| 29 |
} |
| 30 |
} |