Thursday, February 23, 2012

Show the content of set


    
public void showSetOntent(Set<LongsetLongs){
        if(
setLongs==null || setLongs.isEmpty()){
            return;
        }
       
        
Iterator<Longiterator setLongs.iterator();
        while(
iterator.hasNext()){
            
System.out.println("Show current content = "+iterator.next());
        }
        }

No comments:

Post a Comment