Table of Contents

Method GetValue

Namespace
PaintDotNet.FileTypes
Assembly
PaintDotNet.FileTypes.dll

GetValue<TEnum>(IReadOnlyFileTypePropertyBag, string, TEnum)

Retrieves a value from the property bag and parses it using the specified type. If the key does not exist, or if the parsing fails, then the given default value is returned instead.

public static TEnum GetValue<TEnum>(this IReadOnlyFileTypePropertyBag propertyBag, string key, TEnum defaultValue) where TEnum : struct, Enum

Parameters

propertyBag IReadOnlyFileTypePropertyBag
key string
defaultValue TEnum

Returns

TEnum

Type Parameters

TEnum