I have a sentence diagramming problem. So I have a datastructure where a sentence holds sometimes a sentence, a subject, the subject holds sometimes another subject, which holds words, etc. So the nodes can hold instances of the same type as themselves and can hold a variety of kinds of nodes, but necessarily eventually hold a leaf object.
Right now I'm using custom classes and it looks like a muddle.
Is there a built in collection for trees, in the same way that there is a built in Array, Collection, Dictionary, List and Set?