Namespace: | Sirenix.OdinInspector.Editor |
Assembly: | Sirenix.OdinInspector.Editor |
public sealed class PropertyValueEntryAlias<TActualValue, TValue> : PropertyValueEntryAlias, IPropertyValueEntry<TValue>, IPropertyValueEntry, IDisposable, IValueEntryActualValueSetter<TValue>, IValueEntryActualValueSetter
public PropertyValueEntryAlias(PropertyValueEntry valueEntryWeak)
PropertyValueEntry | valueEntryWeak |
System.ArgumentNullException | valueEntry is null |
public override Type BaseValueType { get; }
public override bool DictionaryChangedFromPrefab { get; }
public override bool IsEditable { get; }
public override bool IsMarkedAtomic { get; }
public override bool ListLengthChangedFromPrefab { get; }
public override Type ParentType { get; }
public override InspectorProperty Property { get; }
The actual serialization backend for this value entry, possibly inherited from the serialization backend of the root property this entry is a child of.
Note that this is *not* always equal to SerializationBackend.
public override SerializationBackend SerializationBackend { get; }
A strongly typed smart value that represents the first element of the value entry's value collection, but has "smart logic" for setting the value that detects relevant changes and applies them in parallel.
This lets you often just use the smart value instead of having to deal with the tedium of multiple parallel values.
public TValue SmartValue { get; set; }
public override string TargetReferencePath { get; }
public override Type TypeOfValue { get; }
public override bool ValueChangedFromPrefab { get; }
public override int ValueCount { get; }
public IPropertyValueCollection<TValue> Values { get; }
public override PropertyValueState ValueState { get; }
A weakly typed smart value that represents the first element of the value entry's value collection, but has "smart logic" for setting the value that detects relevant changes and applies them in parallel.
This lets you often just use the smart value instead of having to deal with the tedium of multiple parallel values.
public override object WeakSmartValue { get; set; }
public override IPropertyValueCollection WeakValues { get; }
public override bool ApplyChanges()
System.Boolean | True if any changes were made, otherwise, false. |
public override void Dispose()
protected override sealed void SetActualValue(int index, object value)
System.Int32 | index | |
System.Object | value |
public override void Update()
Determines whether the value at the given selection index is different from the given prefab value, as is relevant for prefab modification checks.
If the value is a reference type, null and type difference is checked. If value is a value type, a comparer from GetEqualityComparerDelegate<T>() is used.
This method is best ignored unless you know what you are doing.
public bool ValueIsPrefabDifferent(TValue value, int index)
TValue | value | The value to check differences against. |
System.Int32 | index | The selection index to compare against. |
System.Boolean |
Determines whether the value at the given selection index is different from the given prefab value, as is relevant for prefab modification checks.
If the value is a reference type, null and type difference is checked. If value is a value type, a comparer from GetEqualityComparerDelegate<T>() is used.
This method is best ignored unless you know what you are doing.
public override bool ValueIsPrefabDifferent(object value, int index)
System.Object | value | The value to check differences against. |
System.Int32 | index | The selection index to compare against. |
System.Boolean |
Checks whether the values in this value entry are equal to the values in another value entry.
Note, both value entries must have the same value type, and must represent values that are .NET value types.
public override bool ValueTypeValuesAreEqual(IPropertyValueEntry other)
Sirenix.OdinInspector.Editor.IPropertyValueEntry | other |
System.Boolean |
public override event Action<int> OnChildValueChanged
public override event Action<int> OnValueChanged