001: /*
002: * This class was automatically generated with
003: * <a href="http://www.castor.org">Castor 0.9.4.3</a>, using an XML
004: * Schema.
005: * $Id$
006: */
007:
008: package com.calipso.reportgenerator.reportdefinitions;
009:
010: //---------------------------------/
011: //- Imported classes and packages -/
012: //---------------------------------/
013:
014: import com.calipso.reportgenerator.reportdefinitions.types.ReportDataType;
015: import java.io.IOException;
016: import java.io.Reader;
017: import java.io.Serializable;
018: import java.io.Writer;
019: import org.exolab.castor.xml.MarshalException;
020: import org.exolab.castor.xml.Marshaller;
021: import org.exolab.castor.xml.Unmarshaller;
022: import org.exolab.castor.xml.ValidationException;
023: import org.xml.sax.ContentHandler;
024:
025: /**
026: * Class DimensionSourceDefinition.
027: *
028: * @version $Revision$ $Date$
029: */
030: public class DimensionSourceDefinition implements java.io.Serializable {
031:
032: //--------------------------/
033: //- Class/Member Variables -/
034: //--------------------------/
035:
036: /**
037: * Field _name
038: */
039: private java.lang.String _name;
040:
041: /**
042: * Field _description
043: */
044: private java.lang.String _description;
045:
046: /**
047: * Field _dataType
048: */
049: private com.calipso.reportgenerator.reportdefinitions.types.ReportDataType _dataType;
050:
051: /**
052: * Field _calculated
053: */
054: private boolean _calculated;
055:
056: /**
057: * keeps track of state for field: _calculated
058: */
059: private boolean _has_calculated;
060:
061: /**
062: * Field _expression
063: */
064: private java.lang.String _expression;
065:
066: /**
067: * Field _externalData
068: */
069: private java.lang.String _externalData;
070:
071: /**
072: * Field _indexed
073: */
074: private boolean _indexed;
075:
076: /**
077: * keeps track of state for field: _indexed
078: */
079: private boolean _has_indexed;
080:
081: //----------------/
082: //- Constructors -/
083: //----------------/
084:
085: public DimensionSourceDefinition() {
086: super ();
087: } //-- com.calipso.reportgenerator.reportdefinitions.DimensionSourceDefinition()
088:
089: //-----------/
090: //- Methods -/
091: //-----------/
092:
093: /**
094: * Method deleteCalculated
095: */
096: public void deleteCalculated() {
097: this ._has_calculated = false;
098: } //-- void deleteCalculated()
099:
100: /**
101: * Method deleteIndexed
102: */
103: public void deleteIndexed() {
104: this ._has_indexed = false;
105: } //-- void deleteIndexed()
106:
107: /**
108: * Method getCalculatedReturns the value of field 'calculated'.
109: *
110: * @return the value of field 'calculated'.
111: */
112: public boolean getCalculated() {
113: return this ._calculated;
114: } //-- boolean getCalculated()
115:
116: /**
117: * Method getDataTypeReturns the value of field 'dataType'.
118: *
119: * @return the value of field 'dataType'.
120: */
121: public com.calipso.reportgenerator.reportdefinitions.types.ReportDataType getDataType() {
122: return this ._dataType;
123: } //-- com.calipso.reportgenerator.reportdefinitions.types.ReportDataType getDataType()
124:
125: /**
126: * Method getDescriptionReturns the value of field
127: * 'description'.
128: *
129: * @return the value of field 'description'.
130: */
131: public java.lang.String getDescription() {
132: return this ._description;
133: } //-- java.lang.String getDescription()
134:
135: /**
136: * Method getExpressionReturns the value of field 'expression'.
137: *
138: * @return the value of field 'expression'.
139: */
140: public java.lang.String getExpression() {
141: return this ._expression;
142: } //-- java.lang.String getExpression()
143:
144: /**
145: * Method getExternalDataReturns the value of field
146: * 'externalData'.
147: *
148: * @return the value of field 'externalData'.
149: */
150: public java.lang.String getExternalData() {
151: return this ._externalData;
152: } //-- java.lang.String getExternalData()
153:
154: /**
155: * Method getIndexedReturns the value of field 'indexed'.
156: *
157: * @return the value of field 'indexed'.
158: */
159: public boolean getIndexed() {
160: return this ._indexed;
161: } //-- boolean getIndexed()
162:
163: /**
164: * Method getNameReturns the value of field 'name'.
165: *
166: * @return the value of field 'name'.
167: */
168: public java.lang.String getName() {
169: return this ._name;
170: } //-- java.lang.String getName()
171:
172: /**
173: * Method hasCalculated
174: */
175: public boolean hasCalculated() {
176: return this ._has_calculated;
177: } //-- boolean hasCalculated()
178:
179: /**
180: * Method hasIndexed
181: */
182: public boolean hasIndexed() {
183: return this ._has_indexed;
184: } //-- boolean hasIndexed()
185:
186: /**
187: * Method isValid
188: */
189: public boolean isValid() {
190: try {
191: validate();
192: } catch (org.exolab.castor.xml.ValidationException vex) {
193: return false;
194: }
195: return true;
196: } //-- boolean isValid()
197:
198: /**
199: * Method marshal
200: *
201: * @param out
202: */
203: public void marshal(java.io.Writer out)
204: throws org.exolab.castor.xml.MarshalException,
205: org.exolab.castor.xml.ValidationException {
206:
207: Marshaller.marshal(this , out);
208: } //-- void marshal(java.io.Writer)
209:
210: /**
211: * Method marshal
212: *
213: * @param handler
214: */
215: public void marshal(org.xml.sax.ContentHandler handler)
216: throws java.io.IOException,
217: org.exolab.castor.xml.MarshalException,
218: org.exolab.castor.xml.ValidationException {
219:
220: Marshaller.marshal(this , handler);
221: } //-- void marshal(org.xml.sax.ContentHandler)
222:
223: /**
224: * Method setCalculatedSets the value of field 'calculated'.
225: *
226: * @param calculated the value of field 'calculated'.
227: */
228: public void setCalculated(boolean calculated) {
229: this ._calculated = calculated;
230: this ._has_calculated = true;
231: } //-- void setCalculated(boolean)
232:
233: /**
234: * Method setDataTypeSets the value of field 'dataType'.
235: *
236: * @param dataType the value of field 'dataType'.
237: */
238: public void setDataType(
239: com.calipso.reportgenerator.reportdefinitions.types.ReportDataType dataType) {
240: this ._dataType = dataType;
241: } //-- void setDataType(com.calipso.reportgenerator.reportdefinitions.types.ReportDataType)
242:
243: /**
244: * Method setDescriptionSets the value of field 'description'.
245: *
246: * @param description the value of field 'description'.
247: */
248: public void setDescription(java.lang.String description) {
249: this ._description = description;
250: } //-- void setDescription(java.lang.String)
251:
252: /**
253: * Method setExpressionSets the value of field 'expression'.
254: *
255: * @param expression the value of field 'expression'.
256: */
257: public void setExpression(java.lang.String expression) {
258: this ._expression = expression;
259: } //-- void setExpression(java.lang.String)
260:
261: /**
262: * Method setExternalDataSets the value of field
263: * 'externalData'.
264: *
265: * @param externalData the value of field 'externalData'.
266: */
267: public void setExternalData(java.lang.String externalData) {
268: this ._externalData = externalData;
269: } //-- void setExternalData(java.lang.String)
270:
271: /**
272: * Method setIndexedSets the value of field 'indexed'.
273: *
274: * @param indexed the value of field 'indexed'.
275: */
276: public void setIndexed(boolean indexed) {
277: this ._indexed = indexed;
278: this ._has_indexed = true;
279: } //-- void setIndexed(boolean)
280:
281: /**
282: * Method setNameSets the value of field 'name'.
283: *
284: * @param name the value of field 'name'.
285: */
286: public void setName(java.lang.String name) {
287: this ._name = name;
288: } //-- void setName(java.lang.String)
289:
290: /**
291: * Method unmarshal
292: *
293: * @param reader
294: */
295: public static com.calipso.reportgenerator.reportdefinitions.DimensionSourceDefinition unmarshal(
296: java.io.Reader reader)
297: throws org.exolab.castor.xml.MarshalException,
298: org.exolab.castor.xml.ValidationException {
299: return (com.calipso.reportgenerator.reportdefinitions.DimensionSourceDefinition) Unmarshaller
300: .unmarshal(
301: com.calipso.reportgenerator.reportdefinitions.DimensionSourceDefinition.class,
302: reader);
303: } //-- com.calipso.reportgenerator.reportdefinitions.DimensionSourceDefinition unmarshal(java.io.Reader)
304:
305: /**
306: * Method validate
307: */
308: public void validate()
309: throws org.exolab.castor.xml.ValidationException {
310: org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
311: validator.validate(this );
312: } //-- void validate()
313:
314: }
|