- Namespace
- Statiq
.Common - Base Types
-
- object
graph BT
Type-->Base0["object"]
Type["IMetadataGetExtensions"]
class Type type-node
Syntax
public static class IMetadataGetExtensions
Methods
Name | Return Value | Summary |
---|---|---|
FilterMetadata |
IMetadata |
Gets a new filtered
IMetadata containing only the specified keys and their values. If a key is not present in the current
metadata, it will be ignored and will not be copied to the new metadata object.
static
|
Get |
object |
Gets the value for the specified key. This method never throws an exception. It will return the specified
default value or null if the key is not found or is
null .
static
|
Get |
T |
Gets the value for the specified key. This method never throws an exception. It will return the specified
default value if the key is not found or is
null .
static
|
Get |
T |
Gets the value for the specified key converted to the specified type.
This method never throws an exception. It will return default(T) if the key is not found,
is
null , or the value cannot be converted to T.
static
|
GetEnumerable |
IEnumerable |
Gets an enumerable that enumerates key-value pairs.
static
|
GetRaw |
object |
Gets the raw value for the specified key. This method will not materialize
IMetadataValue
values the way other get methods will. A System.Collections.Generic.KeyNotFoundException will be thrown
for missing keys.
static
|
GetRawEnumerable |
IEnumerable |
Gets an enumerable that enumerates raw key-value pairs
(I.e., the values have not been expanded similar to
TryGetRaw(string, object) ).
static
|
TryGetValue |
bool |
Tries to get the value for the specified key.
static
|
WithoutSettings |
IMetadata |
static
|