2 * This class was automatically generated with
\r
3 * <a href="http://www.castor.org">Castor 0.9.6</a>, using an XML
\r
8 package jalview.binding;
\r
10 //---------------------------------/
\r
11 //- Imported classes and packages -/
\r
12 //---------------------------------/
\r
14 import java.io.Serializable;
\r
15 import java.util.Enumeration;
\r
16 import java.util.Vector;
\r
17 import org.exolab.castor.xml.Marshaller;
\r
18 import org.exolab.castor.xml.Unmarshaller;
\r
21 * Class PdbentryItem.
\r
23 * @version $Revision$ $Date$
\r
25 public class PdbentryItem implements java.io.Serializable {
\r
28 //--------------------------/
\r
29 //- Class/Member Variables -/
\r
30 //--------------------------/
\r
33 * Field _propertyList
\r
35 private java.util.Vector _propertyList;
\r
42 public PdbentryItem() {
\r
44 _propertyList = new Vector();
\r
45 } //-- jalview.binding.PdbentryItem()
\r
53 * Method addProperty
\r
59 public void addProperty(jalview.binding.Property vProperty)
\r
60 throws java.lang.IndexOutOfBoundsException
\r
62 _propertyList.addElement(vProperty);
\r
63 } //-- void addProperty(jalview.binding.Property)
\r
66 * Method addProperty
\r
73 public void addProperty(int index, jalview.binding.Property vProperty)
\r
74 throws java.lang.IndexOutOfBoundsException
\r
76 _propertyList.insertElementAt(vProperty, index);
\r
77 } //-- void addProperty(int, jalview.binding.Property)
\r
80 * Method enumerateProperty
\r
84 * @return Enumeration
\r
86 public java.util.Enumeration enumerateProperty()
\r
88 return _propertyList.elements();
\r
89 } //-- java.util.Enumeration enumerateProperty()
\r
92 * Method getProperty
\r
99 public jalview.binding.Property getProperty(int index)
\r
100 throws java.lang.IndexOutOfBoundsException
\r
102 //-- check bounds for index
\r
103 if ((index < 0) || (index > _propertyList.size())) {
\r
104 throw new IndexOutOfBoundsException();
\r
107 return (jalview.binding.Property) _propertyList.elementAt(index);
\r
108 } //-- jalview.binding.Property getProperty(int)
\r
111 * Method getProperty
\r
117 public jalview.binding.Property[] getProperty()
\r
119 int size = _propertyList.size();
\r
120 jalview.binding.Property[] mArray = new jalview.binding.Property[size];
\r
121 for (int index = 0; index < size; index++) {
\r
122 mArray[index] = (jalview.binding.Property) _propertyList.elementAt(index);
\r
125 } //-- jalview.binding.Property[] getProperty()
\r
128 * Method getPropertyCount
\r
134 public int getPropertyCount()
\r
136 return _propertyList.size();
\r
137 } //-- int getPropertyCount()
\r
140 * Method removeAllProperty
\r
143 public void removeAllProperty()
\r
145 _propertyList.removeAllElements();
\r
146 } //-- void removeAllProperty()
\r
149 * Method removeProperty
\r
156 public jalview.binding.Property removeProperty(int index)
\r
158 java.lang.Object obj = _propertyList.elementAt(index);
\r
159 _propertyList.removeElementAt(index);
\r
160 return (jalview.binding.Property) obj;
\r
161 } //-- jalview.binding.Property removeProperty(int)
\r
164 * Method setProperty
\r
171 public void setProperty(int index, jalview.binding.Property vProperty)
\r
172 throws java.lang.IndexOutOfBoundsException
\r
174 //-- check bounds for index
\r
175 if ((index < 0) || (index > _propertyList.size())) {
\r
176 throw new IndexOutOfBoundsException();
\r
178 _propertyList.setElementAt(vProperty, index);
\r
179 } //-- void setProperty(int, jalview.binding.Property)
\r
182 * Method setProperty
\r
186 * @param propertyArray
\r
188 public void setProperty(jalview.binding.Property[] propertyArray)
\r
191 _propertyList.removeAllElements();
\r
192 for (int i = 0; i < propertyArray.length; i++) {
\r
193 _propertyList.addElement(propertyArray[i]);
\r
195 } //-- void setProperty(jalview.binding.Property)
\r