Class DefaultValueMetadata
Abstract class that could be overloaded in order to define how to get default value of an PropertyKey.
public abstract class DefaultValueMetadata : PropertyKeyMetadata- Inheritance
- 
      objectDefaultValueMetadata
- Derived
Properties
KeepValue
Gets a value indicating whether this value is kept.
public virtual bool KeepValue { get; }Property Value
- bool
- trueif this value is kept; otherwise,- false.
PropertyUpdateCallback
Gets or sets the property update callback.
public PropertyContainer.PropertyUpdatedDelegate? PropertyUpdateCallback { get; set; }Property Value
- PropertyContainer.PropertyUpdatedDelegate
- The property update callback. 
Methods
Delegate<T>(DefaultValueCallback)
public static DelegateDefaultValueMetadata<T> Delegate<T>(DelegateDefaultValueMetadata<T>.DefaultValueCallback callback)Parameters
- callbackDelegateDefaultValueMetadata<T>.DefaultValueCallback
Returns
Type Parameters
- T
GetDefaultValue(ref PropertyContainer)
Gets the default value of an external property, and specify if this default value should be kept. It could be usefull with properties with default values depending of its container, especially if they are long to generate. An example would be collision data, which should be generated only once.
public abstract object GetDefaultValue(ref PropertyContainer obj)Parameters
- objPropertyContainer
- The property container. 
Returns
- object
- The default value. 
Static<T>(T, bool)
public static StaticDefaultValueMetadata<T> Static<T>(T defaultValue, bool keepDefaultValue = false)Parameters
- defaultValueT
- keepDefaultValuebool
Returns
Type Parameters
- T