Hold a list of items stored in recursive class? Alright, well the title doesn't really explain anything, so I'll show a pared down version of my code:

class Handler {
    Dictionary&lt;object, Leaf&gt; AllItems = new Dictionary&lt;object, Leaf&gt;(); //This list

    Leaf RootLeaf = new Leaf();
    public void Add (object obj)
    {
        Leaf AddedTo = RootLeaf.Add(obj); //Adds to a leaf, then returns the leaf it was added to
        AllItems.Add(obj, AddedTo); //adds references to the obj and the leaf it's in.
    }
}

class Leaf {
    private Leaf _Parent;
    public Leaf SubLeaf;
    public List&lt;object&gt; Children = new List&lt;object&gt;();

    public Leaf (Leaf parent)
    {
        this._Parent = parent;
    }

    public void Add (object obj)
    {
        if (Children.Count &gt; 5)
        {
            SubLeaf = new Leaf();
            return SubLeaf.Add(obj); //recursively return the reference to the end leaf
        }
        Children.Add(obj);
        return this; //start the recursive return
    }

    public Leaf Parent { get { return this._Parent; } }
}


Note: The above isn't real code, just an example of what I plan to do.

So the idea of the above is to organize all the items into leaves, but I need a quick way to loop through every object, and its leaf.  Would doing the above (storing a reference of every object &amp; its parent in a list in the Handler class) cause a drop in performance?  Or would there be a better way to do this?

I hope this was clear enough, if not, please ask any questions.
Well, it's not a tree, it's a linked list, and it won't work properly for more than seven items. After that you will overwrite the SubLeaf variable in the first node, and previously added items will be removed from the list, and AllItems will contain lost items with disowned nodes.

To make the list work you have to check if the node has a next node before creating a new one.

public class Node {

  private Node _next;
  private List&lt;object&gt; _items;

  public Node Previous { get; private set; }

  public Leaf (Leaf previous) {
    _previous = previous;
    _next = null;
    _items = new List&lt;object&gt;(6);
  }

  public void Add(object obj) {
    if (_items.Count == 6) {
      if (_next == null) {
        _next = new Leaf(this);
      }
      return _next.Add(obj);
    }
    _items.Add(obj);
    return this;
  }

}


Note: Consider using an array in the node instead of a list. Creating a list that uses lists seems redundant...

Also, keeping a reference to the last node in the handler would help when you want to add nodes, so that you don't have to loop through all nodes each time.

Putting the objects and their nodes in a list is not needed for looping through them, as you already have all the nodes and the objects. Adding the list would roughly tripple the memory usage and the time to add an item. You would only need another list if you need two completely different ways of accessing the items, for example both predictable enumerating and hash lookup.

To enumerate the list as pairs of objects and nodes, you can put an enumerator in the Node class which gets all objects and their nodes from the current node and forward, so you just use it on the first node to get all objects:

public IEnumerable&lt;KeyValuePair&lt;object,Node&gt;&gt; GetAll() {
  Node node = this;
  while (node != null() {
    foreach (object obj in node._items) {
      yield return new KeyValuePair&lt;object,Node&gt;(obj, node);
    }
    node = node._next;
  }
}