ClassElement
Base class for nodes that may have children.
Definition
Namespace:Telerik.Core
Assembly:Telerik.WinUI.Controls.dll
Syntax:
public abstract class Element : Node, INotifyPropertyChanged
Inheritance: objectPropertyBagObjectNodeElement
Derived Classes:
Implements:
Inherited Members
Constructors
Properties
Presenter
Gets the IElementPresenter instance where this element is presented.
Declaration
public override IElementPresenter Presenter { get; }
Property Value
Overrides
Methods
EnumDescendants()
Provides flexible routine for traversing all descendants of this instance.
EnumDescendants(Predicate<Node>, TreeTraversalMode)
Provides flexible routine for traversing all descendants of this instance that match the provided predicate.
Declaration
public IEnumerable<Node> EnumDescendants(Predicate<Node> predicate, TreeTraversalMode traverseMode)
Parameters
predicate
The predicate that defines the match criteria.
traverseMode
The mode used to traverse the subtree.
Returns
EnumDescendants(TreeTraversalMode)
Provides flexible routine for traversing all descendants of this instance.
Declaration
public IEnumerable<Node> EnumDescendants(TreeTraversalMode traverseMode)
Parameters
traverseMode
The mode used to traverse the subtree.
Returns
FindAncestor<T>()
Searches up the parent chain and returns the first parent of type T.
Declaration
public T FindAncestor<T>() where T : Element
Returns
T
FindDescendant(Predicate<Node>)
Searches down the subtree of elements, using breadth-first approach, and returns the first descendant of type T.
FindDescendant<T>()
Searches down the subtree of elements, using breadth-first approach, and returns the first descendant of type T.
Declaration
public T FindDescendant<T>() where T : Node
Returns
T
IsAncestorOf(Node)
Gets a boolean value that determines whether a given element resides in the element hierarchy of this element.