KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > it > businesslogic > ireport > crosstab > CrosstabGroup


1 /*
2  * Copyright (C) 2005 - 2006 JasperSoft Corporation. All rights reserved.
3  * http://www.jaspersoft.com.
4  *
5  * Unless you have purchased a commercial license agreement from JasperSoft,
6  * the following license terms apply:
7  *
8  * This program is free software; you can redistribute it and/or modify
9  * it under the terms of the GNU General Public License version 2 as published by
10  * the Free Software Foundation.
11  *
12  * This program is distributed WITHOUT ANY WARRANTY; and without the
13  * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
14  * See the GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with this program; if not, see http://www.gnu.org/licenses/gpl.txt
18  * or write to:
19  *
20  * Free Software Foundation, Inc.,
21  * 59 Temple Place - Suite 330,
22  * Boston, MA USA 02111-1307
23  *
24  *
25  *
26  *
27  * CrosstabGroup.java
28  *
29  * Created on 5 gennaio 2006, 15.52
30  *
31  */

32
33 package it.businesslogic.ireport.crosstab;
34
35 /**
36  *
37  * @author Administrator
38  */

39 public class CrosstabGroup {
40     
41     
42     protected CrosstabCell headerCell = null;
43     protected CrosstabCell totalCell = null;
44     private int size = 0;
45     
46     private boolean hasHeader = true;
47     private boolean hasTotal = true;
48     
49     protected String JavaDoc name = "";
50     protected String JavaDoc totalPosition = "None";
51     protected String JavaDoc headerPosition = "";
52     
53     private String JavaDoc bucketExpression = "";
54     private String JavaDoc bucketExpressionClass = "";
55     private String JavaDoc bucketOrder = "Ascending";
56     private String JavaDoc bucketComparatorExpression = "";
57     
58     /** Creates a new instance of CrosstabGroup */
59     public CrosstabGroup() {
60     }
61
62     public CrosstabCell getHeaderCell() {
63         return headerCell;
64     }
65
66     public void setHeaderCell(CrosstabCell headerCell) {
67         this.headerCell = headerCell;
68     }
69
70     public CrosstabCell getTotalCell() {
71         return totalCell;
72     }
73
74     public void setTotalCell(CrosstabCell totalCell) {
75         this.totalCell = totalCell;
76     }
77
78     public String JavaDoc getName() {
79         return name;
80     }
81
82     public void setName(String JavaDoc name) {
83         this.name = name;
84     }
85
86     public String JavaDoc getTotalPosition() {
87         return totalPosition;
88     }
89
90     public void setTotalPosition(String JavaDoc totalPosition) {
91         this.totalPosition = totalPosition;
92     }
93
94     public String JavaDoc getHeaderPosition() {
95         return headerPosition;
96     }
97
98     public void setHeaderPosition(String JavaDoc headerPosition) {
99         this.headerPosition = headerPosition;
100     }
101
102     public String JavaDoc getBucketExpression() {
103         return bucketExpression;
104     }
105
106     public void setBucketExpression(String JavaDoc bucketExpression) {
107         this.bucketExpression = bucketExpression;
108     }
109
110     public String JavaDoc getBucketOrder() {
111         return bucketOrder;
112     }
113
114     public void setBucketOrder(String JavaDoc bucketOrder) {
115         this.bucketOrder = bucketOrder;
116     }
117
118     public String JavaDoc getBucketComparatorExpression() {
119         return bucketComparatorExpression;
120     }
121
122     public void setBucketComparatorExpression(String JavaDoc bucketComparatorExpression) {
123         this.bucketComparatorExpression = bucketComparatorExpression;
124     }
125
126     public int getSize() {
127         return size;
128     }
129
130     public void setSize(int size) {
131         this.size = size;
132     }
133
134     public boolean isHasHeader() {
135         return true;
136     }
137
138     public void setHasHeader(boolean hasHeader) {
139         this.hasHeader = hasHeader;
140     }
141
142     public String JavaDoc getBucketExpressionClass() {
143         return bucketExpressionClass;
144     }
145
146     public void setBucketExpressionClass(String JavaDoc bucketExpressionClass) {
147         this.bucketExpressionClass = bucketExpressionClass;
148     }
149
150     public boolean isHasTotal() {
151         return !getTotalPosition().equals("None");
152     }
153
154     public void setHasTotal(boolean hasTotal) {
155         this.hasTotal = hasTotal;
156     }
157     
158     public String JavaDoc toString()
159     {
160         return "" + name;
161     }
162     
163     
164 }
165
Popular Tags