Code example for TreeSet

Methods: addAll

0
 
    /** 
     * @return a sorted set of the attributes' names 
     */ 
    private SortedSet<String> sortedNames() {
        SortedSet<String> names = new TreeSet<String>();
        names.addAll(getAttributes().keySet());
        return names;
    } 
 
}