Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Info
titleReference

Refer to section ‎TBD for more information on Customizing the Default Deployment Configuration.

Alternative Shortcuts

Clients specify the requested media type by setting the Http Accept header. Apache Wink provides an alternate method for specifying the requested media type via use of the "alt" request parameter. This functionality is useful for situation where the client has little affect on the accept header, for example when requesting a resource using a browser.
For example, a request to /entry?alt=application/xml  specifies that the requested response media type is application/xml.
Apache Wink provides a shortcut mechanism for specifying the media type of the alt query parameter and provides a predefined set of shortcuts for common media types.

Predefined Shortcuts

Shortcut

Media Type

json

text/javascript

atom

application/atom+xml

xml

application/xml

text

text/plain

html

text/html

csv

text/csv

opensearch

application/opensearchdescription+xml

Customizing Shortcuts

The shortcuts table can be customized by overriding the deployment configuration class.

Info
titleReference

Refer to chapter ‎0 for more information about Deployment Configuration.