Set<String> keySet = resourceList.keySet();
String[] sortedKeys = keySet.toArray(new String[keySet.size()]);
Arrays.sort(sortedKeys);
for (String key : sortedKeys) {
out.println();
AnnotationsResource annotResource = resourceList.getAnnotationsResource(
logger, key);
if (annotResource != null) {
// Write comments from the annotations.
writeAnnotComments(out, annotResource, key);
}