23 instantiations of MediaType
Microsoft.AspNetCore.Mvc.Core (23)
ConsumesAttribute.cs (3)
130var parsedRequestMediaType = new MediaType(requestMediaType); 133var contentTypeMediaType = new MediaType(ContentTypes[i]); 244var mediaType = new MediaType(arg);
Formatters\FormatFilter.cs (2)
110var parsedContentType = new MediaType(contentType); 113var supportedMediaType = new MediaType(supportedMediaTypes[i]);
Formatters\InputFormatter.cs (4)
68var parsedContentType = new MediaType(contentType); 71var supportedMediaType = new MediaType(SupportedMediaTypes[i]); 144var parsedContentType = new MediaType(contentType); 151var parsedMediaType = new MediaType(mediaType);
Formatters\MediaType.cs (2)
207var parsedMediaType = new MediaType(mediaType); 249var parsedMediaType = new MediaType(mediaType);
Formatters\OutputFormatter.cs (4)
52var parsedContentType = contentType != null ? new MediaType(contentType) : default(MediaType); 56var parsedMediaType = new MediaType(mediaType); 120var parsedContentType = new MediaType(context.ContentType); 123var supportedMediaType = new MediaType(SupportedMediaTypes[i]);
Formatters\TextInputFormatter.cs (1)
85var requestMediaType = string.IsNullOrEmpty(requestContentType) ? default : new MediaType(requestContentType);
Formatters\TextOutputFormatter.cs (1)
83var parsedContentType = new MediaType(context.ContentType);
Infrastructure\DefaultOutputFormatterSelector.cs (4)
155var mediaType = new MediaType(result[i].MediaType); 243var acceptableContentType = new MediaType(sortedAcceptableContentTypes[i].MediaType); 246var candidateContentType = new MediaType(possibleOutputContentTypes[j]); 272var parsedContentType = new MediaType(contentType);
ProducesAttribute.cs (1)
115var contentType = new MediaType(arg);
ProducesResponseTypeAttribute.cs (1)
116var mediaType = new MediaType(type);
49 references to MediaType
Microsoft.AspNetCore.Mvc.Core (47)
ConsumesAttribute.cs (3)
130var parsedRequestMediaType = new MediaType(requestMediaType); 133var contentTypeMediaType = new MediaType(ContentTypes[i]); 244var mediaType = new MediaType(arg);
Formatters\AcceptHeaderParser.cs (1)
155result = MediaType.CreateMediaTypeSegmentWithQuality(input, start);
Formatters\FormatFilter.cs (2)
110var parsedContentType = new MediaType(contentType); 113var supportedMediaType = new MediaType(supportedMediaTypes[i]);
Formatters\InputFormatter.cs (4)
68var parsedContentType = new MediaType(contentType); 71var supportedMediaType = new MediaType(SupportedMediaTypes[i]); 144var parsedContentType = new MediaType(contentType); 151var 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>. 159public bool IsSubsetOf(MediaType set) 207var parsedMediaType = new MediaType(mediaType); 249var parsedMediaType = new MediaType(mediaType);
Formatters\OutputFormatter.cs (5)
52var parsedContentType = contentType != null ? new MediaType(contentType) : default(MediaType); 56var parsedMediaType = new MediaType(mediaType); 120var parsedContentType = new MediaType(context.ContentType); 123var supportedMediaType = new MediaType(SupportedMediaTypes[i]);
Formatters\TextInputFormatter.cs (1)
85var requestMediaType = string.IsNullOrEmpty(requestContentType) ? default : new MediaType(requestContentType);
Formatters\TextOutputFormatter.cs (3)
44cache.Add(mediaType, MediaType.ReplaceEncoding(mediaType, Encoding.UTF8)); 83var parsedContentType = new MediaType(context.ContentType); 189return MediaType.ReplaceEncoding(mediaType, encoding);
Infrastructure\ContentResultExecutor.cs (1)
45MediaType.GetEncoding,
Infrastructure\DefaultOutputFormatterSelector.cs (4)
155var mediaType = new MediaType(result[i].MediaType); 243var acceptableContentType = new MediaType(sortedAcceptableContentTypes[i].MediaType); 246var candidateContentType = new MediaType(possibleOutputContentTypes[j]); 272var parsedContentType = new MediaType(contentType);
Infrastructure\SystemTextJsonResultExecutor.cs (1)
47MediaType.GetEncoding,
ProducesAttribute.cs (1)
115var contentType = new MediaType(arg);
ProducesResponseTypeAttribute.cs (1)
116var mediaType = new MediaType(type);
Microsoft.AspNetCore.Mvc.ViewFeatures (2)
ViewComponentResultExecutor.cs (1)
90MediaType.GetEncoding,
ViewExecutor.cs (1)
193MediaType.GetEncoding,