Package com.codename1.annotations.rest
package com.codename1.annotations.rest
Annotations for declaring type safe REST clients.
An interface is marked with RestClient and its methods describe HTTP
requests using the verb annotations GET, POST, PUT, PATCH and
DELETE. Request data is bound through Path, Query, Header, Cookie
and Body. These annotations are processed to generate the concrete REST
client implementation.
-
Annotation TypesClassDescriptionMarks an interface method parameter as the request body.Binds an interface method parameter to a
Cookierequest-header entry.HTTPDELETErequest.HTTPGETrequest.Binds an interface method parameter to an HTTP request header.HTTPPATCHrequest.Binds an interface method parameter to a{name}placeholder in the URL path declared on the verb annotation.HTTPPOSTrequest.HTTPPUTrequest.Binds an interface method parameter to a URL query-string entry.Marks an interface as a REST client that the build-time annotation processor wires up to a generated network implementation.