Showing
7 changed files
with
1721 additions
and
0 deletions
pom.xml
0 → 100644
1 | +<?xml version="1.0" encoding="UTF-8"?> | |
2 | +<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
3 | + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | |
4 | + <modelVersion>4.0.0</modelVersion> | |
5 | + | |
6 | + <groupId>pl.com.it-crowd.youtrack-rest-api</groupId> | |
7 | + <artifactId>youtrack-rest-api</artifactId> | |
8 | + <version>1.0.0-SNAPSHOT</version> | |
9 | + | |
10 | + <dependencies> | |
11 | + <dependency> | |
12 | + <groupId>junit</groupId> | |
13 | + <artifactId>junit</artifactId> | |
14 | + <version>4.8.2</version> | |
15 | + </dependency> | |
16 | + | |
17 | + <dependency> | |
18 | + <groupId>net.sourceforge.htmlunit</groupId> | |
19 | + <artifactId>htmlunit</artifactId> | |
20 | + <version>2.8</version> | |
21 | + </dependency> | |
22 | + </dependencies> | |
23 | + | |
24 | + <build> | |
25 | + <plugins> | |
26 | + <plugin> | |
27 | + <groupId>org.apache.maven.plugins</groupId> | |
28 | + <artifactId>maven-source-plugin</artifactId> | |
29 | + <version>2.1.2</version> | |
30 | + <executions> | |
31 | + <execution> | |
32 | + <id>attach-sources</id> | |
33 | + <phase>package</phase> | |
34 | + <goals> | |
35 | + <goal>jar-no-fork</goal> | |
36 | + </goals> | |
37 | + </execution> | |
38 | + </executions> | |
39 | + </plugin> | |
40 | + </plugins> | |
41 | + </build> | |
42 | + | |
43 | + <profiles> | |
44 | + <profile> | |
45 | + <id>generate-jaxb-artifacts</id> | |
46 | + <build> | |
47 | + <plugins> | |
48 | + <plugin> | |
49 | + <groupId>org.codehaus.mojo</groupId> | |
50 | + <artifactId>jaxb2-maven-plugin</artifactId> | |
51 | + <version>1.3</version> | |
52 | + <executions> | |
53 | + <execution> | |
54 | + <goals> | |
55 | + <goal>xjc</goal> | |
56 | + </goals> | |
57 | + </execution> | |
58 | + </executions> | |
59 | + <configuration> | |
60 | + <packageName>pl.com.it_crowd.youtrack.api.rest</packageName> | |
61 | + <outputDirectory>${build.sourceDirectory}</outputDirectory> | |
62 | + <clearOutputDir>false</clearOutputDir> | |
63 | + </configuration> | |
64 | + </plugin> | |
65 | + </plugins> | |
66 | + </build> | |
67 | + </profile> | |
68 | + </profiles> | |
69 | + | |
70 | + <distributionManagement> | |
71 | + <snapshotRepository> | |
72 | + <id>it-crowd.com.pl</id> | |
73 | + <name>MyCo Internal Repository</name> | |
74 | + <url>http://artifactory.it-crowd.com.pl/libs-snapshot-local</url> | |
75 | + </snapshotRepository> | |
76 | + </distributionManagement> | |
77 | +</project> | |
\ No newline at end of file | ... | ... |
1 | +package pl.com.it_crowd.youtrack.api; | |
2 | + | |
3 | +import org.apache.commons.io.IOUtils; | |
4 | +import pl.com.it_crowd.youtrack.api.rest.Issues; | |
5 | + | |
6 | +import javax.xml.bind.JAXBContext; | |
7 | +import javax.xml.bind.JAXBException; | |
8 | +import java.io.IOException; | |
9 | +import java.io.InputStream; | |
10 | +import java.io.InputStreamReader; | |
11 | +import java.io.Reader; | |
12 | +import java.io.StringReader; | |
13 | +import java.net.URL; | |
14 | + | |
15 | +public class IssuesUnmarshaller { | |
16 | + | |
17 | + public static Issues unmarshal(String url) throws JAXBException, IOException | |
18 | + { | |
19 | + return unmarshal(new URL(url).openStream()); | |
20 | + } | |
21 | + | |
22 | + public static Issues unmarshal(InputStream stream) throws JAXBException, IOException | |
23 | + { | |
24 | + return unmarshal(new InputStreamReader(stream)); | |
25 | + } | |
26 | + | |
27 | + public static Issues unmarshal(Reader reader) throws JAXBException, IOException | |
28 | + { | |
29 | + String content = IOUtils.toString(reader); | |
30 | + try { | |
31 | + JAXBContext jaxbContext = JAXBContext.newInstance(Issues.class.getPackage().getName()); | |
32 | + return (Issues) jaxbContext.createUnmarshaller().unmarshal(new StringReader(content)); | |
33 | + } catch (JAXBException e) { | |
34 | + System.err.println("Cannot unmarshal input stream.\n" + content + e); | |
35 | + throw e; | |
36 | + } | |
37 | + } | |
38 | +} | ... | ... |
1 | +// | |
2 | +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, vhudson-jaxb-ri-2.1-833 | |
3 | +// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> | |
4 | +// Any modifications to this file will be lost upon recompilation of the source schema. | |
5 | +// Generated on: 2011.12.05 at 08:56:01 AM CET | |
6 | +// | |
7 | + | |
8 | +package pl.com.it_crowd.youtrack.api.rest; | |
9 | + | |
10 | +import javax.xml.bind.JAXBElement; | |
11 | +import javax.xml.bind.annotation.XmlAccessType; | |
12 | +import javax.xml.bind.annotation.XmlAccessorType; | |
13 | +import javax.xml.bind.annotation.XmlAttribute; | |
14 | +import javax.xml.bind.annotation.XmlElement; | |
15 | +import javax.xml.bind.annotation.XmlElementRef; | |
16 | +import javax.xml.bind.annotation.XmlElements; | |
17 | +import javax.xml.bind.annotation.XmlMixed; | |
18 | +import javax.xml.bind.annotation.XmlRootElement; | |
19 | +import javax.xml.bind.annotation.XmlType; | |
20 | +import javax.xml.bind.annotation.XmlValue; | |
21 | +import java.io.Serializable; | |
22 | +import java.util.ArrayList; | |
23 | +import java.util.List; | |
24 | + | |
25 | +/** | |
26 | + * <p>Java class for anonymous complex type. | |
27 | + * <p/> | |
28 | + * <p>The following schema fragment specifies the expected content contained within this class. | |
29 | + * <p/> | |
30 | + * <pre> | |
31 | + * <complexType> | |
32 | + * <complexContent> | |
33 | + * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> | |
34 | + * <sequence> | |
35 | + * <element name="issue" maxOccurs="unbounded" minOccurs="0"> | |
36 | + * <complexType> | |
37 | + * <complexContent> | |
38 | + * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> | |
39 | + * <choice maxOccurs="unbounded" minOccurs="0"> | |
40 | + * <element name="field"> | |
41 | + * <complexType> | |
42 | + * <complexContent> | |
43 | + * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> | |
44 | + * <sequence> | |
45 | + * <element name="value" maxOccurs="unbounded" minOccurs="0"> | |
46 | + * <complexType> | |
47 | + * <complexContent> | |
48 | + * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> | |
49 | + * <attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
50 | + * <attribute name="role" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
51 | + * </restriction> | |
52 | + * </complexContent> | |
53 | + * </complexType> | |
54 | + * </element> | |
55 | + * </sequence> | |
56 | + * <attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
57 | + * </restriction> | |
58 | + * </complexContent> | |
59 | + * </complexType> | |
60 | + * </element> | |
61 | + * <element name="comment"> | |
62 | + * <complexType> | |
63 | + * <complexContent> | |
64 | + * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> | |
65 | + * <sequence> | |
66 | + * <element name="replies" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/> | |
67 | + * <element name="value" minOccurs="0"> | |
68 | + * <complexType> | |
69 | + * <simpleContent> | |
70 | + * <extension base="<http://www.w3.org/2001/XMLSchema>string"> | |
71 | + * <attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
72 | + * <attribute name="role" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
73 | + * </extension> | |
74 | + * </simpleContent> | |
75 | + * </complexType> | |
76 | + * </element> | |
77 | + * </sequence> | |
78 | + * <attribute name="id" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
79 | + * <attribute name="author" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
80 | + * <attribute name="issueId" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
81 | + * <attribute name="deleted" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
82 | + * <attribute name="text" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
83 | + * <attribute name="shownForIssueAuthor" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
84 | + * <attribute name="created" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
85 | + * <attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
86 | + * </restriction> | |
87 | + * </complexContent> | |
88 | + * </complexType> | |
89 | + * </element> | |
90 | + * </choice> | |
91 | + * <attribute name="id" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
92 | + * </restriction> | |
93 | + * </complexContent> | |
94 | + * </complexType> | |
95 | + * </element> | |
96 | + * </sequence> | |
97 | + * </restriction> | |
98 | + * </complexContent> | |
99 | + * </complexType> | |
100 | + * </pre> | |
101 | + */ | |
102 | +@XmlAccessorType(XmlAccessType.FIELD) | |
103 | +@XmlType(name = "", propOrder = {"issue"}) | |
104 | +@XmlRootElement(name = "issues") | |
105 | +public class Issues { | |
106 | + | |
107 | + protected List<Issues.Issue> issue; | |
108 | + | |
109 | + /** | |
110 | + * Gets the value of the issue property. | |
111 | + * <p/> | |
112 | + * <p/> | |
113 | + * This accessor method returns a reference to the live list, | |
114 | + * not a snapshot. Therefore any modification you make to the | |
115 | + * returned list will be present inside the JAXB object. | |
116 | + * This is why there is not a <CODE>set</CODE> method for the issue property. | |
117 | + * <p/> | |
118 | + * <p/> | |
119 | + * For example, to add a new item, do as follows: | |
120 | + * <pre> | |
121 | + * getIssue().add(newItem); | |
122 | + * </pre> | |
123 | + * <p/> | |
124 | + * <p/> | |
125 | + * <p/> | |
126 | + * Objects of the following type(s) are allowed in the list | |
127 | + * {@link Issues.Issue } | |
128 | + */ | |
129 | + public List<Issues.Issue> getIssue() | |
130 | + { | |
131 | + if (issue == null) { | |
132 | + issue = new ArrayList<Issues.Issue>(); | |
133 | + } | |
134 | + return this.issue; | |
135 | + } | |
136 | + | |
137 | + /** | |
138 | + * <p>Java class for anonymous complex type. | |
139 | + * <p/> | |
140 | + * <p>The following schema fragment specifies the expected content contained within this class. | |
141 | + * <p/> | |
142 | + * <pre> | |
143 | + * <complexType> | |
144 | + * <complexContent> | |
145 | + * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> | |
146 | + * <choice maxOccurs="unbounded" minOccurs="0"> | |
147 | + * <element name="field"> | |
148 | + * <complexType> | |
149 | + * <complexContent> | |
150 | + * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> | |
151 | + * <sequence> | |
152 | + * <element name="value" maxOccurs="unbounded" minOccurs="0"> | |
153 | + * <complexType> | |
154 | + * <complexContent> | |
155 | + * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> | |
156 | + * <attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
157 | + * <attribute name="role" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
158 | + * </restriction> | |
159 | + * </complexContent> | |
160 | + * </complexType> | |
161 | + * </element> | |
162 | + * </sequence> | |
163 | + * <attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
164 | + * </restriction> | |
165 | + * </complexContent> | |
166 | + * </complexType> | |
167 | + * </element> | |
168 | + * <element name="comment"> | |
169 | + * <complexType> | |
170 | + * <complexContent> | |
171 | + * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> | |
172 | + * <sequence> | |
173 | + * <element name="replies" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/> | |
174 | + * <element name="value" minOccurs="0"> | |
175 | + * <complexType> | |
176 | + * <simpleContent> | |
177 | + * <extension base="<http://www.w3.org/2001/XMLSchema>string"> | |
178 | + * <attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
179 | + * <attribute name="role" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
180 | + * </extension> | |
181 | + * </simpleContent> | |
182 | + * </complexType> | |
183 | + * </element> | |
184 | + * </sequence> | |
185 | + * <attribute name="id" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
186 | + * <attribute name="author" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
187 | + * <attribute name="issueId" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
188 | + * <attribute name="deleted" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
189 | + * <attribute name="text" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
190 | + * <attribute name="shownForIssueAuthor" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
191 | + * <attribute name="created" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
192 | + * <attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
193 | + * </restriction> | |
194 | + * </complexContent> | |
195 | + * </complexType> | |
196 | + * </element> | |
197 | + * </choice> | |
198 | + * <attribute name="id" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
199 | + * </restriction> | |
200 | + * </complexContent> | |
201 | + * </complexType> | |
202 | + * </pre> | |
203 | + */ | |
204 | + @XmlAccessorType(XmlAccessType.FIELD) | |
205 | + @XmlType(name = "", propOrder = {"fieldOrComment"}) | |
206 | + public static class Issue { | |
207 | + | |
208 | + @XmlElements({@XmlElement(name = "field", type = Issues.Issue.Field.class), @XmlElement(name = "comment", type = Issues.Issue.Comment.class)}) | |
209 | + protected List<Object> fieldOrComment; | |
210 | + | |
211 | + @XmlAttribute | |
212 | + protected String id; | |
213 | + | |
214 | + /** | |
215 | + * Gets the value of the fieldOrComment property. | |
216 | + * <p/> | |
217 | + * <p/> | |
218 | + * This accessor method returns a reference to the live list, | |
219 | + * not a snapshot. Therefore any modification you make to the | |
220 | + * returned list will be present inside the JAXB object. | |
221 | + * This is why there is not a <CODE>set</CODE> method for the fieldOrComment property. | |
222 | + * <p/> | |
223 | + * <p/> | |
224 | + * For example, to add a new item, do as follows: | |
225 | + * <pre> | |
226 | + * getFieldOrComment().add(newItem); | |
227 | + * </pre> | |
228 | + * <p/> | |
229 | + * <p/> | |
230 | + * <p/> | |
231 | + * Objects of the following type(s) are allowed in the list | |
232 | + * {@link Issues.Issue.Field } | |
233 | + * {@link Issues.Issue.Comment } | |
234 | + */ | |
235 | + public List<Object> getFieldOrComment() | |
236 | + { | |
237 | + if (fieldOrComment == null) { | |
238 | + fieldOrComment = new ArrayList<Object>(); | |
239 | + } | |
240 | + return this.fieldOrComment; | |
241 | + } | |
242 | + | |
243 | + /** | |
244 | + * Gets the value of the id property. | |
245 | + * | |
246 | + * @return possible object is | |
247 | + * {@link String } | |
248 | + */ | |
249 | + public String getId() | |
250 | + { | |
251 | + return id; | |
252 | + } | |
253 | + | |
254 | + /** | |
255 | + * Sets the value of the id property. | |
256 | + * | |
257 | + * @param value allowed object is | |
258 | + * {@link String } | |
259 | + */ | |
260 | + public void setId(String value) | |
261 | + { | |
262 | + this.id = value; | |
263 | + } | |
264 | + | |
265 | + /** | |
266 | + * <p>Java class for anonymous complex type. | |
267 | + * <p/> | |
268 | + * <p>The following schema fragment specifies the expected content contained within this class. | |
269 | + * <p/> | |
270 | + * <pre> | |
271 | + * <complexType> | |
272 | + * <complexContent> | |
273 | + * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> | |
274 | + * <sequence> | |
275 | + * <element name="replies" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/> | |
276 | + * <element name="value" minOccurs="0"> | |
277 | + * <complexType> | |
278 | + * <simpleContent> | |
279 | + * <extension base="<http://www.w3.org/2001/XMLSchema>string"> | |
280 | + * <attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
281 | + * <attribute name="role" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
282 | + * </extension> | |
283 | + * </simpleContent> | |
284 | + * </complexType> | |
285 | + * </element> | |
286 | + * </sequence> | |
287 | + * <attribute name="id" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
288 | + * <attribute name="author" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
289 | + * <attribute name="issueId" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
290 | + * <attribute name="deleted" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
291 | + * <attribute name="text" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
292 | + * <attribute name="shownForIssueAuthor" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
293 | + * <attribute name="created" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
294 | + * <attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
295 | + * </restriction> | |
296 | + * </complexContent> | |
297 | + * </complexType> | |
298 | + * </pre> | |
299 | + */ | |
300 | + @XmlAccessorType(XmlAccessType.FIELD) | |
301 | + @XmlType(name = "", propOrder = {"replies", "value"}) | |
302 | + public static class Comment { | |
303 | + | |
304 | + protected String replies; | |
305 | + | |
306 | + protected Issues.Issue.Comment.Value value; | |
307 | + | |
308 | + @XmlAttribute | |
309 | + protected String id; | |
310 | + | |
311 | + @XmlAttribute | |
312 | + protected String author; | |
313 | + | |
314 | + @XmlAttribute | |
315 | + protected String issueId; | |
316 | + | |
317 | + @XmlAttribute | |
318 | + protected String deleted; | |
319 | + | |
320 | + @XmlAttribute | |
321 | + protected String text; | |
322 | + | |
323 | + @XmlAttribute | |
324 | + protected String shownForIssueAuthor; | |
325 | + | |
326 | + @XmlAttribute | |
327 | + protected String created; | |
328 | + | |
329 | + @XmlAttribute | |
330 | + protected String name; | |
331 | + | |
332 | + /** | |
333 | + * Gets the value of the replies property. | |
334 | + * | |
335 | + * @return possible object is | |
336 | + * {@link String } | |
337 | + */ | |
338 | + public String getReplies() | |
339 | + { | |
340 | + return replies; | |
341 | + } | |
342 | + | |
343 | + /** | |
344 | + * Sets the value of the replies property. | |
345 | + * | |
346 | + * @param value allowed object is | |
347 | + * {@link String } | |
348 | + */ | |
349 | + public void setReplies(String value) | |
350 | + { | |
351 | + this.replies = value; | |
352 | + } | |
353 | + | |
354 | + /** | |
355 | + * Gets the value of the value property. | |
356 | + * | |
357 | + * @return possible object is | |
358 | + * {@link Issues.Issue.Comment.Value } | |
359 | + */ | |
360 | + public Issues.Issue.Comment.Value getValue() | |
361 | + { | |
362 | + return value; | |
363 | + } | |
364 | + | |
365 | + /** | |
366 | + * Sets the value of the value property. | |
367 | + * | |
368 | + * @param value allowed object is | |
369 | + * {@link Issues.Issue.Comment.Value } | |
370 | + */ | |
371 | + public void setValue(Issues.Issue.Comment.Value value) | |
372 | + { | |
373 | + this.value = value; | |
374 | + } | |
375 | + | |
376 | + /** | |
377 | + * Gets the value of the id property. | |
378 | + * | |
379 | + * @return possible object is | |
380 | + * {@link String } | |
381 | + */ | |
382 | + public String getId() | |
383 | + { | |
384 | + return id; | |
385 | + } | |
386 | + | |
387 | + /** | |
388 | + * Sets the value of the id property. | |
389 | + * | |
390 | + * @param value allowed object is | |
391 | + * {@link String } | |
392 | + */ | |
393 | + public void setId(String value) | |
394 | + { | |
395 | + this.id = value; | |
396 | + } | |
397 | + | |
398 | + /** | |
399 | + * Gets the value of the author property. | |
400 | + * | |
401 | + * @return possible object is | |
402 | + * {@link String } | |
403 | + */ | |
404 | + public String getAuthor() | |
405 | + { | |
406 | + return author; | |
407 | + } | |
408 | + | |
409 | + /** | |
410 | + * Sets the value of the author property. | |
411 | + * | |
412 | + * @param value allowed object is | |
413 | + * {@link String } | |
414 | + */ | |
415 | + public void setAuthor(String value) | |
416 | + { | |
417 | + this.author = value; | |
418 | + } | |
419 | + | |
420 | + /** | |
421 | + * Gets the value of the issueId property. | |
422 | + * | |
423 | + * @return possible object is | |
424 | + * {@link String } | |
425 | + */ | |
426 | + public String getIssueId() | |
427 | + { | |
428 | + return issueId; | |
429 | + } | |
430 | + | |
431 | + /** | |
432 | + * Sets the value of the issueId property. | |
433 | + * | |
434 | + * @param value allowed object is | |
435 | + * {@link String } | |
436 | + */ | |
437 | + public void setIssueId(String value) | |
438 | + { | |
439 | + this.issueId = value; | |
440 | + } | |
441 | + | |
442 | + /** | |
443 | + * Gets the value of the deleted property. | |
444 | + * | |
445 | + * @return possible object is | |
446 | + * {@link String } | |
447 | + */ | |
448 | + public String getDeleted() | |
449 | + { | |
450 | + return deleted; | |
451 | + } | |
452 | + | |
453 | + /** | |
454 | + * Sets the value of the deleted property. | |
455 | + * | |
456 | + * @param value allowed object is | |
457 | + * {@link String } | |
458 | + */ | |
459 | + public void setDeleted(String value) | |
460 | + { | |
461 | + this.deleted = value; | |
462 | + } | |
463 | + | |
464 | + /** | |
465 | + * Gets the value of the text property. | |
466 | + * | |
467 | + * @return possible object is | |
468 | + * {@link String } | |
469 | + */ | |
470 | + public String getText() | |
471 | + { | |
472 | + return text; | |
473 | + } | |
474 | + | |
475 | + /** | |
476 | + * Sets the value of the text property. | |
477 | + * | |
478 | + * @param value allowed object is | |
479 | + * {@link String } | |
480 | + */ | |
481 | + public void setText(String value) | |
482 | + { | |
483 | + this.text = value; | |
484 | + } | |
485 | + | |
486 | + /** | |
487 | + * Gets the value of the shownForIssueAuthor property. | |
488 | + * | |
489 | + * @return possible object is | |
490 | + * {@link String } | |
491 | + */ | |
492 | + public String getShownForIssueAuthor() | |
493 | + { | |
494 | + return shownForIssueAuthor; | |
495 | + } | |
496 | + | |
497 | + /** | |
498 | + * Sets the value of the shownForIssueAuthor property. | |
499 | + * | |
500 | + * @param value allowed object is | |
501 | + * {@link String } | |
502 | + */ | |
503 | + public void setShownForIssueAuthor(String value) | |
504 | + { | |
505 | + this.shownForIssueAuthor = value; | |
506 | + } | |
507 | + | |
508 | + /** | |
509 | + * Gets the value of the created property. | |
510 | + * | |
511 | + * @return possible object is | |
512 | + * {@link String } | |
513 | + */ | |
514 | + public String getCreated() | |
515 | + { | |
516 | + return created; | |
517 | + } | |
518 | + | |
519 | + /** | |
520 | + * Sets the value of the created property. | |
521 | + * | |
522 | + * @param value allowed object is | |
523 | + * {@link String } | |
524 | + */ | |
525 | + public void setCreated(String value) | |
526 | + { | |
527 | + this.created = value; | |
528 | + } | |
529 | + | |
530 | + /** | |
531 | + * Gets the value of the name property. | |
532 | + * | |
533 | + * @return possible object is | |
534 | + * {@link String } | |
535 | + */ | |
536 | + public String getName() | |
537 | + { | |
538 | + return name; | |
539 | + } | |
540 | + | |
541 | + /** | |
542 | + * Sets the value of the name property. | |
543 | + * | |
544 | + * @param value allowed object is | |
545 | + * {@link String } | |
546 | + */ | |
547 | + public void setName(String value) | |
548 | + { | |
549 | + this.name = value; | |
550 | + } | |
551 | + | |
552 | + /** | |
553 | + * <p>Java class for anonymous complex type. | |
554 | + * <p/> | |
555 | + * <p>The following schema fragment specifies the expected content contained within this class. | |
556 | + * <p/> | |
557 | + * <pre> | |
558 | + * <complexType> | |
559 | + * <simpleContent> | |
560 | + * <extension base="<http://www.w3.org/2001/XMLSchema>string"> | |
561 | + * <attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
562 | + * <attribute name="role" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
563 | + * </extension> | |
564 | + * </simpleContent> | |
565 | + * </complexType> | |
566 | + * </pre> | |
567 | + */ | |
568 | + @XmlAccessorType(XmlAccessType.FIELD) | |
569 | + @XmlType(name = "", propOrder = {"value"}) | |
570 | + public static class Value { | |
571 | + | |
572 | + @XmlValue | |
573 | + protected String value; | |
574 | + | |
575 | + @XmlAttribute | |
576 | + protected String type; | |
577 | + | |
578 | + @XmlAttribute | |
579 | + protected String role; | |
580 | + | |
581 | + /** | |
582 | + * Gets the value of the value property. | |
583 | + * | |
584 | + * @return possible object is | |
585 | + * {@link String } | |
586 | + */ | |
587 | + public String getValue() | |
588 | + { | |
589 | + return value; | |
590 | + } | |
591 | + | |
592 | + /** | |
593 | + * Sets the value of the value property. | |
594 | + * | |
595 | + * @param value allowed object is | |
596 | + * {@link String } | |
597 | + */ | |
598 | + public void setValue(String value) | |
599 | + { | |
600 | + this.value = value; | |
601 | + } | |
602 | + | |
603 | + /** | |
604 | + * Gets the value of the type property. | |
605 | + * | |
606 | + * @return possible object is | |
607 | + * {@link String } | |
608 | + */ | |
609 | + public String getType() | |
610 | + { | |
611 | + return type; | |
612 | + } | |
613 | + | |
614 | + /** | |
615 | + * Sets the value of the type property. | |
616 | + * | |
617 | + * @param value allowed object is | |
618 | + * {@link String } | |
619 | + */ | |
620 | + public void setType(String value) | |
621 | + { | |
622 | + this.type = value; | |
623 | + } | |
624 | + | |
625 | + /** | |
626 | + * Gets the value of the role property. | |
627 | + * | |
628 | + * @return possible object is | |
629 | + * {@link String } | |
630 | + */ | |
631 | + public String getRole() | |
632 | + { | |
633 | + return role; | |
634 | + } | |
635 | + | |
636 | + /** | |
637 | + * Sets the value of the role property. | |
638 | + * | |
639 | + * @param value allowed object is | |
640 | + * {@link String } | |
641 | + */ | |
642 | + public void setRole(String value) | |
643 | + { | |
644 | + this.role = value; | |
645 | + } | |
646 | + } | |
647 | + } | |
648 | + | |
649 | + /** | |
650 | + * <p>Java class for anonymous complex type. | |
651 | + * <p/> | |
652 | + * <p>The following schema fragment specifies the expected content contained within this class. | |
653 | + * <p/> | |
654 | + * <pre> | |
655 | + * <complexType> | |
656 | + * <complexContent> | |
657 | + * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> | |
658 | + * <sequence> | |
659 | + * <element name="value" maxOccurs="unbounded" minOccurs="0"> | |
660 | + * <complexType> | |
661 | + * <complexContent> | |
662 | + * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> | |
663 | + * <attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
664 | + * <attribute name="role" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
665 | + * </restriction> | |
666 | + * </complexContent> | |
667 | + * </complexType> | |
668 | + * </element> | |
669 | + * </sequence> | |
670 | + * <attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
671 | + * </restriction> | |
672 | + * </complexContent> | |
673 | + * </complexType> | |
674 | + * </pre> | |
675 | + */ | |
676 | + @XmlAccessorType(XmlAccessType.FIELD) | |
677 | + @XmlType(name = "", propOrder = {"content"}) | |
678 | + public static class Field { | |
679 | + | |
680 | + @XmlElementRef(name = "value", type = JAXBElement.class) | |
681 | + @XmlMixed | |
682 | + protected List<Serializable> content; | |
683 | + | |
684 | + @XmlAttribute | |
685 | + protected String name; | |
686 | + | |
687 | + /** | |
688 | + * Gets the value of the content property. | |
689 | + * <p/> | |
690 | + * <p/> | |
691 | + * This accessor method returns a reference to the live list, | |
692 | + * not a snapshot. Therefore any modification you make to the | |
693 | + * returned list will be present inside the JAXB object. | |
694 | + * This is why there is not a <CODE>set</CODE> method for the content property. | |
695 | + * <p/> | |
696 | + * <p/> | |
697 | + * For example, to add a new item, do as follows: | |
698 | + * <pre> | |
699 | + * getContent().add(newItem); | |
700 | + * </pre> | |
701 | + * <p/> | |
702 | + * <p/> | |
703 | + * <p/> | |
704 | + * Objects of the following type(s) are allowed in the list | |
705 | + * {@link String } | |
706 | + * {@link JAXBElement }{@code <}{@link Issues.Issue.Field.Value }{@code >} | |
707 | + */ | |
708 | + public List<Serializable> getContent() | |
709 | + { | |
710 | + if (content == null) { | |
711 | + content = new ArrayList<Serializable>(); | |
712 | + } | |
713 | + return this.content; | |
714 | + } | |
715 | + | |
716 | + /** | |
717 | + * Gets the value of the name property. | |
718 | + * | |
719 | + * @return possible object is | |
720 | + * {@link String } | |
721 | + */ | |
722 | + public String getName() | |
723 | + { | |
724 | + return name; | |
725 | + } | |
726 | + | |
727 | + /** | |
728 | + * Sets the value of the name property. | |
729 | + * | |
730 | + * @param value allowed object is | |
731 | + * {@link String } | |
732 | + */ | |
733 | + public void setName(String value) | |
734 | + { | |
735 | + this.name = value; | |
736 | + } | |
737 | + | |
738 | + /** | |
739 | + * <p>Java class for anonymous complex type. | |
740 | + * <p/> | |
741 | + * <p>The following schema fragment specifies the expected content contained within this class. | |
742 | + * <p/> | |
743 | + * <pre> | |
744 | + * <complexType> | |
745 | + * <complexContent> | |
746 | + * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> | |
747 | + * <attribute name="type" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
748 | + * <attribute name="role" type="{http://www.w3.org/2001/XMLSchema}string" /> | |
749 | + * </restriction> | |
750 | + * </complexContent> | |
751 | + * </complexType> | |
752 | + * </pre> | |
753 | + */ | |
754 | + @XmlAccessorType(XmlAccessType.FIELD) | |
755 | + @XmlType(name = "") | |
756 | + public static class Value { | |
757 | + | |
758 | + @XmlAttribute | |
759 | + protected String type; | |
760 | + | |
761 | + @XmlAttribute | |
762 | + protected String role; | |
763 | + | |
764 | + /** | |
765 | + * Gets the value of the type property. | |
766 | + * | |
767 | + * @return possible object is | |
768 | + * {@link String } | |
769 | + */ | |
770 | + public String getType() | |
771 | + { | |
772 | + return type; | |
773 | + } | |
774 | + | |
775 | + /** | |
776 | + * Sets the value of the type property. | |
777 | + * | |
778 | + * @param value allowed object is | |
779 | + * {@link String } | |
780 | + */ | |
781 | + public void setType(String value) | |
782 | + { | |
783 | + this.type = value; | |
784 | + } | |
785 | + | |
786 | + /** | |
787 | + * Gets the value of the role property. | |
788 | + * | |
789 | + * @return possible object is | |
790 | + * {@link String } | |
791 | + */ | |
792 | + public String getRole() | |
793 | + { | |
794 | + return role; | |
795 | + } | |
796 | + | |
797 | + /** | |
798 | + * Sets the value of the role property. | |
799 | + * | |
800 | + * @param value allowed object is | |
801 | + * {@link String } | |
802 | + */ | |
803 | + public void setRole(String value) | |
804 | + { | |
805 | + this.role = value; | |
806 | + } | |
807 | + } | |
808 | + } | |
809 | + } | |
810 | +} | ... | ... |
1 | +// | |
2 | +// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, vhudson-jaxb-ri-2.1-833 | |
3 | +// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> | |
4 | +// Any modifications to this file will be lost upon recompilation of the source schema. | |
5 | +// Generated on: 2011.12.05 at 08:56:01 AM CET | |
6 | +// | |
7 | + | |
8 | +package pl.com.it_crowd.youtrack.api.rest; | |
9 | + | |
10 | +import javax.xml.bind.JAXBElement; | |
11 | +import javax.xml.bind.annotation.XmlElementDecl; | |
12 | +import javax.xml.bind.annotation.XmlRegistry; | |
13 | +import javax.xml.namespace.QName; | |
14 | + | |
15 | +/** | |
16 | + * This object contains factory methods for each | |
17 | + * Java content interface and Java element interface | |
18 | + * generated in the pl.com.it_crowd.youtrack.api.rest package. | |
19 | + * <p>An ObjectFactory allows you to programatically | |
20 | + * construct new instances of the Java representation | |
21 | + * for XML content. The Java representation of XML | |
22 | + * content can consist of schema derived interfaces | |
23 | + * and classes representing the binding of schema | |
24 | + * type definitions, element declarations and model | |
25 | + * groups. Factory methods for each of these are | |
26 | + * provided in this class. | |
27 | + */ | |
28 | +@XmlRegistry | |
29 | +public class ObjectFactory { | |
30 | + | |
31 | + private final static QName _IssuesIssueFieldValue_QNAME = new QName("", "value"); | |
32 | + | |
33 | + /** | |
34 | + * Create a new ObjectFactory that can be used to create new instances of schema derived classes for package: pl.com.it_crowd.youtrack.api.rest | |
35 | + */ | |
36 | + public ObjectFactory() | |
37 | + { | |
38 | + } | |
39 | + | |
40 | + /** | |
41 | + * Create an instance of {@link Issues.Issue.Comment.Value } | |
42 | + */ | |
43 | + public Issues.Issue.Comment.Value createIssuesIssueCommentValue() | |
44 | + { | |
45 | + return new Issues.Issue.Comment.Value(); | |
46 | + } | |
47 | + | |
48 | + /** | |
49 | + * Create an instance of {@link Issues.Issue.Comment } | |
50 | + */ | |
51 | + public Issues.Issue.Comment createIssuesIssueComment() | |
52 | + { | |
53 | + return new Issues.Issue.Comment(); | |
54 | + } | |
55 | + | |
56 | + /** | |
57 | + * Create an instance of {@link Issues.Issue.Field } | |
58 | + */ | |
59 | + public Issues.Issue.Field createIssuesIssueField() | |
60 | + { | |
61 | + return new Issues.Issue.Field(); | |
62 | + } | |
63 | + | |
64 | + /** | |
65 | + * Create an instance of {@link Issues } | |
66 | + */ | |
67 | + public Issues createIssues() | |
68 | + { | |
69 | + return new Issues(); | |
70 | + } | |
71 | + | |
72 | + /** | |
73 | + * Create an instance of {@link Issues.Issue } | |
74 | + */ | |
75 | + public Issues.Issue createIssuesIssue() | |
76 | + { | |
77 | + return new Issues.Issue(); | |
78 | + } | |
79 | + | |
80 | + /** | |
81 | + * Create an instance of {@link Issues.Issue.Field.Value } | |
82 | + */ | |
83 | + public Issues.Issue.Field.Value createIssuesIssueFieldValue() | |
84 | + { | |
85 | + return new Issues.Issue.Field.Value(); | |
86 | + } | |
87 | + | |
88 | + /** | |
89 | + * Create an instance of {@link JAXBElement }{@code <}{@link Issues.Issue.Field.Value }{@code >}} | |
90 | + */ | |
91 | + @XmlElementDecl(namespace = "", name = "value", scope = Issues.Issue.Field.class) | |
92 | + public JAXBElement<Issues.Issue.Field.Value> createIssuesIssueFieldValue(Issues.Issue.Field.Value value) | |
93 | + { | |
94 | + return new JAXBElement<Issues.Issue.Field.Value>(_IssuesIssueFieldValue_QNAME, Issues.Issue.Field.Value.class, Issues.Issue.Field.class, value); | |
95 | + } | |
96 | +} | ... | ... |
1 | +package pl.com.it_crowd.youtrack.api.rest; | |
2 | + | |
3 | +import com.gargoylesoftware.htmlunit.BrowserVersion; | |
4 | +import com.gargoylesoftware.htmlunit.HttpMethod; | |
5 | +import com.gargoylesoftware.htmlunit.Page; | |
6 | +import com.gargoylesoftware.htmlunit.WebClient; | |
7 | +import com.gargoylesoftware.htmlunit.WebRequest; | |
8 | +import com.gargoylesoftware.htmlunit.WebResponse; | |
9 | +import com.gargoylesoftware.htmlunit.util.NameValuePair; | |
10 | +import pl.com.it_crowd.youtrack.api.IssuesUnmarshaller; | |
11 | + | |
12 | +import javax.xml.bind.JAXBException; | |
13 | +import java.io.IOException; | |
14 | +import java.net.URL; | |
15 | +import java.util.ArrayList; | |
16 | + | |
17 | +public class YoutrackAPI { | |
18 | + | |
19 | + private String serviceLocation; | |
20 | + | |
21 | + private WebClient webClient; | |
22 | + | |
23 | + public String getServiceLocation() | |
24 | + { | |
25 | + return serviceLocation; | |
26 | + } | |
27 | + | |
28 | + public YoutrackAPI(String serviceLocation) | |
29 | + { | |
30 | + this.serviceLocation = serviceLocation; | |
31 | + this.webClient = new WebClient(BrowserVersion.FIREFOX_3_6); | |
32 | + this.webClient.setJavaScriptEnabled(false); | |
33 | + this.webClient.setCssEnabled(false); | |
34 | + } | |
35 | + | |
36 | + public YoutrackAPI(String serviceLocation, String username, String password) throws IOException | |
37 | + { | |
38 | + this(serviceLocation); | |
39 | + login(username, password); | |
40 | + } | |
41 | + | |
42 | + public void login(String username, String password) throws IOException | |
43 | + { | |
44 | + ArrayList<NameValuePair> requestParameters = new ArrayList<NameValuePair>(); | |
45 | + requestParameters.add(new NameValuePair("login", username)); | |
46 | + requestParameters.add(new NameValuePair("password", password)); | |
47 | + WebRequest request = new WebRequest(new URL(serviceLocation + "/rest/user/login"), HttpMethod.POST); | |
48 | + request.setRequestParameters(requestParameters); | |
49 | + WebResponse response = webClient.getPage(request).getWebResponse(); | |
50 | + System.out.println(response); | |
51 | + System.out.println(response.getContentAsString()); | |
52 | + } | |
53 | + | |
54 | + public Issues searchIssuesByProject(String project, String filter) throws JAXBException, IOException | |
55 | + { | |
56 | + String url = serviceLocation + "/rest/issue/byproject/" + project + "?filter=" + filter; | |
57 | + return IssuesUnmarshaller.unmarshal(webClient.<Page>getPage(url).getWebResponse().getContentAsStream()); | |
58 | + } | |
59 | +} | ... | ... |
src/main/xsd/issuesByProject.xml
0 → 100644
1 | +<?xml version="1.0" encoding="UTF-8" standalone="yes"?> | |
2 | +<issues> | |
3 | + <issue id="SM-1"> | |
4 | + <field name="voterName"/> | |
5 | + <field name="Priority"> | |
6 | + <value>Normal</value> | |
7 | + </field> | |
8 | + <field name="Type"> | |
9 | + <value>Task</value> | |
10 | + </field> | |
11 | + <field name="State"> | |
12 | + <value>Verified</value> | |
13 | + </field> | |
14 | + <field name="Subsystem"> | |
15 | + <value>No subsystem</value> | |
16 | + </field> | |
17 | + <field name="links"> | |
18 | + <value type="Depend" role="depends on">SM-2</value> | |
19 | + <value type="Depend" role="depends on">SM-3</value> | |
20 | + <value type="Depend" role="depends on">SM-4</value> | |
21 | + <value type="Depend" role="depends on">SM-5</value> | |
22 | + <value type="Depend" role="depends on">SM-6</value> | |
23 | + <value type="Depend" role="depends on">SM-7</value> | |
24 | + <value type="Depend" role="depends on">SM-8</value> | |
25 | + <value type="Depend" role="depends on">SM-9</value> | |
26 | + <value type="Depend" role="depends on">SM-10</value> | |
27 | + </field> | |
28 | + <field name="projectShortName"> | |
29 | + <value>SM</value> | |
30 | + </field> | |
31 | + <field name="numberInProject"> | |
32 | + <value>1</value> | |
33 | + </field> | |
34 | + <field name="summary"> | |
35 | + <value>Draw screens</value> | |
36 | + </field> | |
37 | + <field name="description"> | |
38 | + <value>Draw screens in Balsamiq, the online tool for drawing screen sketches. http://balsamiq.com/ | |
39 | + As a result the screen image in PNG format and Balsamiq source in XML format are expected. | |
40 | + Artefacts must be delivered in form of directory structure (not in Enterprise Architect file). | |
41 | + Partially documented packages will not be accepted. | |
42 | + Sample directory structure: | |
43 | + + Package name (directory) | |
44 | + + Screen name (directory) | |
45 | + - Screen name.png | |
46 | + - Screen name.xml | |
47 | + | |
48 | + In screens include only elements specific to documented screen. Do not include stuff that will land in template. | |
49 | + </value> | |
50 | + </field> | |
51 | + <field name="created"> | |
52 | + <value>1292829185847</value> | |
53 | + </field> | |
54 | + <field name="updated"> | |
55 | + <value>1321871424473</value> | |
56 | + </field> | |
57 | + <field name="updaterName"> | |
58 | + <value>root</value> | |
59 | + </field> | |
60 | + <field name="resolved"> | |
61 | + <value>1321607946298</value> | |
62 | + </field> | |
63 | + <field name="reporterName"> | |
64 | + <value>bernard</value> | |
65 | + </field> | |
66 | + <field name="commentsCount"> | |
67 | + <value>0</value> | |
68 | + </field> | |
69 | + <field name="votes"> | |
70 | + <value>0</value> | |
71 | + </field> | |
72 | + </issue> | |
73 | + <issue id="SM-2"> | |
74 | + <field name="voterName"/> | |
75 | + <comment id="39-74" author="bernard" issueId="SM-2" deleted="false" text="See parent task for details." shownForIssueAuthor="false" | |
76 | + created="1292829250455"> | |
77 | + <replies/> | |
78 | + </comment> | |
79 | + <field name="Priority"> | |
80 | + <value>Normal</value> | |
81 | + </field> | |
82 | + <field name="Type"> | |
83 | + <value>Task</value> | |
84 | + </field> | |
85 | + <field name="State"> | |
86 | + <value>Verified</value> | |
87 | + </field> | |
88 | + <field name="Assignee"> | |
89 | + <value>tomek</value> | |
90 | + </field> | |
91 | + <field name="Subsystem"> | |
92 | + <value>No subsystem</value> | |
93 | + </field> | |
94 | + <field name="links"> | |
95 | + <value type="Depend" role="is required for">SM-1</value> | |
96 | + </field> | |
97 | + <field name="projectShortName"> | |
98 | + <value>SM</value> | |
99 | + </field> | |
100 | + <field name="numberInProject"> | |
101 | + <value>2</value> | |
102 | + </field> | |
103 | + <field name="summary"> | |
104 | + <value>Draw screens for "Courses & classes" package</value> | |
105 | + </field> | |
106 | + <field name="created"> | |
107 | + <value>1292829263475</value> | |
108 | + </field> | |
109 | + <field name="updated"> | |
110 | + <value>1321871424473</value> | |
111 | + </field> | |
112 | + <field name="updaterName"> | |
113 | + <value>root</value> | |
114 | + </field> | |
115 | + <field name="resolved"> | |
116 | + <value>1321607946297</value> | |
117 | + </field> | |
118 | + <field name="reporterName"> | |
119 | + <value>bernard</value> | |
120 | + </field> | |
121 | + <field name="commentsCount"> | |
122 | + <value>1</value> | |
123 | + </field> | |
124 | + <field name="votes"> | |
125 | + <value>0</value> | |
126 | + </field> | |
127 | + </issue> | |
128 | + <issue id="SM-3"> | |
129 | + <field name="voterName"/> | |
130 | + <comment id="39-75" author="bernard" issueId="SM-3" deleted="false" text="See parent task for details." shownForIssueAuthor="false" | |
131 | + created="1292829295404"> | |
132 | + <replies/> | |
133 | + </comment> | |
134 | + <field name="Priority"> | |
135 | + <value>Normal</value> | |
136 | + </field> | |
137 | + <field name="Type"> | |
138 | + <value>Task</value> | |
139 | + </field> | |
140 | + <field name="State"> | |
141 | + <value>Verified</value> | |
142 | + </field> | |
143 | + <field name="Assignee"> | |
144 | + <value>tomek</value> | |
145 | + </field> | |
146 | + <field name="Subsystem"> | |
147 | + <value>No subsystem</value> | |
148 | + </field> | |
149 | + <field name="links"> | |
150 | + <value type="Depend" role="is required for">SM-1</value> | |
151 | + </field> | |
152 | + <field name="projectShortName"> | |
153 | + <value>SM</value> | |
154 | + </field> | |
155 | + <field name="numberInProject"> | |
156 | + <value>3</value> | |
157 | + </field> | |
158 | + <field name="summary"> | |
159 | + <value>Draw screens for "Discounts" package</value> | |
160 | + </field> | |
161 | + <field name="created"> | |
162 | + <value>1292829302297</value> | |
163 | + </field> | |
164 | + <field name="updated"> | |
165 | + <value>1321871424473</value> | |
166 | + </field> | |
167 | + <field name="updaterName"> | |
168 | + <value>root</value> | |
169 | + </field> | |
170 | + <field name="resolved"> | |
171 | + <value>1321607946296</value> | |
172 | + </field> | |
173 | + <field name="reporterName"> | |
174 | + <value>bernard</value> | |
175 | + </field> | |
176 | + <field name="commentsCount"> | |
177 | + <value>1</value> | |
178 | + </field> | |
179 | + <field name="votes"> | |
180 | + <value>0</value> | |
181 | + </field> | |
182 | + </issue> | |
183 | + <issue id="SM-4"> | |
184 | + <field name="voterName"/> | |
185 | + <comment id="39-76" author="bernard" issueId="SM-4" deleted="false" text="See parent task for details." shownForIssueAuthor="false" | |
186 | + created="1292829335014"> | |
187 | + <replies/> | |
188 | + </comment> | |
189 | + <comment id="39-86" author="tomek" issueId="SM-4" deleted="false" | |
190 | + text="Some use cases are related to "Students" and "Courses and Classes" packages. These weren't finished yet." | |
191 | + shownForIssueAuthor="false" created="1292932584457"> | |
192 | + <replies/> | |
193 | + </comment> | |
194 | + <field name="Priority"> | |
195 | + <value>Normal</value> | |
196 | + </field> | |
197 | + <field name="Type"> | |
198 | + <value>Task</value> | |
199 | + </field> | |
200 | + <field name="State"> | |
201 | + <value>Verified</value> | |
202 | + </field> | |
203 | + <field name="Assignee"> | |
204 | + <value>tomek</value> | |
205 | + </field> | |
206 | + <field name="Subsystem"> | |
207 | + <value>No subsystem</value> | |
208 | + </field> | |
209 | + <field name="links"> | |
210 | + <value type="Depend" role="is required for">SM-1</value> | |
211 | + </field> | |
212 | + <field name="projectShortName"> | |
213 | + <value>SM</value> | |
214 | + </field> | |
215 | + <field name="numberInProject"> | |
216 | + <value>4</value> | |
217 | + </field> | |
218 | + <field name="summary"> | |
219 | + <value>Draw screens for "Passes" package</value> | |
220 | + </field> | |
221 | + <field name="created"> | |
222 | + <value>1292829339100</value> | |
223 | + </field> | |
224 | + <field name="updated"> | |
225 | + <value>1321871424473</value> | |
226 | + </field> | |
227 | + <field name="updaterName"> | |
228 | + <value>root</value> | |
229 | + </field> | |
230 | + <field name="resolved"> | |
231 | + <value>1321607946296</value> | |
232 | + </field> | |
233 | + <field name="reporterName"> | |
234 | + <value>bernard</value> | |
235 | + </field> | |
236 | + <field name="commentsCount"> | |
237 | + <value>2</value> | |
238 | + </field> | |
239 | + <field name="votes"> | |
240 | + <value>0</value> | |
241 | + </field> | |
242 | + </issue> | |
243 | + <issue id="SM-5"> | |
244 | + <field name="voterName"/> | |
245 | + <comment id="39-77" author="bernard" issueId="SM-5" deleted="false" text="See parent task for details." shownForIssueAuthor="false" | |
246 | + created="1292829374840"> | |
247 | + <replies/> | |
248 | + </comment> | |
249 | + <comment id="39-83" author="jacek" issueId="SM-5" deleted="true" | |
250 | + text="Można by się zastanowić czy szkoła ustala listę sprzętu i przy tworzeniu sali wybiera sprzęt z listy, czy po prostu wpisuje w inputa całą listę" | |
251 | + shownForIssueAuthor="false" created="1292881859712"> | |
252 | + <replies/> | |
253 | + </comment> | |
254 | + <comment id="39-84" author="jacek" issueId="SM-5" deleted="false" | |
255 | + text="Zastanawiam się czy będziemy używać stron w modelu view/edit, czy na liście będziemy mieli przyciski edytuj oraz usuń po których wykonywać się będą odpowiednie akcje" | |
256 | + shownForIssueAuthor="false" created="1292882323313"> | |
257 | + <replies/> | |
258 | + </comment> | |
259 | + <comment id="39-85" author="jacek" issueId="SM-5" deleted="false" text="Będziemy używać komponentów typu input inplace " shownForIssueAuthor="false" | |
260 | + created="1292924308679"> | |
261 | + <replies/> | |
262 | + </comment> | |
263 | + <field name="Priority"> | |
264 | + <value>Normal</value> | |
265 | + </field> | |
266 | + <field name="Type"> | |
267 | + <value>Task</value> | |
268 | + </field> | |
269 | + <field name="State"> | |
270 | + <value>Verified</value> | |
271 | + </field> | |
272 | + <field name="Assignee"> | |
273 | + <value>jacek</value> | |
274 | + </field> | |
275 | + <field name="Subsystem"> | |
276 | + <value>No subsystem</value> | |
277 | + </field> | |
278 | + <field name="links"> | |
279 | + <value type="Depend" role="is required for">SM-1</value> | |
280 | + </field> | |
281 | + <field name="projectShortName"> | |
282 | + <value>SM</value> | |
283 | + </field> | |
284 | + <field name="numberInProject"> | |
285 | + <value>5</value> | |
286 | + </field> | |
287 | + <field name="summary"> | |
288 | + <value>Draw screens for "Rooms" package</value> | |
289 | + </field> | |
290 | + <field name="created"> | |
291 | + <value>1292829377329</value> | |
292 | + </field> | |
293 | + <field name="updated"> | |
294 | + <value>1321871424471</value> | |
295 | + </field> | |
296 | + <field name="updaterName"> | |
297 | + <value>root</value> | |
298 | + </field> | |
299 | + <field name="resolved"> | |
300 | + <value>1321607946295</value> | |
301 | + </field> | |
302 | + <field name="reporterName"> | |
303 | + <value>bernard</value> | |
304 | + </field> | |
305 | + <field name="commentsCount"> | |
306 | + <value>3</value> | |
307 | + </field> | |
308 | + <field name="votes"> | |
309 | + <value>0</value> | |
310 | + </field> | |
311 | + </issue> | |
312 | + <issue id="SM-6"> | |
313 | + <field name="voterName"/> | |
314 | + <comment id="39-78" author="bernard" issueId="SM-6" deleted="false" text="See parent task for details." shownForIssueAuthor="false" | |
315 | + created="1292829408224"> | |
316 | + <replies/> | |
317 | + </comment> | |
318 | + <field name="Priority"> | |
319 | + <value>Normal</value> | |
320 | + </field> | |
321 | + <field name="Type"> | |
322 | + <value>Task</value> | |
323 | + </field> | |
324 | + <field name="State"> | |
325 | + <value>Verified</value> | |
326 | + </field> | |
327 | + <field name="Assignee"> | |
328 | + <value>tomek</value> | |
329 | + </field> | |
330 | + <field name="Subsystem"> | |
331 | + <value>No subsystem</value> | |
332 | + </field> | |
333 | + <field name="links"> | |
334 | + <value type="Depend" role="is required for">SM-1</value> | |
335 | + </field> | |
336 | + <field name="projectShortName"> | |
337 | + <value>SM</value> | |
338 | + </field> | |
339 | + <field name="numberInProject"> | |
340 | + <value>6</value> | |
341 | + </field> | |
342 | + <field name="summary"> | |
343 | + <value>Draw screens for "Schools" package</value> | |
344 | + </field> | |
345 | + <field name="created"> | |
346 | + <value>1292829411325</value> | |
347 | + </field> | |
348 | + <field name="updated"> | |
349 | + <value>1321871424472</value> | |
350 | + </field> | |
351 | + <field name="updaterName"> | |
352 | + <value>root</value> | |
353 | + </field> | |
354 | + <field name="resolved"> | |
355 | + <value>1321607946294</value> | |
356 | + </field> | |
357 | + <field name="reporterName"> | |
358 | + <value>bernard</value> | |
359 | + </field> | |
360 | + <field name="commentsCount"> | |
361 | + <value>1</value> | |
362 | + </field> | |
363 | + <field name="votes"> | |
364 | + <value>0</value> | |
365 | + </field> | |
366 | + </issue> | |
367 | + <issue id="SM-7"> | |
368 | + <field name="voterName"/> | |
369 | + <comment id="39-79" author="bernard" issueId="SM-7" deleted="false" text="See parent task for details." shownForIssueAuthor="false" | |
370 | + created="1292829466655"> | |
371 | + <replies/> | |
372 | + </comment> | |
373 | + <field name="Priority"> | |
374 | + <value>Normal</value> | |
375 | + </field> | |
376 | + <field name="Type"> | |
377 | + <value>Task</value> | |
378 | + </field> | |
379 | + <field name="State"> | |
380 | + <value>Verified</value> | |
381 | + </field> | |
382 | + <field name="Assignee"> | |
383 | + <value>jacek</value> | |
384 | + </field> | |
385 | + <field name="Subsystem"> | |
386 | + <value>No subsystem</value> | |
387 | + </field> | |
388 | + <field name="links"> | |
389 | + <value type="Depend" role="is required for">SM-1</value> | |
390 | + </field> | |
391 | + <field name="projectShortName"> | |
392 | + <value>SM</value> | |
393 | + </field> | |
394 | + <field name="numberInProject"> | |
395 | + <value>7</value> | |
396 | + </field> | |
397 | + <field name="summary"> | |
398 | + <value>Draw screens for "Students" package</value> | |
399 | + </field> | |
400 | + <field name="created"> | |
401 | + <value>1292829469581</value> | |
402 | + </field> | |
403 | + <field name="updated"> | |
404 | + <value>1321871424472</value> | |
405 | + </field> | |
406 | + <field name="updaterName"> | |
407 | + <value>root</value> | |
408 | + </field> | |
409 | + <field name="resolved"> | |
410 | + <value>1321607946302</value> | |
411 | + </field> | |
412 | + <field name="reporterName"> | |
413 | + <value>bernard</value> | |
414 | + </field> | |
415 | + <field name="commentsCount"> | |
416 | + <value>1</value> | |
417 | + </field> | |
418 | + <field name="votes"> | |
419 | + <value>0</value> | |
420 | + </field> | |
421 | + </issue> | |
422 | + <issue id="SM-8"> | |
423 | + <field name="voterName"/> | |
424 | + <comment id="39-80" author="bernard" issueId="SM-8" deleted="false" text="See parent task for details." shownForIssueAuthor="false" | |
425 | + created="1292829510003"> | |
426 | + <replies/> | |
427 | + </comment> | |
428 | + <field name="Priority"> | |
429 | + <value>Normal</value> | |
430 | + </field> | |
431 | + <field name="Type"> | |
432 | + <value>Task</value> | |
433 | + </field> | |
434 | + <field name="State"> | |
435 | + <value>Verified</value> | |
436 | + </field> | |
437 | + <field name="Assignee"> | |
438 | + <value>tomek</value> | |
439 | + </field> | |
440 | + <field name="Subsystem"> | |
441 | + <value>No subsystem</value> | |
442 | + </field> | |
443 | + <field name="links"> | |
444 | + <value type="Depend" role="is required for">SM-1</value> | |
445 | + </field> | |
446 | + <field name="projectShortName"> | |
447 | + <value>SM</value> | |
448 | + </field> | |
449 | + <field name="numberInProject"> | |
450 | + <value>8</value> | |
451 | + </field> | |
452 | + <field name="summary"> | |
453 | + <value>Draw screens for "Subjects" package</value> | |
454 | + </field> | |
455 | + <field name="created"> | |
456 | + <value>1292829513591</value> | |
457 | + </field> | |
458 | + <field name="updated"> | |
459 | + <value>1321871424472</value> | |
460 | + </field> | |
461 | + <field name="updaterName"> | |
462 | + <value>root</value> | |
463 | + </field> | |
464 | + <field name="resolved"> | |
465 | + <value>1321607946301</value> | |
466 | + </field> | |
467 | + <field name="reporterName"> | |
468 | + <value>bernard</value> | |
469 | + </field> | |
470 | + <field name="commentsCount"> | |
471 | + <value>1</value> | |
472 | + </field> | |
473 | + <field name="votes"> | |
474 | + <value>0</value> | |
475 | + </field> | |
476 | + </issue> | |
477 | + <issue id="SM-9"> | |
478 | + <field name="voterName"/> | |
479 | + <comment id="39-81" author="bernard" issueId="SM-9" deleted="false" text="See parent task for details." shownForIssueAuthor="false" | |
480 | + created="1292829550576"> | |
481 | + <replies/> | |
482 | + </comment> | |
483 | + <field name="Priority"> | |
484 | + <value>Normal</value> | |
485 | + </field> | |
486 | + <field name="Type"> | |
487 | + <value>Task</value> | |
488 | + </field> | |
489 | + <field name="State"> | |
490 | + <value>Verified</value> | |
491 | + </field> | |
492 | + <field name="Assignee"> | |
493 | + <value>tomek</value> | |
494 | + </field> | |
495 | + <field name="Subsystem"> | |
496 | + <value>No subsystem</value> | |
497 | + </field> | |
498 | + <field name="links"> | |
499 | + <value type="Depend" role="is required for">SM-1</value> | |
500 | + </field> | |
501 | + <field name="projectShortName"> | |
502 | + <value>SM</value> | |
503 | + </field> | |
504 | + <field name="numberInProject"> | |
505 | + <value>9</value> | |
506 | + </field> | |
507 | + <field name="summary"> | |
508 | + <value>Draw screens for "Teachers" package</value> | |
509 | + </field> | |
510 | + <field name="created"> | |
511 | + <value>1292829553292</value> | |
512 | + </field> | |
513 | + <field name="updated"> | |
514 | + <value>1321871424470</value> | |
515 | + </field> | |
516 | + <field name="updaterName"> | |
517 | + <value>root</value> | |
518 | + </field> | |
519 | + <field name="resolved"> | |
520 | + <value>1321607946301</value> | |
521 | + </field> | |
522 | + <field name="reporterName"> | |
523 | + <value>bernard</value> | |
524 | + </field> | |
525 | + <field name="commentsCount"> | |
526 | + <value>1</value> | |
527 | + </field> | |
528 | + <field name="votes"> | |
529 | + <value>0</value> | |
530 | + </field> | |
531 | + </issue> | |
532 | + <issue id="SM-10"> | |
533 | + <field name="voterName"/> | |
534 | + <comment id="39-82" author="bernard" issueId="SM-10" deleted="false" text="See parent task for details." shownForIssueAuthor="false" | |
535 | + created="1292829586642"> | |
536 | + <replies/> | |
537 | + </comment> | |
538 | + <field name="Priority"> | |
539 | + <value>Normal</value> | |
540 | + </field> | |
541 | + <field name="Type"> | |
542 | + <value>Task</value> | |
543 | + </field> | |
544 | + <field name="State"> | |
545 | + <value>Verified</value> | |
546 | + </field> | |
547 | + <field name="Assignee"> | |
548 | + <value>tomek</value> | |
549 | + </field> | |
550 | + <field name="Subsystem"> | |
551 | + <value>No subsystem</value> | |
552 | + </field> | |
553 | + <field name="links"> | |
554 | + <value type="Depend" role="is required for">SM-1</value> | |
555 | + </field> | |
556 | + <field name="projectShortName"> | |
557 | + <value>SM</value> | |
558 | + </field> | |
559 | + <field name="numberInProject"> | |
560 | + <value>10</value> | |
561 | + </field> | |
562 | + <field name="summary"> | |
563 | + <value>Draw screens for "Users" package</value> | |
564 | + </field> | |
565 | + <field name="created"> | |
566 | + <value>1292829588016</value> | |
567 | + </field> | |
568 | + <field name="updated"> | |
569 | + <value>1321871424471</value> | |
570 | + </field> | |
571 | + <field name="updaterName"> | |
572 | + <value>root</value> | |
573 | + </field> | |
574 | + <field name="resolved"> | |
575 | + <value>1321607946300</value> | |
576 | + </field> | |
577 | + <field name="reporterName"> | |
578 | + <value>bernard</value> | |
579 | + </field> | |
580 | + <field name="commentsCount"> | |
581 | + <value>1</value> | |
582 | + </field> | |
583 | + <field name="votes"> | |
584 | + <value>0</value> | |
585 | + </field> | |
586 | + </issue> | |
587 | +</issues> | |
\ No newline at end of file | ... | ... |
src/main/xsd/issuesByProject.xsd
0 → 100644
1 | +<?xml version="1.0" encoding="UTF-8"?> | |
2 | +<xs:schema attributeFormDefault="unqualified" elementFormDefault="qualified" xmlns:xs="http://www.w3.org/2001/XMLSchema"> | |
3 | + <xs:element name="issues"> | |
4 | + <xs:complexType> | |
5 | + <xs:sequence> | |
6 | + <xs:element name="issue" maxOccurs="unbounded" minOccurs="0"> | |
7 | + <xs:complexType> | |
8 | + <xs:choice maxOccurs="unbounded" minOccurs="0"> | |
9 | + <xs:element name="field"> | |
10 | + <xs:complexType mixed="true"> | |
11 | + <xs:sequence> | |
12 | + <xs:element name="value" maxOccurs="unbounded" minOccurs="0"> | |
13 | + <xs:complexType> | |
14 | + <xs:attribute type="xs:string" name="type" use="optional"/> | |
15 | + <xs:attribute type="xs:string" name="role" use="optional"/> | |
16 | + </xs:complexType> | |
17 | + </xs:element> | |
18 | + </xs:sequence> | |
19 | + <xs:attribute type="xs:string" name="name" use="optional"/> | |
20 | + </xs:complexType> | |
21 | + </xs:element> | |
22 | + <xs:element name="comment"> | |
23 | + <xs:complexType> | |
24 | + <xs:sequence> | |
25 | + <xs:element type="xs:string" name="replies" minOccurs="0"/> | |
26 | + <xs:element name="value" minOccurs="0"> | |
27 | + <xs:complexType> | |
28 | + <xs:simpleContent> | |
29 | + <xs:extension base="xs:string"> | |
30 | + <xs:attribute type="xs:string" name="type" use="optional"/> | |
31 | + <xs:attribute type="xs:string" name="role" use="optional"/> | |
32 | + </xs:extension> | |
33 | + </xs:simpleContent> | |
34 | + </xs:complexType> | |
35 | + </xs:element> | |
36 | + </xs:sequence> | |
37 | + <xs:attribute type="xs:string" name="id" use="optional"/> | |
38 | + <xs:attribute type="xs:string" name="author" use="optional"/> | |
39 | + <xs:attribute type="xs:string" name="issueId" use="optional"/> | |
40 | + <xs:attribute type="xs:string" name="deleted" use="optional"/> | |
41 | + <xs:attribute type="xs:string" name="text" use="optional"/> | |
42 | + <xs:attribute type="xs:string" name="shownForIssueAuthor" use="optional"/> | |
43 | + <xs:attribute type="xs:string" name="created" use="optional"/> | |
44 | + <xs:attribute type="xs:string" name="name" use="optional"/> | |
45 | + </xs:complexType> | |
46 | + </xs:element> | |
47 | + </xs:choice> | |
48 | + <xs:attribute type="xs:string" name="id" use="optional"/> | |
49 | + </xs:complexType> | |
50 | + </xs:element> | |
51 | + </xs:sequence> | |
52 | + </xs:complexType> | |
53 | + </xs:element> | |
54 | +</xs:schema> | |
\ No newline at end of file | ... | ... |
Please
register
or
login
to post a comment