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 Types
    Class
    Description
    Marks an interface method parameter as the request body.
    Binds an interface method parameter to a Cookie request-header entry.
    HTTP DELETE request.
    HTTP GET request.
    Binds an interface method parameter to an HTTP request header.
    HTTP PATCH request.
    Binds an interface method parameter to a {name} placeholder in the URL path declared on the verb annotation.
    HTTP POST request.
    HTTP PUT request.
    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.