KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > league > util > Round


1 /*
2  * Round.java
3  *
4  * Created on March 16, 2005, 2:24 PM
5  *
6  * To change this template, choose Tools | Options and locate the template under
7  * the Source Creation and Management node. Right-click the template and choose
8  * Open. You can then make changes to the template in the Source Editor.
9  */

10
11 package league.util;
12
13 import java.util.Date JavaDoc;
14 import java.util.Hashtable JavaDoc;
15 import java.util.Vector JavaDoc;
16
17 /**
18  *
19  * @author honza
20  */

21 public class Round extends Object JavaDoc implements java.io.Serializable JavaDoc{
22     private Vector JavaDoc groups=null;
23     private String JavaDoc name=null;
24     private Integer JavaDoc id=null;
25     private Date JavaDoc startDate=null;
26     
27     public Round() {
28     }
29     
30     /** Creates a new instance of Round */
31     public Round(Integer JavaDoc id, String JavaDoc name, Date JavaDoc startDate, Vector JavaDoc groups) {
32         this.id=id;
33         this.name=name;
34         this.startDate=startDate;
35         this.groups=groups;
36         
37     }
38     
39     public String JavaDoc getName() {
40         return name;
41     }
42     public Integer JavaDoc getId() {
43         return id;
44     }
45     
46     
47     public Date JavaDoc getStartDate() {
48         return startDate;
49     }
50     public Vector JavaDoc getGroups() {
51         return groups;
52     }
53     public int getGroupsCount() {
54         if (groups==null) return -1;
55         return groups.size();
56     }
57     public Group getGroupAt(int i) {
58         if (groups==null) return null;
59         return (Group) groups.elementAt(i);
60     }
61     public String JavaDoc toString() {
62         return getName();
63     }
64 }
65
Popular Tags