@POST @Consumes(MediaType.APPLICATION_JSON) @ApiOperation(value = "Create an application") @ElementClass(response = ApplicationDTO.class) public Response create(@ApiParam(required = true) final ApplicationDTO applicationDTO) { Application application = applicationService.create(applicationDTO); return Response.status(Response.Status.CREATED).entity(application).build(); }
@DELETE @Path("/{id}") @ApiOperation(value = "Delete an application") public void delete(@PathParam("id") final String id) { applicationService.delete(id); }
@PUT @Consumes(MediaType.APPLICATION_JSON) @ApiOperation(value = "Update an application") public ApplicationDTO update(@ApiParam(required = true) final ApplicationDTO applicationDTO) { return applicationService.update(applicationDTO); }
@GET @Path("/{id}") @ApiOperation(value = "Read an application") public ApplicationDTO read(@PathParam("id") final String id) { return applicationService.read(id); }