1 |
|
|
2 |
|
|
3 |
|
|
4 |
|
|
5 |
|
|
6 |
|
|
7 |
|
|
8 |
|
|
9 |
|
|
10 |
|
|
11 |
|
|
12 |
|
|
13 |
|
|
14 |
|
|
15 |
|
|
16 |
|
package org.qedeq.kernel.se.dto.module; |
17 |
|
|
18 |
|
import org.qedeq.base.utility.EqualsUtility; |
19 |
|
import org.qedeq.kernel.se.base.module.ChapterList; |
20 |
|
import org.qedeq.kernel.se.base.module.Header; |
21 |
|
import org.qedeq.kernel.se.base.module.LiteratureItemList; |
22 |
|
import org.qedeq.kernel.se.base.module.Qedeq; |
23 |
|
|
24 |
|
|
25 |
|
|
26 |
|
|
27 |
|
|
28 |
|
@author |
29 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (40) |
Complexity: 16 |
Complexity Density: 0.84 |
|
30 |
|
public class QedeqVo implements Qedeq { |
31 |
|
|
32 |
|
|
33 |
|
private Header header; |
34 |
|
|
35 |
|
|
36 |
|
private ChapterListVo chapterList; |
37 |
|
|
38 |
|
|
39 |
|
private LiteratureItemList literatureItemList; |
40 |
|
|
41 |
|
|
42 |
|
|
43 |
|
|
|
|
| - |
Uncovered Elements: 0 (0) |
Complexity: 1 |
Complexity Density: - |
|
44 |
189
|
public QedeqVo() {... |
45 |
|
|
46 |
|
} |
47 |
|
|
48 |
|
|
49 |
|
|
50 |
|
|
51 |
|
@param |
52 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
53 |
37
|
public final void setHeader(final HeaderVo header) {... |
54 |
37
|
this.header = header; |
55 |
|
} |
56 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
57 |
576
|
public final Header getHeader() {... |
58 |
576
|
return header; |
59 |
|
} |
60 |
|
|
61 |
|
|
62 |
|
|
63 |
|
|
64 |
|
@param |
65 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
66 |
143
|
public final void setChapterList(final ChapterListVo chapters) {... |
67 |
143
|
this.chapterList = chapters; |
68 |
|
} |
69 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
70 |
770
|
public final ChapterList getChapterList() {... |
71 |
770
|
return chapterList; |
72 |
|
} |
73 |
|
|
74 |
|
|
75 |
|
|
76 |
|
|
77 |
|
@param |
78 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (5) |
Complexity: 2 |
Complexity Density: 0.67 |
|
79 |
7
|
public final void addChapter(final ChapterVo chapter) {... |
80 |
7
|
if (chapterList == null) { |
81 |
2
|
chapterList = new ChapterListVo(); |
82 |
|
} |
83 |
7
|
chapterList.add(chapter); |
84 |
|
} |
85 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
86 |
331
|
public LiteratureItemList getLiteratureItemList() {... |
87 |
331
|
return literatureItemList; |
88 |
|
} |
89 |
|
|
90 |
|
|
91 |
|
|
92 |
|
|
93 |
|
@param |
94 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
95 |
20
|
public void setLiteratureItemList(final LiteratureItemListVo literatureItemList) {... |
96 |
20
|
this.literatureItemList = literatureItemList; |
97 |
|
} |
98 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (6) |
Complexity: 2 |
Complexity Density: 0.5 |
|
99 |
59
|
public boolean equals(final Object obj) {... |
100 |
59
|
if (!(obj instanceof QedeqVo)) { |
101 |
6
|
return false; |
102 |
|
} |
103 |
53
|
final QedeqVo other = (QedeqVo) obj; |
104 |
53
|
return EqualsUtility.equals(getHeader(), other.getHeader()) |
105 |
|
&& EqualsUtility.equals(getChapterList(), other.getChapterList()) |
106 |
|
&& EqualsUtility.equals(getLiteratureItemList(), other.getLiteratureItemList()); |
107 |
|
} |
108 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (7) |
Complexity: 4 |
Complexity Density: 4 |
|
109 |
50
|
public int hashCode() {... |
110 |
50
|
return (getHeader() != null ? getHeader().hashCode() : 0) |
111 |
50
|
^ (getChapterList() != null ? 1 ^ getChapterList().hashCode() : 0) |
112 |
50
|
^ (getLiteratureItemList() != null ? 2 ^ getLiteratureItemList().hashCode() : 0); |
113 |
|
} |
114 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (5) |
Complexity: 1 |
Complexity Density: 0.2 |
|
115 |
34
|
public String toString() {... |
116 |
34
|
final StringBuffer buffer = new StringBuffer(); |
117 |
34
|
buffer.append(getHeader() + "\n\n"); |
118 |
34
|
buffer.append(getChapterList() + "\n\n"); |
119 |
34
|
buffer.append(getLiteratureItemList()); |
120 |
34
|
return buffer.toString(); |
121 |
|
} |
122 |
|
|
123 |
|
} |