Method GetChildren
GetChildren<T>(VisualElement, bool)
Get child elements of a given type.
Declaration
public static IEnumerable<T> GetChildren<T>(this VisualElement element, bool recursive) where T : VisualElement
Parameters
Type | Name | Description |
---|---|---|
VisualElement | element | The parent element. |
bool | recursive | If true, the search will be recursive. |
Returns
Type | Description |
---|---|
IEnumerable<T> | A list of child elements of the given type. |
Type Parameters
Name | Description |
---|---|
T | The type of the child elements to search for. |
Exceptions
Type | Condition |
---|---|
ArgumentNullException | The VisualElement object can't be null. |