Interface MessageBodyWriter<T>

Type Parameters:
T - the type that can be written.

public interface MessageBodyWriter<T>
Contract for a provider that supports the conversion of a Java type to a stream. A MessageBodyWriter implementation may be annotated with Produces to restrict the media types for which it will be considered suitable. The MessageBodyWriter pipeline is only invoked if there is a non-null response entity.

Providers implementing MessageBodyWriter contract must be either programmatically registered in a JAX-RS runtime or must be annotated with @Provider annotation to be automatically discovered by the JAX-RS runtime during a provider scanning phase.

Since:
1.0
See Also: