ViewVC Help
View File | Revision Log | Show Annotations | Revision Graph | Root Listing
root/i-scream/projects/cms/source/reports/DBReporter/ReportPage.java
(Generate patch)

Comparing projects/cms/source/reports/DBReporter/ReportPage.java (file contents):
Revision 1.9 by pjm2, Sun Jan 7 19:13:14 2001 UTC vs.
Revision 1.11 by pjm2, Thu Jan 11 19:03:04 2001 UTC

# Line 1 | Line 1
1 < //---PACKAGE DECLARATION---
2 <
3 < //---IMPORTS---
4 <
5 < /**
6 < * An object to store page/link data.
7 < *
8 < * @author  $Author$
9 < * @version $Id$
10 < */
11 < public class ReportPage {
12 <
13 < //---FINAL ATTRIBUTES---
14 <
15 <    /**
16 <     * The current CVS revision of this class
17 <     */
18 <    public final String REVISION = "$Revision$";
19 <    
20 <    public static final int HOUR = 0;
21 <    public static final int DAY = 1;
22 <    public static final int WEEK = 2;
23 <    public static final int MONTH = 3;
24 <    
25 <    
26 < //---STATIC METHODS---
27 <
28 < //---CONSTRUCTORS---
29 <
30 <    public ReportPage(String location, String machine_name, String when, String report, int type){
31 <        
32 <        if (type < HOUR || type > MONTH){
33 <            System.out.println("Could not add the page.");
34 <        }
35 <        
36 <        _location = location;
37 <        _machine_name = machine_name;
38 <        _when = when;
39 <        _report = report;
40 <        _type = type;
41 <    }
42 <
43 < //---PUBLIC METHODS---
44 <
45 <
46 <    /**
47 <     * Overrides the {@link java.lang.Object#toString() Object.toString()}
48 <     * method to provide clean logging (every class should have this).
49 <     *
50 <     * @return the name of this class and its CVS revision
51 <     */
52 <    public String toString() {
53 <        return this.getClass().getName() + "(" + REVISION.substring(11, REVISION.length() - 2) + ")";
54 <    }    
55 <    
56 < //---PRIVATE METHODS---
57 <    
58 <    
59 < //---ACCESSOR/MUTATOR METHODS---
60 <
61 <    public String getLocation(){
62 <        return _location;
63 <    }
64 <    
65 <    public String getMachineName(){
66 <        return _machine_name;
67 <    }
68 <
69 <    public String getWhen(){
70 <        return _when;
71 <    }
72 <    
73 <    public String getReport(){
74 <        return _report;
75 <    }
76 <    
77 <    public int getType(){
78 <        return _type;
79 <    }
80 <
81 <    
82 <    
83 < //---ATTRIBUTES---
84 <
85 <    private String _location;
86 <    private String _machine_name;
87 <    private String _when;
88 <    private String _report;
89 <    private int _type;
90 <
91 < //---STATIC ATTRIBUTES---
92 <    
1 > //---PACKAGE DECLARATION---
2  
3 +
4  
5 + //---IMPORTS---
6  
7 +
8  
9 + /**
10  
11 + * An object to store page/link data.
12  
13 + *
14  
15 + * @author  $Author$
16  
17 + * @version $Id$
18  
19 + */
20  
21 + public class ReportPage {
22  
23 +
24  
25 + //---FINAL ATTRIBUTES---
26  
27 +
28  
29 +    /**
30  
31 +     * The current CVS revision of this class
32  
33 +     */
34  
35 +    public final String REVISION = "$Revision$";
36  
37 +    
38  
39 +    public static final int HOUR = 0;
40  
41 +    public static final int DAY = 1;
42  
43 +    public static final int WEEK = 2;
44  
45 +    public static final int MONTH = 3;
46  
47 +    
48  
49 +    
50  
51 + //---STATIC METHODS---
52  
53 +
54  
55 + //---CONSTRUCTORS---
56  
57 +
58  
59 +    public ReportPage(String location, String machine_name, String when, String report, int type){
60  
61 +        
62  
63 +        if (type < HOUR || type > MONTH){
64  
65 +            System.out.println("Could not add the page.");
66  
67 +        }
68  
69 +        
70  
71 +        _location = location;
72  
73 +        _machine_name = machine_name;
74  
75 +        _when = when;
76  
77 +        _report = report;
78  
79 +        _type = type;
80  
81 +    }
82  
83 +
84  
85 + //---PUBLIC METHODS---
86  
87 +
88  
89 +
90  
91 +    /**
92  
93 +     * Overrides the {@link java.lang.Object#toString() Object.toString()}
94  
95 +     * method to provide clean logging (every class should have this).
96  
97 +     *
98  
99 +     * @return the name of this class and its CVS revision
100  
101 +     */
102  
103 +    public String toString() {
104  
105 +        return this.getClass().getName() + "(" + REVISION.substring(11, REVISION.length() - 2) + ")";
106  
107 +    }    
108  
109 +    
110  
111 + //---PRIVATE METHODS---
112  
113 +    
114  
115 +    
116  
117 + //---ACCESSOR/MUTATOR METHODS---
118  
119 +
120  
121 +    public String getLocation(){
122  
123 +        return _location;
124  
125 +    }
126  
127 +    
128  
129 +    public String getMachineName(){
130  
131 +        return _machine_name;
132  
133 +    }
134  
135 +
136  
137 +    public String getWhen(){
138  
139 +        return _when;
140  
141 +    }
142  
143 +    
144  
145 +    public String getReport(){
146  
147 +        return _report;
148  
149 +    }
150  
151 +    
152  
153 +    public int getType(){
154  
155 +        return _type;
156  
157 +    }
158  
159 +
160  
161 +    
162  
163 +    
164  
165 + //---ATTRIBUTES---
166  
167 +
168  
169 +    private String _location;
170  
171 +    private String _machine_name;
172  
173 +    private String _when;
174  
175 +    private String _report;
176  
177 +    private int _type;
178  
179 +
180  
181 + //---STATIC ATTRIBUTES---
182  
183 +    
184  
185   }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines