@Retention(value=CLASS) @Target(value=METHOD) public @interface Post
Use on methods in Rest annotated class to add a new rest service of
type POST.
This annotation as the same constraints as Get.
If an extra parameter is present (ie the only one not mapped with URI placeholders) it will be send in the request body using given converter.
Example :
@Rest(rootUrl = "http://myserver", converters = MappingJacksonHttpMessageConverter.class)
public interface MyRestClient {
@Post("/events/new/random")
Event newEvent();
@Post("/events/new/{id}")
void newEvent(@Body Event event, @Path int id);
}
public abstract String value
Copyright © 2010–2020 simpligility technologies inc.. All rights reserved.