GetPath(IMetadata, string, NormalizedPath) Method
Gets the value for the specified key converted to a NormalizedPath. This method never throws an exception. It will return the specified default value if the key is not found.
Namespace
Statiq.Common
Containing Type
IMetadataConversionExtensions

Syntax

public static NormalizedPath GetPath(this IMetadata metadata, string key, in NormalizedPath defaultValue = default(NormalizedPath))

Parameters

Name Type Description
metadata IMetadata The metadata instance.
key string The key of the value to get.
defaultValue NormalizedPath The default value to use if the key is not found.

Return Value

Type Description
NormalizedPath The value for the specified key converted to a NormalizedPath or the specified default value.