Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||
Banner |
|
| 2.55;2,55 |
1 | /* | |
2 | =================== DO NOT EDIT THIS FILE ==================== | |
3 | Generated by Modello 1.4.1 on 2012-04-17 22:28:45, | |
4 | any modifications will be overwritten. | |
5 | ============================================================== | |
6 | */ | |
7 | ||
8 | package org.apache.maven.doxia.site.decoration; | |
9 | ||
10 | /** | |
11 | * Banner logo on the masthead of the site. | |
12 | * | |
13 | * @version $Revision$ $Date$ | |
14 | */ | |
15 | @SuppressWarnings( "all" ) | |
16 | 132 | public class Banner |
17 | implements java.io.Serializable, java.lang.Cloneable | |
18 | { | |
19 | ||
20 | //--------------------------/ | |
21 | //- Class/Member Variables -/ | |
22 | //--------------------------/ | |
23 | ||
24 | /** | |
25 | * The name of the banner. | |
26 | */ | |
27 | private String name; | |
28 | ||
29 | /** | |
30 | * The source location of an image for the banner. | |
31 | */ | |
32 | private String src; | |
33 | ||
34 | /** | |
35 | * The alt description for the banner image. | |
36 | */ | |
37 | private String alt; | |
38 | ||
39 | /** | |
40 | * The href of a link to be used for the banner image. | |
41 | */ | |
42 | private String href; | |
43 | ||
44 | /** | |
45 | * The border to use for the banner image. | |
46 | */ | |
47 | private String border; | |
48 | ||
49 | /** | |
50 | * The width to use for the banner image. | |
51 | */ | |
52 | private String width; | |
53 | ||
54 | /** | |
55 | * The height to use for the banner image. | |
56 | */ | |
57 | private String height; | |
58 | ||
59 | /** | |
60 | * The title for the banner image. | |
61 | */ | |
62 | private String title; | |
63 | ||
64 | ||
65 | //-----------/ | |
66 | //- Methods -/ | |
67 | //-----------/ | |
68 | ||
69 | /** | |
70 | * Method clone. | |
71 | * | |
72 | * @return Banner | |
73 | */ | |
74 | public Banner clone() | |
75 | { | |
76 | try | |
77 | { | |
78 | 72 | Banner copy = (Banner) super.clone(); |
79 | ||
80 | 72 | return copy; |
81 | } | |
82 | 0 | catch ( java.lang.Exception ex ) |
83 | { | |
84 | 0 | throw (java.lang.RuntimeException) new java.lang.UnsupportedOperationException( getClass().getName() |
85 | + " does not support clone()" ).initCause( ex ); | |
86 | } | |
87 | } //-- Banner clone() | |
88 | ||
89 | /** | |
90 | * Method equals. | |
91 | * | |
92 | * @param other | |
93 | * @return boolean | |
94 | */ | |
95 | public boolean equals( Object other ) | |
96 | { | |
97 | 82 | if ( this == other ) |
98 | { | |
99 | 0 | return true; |
100 | } | |
101 | ||
102 | 82 | if ( !( other instanceof Banner ) ) |
103 | { | |
104 | 0 | return false; |
105 | } | |
106 | ||
107 | 82 | Banner that = (Banner) other; |
108 | 82 | boolean result = true; |
109 | ||
110 | 82 | result = result && ( getName() == null ? that.getName() == null : getName().equals( that.getName() ) ); |
111 | 82 | result = result && ( getSrc() == null ? that.getSrc() == null : getSrc().equals( that.getSrc() ) ); |
112 | 82 | result = result && ( getAlt() == null ? that.getAlt() == null : getAlt().equals( that.getAlt() ) ); |
113 | 82 | result = result && ( getHref() == null ? that.getHref() == null : getHref().equals( that.getHref() ) ); |
114 | 82 | result = result && ( getBorder() == null ? that.getBorder() == null : getBorder().equals( that.getBorder() ) ); |
115 | 82 | result = result && ( getWidth() == null ? that.getWidth() == null : getWidth().equals( that.getWidth() ) ); |
116 | 82 | result = result && ( getHeight() == null ? that.getHeight() == null : getHeight().equals( that.getHeight() ) ); |
117 | 82 | result = result && ( getTitle() == null ? that.getTitle() == null : getTitle().equals( that.getTitle() ) ); |
118 | ||
119 | 82 | return result; |
120 | } //-- boolean equals( Object ) | |
121 | ||
122 | /** | |
123 | * Get the alt description for the banner image. | |
124 | * | |
125 | * @return String | |
126 | */ | |
127 | public String getAlt() | |
128 | { | |
129 | 166 | return this.alt; |
130 | } //-- String getAlt() | |
131 | ||
132 | /** | |
133 | * Get the border to use for the banner image. | |
134 | * | |
135 | * @return String | |
136 | */ | |
137 | public String getBorder() | |
138 | { | |
139 | 164 | return this.border; |
140 | } //-- String getBorder() | |
141 | ||
142 | /** | |
143 | * Get the height to use for the banner image. | |
144 | * | |
145 | * @return String | |
146 | */ | |
147 | public String getHeight() | |
148 | { | |
149 | 164 | return this.height; |
150 | } //-- String getHeight() | |
151 | ||
152 | /** | |
153 | * Get the href of a link to be used for the banner image. | |
154 | * | |
155 | * @return String | |
156 | */ | |
157 | public String getHref() | |
158 | { | |
159 | 474 | return this.href; |
160 | } //-- String getHref() | |
161 | ||
162 | /** | |
163 | * Get the name of the banner. | |
164 | * | |
165 | * @return String | |
166 | */ | |
167 | public String getName() | |
168 | { | |
169 | 246 | return this.name; |
170 | } //-- String getName() | |
171 | ||
172 | /** | |
173 | * Get the source location of an image for the banner. | |
174 | * | |
175 | * @return String | |
176 | */ | |
177 | public String getSrc() | |
178 | { | |
179 | 466 | return this.src; |
180 | } //-- String getSrc() | |
181 | ||
182 | /** | |
183 | * Get the title for the banner image. | |
184 | * | |
185 | * @return String | |
186 | */ | |
187 | public String getTitle() | |
188 | { | |
189 | 164 | return this.title; |
190 | } //-- String getTitle() | |
191 | ||
192 | /** | |
193 | * Get the width to use for the banner image. | |
194 | * | |
195 | * @return String | |
196 | */ | |
197 | public String getWidth() | |
198 | { | |
199 | 164 | return this.width; |
200 | } //-- String getWidth() | |
201 | ||
202 | /** | |
203 | * Method hashCode. | |
204 | * | |
205 | * @return int | |
206 | */ | |
207 | public int hashCode() | |
208 | { | |
209 | 0 | int result = 17; |
210 | ||
211 | 0 | result = 37 * result + ( name != null ? name.hashCode() : 0 ); |
212 | 0 | result = 37 * result + ( src != null ? src.hashCode() : 0 ); |
213 | 0 | result = 37 * result + ( alt != null ? alt.hashCode() : 0 ); |
214 | 0 | result = 37 * result + ( href != null ? href.hashCode() : 0 ); |
215 | 0 | result = 37 * result + ( border != null ? border.hashCode() : 0 ); |
216 | 0 | result = 37 * result + ( width != null ? width.hashCode() : 0 ); |
217 | 0 | result = 37 * result + ( height != null ? height.hashCode() : 0 ); |
218 | 0 | result = 37 * result + ( title != null ? title.hashCode() : 0 ); |
219 | ||
220 | 0 | return result; |
221 | } //-- int hashCode() | |
222 | ||
223 | /** | |
224 | * Set the alt description for the banner image. | |
225 | * | |
226 | * @param alt | |
227 | */ | |
228 | public void setAlt( String alt ) | |
229 | { | |
230 | 4 | this.alt = alt; |
231 | 4 | } //-- void setAlt( String ) |
232 | ||
233 | /** | |
234 | * Set the border to use for the banner image. | |
235 | * | |
236 | * @param border | |
237 | */ | |
238 | public void setBorder( String border ) | |
239 | { | |
240 | 0 | this.border = border; |
241 | 0 | } //-- void setBorder( String ) |
242 | ||
243 | /** | |
244 | * Set the height to use for the banner image. | |
245 | * | |
246 | * @param height | |
247 | */ | |
248 | public void setHeight( String height ) | |
249 | { | |
250 | 0 | this.height = height; |
251 | 0 | } //-- void setHeight( String ) |
252 | ||
253 | /** | |
254 | * Set the href of a link to be used for the banner image. | |
255 | * | |
256 | * @param href | |
257 | */ | |
258 | public void setHref( String href ) | |
259 | { | |
260 | 234 | this.href = href; |
261 | 234 | } //-- void setHref( String ) |
262 | ||
263 | /** | |
264 | * Set the name of the banner. | |
265 | * | |
266 | * @param name | |
267 | */ | |
268 | public void setName( String name ) | |
269 | { | |
270 | 132 | this.name = name; |
271 | 132 | } //-- void setName( String ) |
272 | ||
273 | /** | |
274 | * Set the source location of an image for the banner. | |
275 | * | |
276 | * @param src | |
277 | */ | |
278 | public void setSrc( String src ) | |
279 | { | |
280 | 224 | this.src = src; |
281 | 224 | } //-- void setSrc( String ) |
282 | ||
283 | /** | |
284 | * Set the title for the banner image. | |
285 | * | |
286 | * @param title | |
287 | */ | |
288 | public void setTitle( String title ) | |
289 | { | |
290 | 0 | this.title = title; |
291 | 0 | } //-- void setTitle( String ) |
292 | ||
293 | /** | |
294 | * Set the width to use for the banner image. | |
295 | * | |
296 | * @param width | |
297 | */ | |
298 | public void setWidth( String width ) | |
299 | { | |
300 | 0 | this.width = width; |
301 | 0 | } //-- void setWidth( String ) |
302 | ||
303 | /** | |
304 | * Method toString. | |
305 | * | |
306 | * @return String | |
307 | */ | |
308 | public java.lang.String toString() | |
309 | { | |
310 | 0 | StringBuilder buf = new StringBuilder( 128 ); |
311 | ||
312 | 0 | buf.append( "name = '" ); |
313 | 0 | buf.append( getName() ); |
314 | 0 | buf.append( "'" ); |
315 | 0 | buf.append( "\n" ); |
316 | 0 | buf.append( "src = '" ); |
317 | 0 | buf.append( getSrc() ); |
318 | 0 | buf.append( "'" ); |
319 | 0 | buf.append( "\n" ); |
320 | 0 | buf.append( "alt = '" ); |
321 | 0 | buf.append( getAlt() ); |
322 | 0 | buf.append( "'" ); |
323 | 0 | buf.append( "\n" ); |
324 | 0 | buf.append( "href = '" ); |
325 | 0 | buf.append( getHref() ); |
326 | 0 | buf.append( "'" ); |
327 | 0 | buf.append( "\n" ); |
328 | 0 | buf.append( "border = '" ); |
329 | 0 | buf.append( getBorder() ); |
330 | 0 | buf.append( "'" ); |
331 | 0 | buf.append( "\n" ); |
332 | 0 | buf.append( "width = '" ); |
333 | 0 | buf.append( getWidth() ); |
334 | 0 | buf.append( "'" ); |
335 | 0 | buf.append( "\n" ); |
336 | 0 | buf.append( "height = '" ); |
337 | 0 | buf.append( getHeight() ); |
338 | 0 | buf.append( "'" ); |
339 | 0 | buf.append( "\n" ); |
340 | 0 | buf.append( "title = '" ); |
341 | 0 | buf.append( getTitle() ); |
342 | 0 | buf.append( "'" ); |
343 | ||
344 | 0 | return buf.toString(); |
345 | } //-- java.lang.String toString() | |
346 | ||
347 | } |