12 references to GetMediaTypeMappingForFormat
Microsoft.AspNetCore.Mvc.Core (2)
Formatters\FormatFilter.cs (2)
72
var contentType = _options.FormatterMappings.
GetMediaTypeMappingForFormat
(format);
157
var contentType = _options.FormatterMappings.
GetMediaTypeMappingForFormat
(format);
Microsoft.AspNetCore.Mvc.Core.Test (3)
Formatters\FormatterMappingsTest.cs (3)
20
Assert.Throws<ArgumentException>("format", () => options.
GetMediaTypeMappingForFormat
(format));
36
var returnMediaType = options.
GetMediaTypeMappingForFormat
(getFormat);
125
Assert.Null(options.
GetMediaTypeMappingForFormat
(format));
Microsoft.AspNetCore.Mvc.Formatters.Xml (2)
DependencyInjection\XmlDataContractSerializerMvcOptionsSetup.cs (1)
49
var mapping = options.FormatterMappings.
GetMediaTypeMappingForFormat
(key);
DependencyInjection\XmlSerializerMvcOptionsSetup.cs (1)
37
var mapping = options.FormatterMappings.
GetMediaTypeMappingForFormat
(key);
Microsoft.AspNetCore.Mvc.Formatters.Xml.Test (4)
DependencyInjection\XmlDataContractSerializerMvcOptionsSetupTest.cs (2)
23
var mappedContentType = options.FormatterMappings.
GetMediaTypeMappingForFormat
("xml");
39
var mappedContentType = options.FormatterMappings.
GetMediaTypeMappingForFormat
("xml");
DependencyInjection\XmlSerializerMvcOptionsSetupTest.cs (2)
23
var mappedContentType = options.FormatterMappings.
GetMediaTypeMappingForFormat
("xml");
39
var mappedContentType = options.FormatterMappings.
GetMediaTypeMappingForFormat
("xml");
Microsoft.AspNetCore.Mvc.Test (1)
MvcOptionsSetupTest.cs (1)
117
var mapping = options.FormatterMappings.
GetMediaTypeMappingForFormat
("json");