Use custom entity formats
Even though the Java API for RESTful Web Services (JAX-RS) runtime environment includes several entity providers for handling serialization from and deserialization to Java types, it does not support all possible media types. We can develop a custom entity provider to handle binding Java types to message bodies.
If the JAX-RS web application requires that additional Java types or media types are supported beyond what the JAX-RS APIs support, we can add a custom entity provider to the application. Any custom-defined entity provider takes precedence over the entity providers that are included in the JAX-RS runtime environment. Unlike resources, providers are always singleton beans.
- Configure the development environment.
- Define resources in JAX-RS web applications.
- Configure the JAX-RS application.
- Implement custom entity formats.
- Assemble JAX-RS web applications.
- Deploy JAX-RS web applications.
Related tasks
Custom entity formatsWeb services specifications and APIs