Since TreeNode isn't exposed on TreeSet anymore, it can be a private class. Otherwise you `object` should be private, and maybe there should be a `value` getter.