Options
All
  • Public
  • Public/Protected
  • All
Menu

Class ResponseContentTypeHandler

A handler which sets the response content type automatically according to the best Accept header match.

The header is set only if:

  • no object is stored in the routing context under the name DEFAULT_DISABLE_FLAG
  • a match is found
  • the header is not present already
  • content length header is absent or set to something different than zero

Hierarchy

  • ResponseContentTypeHandler

Implements

Index

Properties

Methods

Properties

Static Readonly DEFAULT_DISABLE_FLAG

DEFAULT_DISABLE_FLAG: string

Methods

handle

Static create

  • Create a response content type handler.

    Returns ResponseContentTypeHandler

  • Create a response content type handler with a custom disable flag.

    Parameters

    • disableFlag: string

    Returns ResponseContentTypeHandler

Generated using TypeDoc