Skip to content

Instantly share code, notes, and snippets.

@martkoehler
Created November 13, 2015 13:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save martkoehler/700069419910992be3ce to your computer and use it in GitHub Desktop.
Save martkoehler/700069419910992be3ce to your computer and use it in GitHub Desktop.
@Path("customer")
@Api(value = "/customer", description = "Customer Operations")
public interface CustomerResource {
@GET
@Path("/{id:[1-9][0-9]*}")
@Produces({ MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML })
@ApiOperation(value = "Find customer by id")
Response getCustomer(@PathParam("id") final Long id);
@GET
@Produces({ MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML })
@ApiOperation(value = "Find all customers")
Response getCustomers();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment