1 /*******************************************************************************
2 * Jalview - A Sequence Alignment Editor and Viewer ($$Version-Rel$$)
3 * Copyright (C) $(date) The Jalview Authors
5 * This file is part of Jalview.
7 * Jalview is free software: you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License
9 * as published by the Free Software Foundation, either version 3
10 * of the License, or (at your option) any later version.
12 * Jalview is distributed in the hope that it will be useful, but
13 * WITHOUT ANY WARRANTY; without even the implied warranty
14 * of MERCHANTABILITY or FITNESS FOR A PARTICULAR
15 * PURPOSE. See the GNU General Public License for more details.
17 * You should have received a copy of the GNU General Public License
18 * along with Jalview. If not, see <http://www.gnu.org/licenses/>.
19 * The Jalview Authors are detailed in the 'AUTHORS' file.
20 *******************************************************************************/
22 * This class was automatically generated with
23 * <a href="http://www.castor.org">Castor 1.1</a>, using an XML
28 package jalview.schemabinding.version2;
30 //---------------------------------/
31 //- Imported classes and packages -/
32 //---------------------------------/
34 import org.exolab.castor.xml.Marshaller;
35 import org.exolab.castor.xml.Unmarshaller;
38 * a region from start to end inclusive
40 * @version $Revision$ $Date$
42 public class MapListTo implements java.io.Serializable
45 // --------------------------/
46 // - Class/Member Variables -/
47 // --------------------------/
55 * keeps track of state for field: _start
57 private boolean _has_start;
65 * keeps track of state for field: _end
67 private boolean _has_end;
84 public void deleteEnd()
86 this._has_end = false;
91 public void deleteStart()
93 this._has_start = false;
97 * Returns the value of field 'end'.
99 * @return the value of field 'End'.
107 * Returns the value of field 'start'.
109 * @return the value of field 'Start'.
111 public int getStart()
119 * @return true if at least one End has been added
121 public boolean hasEnd()
123 return this._has_end;
129 * @return true if at least one Start has been added
131 public boolean hasStart()
133 return this._has_start;
139 * @return true if this object is valid according to the schema
141 public boolean isValid()
146 } catch (org.exolab.castor.xml.ValidationException vex)
157 * @throws org.exolab.castor.xml.MarshalException
158 * if object is null or if any SAXException is thrown during
160 * @throws org.exolab.castor.xml.ValidationException
161 * if this object is an invalid instance according to the schema
163 public void marshal(final java.io.Writer out)
164 throws org.exolab.castor.xml.MarshalException,
165 org.exolab.castor.xml.ValidationException
167 Marshaller.marshal(this, out);
174 * @throws java.io.IOException
175 * if an IOException occurs during marshaling
176 * @throws org.exolab.castor.xml.ValidationException
177 * if this object is an invalid instance according to the schema
178 * @throws org.exolab.castor.xml.MarshalException
179 * if object is null or if any SAXException is thrown during
182 public void marshal(final org.xml.sax.ContentHandler handler)
183 throws java.io.IOException,
184 org.exolab.castor.xml.MarshalException,
185 org.exolab.castor.xml.ValidationException
187 Marshaller.marshal(this, handler);
191 * Sets the value of field 'end'.
194 * the value of field 'end'.
196 public void setEnd(final int end)
199 this._has_end = true;
203 * Sets the value of field 'start'.
206 * the value of field 'start'.
208 public void setStart(final int start)
211 this._has_start = true;
218 * @throws org.exolab.castor.xml.MarshalException
219 * if object is null or if any SAXException is thrown during
221 * @throws org.exolab.castor.xml.ValidationException
222 * if this object is an invalid instance according to the schema
223 * @return the unmarshaled jalview.schemabinding.version2.MapListTo
225 public static jalview.schemabinding.version2.MapListTo unmarshal(
226 final java.io.Reader reader)
227 throws org.exolab.castor.xml.MarshalException,
228 org.exolab.castor.xml.ValidationException
230 return (jalview.schemabinding.version2.MapListTo) Unmarshaller
231 .unmarshal(jalview.schemabinding.version2.MapListTo.class,
238 * @throws org.exolab.castor.xml.ValidationException
239 * if this object is an invalid instance according to the schema
241 public void validate() throws org.exolab.castor.xml.ValidationException
243 org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
244 validator.validate(this);