Add a new node, with a given label.
Find the node representing a given node, and its label.
Merge two sets. The first argument is a function that takes the labels of the corresponding sets' representatives and computes a new label for the joined set. Returns Nothing if the given nodes are in the same set already.
Re-label a node.
Flatten the disjoint set forest for faster lookups.