Share via


FormatFilterAttribute Class

Definition

A filter that will use the format value in the route data or query string to set the content type on an ObjectResult returned from an action.

public ref class FormatFilterAttribute : Attribute, Microsoft::AspNetCore::Mvc::Filters::IFilterFactory
[System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Method, AllowMultiple=false, Inherited=true)]
public class FormatFilterAttribute : Attribute, Microsoft.AspNetCore.Mvc.Filters.IFilterFactory
[<System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Method, AllowMultiple=false, Inherited=true)>]
type FormatFilterAttribute = class
    inherit Attribute
    interface IFilterFactory
    interface IFilterMetadata
Public Class FormatFilterAttribute
Inherits Attribute
Implements IFilterFactory
Inheritance
FormatFilterAttribute
Attributes
Implements

Constructors

FormatFilterAttribute()

Properties

IsReusable

Gets a value that indicates if the result of CreateInstance(IServiceProvider) can be reused across requests.

Methods

CreateInstance(IServiceProvider)

Creates an instance of FormatFilter.

Applies to