Class JaxRsResource


  • @Path("/jaxrs")
    public class JaxRsResource
    extends java.lang.Object
    JAX-RS resource.
    Author:
    Daniel Sagenschneider
    • Constructor Detail

      • JaxRsResource

        public JaxRsResource()
    • Method Detail

      • inject

        @GET
        @Path("/inject")
        public java.lang.String inject()
      • pathParam

        @GET
        @Path("/path/{param}")
        public java.lang.String pathParam​(@PathParam("param")
                                          java.lang.String param)
      • json

        @POST
        @Path("/json")
        @Consumes("application/json")
        @Produces("application/json")
        public JsonResponse json​(JsonRequest request)
      • get

        @GET
        public java.lang.String get()
      • queryParam

        @GET
        @Path("/query")
        public java.lang.String queryParam​(@DefaultValue("default") @QueryParam("param")
                                           java.lang.String param)
      • headerParam

        @GET
        @Path("/header")
        public java.lang.String headerParam​(@HeaderParam("param")
                                            java.lang.String param)
      • cookieParam

        @GET
        @Path("/cookie")
        public java.lang.String cookieParam​(@CookieParam("param")
                                            java.lang.String param)
      • formParam

        @POST
        @Path("/form")
        @Consumes("application/x-www-form-urlencoded")
        public java.lang.String formParam​(@FormParam("param")
                                          java.lang.String param)
      • uriInfo

        @GET
        @Path("/uriInfo/{param}")
        public java.lang.String uriInfo​(@Context
                                        javax.ws.rs.core.UriInfo info)
      • httpHeaders

        @GET
        @Path("/headers")
        public java.lang.String httpHeaders​(@Context
                                            javax.ws.rs.core.HttpHeaders headers)
      • context

        @GET
        @Path("/context")
        public java.lang.String context​(@Context
                                        JaxRsDependency dependency)
      • asyncSynchronous

        @GET
        @Path("/async/synchronous")
        public void asyncSynchronous​(@Suspended
                                     javax.ws.rs.container.AsyncResponse async)
      • asyncAsynchronous

        @GET
        @Path("/async/asynchronous")
        public void asyncAsynchronous​(@Suspended
                                      javax.ws.rs.container.AsyncResponse async)
      • checkedException

        @GET
        @Path("/exception/checked")
        public java.lang.String checkedException()
                                          throws java.lang.Exception
        Throws:
        java.lang.Exception
      • uncheckedException

        @GET
        @Path("/exception/unchecked")
        public java.lang.String uncheckedException()
      • asyncException

        @GET
        @Path("/exception/async")
        public void asyncException​(@Suspended
                                   javax.ws.rs.container.AsyncResponse async)