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 org.exolab.castor.mapping.AccessMode;
015: import org.exolab.castor.xml.TypeValidator;
016: import org.exolab.castor.xml.XMLFieldDescriptor;
017: import org.exolab.castor.xml.validators.*;
018:
019: /**
020: * Class DimensionSourceDefinitionsDescriptor.
021: *
022: * @version $Revision$ $Date$
023: */
024: public class DimensionSourceDefinitionsDescriptor extends
025: org.exolab.castor.xml.util.XMLClassDescriptorImpl {
026:
027: //--------------------------/
028: //- Class/Member Variables -/
029: //--------------------------/
030:
031: /**
032: * Field nsPrefix
033: */
034: private java.lang.String nsPrefix;
035:
036: /**
037: * Field nsURI
038: */
039: private java.lang.String nsURI;
040:
041: /**
042: * Field xmlName
043: */
044: private java.lang.String xmlName;
045:
046: /**
047: * Field identity
048: */
049: private org.exolab.castor.xml.XMLFieldDescriptor identity;
050:
051: //----------------/
052: //- Constructors -/
053: //----------------/
054:
055: public DimensionSourceDefinitionsDescriptor() {
056: super ();
057: xmlName = "DimensionSourceDefinitions";
058:
059: //-- set grouping compositor
060: setCompositorAsSequence();
061: org.exolab.castor.xml.util.XMLFieldDescriptorImpl desc = null;
062: org.exolab.castor.xml.XMLFieldHandler handler = null;
063: org.exolab.castor.xml.FieldValidator fieldValidator = null;
064: //-- initialize attribute descriptors
065:
066: //-- initialize element descriptors
067:
068: //-- _dimensionSourceDefinitionList
069: desc = new org.exolab.castor.xml.util.XMLFieldDescriptorImpl(
070: com.calipso.reportgenerator.reportdefinitions.DimensionSourceDefinition.class,
071: "_dimensionSourceDefinitionList",
072: "DimensionSourceDefinition",
073: org.exolab.castor.xml.NodeType.Element);
074: handler = (new org.exolab.castor.xml.XMLFieldHandler() {
075: public java.lang.Object getValue(java.lang.Object object)
076: throws IllegalStateException {
077: DimensionSourceDefinitions target = (DimensionSourceDefinitions) object;
078: return target.getDimensionSourceDefinition();
079: }
080:
081: public void setValue(java.lang.Object object,
082: java.lang.Object value)
083: throws IllegalStateException,
084: IllegalArgumentException {
085: try {
086: DimensionSourceDefinitions target = (DimensionSourceDefinitions) object;
087: target
088: .addDimensionSourceDefinition((com.calipso.reportgenerator.reportdefinitions.DimensionSourceDefinition) value);
089: } catch (java.lang.Exception ex) {
090: throw new IllegalStateException(ex.toString());
091: }
092: }
093:
094: public java.lang.Object newInstance(java.lang.Object parent) {
095: return new com.calipso.reportgenerator.reportdefinitions.DimensionSourceDefinition();
096: }
097: });
098: desc.setHandler(handler);
099: desc.setRequired(true);
100: desc.setMultivalued(true);
101: addFieldDescriptor(desc);
102:
103: //-- validation code for: _dimensionSourceDefinitionList
104: fieldValidator = new org.exolab.castor.xml.FieldValidator();
105: fieldValidator.setMinOccurs(1);
106: { //-- local scope
107: }
108: desc.setValidator(fieldValidator);
109: } //-- com.calipso.reportgenerator.reportdefinitions.DimensionSourceDefinitionsDescriptor()
110:
111: //-----------/
112: //- Methods -/
113: //-----------/
114:
115: /**
116: * Method getAccessMode
117: */
118: public org.exolab.castor.mapping.AccessMode getAccessMode() {
119: return null;
120: } //-- org.exolab.castor.mapping.AccessMode getAccessMode()
121:
122: /**
123: * Method getExtends
124: */
125: public org.exolab.castor.mapping.ClassDescriptor getExtends() {
126: return null;
127: } //-- org.exolab.castor.mapping.ClassDescriptor getExtends()
128:
129: /**
130: * Method getIdentity
131: */
132: public org.exolab.castor.mapping.FieldDescriptor getIdentity() {
133: return identity;
134: } //-- org.exolab.castor.mapping.FieldDescriptor getIdentity()
135:
136: /**
137: * Method getJavaClass
138: */
139: public java.lang.Class getJavaClass() {
140: return com.calipso.reportgenerator.reportdefinitions.DimensionSourceDefinitions.class;
141: } //-- java.lang.Class getJavaClass()
142:
143: /**
144: * Method getNameSpacePrefix
145: */
146: public java.lang.String getNameSpacePrefix() {
147: return nsPrefix;
148: } //-- java.lang.String getNameSpacePrefix()
149:
150: /**
151: * Method getNameSpaceURI
152: */
153: public java.lang.String getNameSpaceURI() {
154: return nsURI;
155: } //-- java.lang.String getNameSpaceURI()
156:
157: /**
158: * Method getValidator
159: */
160: public org.exolab.castor.xml.TypeValidator getValidator() {
161: return this ;
162: } //-- org.exolab.castor.xml.TypeValidator getValidator()
163:
164: /**
165: * Method getXMLName
166: */
167: public java.lang.String getXMLName() {
168: return xmlName;
169: } //-- java.lang.String getXMLName()
170:
171: }
|