Example #1
0
        private HashSet <int> GetParentsBelowRecursive(BackendData.Foo searchFromThis)
        {
            HashSet <int> parentIDs = new HashSet <int>();

            BackendData.GetParentsBelowRecursive(searchFromThis, parentIDs);
            return(parentIDs);
        }
Example #2
0
        private HashSet <int> GetParentsBelowRecursive(BackendData.Foo searchFromThis)
        {
            HashSet <int> hashSet = new HashSet <int>();

            BackendData.GetParentsBelowRecursive(searchFromThis, hashSet);
            return(hashSet);
        }
Example #3
0
 private static void GetParentsBelowRecursive(BackendData.Foo item, HashSet <int> parentIDs)
 {
     if (!item.hasChildren)
     {
         return;
     }
     parentIDs.Add(item.id);
     foreach (BackendData.Foo current in item.children)
     {
         BackendData.GetParentsBelowRecursive(current, parentIDs);
     }
 }
Example #4
0
 private static void GetParentsBelowRecursive(BackendData.Foo item, HashSet <int> parentIDs)
 {
     if (!item.hasChildren)
     {
         return;
     }
     parentIDs.Add(item.id);
     using (List <BackendData.Foo> .Enumerator enumerator = item.children.GetEnumerator())
     {
         while (enumerator.MoveNext())
         {
             BackendData.GetParentsBelowRecursive(enumerator.Current, parentIDs);
         }
     }
 }