KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > calipso > reportgenerator > reportdefinitions > types > ReportDefinitionReportTypeType


1 /*
2  * This class was automatically generated with
3  * <a HREF="http://www.castor.org">Castor 0.9.4.3</a>, using an XML
4  * Schema.
5  * $Id$
6  */

7
8 package com.calipso.reportgenerator.reportdefinitions.types;
9
10   //---------------------------------/
11
//- Imported classes and packages -/
12
//---------------------------------/
13

14 import java.io.Serializable JavaDoc;
15 import java.util.Enumeration JavaDoc;
16 import java.util.Hashtable JavaDoc;
17 import org.exolab.castor.xml.Marshaller;
18 import org.exolab.castor.xml.Unmarshaller;
19
20 /**
21  * Class ReportDefinitionReportTypeType.
22  *
23  * @version $Revision$ $Date$
24  */

25 public class ReportDefinitionReportTypeType implements java.io.Serializable JavaDoc {
26
27
28       //--------------------------/
29
//- Class/Member Variables -/
30
//--------------------------/
31

32     /**
33      * The CUBE type
34      */

35     public static final int CUBE_TYPE = 0;
36
37     /**
38      * The instance of the CUBE type
39      */

40     public static final ReportDefinitionReportTypeType CUBE = new ReportDefinitionReportTypeType(CUBE_TYPE, "CUBE");
41
42     /**
43      * The CHARTCUBE type
44      */

45     public static final int CHARTCUBE_TYPE = 1;
46
47     /**
48      * The instance of the CHARTCUBE type
49      */

50     public static final ReportDefinitionReportTypeType CHARTCUBE = new ReportDefinitionReportTypeType(CHARTCUBE_TYPE, "CHARTCUBE");
51
52     /**
53      * The ACCUM type
54      */

55     public static final int ACCUM_TYPE = 2;
56
57     /**
58      * The instance of the ACCUM type
59      */

60     public static final ReportDefinitionReportTypeType ACCUM = new ReportDefinitionReportTypeType(ACCUM_TYPE, "ACCUM");
61
62     /**
63      * The GROUP type
64      */

65     public static final int GROUP_TYPE = 3;
66
67     /**
68      * The instance of the GROUP type
69      */

70     public static final ReportDefinitionReportTypeType GROUP = new ReportDefinitionReportTypeType(GROUP_TYPE, "GROUP");
71
72     /**
73      * The STATICSQL type
74      */

75     public static final int STATICSQL_TYPE = 4;
76
77     /**
78      * The instance of the STATICSQL type
79      */

80     public static final ReportDefinitionReportTypeType STATICSQL = new ReportDefinitionReportTypeType(STATICSQL_TYPE, "STATICSQL");
81
82     /**
83      * Field _memberTable
84      */

85     private static java.util.Hashtable JavaDoc _memberTable = init();
86
87     /**
88      * Field type
89      */

90     private int type = -1;
91
92     /**
93      * Field stringValue
94      */

95     private java.lang.String JavaDoc stringValue = null;
96
97
98       //----------------/
99
//- Constructors -/
100
//----------------/
101

102     private ReportDefinitionReportTypeType(int type, java.lang.String JavaDoc value) {
103         super();
104         this.type = type;
105         this.stringValue = value;
106     } //-- com.calipso.reportgenerator.reportdefinitions.types.ReportDefinitionReportTypeType(int, java.lang.String)
107

108
109       //-----------/
110
//- Methods -/
111
//-----------/
112

113     /**
114      * Method enumerateReturns an enumeration of all possible
115      * instances of ReportDefinitionReportTypeType
116      */

117     public static java.util.Enumeration JavaDoc enumerate()
118     {
119         return _memberTable.elements();
120     } //-- java.util.Enumeration enumerate()
121

122     /**
123      * Method getTypeReturns the type of this
124      * ReportDefinitionReportTypeType
125      */

126     public int getType()
127     {
128         return this.type;
129     } //-- int getType()
130

131     /**
132      * Method init
133      */

134     private static java.util.Hashtable JavaDoc init()
135     {
136         Hashtable JavaDoc members = new Hashtable JavaDoc();
137         members.put("CUBE", CUBE);
138         members.put("CHARTCUBE", CHARTCUBE);
139         members.put("ACCUM", ACCUM);
140         members.put("GROUP", GROUP);
141         members.put("STATICSQL", STATICSQL);
142         return members;
143     } //-- java.util.Hashtable init()
144

145     /**
146      * Method toStringReturns the String representation of this
147      * ReportDefinitionReportTypeType
148      */

149     public java.lang.String JavaDoc toString()
150     {
151         return this.stringValue;
152     } //-- java.lang.String toString()
153

154     /**
155      * Method valueOfReturns a new ReportDefinitionReportTypeType
156      * based on the given String value.
157      *
158      * @param string
159      */

160     public static com.calipso.reportgenerator.reportdefinitions.types.ReportDefinitionReportTypeType valueOf(java.lang.String JavaDoc string)
161     {
162         java.lang.Object JavaDoc obj = null;
163         if (string != null) obj = _memberTable.get(string);
164         if (obj == null) {
165             String JavaDoc err = "'" + string + "' is not a valid ReportDefinitionReportTypeType";
166             throw new IllegalArgumentException JavaDoc(err);
167         }
168         return (ReportDefinitionReportTypeType) obj;
169     } //-- com.calipso.reportgenerator.reportdefinitions.types.ReportDefinitionReportTypeType valueOf(java.lang.String)
170

171 }
172
Popular Tags