Version 3.3.1.2

AliasGetterSetter<TOwner, TValue, TPropertyOwner, TPropertyValue> class

Namespace: Sirenix.OdinInspector.Editor
Assembly: Sirenix.OdinInspector.Editor
public class AliasGetterSetter<TOwner, TValue, TPropertyOwner, TPropertyValue> : IValueGetterSetter<TOwner, TValue>, IValueGetterSetter
A polymorphic alias for getting and setting the values of an Sirenix.OdinInspector.Editor.IValueGetterSetter<TOwner, TValue>.
Inheritance
  • System.Object
  • AliasGetterSetter<TOwner, TValue, TPropertyOwner, TPropertyValue>

Type Parameters

TOwner

The type of the owner.

TValue

The type of the value.

TPropertyOwner

The type of the property owner.

TPropertyValue

The type of the property value.

Constructors

AliasGetterSetter(IValueGetterSetter<TPropertyOwner, TPropertyValue>)
public AliasGetterSetter(IValueGetterSetter<TPropertyOwner, TPropertyValue> aliasedGetterSetter)
Parameters
Sirenix.OdinInspector.Editor.IValueGetterSetter<TPropertyOwner, TPropertyValue> aliasedGetterSetter

The information.

Exceptions
System.ArgumentNullException

info

Properties

IsReadonly
Whether the value is readonly.
public bool IsReadonly { get; }
OwnerType
Gets the type of the owner.
public Type OwnerType { get; }
ValueType
Gets the type of the value.
public Type ValueType { get; }

Methods

GetValue(ref TOwner)
Gets the value from a given owner.
public TValue GetValue(ref TOwner owner)
Parameters
TOwner owner

The owner.

Returns
TValue

Exceptions
System.ArgumentNullException

owner is null

GetValue(Object)
Gets the value from a given weakly typed owner.
public object GetValue(object owner)
Parameters
System.Object owner

The weakly typed owner.

Returns
System.Object

The found value.

SetValue(ref TOwner, TValue)
Sets the value on a given owner.
public void SetValue(ref TOwner owner, TValue value)
Parameters
TOwner owner

The owner.

TValue value

The value.

SetValue(Object, Object)
Sets the weakly typed value on a given weakly typed owner.
public void SetValue(object owner, object value)
Parameters
System.Object owner

The owner.

System.Object value

The value.