Show / Hide Table of Contents

Class SceneComponentFinder<TComponentToFind, TNode, TComponent>

Allows various searches over scene graphs. This class can be used directly but will be more commonly used by calling one of the Find extension methods declared in SceneFinderExtensions.

Inheritance
System.Object
Visitor<TNode, TComponent>
SceneFinderBase<TComponentToFind, TNode, TComponent>
SceneComponentFinder<TComponentToFind, TNode, TComponent>
Implements
System.Collections.Generic.IEnumerator<TComponentToFind>
System.Collections.IEnumerator
System.IDisposable
Inherited Members
SceneFinderBase<TComponentToFind, TNode, TComponent>._rootList
SceneFinderBase<TComponentToFind, TNode, TComponent>._match
SceneFinderBase<TComponentToFind, TNode, TComponent>.Reset()
Visitor<TNode, TComponent>.IgnoreInactiveComponents
Visitor<TNode, TComponent>.Traverse(TNode)
Visitor<TNode, TComponent>.Traverse(IEnumerable<TNode>)
Visitor<TNode, TComponent>.InitState()
Visitor<TNode, TComponent>.PushState()
Visitor<TNode, TComponent>.PopState()
Visitor<TNode, TComponent>.CurrentNode
Visitor<TNode, TComponent>.CurrentComponent
Visitor<TNode, TComponent>.YieldOnCurrentNode
Visitor<TNode, TComponent>.YieldOnCurrentComponent
Visitor<TNode, TComponent>.YieldEnumeration
Visitor<TNode, TComponent>.EnumInit(IEnumerator<TNode>)
Visitor<TNode, TComponent>.EnumMoveNext()
Visitor<TNode, TComponent>.EnumMoveNextNoComponent()
Visitor<TNode, TComponent>.VisitorModules
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Fusee.Xene
Assembly: Fusee.Xene.dll
Syntax
public class SceneComponentFinder<TComponentToFind, TNode, TComponent> : SceneFinderBase<TComponentToFind, TNode, TComponent>, IEnumerator<TComponentToFind>, IEnumerator, IDisposable where TComponentToFind : TComponent where TNode : class, INode where TComponent : class, IComponent
Type Parameters
Name Description
TComponentToFind

The concrete type of the components to look for.

TNode

The concrete base type of nodes used as building blocks for scene graphs.

TComponent

The concrete base type of components used as building blocks for scene graphs.

Remarks

Search criteria can be passed as (lambda) predicates matching scene components. Results are returned as enumerator. Instead of directly using this class, users should use one of the FindNodes or FindComponents extension methods.

Constructors

SceneComponentFinder(IEnumerator<TNode>, Predicate<TComponentToFind>)

Initializes a new instance of the SceneComponentFinder<TComponentToFind, TNode, TComponent> class.

Declaration
public SceneComponentFinder(IEnumerator<TNode> rootList, Predicate<TComponentToFind> match)
Parameters
Type Name Description
System.Collections.Generic.IEnumerator<TNode> rootList

The root list.

System.Predicate<TComponentToFind> match

The match.

Properties

Current

Gets the element in the collection at the current position of the enumerator.

Declaration
public TComponentToFind Current { get; }
Property Value
Type Description
TComponentToFind

Methods

Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

Declaration
public void Dispose()

Dispose(Boolean)

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

Declaration
protected virtual void Dispose(bool disposing)
Parameters
Type Name Description
System.Boolean disposing

If disposing equals true, the method has been called directly or indirectly by a user's code. Managed and unmanaged resources can be disposed. If disposing equals false, the method has been called by the runtime from inside the finalizer and you should not reference other objects. Only unmanaged resources can be disposed.

MatchComponent(TComponentToFind)

Reflected Viserator Callback. Performs the match test on the specified component.

Declaration
protected void MatchComponent(TComponentToFind component)
Parameters
Type Name Description
TComponentToFind component

The component to check for the match.

MoveNext()

Advances the enumerator to the next element of the collection.

Declaration
public bool MoveNext()
Returns
Type Description
System.Boolean

true if the enumerator was successfully advanced to the next element; false if the enumerator has passed the end of the collection.

Explicit Interface Implementations

IEnumerator.Current

Declaration
object IEnumerator.Current { get; }
Returns
Type Description
System.Object

Implements

System.Collections.Generic.IEnumerator<T>
System.Collections.IEnumerator
System.IDisposable
Generated by DocFX
GitHub Repo
Back to top