2 * This class was automatically generated with
\r
3 * <a href="http://www.castor.org">Castor 1.1</a>, using an XML
\r
8 package uk.ac.vamsas.objects.core;
\r
10 //---------------------------------/
\r
11 //- Imported classes and packages -/
\r
12 //---------------------------------/
\r
14 import org.exolab.castor.xml.Marshaller;
\r
15 import org.exolab.castor.xml.Unmarshaller;
\r
18 * explicitly named cross reference to other objects in the
\r
22 * @version $Revision$ $Date$
\r
24 public class Vxref extends ReferenceType
\r
25 implements java.io.Serializable
\r
43 * Overrides the java.lang.Object.equals method.
\r
46 * @return true if the objects are equal.
\r
48 public boolean equals(
\r
49 final java.lang.Object obj) {
\r
53 if (super.equals(obj)==false)
\r
56 if (obj instanceof Vxref) {
\r
64 * Overrides the java.lang.Object.hashCode method.
\r
66 * The following steps came from <b>Effective Java Programming
\r
67 * Language Guide</b> by Joshua Bloch, Chapter 3
\r
69 * @return a hash code value for the object.
\r
71 public int hashCode(
\r
73 int result = super.hashCode();
\r
83 * @return true if this object is valid according to the schema
\r
85 public boolean isValid(
\r
89 } catch (org.exolab.castor.xml.ValidationException vex) {
\r
99 * @throws org.exolab.castor.xml.MarshalException if object is
\r
100 * null or if any SAXException is thrown during marshaling
\r
101 * @throws org.exolab.castor.xml.ValidationException if this
\r
102 * object is an invalid instance according to the schema
\r
104 public void marshal(
\r
105 final java.io.Writer out)
\r
106 throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {
\r
107 Marshaller.marshal(this, out);
\r
114 * @throws java.io.IOException if an IOException occurs during
\r
116 * @throws org.exolab.castor.xml.ValidationException if this
\r
117 * object is an invalid instance according to the schema
\r
118 * @throws org.exolab.castor.xml.MarshalException if object is
\r
119 * null or if any SAXException is thrown during marshaling
\r
121 public void marshal(
\r
122 final org.xml.sax.ContentHandler handler)
\r
123 throws java.io.IOException, org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {
\r
124 Marshaller.marshal(this, handler);
\r
128 * Method unmarshal.
\r
131 * @throws org.exolab.castor.xml.MarshalException if object is
\r
132 * null or if any SAXException is thrown during marshaling
\r
133 * @throws org.exolab.castor.xml.ValidationException if this
\r
134 * object is an invalid instance according to the schema
\r
135 * @return the unmarshaled
\r
136 * uk.ac.vamsas.objects.core.ReferenceType
\r
138 public static uk.ac.vamsas.objects.core.ReferenceType unmarshal(
\r
139 final java.io.Reader reader)
\r
140 throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {
\r
141 return (uk.ac.vamsas.objects.core.ReferenceType) Unmarshaller.unmarshal(uk.ac.vamsas.objects.core.Vxref.class, reader);
\r
147 * @throws org.exolab.castor.xml.ValidationException if this
\r
148 * object is an invalid instance according to the schema
\r
150 public void validate(
\r
152 throws org.exolab.castor.xml.ValidationException {
\r
153 org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
\r
154 validator.validate(this);
\r