Class UnityHierarchyUtils
Helpers for navigating and querying the Unity scene hierarchy
Inheritance
UnityHierarchyUtils
Assembly: Serenity.UnityGlobal.Infrastructure.dll
Syntax
public static class UnityHierarchyUtils
Methods
FindChildrenWithTag(GameObject, string)
Declaration
public static GameObject FindChildrenWithTag(GameObject gO, string tag)
Parameters
| Type |
Name |
Description |
| GameObject |
gO |
|
| string |
tag |
|
Returns
| Type |
Description |
| GameObject |
|
FindChildrensWithTag(GameObject, string)
Declaration
public static List<GameObject> FindChildrensWithTag(GameObject gO, string tag)
Parameters
| Type |
Name |
Description |
| GameObject |
gO |
|
| string |
tag |
|
Returns
| Type |
Description |
| List<GameObject> |
|
FindComponent<T>()
Declaration
public static T FindComponent<T>() where T : MonoBehaviour
Returns
Type Parameters
FindComponents<T>()
Declaration
public static T[] FindComponents<T>() where T : MonoBehaviour
Returns
Type Parameters
FindUIChildrenWithTag(GameObject, string)
Declaration
public static GameObject FindUIChildrenWithTag(GameObject gO, string tag)
Parameters
| Type |
Name |
Description |
| GameObject |
gO |
|
| string |
tag |
|
Returns
| Type |
Description |
| GameObject |
|
FindUIChildrensWithTag(GameObject, string)
Declaration
public static List<GameObject> FindUIChildrensWithTag(GameObject gO, string tag)
Parameters
| Type |
Name |
Description |
| GameObject |
gO |
|
| string |
tag |
|
Returns
| Type |
Description |
| List<GameObject> |
|
Declaration
public static RectTransform[] GetAllRectTransformsInHierarchy(GameObject root, bool includeRoot = true)
Parameters
| Type |
Name |
Description |
| GameObject |
root |
|
| bool |
includeRoot |
|
Returns
| Type |
Description |
| RectTransform[] |
|
GetGameObjectPath(GameObject)
Declaration
public static string GetGameObjectPath(GameObject obj)
Parameters
| Type |
Name |
Description |
| GameObject |
obj |
|
Returns
Declaration
public static List<GameObject> GetInmediateChildren(GameObject obj)
Parameters
| Type |
Name |
Description |
| GameObject |
obj |
|
Returns
| Type |
Description |
| List<GameObject> |
|
Declaration
public static bool HasParentLayoutGroup(Transform t)
Parameters
| Type |
Name |
Description |
| Transform |
t |
|
Returns
TryFindFirstImplementer<TInterface>(out TInterface)
Declaration
public static bool TryFindFirstImplementer<TInterface>(out TInterface instance)
Parameters
| Type |
Name |
Description |
| TInterface |
instance |
|
Returns
Type Parameters
| Name |
Description |
| TInterface |
|