feign.codec
Interface Encoder<T>

Type Parameters:
T - widest type an instance of this can encode.
All Known Subinterfaces:
Encoder.Text<T>

public interface Encoder<T>

Encodes an object into an HTTP request body. Like javax.websocket.Encoder.
Encoder is used when a method parameter has no *Param annotation. For example:

 @POST
 @Path("/")
 void create(User user);
 

Form encoding


If any parameters are found in MethodMetadata.formParams(), they will be collected and passed to Encoder.Text<Map<String, ?>>.
 @POST
 @Path("/")
 Session login(@Named("username") String username, @Named("password") String password);
 


Nested Class Summary
static interface Encoder.Text<T>
          Converts objects to an appropriate text representation.