intermediate/StringCollection

From ggc

Jump to: navigation, search

01 package intermediate;
02 //start auto-imports
03 import java.util.*;
04 //end auto-imports
05 
06 
07 /**
08  * All about my helper class.
09  @author My Name Here
10  */
11 public class StringCollection
12 {
13   private ArrayList<String> all;
14 
15   public StringCollection()
16   {
17     all=new ArrayList<String>();
18   }
19 
20   public void add(String one)
21   {
22     all.add(one);
23   }
24 
25   public void sortByJam()
26   {
27     ILikeJamComparator compare=new ILikeJamComparator();
28     Collections.sort(all, compare);
29   }
30 
31   public String[] getAll()
32   {
33     return all.toArray(new String[0]);
34   }
35 }


Download/View intermediate/StringCollection.java





Views
Personal tools
Add to 
del.icio.usAdd to 
diggAdd to 
FacebookAdd to 
favoritesAdd to 
GoogleAdd to 
MySpaceAdd to 
PrintAdd to 
SlashdotAdd to 
StumbleUponAdd to 
Twitter