mirror of
https://github.com/Ellpeck/MLEM.git
synced 2024-12-25 01:39:23 +01:00
added a simple GetChildren too
This commit is contained in:
parent
ef677ae441
commit
ff5f1a5b84
1 changed files with 4 additions and 0 deletions
|
@ -136,6 +136,10 @@ namespace Demos {
|
|||
|
||||
// Below are some querying examples that help you find certain elements easily
|
||||
|
||||
var children = root.GetChildren();
|
||||
var totalChildren = root.GetChildren(regardChildrensChildren: true);
|
||||
Console.WriteLine($"The root has {children.Count()} children, but there are {totalChildren.Count()} when regarding children's children");
|
||||
|
||||
var textFields = root.GetChildren<TextField>();
|
||||
Console.WriteLine($"The root has {textFields.Count()} text fields");
|
||||
|
||||
|
|
Loading…
Reference in a new issue