TryGetComponent

public bool TryGetComponent(string name, out Component value) ;

Get the value of the Component type.

Parameter Name Description
name Name.
value The value you get.

The true when there parameters of the specified name.

public bool TryGetComponent(int id, out Component value) ;

Get the value of the Component type.

Parameter Name Description
id ID.
value The value you get.

The true when there parameters of the specified name.

public bool TryGetComponent<TComponent>(string name, out TComponent value) ;

Get the value of the Component type.

Type Parameter Name Description Type Constraints
TComponent Type of Component to get
Parameter Name Description
name Name.
value The value you get.

The true when there parameters of the specified name.

public bool TryGetComponent<TComponent>(int id, out TComponent value) ;

Get the value of the Component type.

Type Parameter Name Description Type Constraints
TComponent Type of Component to get
Parameter Name Description
id ID.
value The value you get.

The true when there parameters of the specified name.