Clover icon

jalviewX

  1. Project Clover database Wed Oct 31 2018 15:13:58 GMT
  2. Package jalview.schemabinding.version2.descriptors

File SequenceSetPropertiesDescriptor.java

 

Coverage histogram

../../../../img/srcFileCovDistChart9.png
12% of files have more coverage

Code metrics

0
53
15
1
244
132
17
0.32
3.53
15
1.13

Classes

Class Line # Actions
SequenceSetPropertiesDescriptor 21 53 17 12
0.823529482.4%
 

Contributing tests

This file is covered by 1 test. .

Source view

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.descriptors;
9   
10    //---------------------------------/
11    //- Imported classes and packages -/
12    //---------------------------------/
13   
14    import jalview.schemabinding.version2.SequenceSetProperties;
15   
16    /**
17    * Class SequenceSetPropertiesDescriptor.
18    *
19    * @version $Revision$ $Date$
20    */
 
21    public class SequenceSetPropertiesDescriptor extends
22    org.exolab.castor.xml.util.XMLClassDescriptorImpl
23    {
24   
25    // --------------------------/
26    // - Class/Member Variables -/
27    // --------------------------/
28   
29    /**
30    * Field _elementDefinition.
31    */
32    private boolean _elementDefinition;
33   
34    /**
35    * Field _nsPrefix.
36    */
37    private java.lang.String _nsPrefix;
38   
39    /**
40    * Field _nsURI.
41    */
42    private java.lang.String _nsURI;
43   
44    /**
45    * Field _xmlName.
46    */
47    private java.lang.String _xmlName;
48   
49    // ----------------/
50    // - Constructors -/
51    // ----------------/
52   
 
53  63 toggle public SequenceSetPropertiesDescriptor()
54    {
55  63 super();
56  63 _nsURI = "www.vamsas.ac.uk/jalview/version2";
57  63 _xmlName = "sequenceSetProperties";
58  63 _elementDefinition = true;
59  63 org.exolab.castor.xml.util.XMLFieldDescriptorImpl desc = null;
60  63 org.exolab.castor.mapping.FieldHandler handler = null;
61  63 org.exolab.castor.xml.FieldValidator fieldValidator = null;
62    // -- initialize attribute descriptors
63   
64    // -- _key
65  63 desc = new org.exolab.castor.xml.util.XMLFieldDescriptorImpl(
66    java.lang.String.class, "_key", "key",
67    org.exolab.castor.xml.NodeType.Attribute);
68  63 desc.setImmutable(true);
69  63 handler = new org.exolab.castor.xml.XMLFieldHandler()
70    {
 
71  42 toggle public java.lang.Object getValue(java.lang.Object object)
72    throws IllegalStateException
73    {
74  42 SequenceSetProperties target = (SequenceSetProperties) object;
75  42 return target.getKey();
76    }
77   
 
78  21 toggle public void setValue(java.lang.Object object, java.lang.Object value)
79    throws IllegalStateException, IllegalArgumentException
80    {
81  21 try
82    {
83  21 SequenceSetProperties target = (SequenceSetProperties) object;
84  21 target.setKey((java.lang.String) value);
85    } catch (java.lang.Exception ex)
86    {
87  0 throw new IllegalStateException(ex.toString());
88    }
89    }
90   
 
91  0 toggle public java.lang.Object newInstance(java.lang.Object parent)
92    {
93  0 return null;
94    }
95    };
96  63 desc.setHandler(handler);
97  63 desc.setMultivalued(false);
98  63 addFieldDescriptor(desc);
99   
100    // -- validation code for: _key
101  63 fieldValidator = new org.exolab.castor.xml.FieldValidator();
102    { // -- local scope
103  63 org.exolab.castor.xml.validators.StringValidator typeValidator;
104  63 typeValidator = new org.exolab.castor.xml.validators.StringValidator();
105  63 fieldValidator.setValidator(typeValidator);
106  63 typeValidator.setWhiteSpace("preserve");
107    }
108  63 desc.setValidator(fieldValidator);
109    // -- _value
110  63 desc = new org.exolab.castor.xml.util.XMLFieldDescriptorImpl(
111    java.lang.String.class, "_value", "value",
112    org.exolab.castor.xml.NodeType.Attribute);
113  63 desc.setImmutable(true);
114  63 handler = new org.exolab.castor.xml.XMLFieldHandler()
115    {
 
116  42 toggle public java.lang.Object getValue(java.lang.Object object)
117    throws IllegalStateException
118    {
119  42 SequenceSetProperties target = (SequenceSetProperties) object;
120  42 return target.getValue();
121    }
122   
 
123  21 toggle public void setValue(java.lang.Object object, java.lang.Object value)
124    throws IllegalStateException, IllegalArgumentException
125    {
126  21 try
127    {
128  21 SequenceSetProperties target = (SequenceSetProperties) object;
129  21 target.setValue((java.lang.String) value);
130    } catch (java.lang.Exception ex)
131    {
132  0 throw new IllegalStateException(ex.toString());
133    }
134    }
135   
 
136  0 toggle public java.lang.Object newInstance(java.lang.Object parent)
137    {
138  0 return null;
139    }
140    };
141  63 desc.setHandler(handler);
142  63 desc.setMultivalued(false);
143  63 addFieldDescriptor(desc);
144   
145    // -- validation code for: _value
146  63 fieldValidator = new org.exolab.castor.xml.FieldValidator();
147    { // -- local scope
148  63 org.exolab.castor.xml.validators.StringValidator typeValidator;
149  63 typeValidator = new org.exolab.castor.xml.validators.StringValidator();
150  63 fieldValidator.setValidator(typeValidator);
151  63 typeValidator.setWhiteSpace("preserve");
152    }
153  63 desc.setValidator(fieldValidator);
154    // -- initialize element descriptors
155   
156    }
157   
158    // -----------/
159    // - Methods -/
160    // -----------/
161   
162    /**
163    * Method getAccessMode.
164    *
165    * @return the access mode specified for this class.
166    */
 
167  0 toggle public org.exolab.castor.mapping.AccessMode getAccessMode()
168    {
169  0 return null;
170    }
171   
172    /**
173    * Method getIdentity.
174    *
175    * @return the identity field, null if this class has no identity.
176    */
 
177  63 toggle public org.exolab.castor.mapping.FieldDescriptor getIdentity()
178    {
179  63 return super.getIdentity();
180    }
181   
182    /**
183    * Method getJavaClass.
184    *
185    * @return the Java class represented by this descriptor.
186    */
 
187  42 toggle public java.lang.Class getJavaClass()
188    {
189  42 return jalview.schemabinding.version2.SequenceSetProperties.class;
190    }
191   
192    /**
193    * Method getNameSpacePrefix.
194    *
195    * @return the namespace prefix to use when marshaling as XML.
196    */
 
197  21 toggle public java.lang.String getNameSpacePrefix()
198    {
199  21 return _nsPrefix;
200    }
201   
202    /**
203    * Method getNameSpaceURI.
204    *
205    * @return the namespace URI used when marshaling and unmarshaling as XML.
206    */
 
207  0 toggle public java.lang.String getNameSpaceURI()
208    {
209  0 return _nsURI;
210    }
211   
212    /**
213    * Method getValidator.
214    *
215    * @return a specific validator for the class described by this
216    * ClassDescriptor.
217    */
 
218  21 toggle public org.exolab.castor.xml.TypeValidator getValidator()
219    {
220  21 return this;
221    }
222   
223    /**
224    * Method getXMLName.
225    *
226    * @return the XML Name for the Class being described.
227    */
 
228  126 toggle public java.lang.String getXMLName()
229    {
230  126 return _xmlName;
231    }
232   
233    /**
234    * Method isElementDefinition.
235    *
236    * @return true if XML schema definition of this Class is that of a global
237    * element or element with anonymous type definition.
238    */
 
239  0 toggle public boolean isElementDefinition()
240    {
241  0 return _elementDefinition;
242    }
243   
244    }