Merge branch 'feature/JAL-3063JAXB' into feature/JAL-3063jaxbNoCastor
[jalview.git] / src / jalview / schemabinding / version2 / Features.java
1 /*
2  * This class was automatically generated with 
3  * <a href="http://www.castor.org">Castor 1.1</a>, using an XML
4  * Schema.
5  * $Id$
6  */
7
8 package jalview.schemabinding.version2;
9
10 //---------------------------------/
11 //- Imported classes and packages -/
12 //---------------------------------/
13
14 import org.exolab.castor.xml.Marshaller;
15 import org.exolab.castor.xml.Unmarshaller;
16
17 /**
18  * Class Features.
19  * 
20  * @version $Revision$ $Date$
21  */
22 public class Features extends Feature implements java.io.Serializable
23 {
24
25   // ----------------/
26   // - Constructors -/
27   // ----------------/
28
29   public Features()
30   {
31     super();
32   }
33
34   // -----------/
35   // - Methods -/
36   // -----------/
37
38   /**
39    * Method isValid.
40    * 
41    * @return true if this object is valid according to the schema
42    */
43   public boolean isValid()
44   {
45     try
46     {
47       validate();
48     } catch (org.exolab.castor.xml.ValidationException vex)
49     {
50       return false;
51     }
52     return true;
53   }
54
55   /**
56    * 
57    * 
58    * @param out
59    * @throws org.exolab.castor.xml.MarshalException
60    *           if object is null or if any SAXException is thrown during
61    *           marshaling
62    * @throws org.exolab.castor.xml.ValidationException
63    *           if this object is an invalid instance according to the schema
64    */
65   public void marshal(final java.io.Writer out)
66           throws org.exolab.castor.xml.MarshalException,
67           org.exolab.castor.xml.ValidationException
68   {
69     Marshaller.marshal(this, out);
70   }
71
72   /**
73    * 
74    * 
75    * @param handler
76    * @throws java.io.IOException
77    *           if an IOException occurs during marshaling
78    * @throws org.exolab.castor.xml.ValidationException
79    *           if this object is an invalid instance according to the schema
80    * @throws org.exolab.castor.xml.MarshalException
81    *           if object is null or if any SAXException is thrown during
82    *           marshaling
83    */
84   public void marshal(final org.xml.sax.ContentHandler handler)
85           throws java.io.IOException,
86           org.exolab.castor.xml.MarshalException,
87           org.exolab.castor.xml.ValidationException
88   {
89     Marshaller.marshal(this, handler);
90   }
91
92   /**
93    * Method unmarshal.
94    * 
95    * @param reader
96    * @throws org.exolab.castor.xml.MarshalException
97    *           if object is null or if any SAXException is thrown during
98    *           marshaling
99    * @throws org.exolab.castor.xml.ValidationException
100    *           if this object is an invalid instance according to the schema
101    * @return the unmarshaled jalview.schemabinding.version2.Featur
102    */
103   public static jalview.schemabinding.version2.Feature unmarshal(
104           final java.io.Reader reader)
105           throws org.exolab.castor.xml.MarshalException,
106           org.exolab.castor.xml.ValidationException
107   {
108     return (jalview.schemabinding.version2.Feature) Unmarshaller.unmarshal(
109             jalview.schemabinding.version2.Features.class, reader);
110   }
111
112   /**
113    * 
114    * 
115    * @throws org.exolab.castor.xml.ValidationException
116    *           if this object is an invalid instance according to the schema
117    */
118   public void validate() throws org.exolab.castor.xml.ValidationException
119   {
120     org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
121     validator.validate(this);
122   }
123
124 }