TransformExtensions.EnumerateAncestors(Transform, Boolean) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Enumerates the ancestors of the specified transform.
public:
[System::Runtime::CompilerServices::Extension]
static System::Collections::Generic::IEnumerable<UnityEngine::Transform ^> ^ EnumerateAncestors(UnityEngine::Transform ^ startTransform, bool includeSelf);
public static System.Collections.Generic.IEnumerable<UnityEngine.Transform> EnumerateAncestors (this UnityEngine.Transform startTransform, bool includeSelf);
static member EnumerateAncestors : UnityEngine.Transform * bool -> seq<UnityEngine.Transform>
<Extension()>
Public Iterator Function EnumerateAncestors (startTransform As Transform, includeSelf As Boolean) As IEnumerable(Of Transform)
Parameters
- startTransform
- UnityEngine.Transform
Transform for which ancestors must be returned.
- includeSelf
- Boolean
Indicates whether the specified transform should be included.
Returns
IEnumerable<UnityEngine.Transform>
An enumeration of all ancestor transforms of the specified start transform.