This creates a new metadata value based on the specified delegate that will get
evaluated on every value request. Note that the delegate function should be thread-safe.
- Namespace
- Statiq
.Common - Containing Type
- MetadataItem
Syntax
public MetadataItem(string key, Func<IMetadata, object> value, bool cacheValue = false)
Parameters
Name | Type | Description |
---|---|---|
key | string | The key. |
value | Func |
The value delegate. |
cacheValue | bool | if set to true , cache the value after the first request. |