2 * This class was automatically generated with
3 * <a href="http://www.castor.org">Castor 1.1</a>, using an XML
8 package jalview.schemabinding.version2.descriptors;
10 //---------------------------------/
11 //- Imported classes and packages -/
12 //---------------------------------/
14 import jalview.schemabinding.version2.Pdbids;
17 * Class PdbidsDescriptor.
19 * @version $Revision$ $Date$
21 public class PdbidsDescriptor extends jalview.schemabinding.version2.descriptors.PdbentryDescriptor {
24 //--------------------------/
25 //- Class/Member Variables -/
26 //--------------------------/
29 * Field _elementDefinition.
31 private boolean _elementDefinition;
36 private java.lang.String _nsPrefix;
41 private java.lang.String _nsURI;
46 private java.lang.String _xmlName;
53 public PdbidsDescriptor() {
55 setExtendsWithoutFlatten(new jalview.schemabinding.version2.descriptors.PdbentryDescriptor());
56 _nsURI = "www.jalview.org";
58 _elementDefinition = true;
60 //-- set grouping compositor
61 setCompositorAsSequence();
62 org.exolab.castor.xml.util.XMLFieldDescriptorImpl desc = null;
63 org.exolab.castor.mapping.FieldHandler handler = null;
64 org.exolab.castor.xml.FieldValidator fieldValidator = null;
65 //-- initialize attribute descriptors
67 //-- initialize element descriptors
69 //-- _structureStateList
70 desc = new org.exolab.castor.xml.util.XMLFieldDescriptorImpl(jalview.schemabinding.version2.StructureState.class, "_structureStateList", "structureState", org.exolab.castor.xml.NodeType.Element);
71 handler = new org.exolab.castor.xml.XMLFieldHandler() {
72 public java.lang.Object getValue( java.lang.Object object )
73 throws IllegalStateException
75 Pdbids target = (Pdbids) object;
76 return target.getStructureState();
78 public void setValue( java.lang.Object object, java.lang.Object value)
79 throws IllegalStateException, IllegalArgumentException
82 Pdbids target = (Pdbids) object;
83 target.addStructureState( (jalview.schemabinding.version2.StructureState) value);
84 } catch (java.lang.Exception ex) {
85 throw new IllegalStateException(ex.toString());
88 public void resetValue(Object object) throws IllegalStateException, IllegalArgumentException {
90 Pdbids target = (Pdbids) object;
91 target.removeAllStructureState();
92 } catch (java.lang.Exception ex) {
93 throw new IllegalStateException(ex.toString());
96 public java.lang.Object newInstance(java.lang.Object parent) {
97 return new jalview.schemabinding.version2.StructureState();
100 desc.setHandler(handler);
101 desc.setNameSpaceURI("www.jalview.org");
102 desc.setMultivalued(true);
103 addFieldDescriptor(desc);
105 //-- validation code for: _structureStateList
106 fieldValidator = new org.exolab.castor.xml.FieldValidator();
107 fieldValidator.setMinOccurs(0);
110 desc.setValidator(fieldValidator);
119 * Method getAccessMode.
121 * @return the access mode specified for this class.
123 public org.exolab.castor.mapping.AccessMode getAccessMode(
129 * Method getIdentity.
131 * @return the identity field, null if this class has no
134 public org.exolab.castor.mapping.FieldDescriptor getIdentity(
136 return super.getIdentity();
140 * Method getJavaClass.
142 * @return the Java class represented by this descriptor.
144 public java.lang.Class getJavaClass(
146 return jalview.schemabinding.version2.Pdbids.class;
150 * Method getNameSpacePrefix.
152 * @return the namespace prefix to use when marshaling as XML.
154 public java.lang.String getNameSpacePrefix(
160 * Method getNameSpaceURI.
162 * @return the namespace URI used when marshaling and
163 * unmarshaling as XML.
165 public java.lang.String getNameSpaceURI(
171 * Method getValidator.
173 * @return a specific validator for the class described by this
176 public org.exolab.castor.xml.TypeValidator getValidator(
184 * @return the XML Name for the Class being described.
186 public java.lang.String getXMLName(
192 * Method isElementDefinition.
194 * @return true if XML schema definition of this Class is that
196 * element or element with anonymous type definition.
198 public boolean isElementDefinition(
200 return _elementDefinition;