2 * Jalview - A Sequence Alignment Editor and Viewer (Version 2.6)
\r
3 * Copyright (C) 2010 J Procter, AM Waterhouse, G Barton, M Clamp, S Searle
\r
5 * This file is part of Jalview.
\r
7 * Jalview is free software: you can redistribute it and/or
\r
8 * modify it under the terms of the GNU General Public License
\r
9 * as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
\r
11 * Jalview is distributed in the hope that it will be useful, but
\r
12 * WITHOUT ANY WARRANTY; without even the implied warranty
\r
13 * of MERCHANTABILITY or FITNESS FOR A PARTICULAR
\r
14 * PURPOSE. See the GNU General Public License for more details.
\r
16 * You should have received a copy of the GNU General Public License along with Jalview. If not, see <http://www.gnu.org/licenses/>.
\r
18 package jalview.schemabinding.version2;
\r
20 //---------------------------------/
\r
21 //- Imported classes and packages -/
\r
22 //---------------------------------/
\r
24 import org.exolab.castor.xml.Marshaller;
\r
25 import org.exolab.castor.xml.Unmarshaller;
\r
28 * Class UserColourScheme.
\r
30 * @version $Revision$ $Date$
\r
32 public class UserColourScheme extends JalviewUserColours implements
\r
33 java.io.Serializable
\r
36 // ----------------/
\r
37 // - Constructors -/
\r
38 // ----------------/
\r
40 public UserColourScheme()
\r
52 * @return true if this object is valid according to the schema
\r
54 public boolean isValid()
\r
59 } catch (org.exolab.castor.xml.ValidationException vex)
\r
70 * @throws org.exolab.castor.xml.MarshalException
\r
71 * if object is null or if any SAXException is thrown during
\r
73 * @throws org.exolab.castor.xml.ValidationException
\r
74 * if this object is an invalid instance according to the schema
\r
76 public void marshal(final java.io.Writer out)
\r
77 throws org.exolab.castor.xml.MarshalException,
\r
78 org.exolab.castor.xml.ValidationException
\r
80 Marshaller.marshal(this, out);
\r
87 * @throws java.io.IOException
\r
88 * if an IOException occurs during marshaling
\r
89 * @throws org.exolab.castor.xml.ValidationException
\r
90 * if this object is an invalid instance according to the schema
\r
91 * @throws org.exolab.castor.xml.MarshalException
\r
92 * if object is null or if any SAXException is thrown during
\r
95 public void marshal(final org.xml.sax.ContentHandler handler)
\r
96 throws java.io.IOException,
\r
97 org.exolab.castor.xml.MarshalException,
\r
98 org.exolab.castor.xml.ValidationException
\r
100 Marshaller.marshal(this, handler);
\r
104 * Method unmarshal.
\r
107 * @throws org.exolab.castor.xml.MarshalException
\r
108 * if object is null or if any SAXException is thrown during
\r
110 * @throws org.exolab.castor.xml.ValidationException
\r
111 * if this object is an invalid instance according to the schema
\r
112 * @return the unmarshaled jalview.schemabinding.version2.JalviewUserColours
\r
114 public static jalview.schemabinding.version2.JalviewUserColours unmarshal(
\r
115 final java.io.Reader reader)
\r
116 throws org.exolab.castor.xml.MarshalException,
\r
117 org.exolab.castor.xml.ValidationException
\r
119 return (jalview.schemabinding.version2.JalviewUserColours) Unmarshaller
\r
121 jalview.schemabinding.version2.UserColourScheme.class,
\r
128 * @throws org.exolab.castor.xml.ValidationException
\r
129 * if this object is an invalid instance according to the schema
\r
131 public void validate() throws org.exolab.castor.xml.ValidationException
\r
133 org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
\r
134 validator.validate(this);
\r