1
2
3
4
5
6 package org.apache.maven.doxia.module.fml.model;
7
8
9
10
11
12
13
14
15 @SuppressWarnings( "all" )
16 public class Part
17 implements java.io.Serializable
18 {
19
20
21
22
23
24
25
26
27
28
29 private String id;
30
31
32
33
34
35
36 private String title;
37
38
39
40
41 private java.util.List<Faq> faqs;
42
43
44
45
46
47
48
49
50
51
52
53 public void addFaq( Faq faq )
54 {
55 getFaqs().add( faq );
56 }
57
58
59
60
61
62
63
64 public boolean equals( Object other )
65 {
66 if ( this == other )
67 {
68 return true;
69 }
70
71 if ( !( other instanceof Part ) )
72 {
73 return false;
74 }
75
76 Part that = (Part) other;
77 boolean result = true;
78
79 result = result && ( getId() == null ? that.getId() == null : getId().equals( that.getId() ) );
80 result = result && ( getTitle() == null ? that.getTitle() == null : getTitle().equals( that.getTitle() ) );
81 result = result && ( getFaqs() == null ? that.getFaqs() == null : getFaqs().equals( that.getFaqs() ) );
82
83 return result;
84 }
85
86
87
88
89
90
91 public java.util.List<Faq> getFaqs()
92 {
93 if ( this.faqs == null )
94 {
95 this.faqs = new java.util.ArrayList<Faq>();
96 }
97
98 return this.faqs;
99 }
100
101
102
103
104
105
106 public String getId()
107 {
108 return this.id;
109 }
110
111
112
113
114
115
116 public String getTitle()
117 {
118 return this.title;
119 }
120
121
122
123
124
125
126 public int hashCode()
127 {
128 int result = 17;
129
130 result = 37 * result + ( id != null ? id.hashCode() : 0 );
131 result = 37 * result + ( title != null ? title.hashCode() : 0 );
132 result = 37 * result + ( faqs != null ? faqs.hashCode() : 0 );
133
134 return result;
135 }
136
137
138
139
140
141
142 public void removeFaq( Faq faq )
143 {
144 getFaqs().remove( faq );
145 }
146
147
148
149
150
151
152 public void setFaqs( java.util.List<Faq> faqs )
153 {
154 this.faqs = faqs;
155 }
156
157
158
159
160
161
162 public void setId( String id )
163 {
164 this.id = id;
165 }
166
167
168
169
170
171
172 public void setTitle( String title )
173 {
174 this.title = title;
175 }
176
177
178
179
180
181
182 public java.lang.String toString()
183 {
184 StringBuilder buf = new StringBuilder( 128 );
185
186 buf.append( "id = '" );
187 buf.append( getId() );
188 buf.append( "'" );
189 buf.append( "\n" );
190 buf.append( "title = '" );
191 buf.append( getTitle() );
192 buf.append( "'" );
193 buf.append( "\n" );
194 buf.append( "faqs = '" );
195 buf.append( getFaqs() );
196 buf.append( "'" );
197
198 return buf.toString();
199 }
200
201 }