2 * This class was automatically generated with
3 * <a href="http://www.castor.org">Castor 0.9.9M1</a>, using an XML
8 package org.vamsas.objects.core;
10 //---------------------------------/
11 //- Imported classes and packages -/
12 //---------------------------------/
14 import java.io.IOException;
15 import java.io.Reader;
16 import java.io.Serializable;
17 import java.io.Writer;
18 import org.exolab.castor.xml.MarshalException;
19 import org.exolab.castor.xml.Marshaller;
20 import org.exolab.castor.xml.Unmarshaller;
21 import org.exolab.castor.xml.ValidationException;
22 import org.xml.sax.ContentHandler;
27 * @version $Revision$ $Date$
29 public class DbRef extends org.vamsas.client.object
30 implements java.io.Serializable
34 //--------------------------/
35 //- Class/Member Variables -/
36 //--------------------------/
41 private java.lang.Object _source;
46 private java.lang.Object _version;
51 private java.lang.Object _accessionId;
61 } //-- org.vamsas.objects.core.DbRef()
69 * Note: hashCode() has not been overriden
74 public boolean equals(java.lang.Object obj)
79 if (super.equals(obj)==false)
82 if (obj instanceof DbRef) {
84 DbRef temp = (DbRef)obj;
85 if (this._source != null) {
86 if (temp._source == null) return false;
87 else if (!(this._source.equals(temp._source)))
90 else if (temp._source != null)
92 if (this._version != null) {
93 if (temp._version == null) return false;
94 else if (!(this._version.equals(temp._version)))
97 else if (temp._version != null)
99 if (this._accessionId != null) {
100 if (temp._accessionId == null) return false;
101 else if (!(this._accessionId.equals(temp._accessionId)))
104 else if (temp._accessionId != null)
109 } //-- boolean equals(java.lang.Object)
112 * Returns the value of field 'accessionId'.
115 * @return the value of field 'accessionId'.
117 public java.lang.Object getAccessionId()
119 return this._accessionId;
120 } //-- java.lang.Object getAccessionId()
123 * Returns the value of field 'source'.
126 * @return the value of field 'source'.
128 public java.lang.Object getSource()
131 } //-- java.lang.Object getSource()
134 * Returns the value of field 'version'.
137 * @return the value of field 'version'.
139 public java.lang.Object getVersion()
141 return this._version;
142 } //-- java.lang.Object getVersion()
151 public boolean isValid()
156 catch (org.exolab.castor.xml.ValidationException vex) {
160 } //-- boolean isValid()
169 public void marshal(java.io.Writer out)
170 throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException
173 Marshaller.marshal(this, out);
174 } //-- void marshal(java.io.Writer)
183 public void marshal(org.xml.sax.ContentHandler handler)
184 throws java.io.IOException, org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException
187 Marshaller.marshal(this, handler);
188 } //-- void marshal(org.xml.sax.ContentHandler)
191 * Sets the value of field 'accessionId'.
193 * @param accessionId the value of field 'accessionId'.
195 public void setAccessionId(java.lang.Object accessionId)
197 this._accessionId = accessionId;
198 } //-- void setAccessionId(java.lang.Object)
201 * Sets the value of field 'source'.
203 * @param source the value of field 'source'.
205 public void setSource(java.lang.Object source)
207 this._source = source;
208 } //-- void setSource(java.lang.Object)
211 * Sets the value of field 'version'.
213 * @param version the value of field 'version'.
215 public void setVersion(java.lang.Object version)
217 this._version = version;
218 } //-- void setVersion(java.lang.Object)
228 public static org.vamsas.objects.core.DbRef unmarshal(java.io.Reader reader)
229 throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException
231 return (org.vamsas.objects.core.DbRef) Unmarshaller.unmarshal(org.vamsas.objects.core.DbRef.class, reader);
232 } //-- org.vamsas.objects.core.DbRef unmarshal(java.io.Reader)
238 public void validate()
239 throws org.exolab.castor.xml.ValidationException
241 org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
242 validator.validate(this);
243 } //-- void validate()