1 |
|
|
2 |
|
|
3 |
|
|
4 |
|
|
5 |
|
|
6 |
|
|
7 |
|
|
8 |
|
package jalview.schemabinding.version2.descriptors; |
9 |
|
|
10 |
|
import jalview.schemabinding.version2.CompoundMatcher; |
11 |
|
|
12 |
|
|
13 |
|
|
14 |
|
|
15 |
|
|
16 |
|
import jalview.schemabinding.version2.FeatureMatcherSet; |
17 |
|
import jalview.schemabinding.version2.MatchCondition; |
18 |
|
|
19 |
|
|
20 |
|
|
21 |
|
|
22 |
|
@version |
23 |
|
|
|
|
| 77.8% |
Uncovered Elements: 14 (63) |
Complexity: 17 |
Complexity Density: 0.35 |
|
24 |
|
public class FeatureMatcherSetDescriptor |
25 |
|
extends org.exolab.castor.xml.util.XMLClassDescriptorImpl |
26 |
|
{ |
27 |
|
|
28 |
|
|
29 |
|
|
30 |
|
|
31 |
|
|
32 |
|
|
33 |
|
|
34 |
|
|
35 |
|
private boolean _elementDefinition; |
36 |
|
|
37 |
|
|
38 |
|
|
39 |
|
|
40 |
|
private java.lang.String _nsPrefix; |
41 |
|
|
42 |
|
|
43 |
|
|
44 |
|
|
45 |
|
private java.lang.String _nsURI; |
46 |
|
|
47 |
|
|
48 |
|
|
49 |
|
|
50 |
|
private java.lang.String _xmlName; |
51 |
|
|
52 |
|
|
53 |
|
|
54 |
|
|
55 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (26) |
Complexity: 1 |
Complexity Density: 0.04 |
|
56 |
98 |
public FeatureMatcherSetDescriptor()... |
57 |
|
{ |
58 |
98 |
super(); |
59 |
98 |
_nsURI = "www.jalview.org/colours"; |
60 |
98 |
_xmlName = "FeatureMatcherSet"; |
61 |
98 |
_elementDefinition = false; |
62 |
|
|
63 |
|
|
64 |
98 |
setCompositorAsChoice(); |
65 |
98 |
org.exolab.castor.xml.util.XMLFieldDescriptorImpl desc = null; |
66 |
98 |
org.exolab.castor.mapping.FieldHandler handler = null; |
67 |
98 |
org.exolab.castor.xml.FieldValidator fieldValidator = null; |
68 |
|
|
69 |
|
|
70 |
|
|
71 |
|
|
72 |
|
|
73 |
98 |
desc = new org.exolab.castor.xml.util.XMLFieldDescriptorImpl( |
74 |
|
MatchCondition.class, "_matchCondition", "matchCondition", |
75 |
|
org.exolab.castor.xml.NodeType.Element); |
76 |
98 |
handler = new org.exolab.castor.xml.XMLFieldHandler() |
77 |
|
{ |
|
|
| 100% |
Uncovered Elements: 0 (2) |
Complexity: 1 |
Complexity Density: 0.5 |
|
78 |
50 |
@Override... |
79 |
|
public java.lang.Object getValue(java.lang.Object object) |
80 |
|
throws IllegalStateException |
81 |
|
{ |
82 |
50 |
FeatureMatcherSet target = (FeatureMatcherSet) object; |
83 |
50 |
return target.getMatchCondition(); |
84 |
|
} |
85 |
|
|
|
|
| 75% |
Uncovered Elements: 1 (4) |
Complexity: 2 |
Complexity Density: 0.5 |
|
86 |
10 |
@Override... |
87 |
|
public void setValue(java.lang.Object object, java.lang.Object value) |
88 |
|
throws IllegalStateException, IllegalArgumentException |
89 |
|
{ |
90 |
10 |
try |
91 |
|
{ |
92 |
10 |
FeatureMatcherSet target = (FeatureMatcherSet) object; |
93 |
10 |
target.setMatchCondition((MatchCondition) value); |
94 |
|
} catch (java.lang.Exception ex) |
95 |
|
{ |
96 |
0 |
throw new IllegalStateException(ex.toString()); |
97 |
|
} |
98 |
|
} |
99 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
100 |
10 |
@Override... |
101 |
|
public java.lang.Object newInstance(java.lang.Object parent) |
102 |
|
{ |
103 |
10 |
return new MatchCondition(); |
104 |
|
} |
105 |
|
}; |
106 |
98 |
desc.setHandler(handler); |
107 |
98 |
desc.setRequired(true); |
108 |
98 |
desc.setMultivalued(false); |
109 |
98 |
addFieldDescriptor(desc); |
110 |
|
|
111 |
|
|
112 |
98 |
fieldValidator = new org.exolab.castor.xml.FieldValidator(); |
113 |
98 |
fieldValidator.setMinOccurs(1); |
114 |
|
{ |
115 |
|
} |
116 |
98 |
desc.setValidator(fieldValidator); |
117 |
|
|
118 |
98 |
desc = new org.exolab.castor.xml.util.XMLFieldDescriptorImpl( |
119 |
|
CompoundMatcher.class, "_compoundMatcher", "compoundMatcher", |
120 |
|
org.exolab.castor.xml.NodeType.Element); |
121 |
98 |
handler = new org.exolab.castor.xml.XMLFieldHandler() |
122 |
|
{ |
|
|
| 100% |
Uncovered Elements: 0 (2) |
Complexity: 1 |
Complexity Density: 0.5 |
|
123 |
41 |
@Override... |
124 |
|
public java.lang.Object getValue(java.lang.Object object) |
125 |
|
throws IllegalStateException |
126 |
|
{ |
127 |
41 |
FeatureMatcherSet target = (FeatureMatcherSet) object; |
128 |
41 |
return target.getCompoundMatcher(); |
129 |
|
} |
130 |
|
|
|
|
| 75% |
Uncovered Elements: 1 (4) |
Complexity: 2 |
Complexity Density: 0.5 |
|
131 |
4 |
@Override... |
132 |
|
public void setValue(java.lang.Object object, java.lang.Object value) |
133 |
|
throws IllegalStateException, IllegalArgumentException |
134 |
|
{ |
135 |
4 |
try |
136 |
|
{ |
137 |
4 |
FeatureMatcherSet target = (FeatureMatcherSet) object; |
138 |
4 |
target.setCompoundMatcher((CompoundMatcher) value); |
139 |
|
} catch (java.lang.Exception ex) |
140 |
|
{ |
141 |
0 |
throw new IllegalStateException(ex.toString()); |
142 |
|
} |
143 |
|
} |
144 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
145 |
4 |
@Override... |
146 |
|
public java.lang.Object newInstance(java.lang.Object parent) |
147 |
|
{ |
148 |
4 |
return new CompoundMatcher(); |
149 |
|
} |
150 |
|
}; |
151 |
98 |
desc.setHandler(handler); |
152 |
98 |
desc.setRequired(true); |
153 |
98 |
desc.setMultivalued(false); |
154 |
98 |
addFieldDescriptor(desc); |
155 |
|
|
156 |
|
|
157 |
98 |
fieldValidator = new org.exolab.castor.xml.FieldValidator(); |
158 |
98 |
fieldValidator.setMinOccurs(1); |
159 |
|
{ |
160 |
|
} |
161 |
98 |
desc.setValidator(fieldValidator); |
162 |
|
} |
163 |
|
|
164 |
|
|
165 |
|
|
166 |
|
|
167 |
|
|
168 |
|
|
169 |
|
|
170 |
|
|
171 |
|
@return |
172 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
173 |
0 |
@Override... |
174 |
|
public org.exolab.castor.mapping.AccessMode getAccessMode() |
175 |
|
{ |
176 |
0 |
return null; |
177 |
|
} |
178 |
|
|
179 |
|
|
180 |
|
|
181 |
|
|
182 |
|
@return |
183 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
184 |
14 |
@Override... |
185 |
|
public org.exolab.castor.mapping.FieldDescriptor getIdentity() |
186 |
|
{ |
187 |
14 |
return super.getIdentity(); |
188 |
|
} |
189 |
|
|
190 |
|
|
191 |
|
|
192 |
|
|
193 |
|
@return |
194 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
195 |
21 |
@Override... |
196 |
|
public java.lang.Class getJavaClass() |
197 |
|
{ |
198 |
21 |
return jalview.schemabinding.version2.FeatureMatcherSet.class; |
199 |
|
} |
200 |
|
|
201 |
|
|
202 |
|
|
203 |
|
|
204 |
|
@return |
205 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
206 |
0 |
@Override... |
207 |
|
public java.lang.String getNameSpacePrefix() |
208 |
|
{ |
209 |
0 |
return _nsPrefix; |
210 |
|
} |
211 |
|
|
212 |
|
|
213 |
|
|
214 |
|
|
215 |
|
@return |
216 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
217 |
0 |
@Override... |
218 |
|
public java.lang.String getNameSpaceURI() |
219 |
|
{ |
220 |
0 |
return _nsURI; |
221 |
|
} |
222 |
|
|
223 |
|
|
224 |
|
|
225 |
|
|
226 |
|
@return |
227 |
|
|
228 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
229 |
0 |
@Override... |
230 |
|
public org.exolab.castor.xml.TypeValidator getValidator() |
231 |
|
{ |
232 |
0 |
return this; |
233 |
|
} |
234 |
|
|
235 |
|
|
236 |
|
|
237 |
|
|
238 |
|
@return |
239 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
240 |
0 |
@Override... |
241 |
|
public java.lang.String getXMLName() |
242 |
|
{ |
243 |
0 |
return _xmlName; |
244 |
|
} |
245 |
|
|
246 |
|
|
247 |
|
|
248 |
|
|
249 |
|
@return |
250 |
|
|
251 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
252 |
0 |
@Override... |
253 |
|
public boolean isElementDefinition() |
254 |
|
{ |
255 |
0 |
return _elementDefinition; |
256 |
|
} |
257 |
|
|
258 |
|
} |