• Articles
  • API Documentation
Search Results for

    Show / Hide Table of Contents
    • SixLabors.ImageSharp.Web
      • CaseHandlingUriBuilder
      • CaseHandlingUriBuilder.CaseHandling
      • ExifOrientationUtilities
      • FormattedImage
      • FormatUtilities
      • HMACUtilities
      • ImageCacheMetadata
      • ImageMetadata
    • SixLabors.ImageSharp.Web.Caching
      • ICacheHash
      • ICacheKey
      • IImageCache
      • LegacyV1CacheKey
      • PhysicalFileSystemCache
      • PhysicalFileSystemCacheOptions
      • SHA256CacheHash
      • UriAbsoluteCacheKey
      • UriAbsoluteLowerInvariantCacheKey
      • UriRelativeCacheKey
      • UriRelativeLowerInvariantCacheKey
    • SixLabors.ImageSharp.Web.Commands
      • CommandCollection
      • CommandCollectionExtensions
      • CommandParser
      • IRequestParser
      • PresetOnlyQueryCollectionRequestParser
      • PresetOnlyQueryCollectionRequestParserOptions
      • QueryCollectionRequestParser
    • SixLabors.ImageSharp.Web.Commands.Converters
      • ArrayConverter<T>
      • ColorConverter
      • EnumConverter
      • ICommandConverter
      • ICommandConverter<T>
      • IntegralNumberConverter<T>
      • ListConverter<T>
      • SimpleCommandConverter<T>
    • SixLabors.ImageSharp.Web.DependencyInjection
      • ApplicationBuilderExtensions
      • IImageSharpBuilder
      • ImageSharpBuilderExtensions
      • ServiceCollectionExtensions
    • SixLabors.ImageSharp.Web.Middleware
      • ImageCommandContext
      • ImageProcessingContext
      • ImageSharpMiddleware
      • ImageSharpMiddlewareOptions
    • SixLabors.ImageSharp.Web.Processors
      • AutoOrientWebProcessor
      • BackgroundColorWebProcessor
      • FormatWebProcessor
      • IImageWebProcessor
      • QualityWebProcessor
      • ResizeWebProcessor
    • SixLabors.ImageSharp.Web.Providers
      • FileProviderImageProvider
      • IImageProvider
      • PhysicalFileSystemProvider
      • PhysicalFileSystemProviderOptions
      • ProcessingBehavior
      • WebRootImageProvider
    • SixLabors.ImageSharp.Web.Resolvers
      • FileProviderImageResolver
      • IImageCacheResolver
      • IImageResolver
      • PhysicalFileSystemCacheResolver
    • SixLabors.ImageSharp.Web.Synchronization
      • AsyncKeyLock<TKey>
      • AsyncKeyReaderWriterLock<TKey>
      • AsyncLock
      • AsyncReaderWriterLock
      • RefCountedConcurrentDictionary<TKey, TValue>

    Class FormatUtilities

    Contains various helper methods for working with image formats based on the given configuration.

    Inheritance
    Object
    FormatUtilities
    Inherited Members
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Object.ReferenceEquals(Object, Object)
    Object.ToString()
    Namespace: SixLabors.ImageSharp.Web
    Assembly: SixLabors.ImageSharp.Web.dll
    Syntax
    public sealed class FormatUtilities

    Constructors

    | Improve this Doc View Source

    FormatUtilities(IOptions<ImageSharpMiddlewareOptions>)

    Initializes a new instance of the FormatUtilities class.

    Declaration
    public FormatUtilities(IOptions<ImageSharpMiddlewareOptions> options)
    Parameters
    Type Name Description
    IOptions<ImageSharpMiddlewareOptions> options

    The middleware options.

    Methods

    | Improve this Doc View Source

    GetExtensionFromContentType(String)

    Gets the correct extension for the given content type (mime-type).

    Declaration
    public string GetExtensionFromContentType(string contentType)
    Parameters
    Type Name Description
    String contentType

    The content type (mime-type).

    Returns
    Type Description
    String

    The String.

    | Improve this Doc View Source

    TryGetExtensionFromUri(String, out String)

    Gets the file extension for the given image uri.

    Declaration
    public bool TryGetExtensionFromUri(string uri, out string extension)
    Parameters
    Type Name Description
    String uri

    The full request uri.

    String extension

    When this method returns, contains the file extension for the image source, if the path exists; otherwise, the default value for the type of the path parameter. This parameter is passed uninitialized.

    Returns
    Type Description
    Boolean

    true if the uri contains an extension; otherwise, false.

    • Improve this Doc
    • View Source
    In This Article
    Back to top Generated by DocFX