23 instantiations of MediaType
Microsoft.AspNetCore.Mvc.Core (23)
ConsumesAttribute.cs (3)
130
var parsedRequestMediaType = new
MediaType
(requestMediaType);
133
var contentTypeMediaType = new
MediaType
(ContentTypes[i]);
244
var mediaType = new
MediaType
(arg);
Formatters\FormatFilter.cs (2)
110
var parsedContentType = new
MediaType
(contentType);
113
var supportedMediaType = new
MediaType
(supportedMediaTypes[i]);
Formatters\InputFormatter.cs (4)
68
var parsedContentType = new
MediaType
(contentType);
71
var supportedMediaType = new
MediaType
(SupportedMediaTypes[i]);
144
var parsedContentType = new
MediaType
(contentType);
151
var parsedMediaType = new
MediaType
(mediaType);
Formatters\MediaType.cs (2)
207
var parsedMediaType = new
MediaType
(mediaType);
249
var parsedMediaType = new
MediaType
(mediaType);
Formatters\OutputFormatter.cs (4)
52
var parsedContentType = contentType != null ? new
MediaType
(contentType) : default(MediaType);
56
var parsedMediaType = new
MediaType
(mediaType);
120
var parsedContentType = new
MediaType
(context.ContentType);
123
var supportedMediaType = new
MediaType
(SupportedMediaTypes[i]);
Formatters\TextInputFormatter.cs (1)
85
var requestMediaType = string.IsNullOrEmpty(requestContentType) ? default : new
MediaType
(requestContentType);
Formatters\TextOutputFormatter.cs (1)
83
var parsedContentType = new
MediaType
(context.ContentType);
Infrastructure\DefaultOutputFormatterSelector.cs (4)
155
var mediaType = new
MediaType
(result[i].MediaType);
243
var acceptableContentType = new
MediaType
(sortedAcceptableContentTypes[i].MediaType);
246
var candidateContentType = new
MediaType
(possibleOutputContentTypes[j]);
272
var parsedContentType = new
MediaType
(contentType);
ProducesAttribute.cs (1)
115
var contentType = new
MediaType
(arg);
ProducesResponseTypeAttribute.cs (1)
116
var mediaType = new
MediaType
(type);
49 references to MediaType
Microsoft.AspNetCore.Mvc.Core (47)
ConsumesAttribute.cs (3)
130
var
parsedRequestMediaType = new MediaType(requestMediaType);
133
var
contentTypeMediaType = new MediaType(ContentTypes[i]);
244
var
mediaType = new MediaType(arg);
Formatters\AcceptHeaderParser.cs (1)
155
result =
MediaType
.CreateMediaTypeSegmentWithQuality(input, start);
Formatters\FormatFilter.cs (2)
110
var
parsedContentType = new MediaType(contentType);
113
var
supportedMediaType = new MediaType(supportedMediaTypes[i]);
Formatters\InputFormatter.cs (4)
68
var
parsedContentType = new MediaType(contentType);
71
var
supportedMediaType = new MediaType(SupportedMediaTypes[i]);
144
var
parsedContentType = new MediaType(contentType);
151
var
parsedMediaType = new MediaType(mediaType);
Formatters\MediaType.cs (20)
23
/// Initializes a <see cref="
MediaType
"/> instance.
32
/// Initializes a <see cref="
MediaType
"/> instance.
72
/// Gets the type of the <see cref="
MediaType
"/>.
80
/// Gets whether this <see cref="
MediaType
"/> matches all types.
85
/// Gets the subtype of the <see cref="
MediaType
"/>.
94
/// Gets the subtype of the <see cref="
MediaType
"/>, excluding any structured syntax suffix.
103
/// Gets the structured syntax suffix of the <see cref="
MediaType
"/> if it has one.
112
/// Gets whether this <see cref="
MediaType
"/> matches all subtypes.
123
/// Gets whether this <see cref="
MediaType
"/> matches all subtypes, ignoring any structured syntax suffix.
134
/// Gets the <see cref="System.Text.Encoding"/> of the <see cref="
MediaType
"/> if it has one.
139
/// Gets the charset parameter of the <see cref="
MediaType
"/> if it has one.
144
/// Determines whether the current <see cref="
MediaType
"/> contains a wildcard.
147
/// <c>true</c> if this <see cref="
MediaType
"/> contains a wildcard; otherwise <c>false</c>.
152
/// Determines whether the current <see cref="
MediaType
"/> is a subset of the <paramref name="set"/>
153
/// <see cref="
MediaType
"/>.
155
/// <param name="set">The set <see cref="
MediaType
"/>.</param>
157
/// <c>true</c> if this <see cref="
MediaType
"/> is a subset of <paramref name="set"/>; otherwise <c>false</c>.
159
public bool IsSubsetOf(
MediaType
set)
207
var
parsedMediaType = new MediaType(mediaType);
249
var
parsedMediaType = new MediaType(mediaType);
Formatters\OutputFormatter.cs (5)
52
var
parsedContentType = contentType != null ? new MediaType(contentType) : default(
MediaType
);
56
var
parsedMediaType = new MediaType(mediaType);
120
var
parsedContentType = new MediaType(context.ContentType);
123
var
supportedMediaType = new MediaType(SupportedMediaTypes[i]);
Formatters\TextInputFormatter.cs (1)
85
var
requestMediaType = string.IsNullOrEmpty(requestContentType) ? default : new MediaType(requestContentType);
Formatters\TextOutputFormatter.cs (3)
44
cache.Add(mediaType,
MediaType
.ReplaceEncoding(mediaType, Encoding.UTF8));
83
var
parsedContentType = new MediaType(context.ContentType);
189
return
MediaType
.ReplaceEncoding(mediaType, encoding);
Infrastructure\ContentResultExecutor.cs (1)
45
MediaType
.GetEncoding,
Infrastructure\DefaultOutputFormatterSelector.cs (4)
155
var
mediaType = new MediaType(result[i].MediaType);
243
var
acceptableContentType = new MediaType(sortedAcceptableContentTypes[i].MediaType);
246
var
candidateContentType = new MediaType(possibleOutputContentTypes[j]);
272
var
parsedContentType = new MediaType(contentType);
Infrastructure\SystemTextJsonResultExecutor.cs (1)
47
MediaType
.GetEncoding,
ProducesAttribute.cs (1)
115
var
contentType = new MediaType(arg);
ProducesResponseTypeAttribute.cs (1)
116
var
mediaType = new MediaType(type);
Microsoft.AspNetCore.Mvc.ViewFeatures (2)
ViewComponentResultExecutor.cs (1)
90
MediaType
.GetEncoding,
ViewExecutor.cs (1)
193
MediaType
.GetEncoding,