Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


GetValue

Gets the value of a property by name.
Read time 1 minuteLast updated 6 days ago

Definition

  • Type: Method
  • Namespace: Unity.Properties
  • Assembly: UnityEngine.PropertiesModule

GetValue<T, U>(T, string)

Gets the value of a property by name.
public static TValue GetValue<TContainer, TValue>(TContainer container, string name)

Parameters

container

T
The container whose property value will be returned.

name

The name of the property to get.

Returns

Type

Description

TThe value for the specified name.

GetValue<T, U>(T, string)

Gets the value of a property by name.
public static TValue GetValue<TContainer, TValue>(ref TContainer container, string name)

Parameters

container

T
The container whose property value will be returned.

name

The name of the property to get.

Returns

Type

Description

TThe value for the specified name.

GetValue<T, U>(T, PropertyPath)

Gets the value of a property by path.
public static TValue GetValue<TContainer, TValue>(TContainer container, in PropertyPath path)

Parameters

container

T
The container whose property value will be returned.

The path of the property to get.

Returns

Type

Description

TThe value at the specified path.

GetValue<T, U>(T, PropertyPath)

Gets the value of a property by path.
public static TValue GetValue<TContainer, TValue>(ref TContainer container, in PropertyPath path)

Parameters

container

T
The container whose property value will be returned.

The path of the property to get.

Returns

Type

Description

TThe value at the specified path.