I think this would be more easily done by using a TreeMap.  The keys (rule names) would already be in order then, so there would be no need to create a separate list of them, and sort it.