package hello.controllers;

import hello.models.User;
import leap.web.annotation.http.DELETE;
import leap.web.annotation.http.GET;
import leap.web.annotation.http.POST;
import leap.web.annotation.http.PUT;
import leap.web.api.mvc.ApiResponse;
import leap.web.api.mvc.ModelController;
import leap.web.api.mvc.params.DeleteOptions;
import leap.web.api.mvc.params.Partial;
import leap.web.api.mvc.params.QueryOptions;
import leap.web.api.mvc.params.QueryOptionsBase;

public class UserController extends ModelController<User> {

    @POST
    public ApiResponse createUser(Partial<User> user) {
        return createAndReturn(user);
    }

    @GET("/{id}")
    public ApiResponse retrieveUser(String id, QueryOptionsBase options) {
        return get(id);
    }

    @PUT("/{id}")
    public ApiResponse updateUser(String id, Partial<User> user) {
        return updatePartial(id, user);
    }

    @DELETE("/{id}")
    public ApiResponse deleteUser(String id) {
        return delete(id);
    }

    @GET
    public ApiResponse queryUsers(QueryOptions options) {
        return queryList(options);
    }

}
@@ -83,126 +83,9 @@
 ttp.
-DELETE;%0Aimport leap.web.annotation.http.GET;%0Aimport leap.web.annotation.http.POST;%0Aimport leap.web.annotation.http.PUT
+*
 ;%0Aim
@@ -647,10 +647,12 @@
   @P
-UT
+ATCH
 (%22/%7B

update UserController