1
2
3
4
5 package org.apache.maven.model;
6
7
8
9
10
11 import java.util.Date;
12
13
14
15
16
17
18 public class Reporting implements java.io.Serializable {
19
20
21
22
23
24
25
26
27
28
29
30
31 private Boolean excludeDefaultsValue;
32
33
34
35
36
37
38
39
40
41
42
43 private String outputDirectory;
44
45
46
47
48 private java.util.List plugins;
49
50
51
52
53
54
55
56
57
58
59
60 public void addPlugin( ReportPlugin reportPlugin )
61 {
62 if ( !(reportPlugin instanceof ReportPlugin) )
63 {
64 throw new ClassCastException( "Reporting.addPlugins(reportPlugin) parameter must be instanceof " + ReportPlugin.class.getName() );
65 }
66 getPlugins().add( reportPlugin );
67 }
68
69
70
71
72
73
74
75
76
77
78
79
80
81 public String getOutputDirectory()
82 {
83 return this.outputDirectory;
84 }
85
86
87
88
89
90
91 public java.util.List getPlugins()
92 {
93 if ( this.plugins == null )
94 {
95 this.plugins = new java.util.ArrayList();
96 }
97
98 return this.plugins;
99 }
100
101
102
103
104
105
106
107
108
109 public Boolean isExcludeDefaultsValue()
110 {
111 return this.excludeDefaultsValue;
112 }
113
114
115
116
117
118
119 public void removePlugin( ReportPlugin reportPlugin )
120 {
121 if ( !(reportPlugin instanceof ReportPlugin) )
122 {
123 throw new ClassCastException( "Reporting.removePlugins(reportPlugin) parameter must be instanceof " + ReportPlugin.class.getName() );
124 }
125 getPlugins().remove( reportPlugin );
126 }
127
128
129
130
131
132
133
134
135
136 public void setExcludeDefaultsValue( Boolean excludeDefaultsValue )
137 {
138 this.excludeDefaultsValue = excludeDefaultsValue;
139 }
140
141
142
143
144
145
146
147
148
149
150
151
152
153 public void setOutputDirectory( String outputDirectory )
154 {
155 this.outputDirectory = outputDirectory;
156 }
157
158
159
160
161
162
163 public void setPlugins( java.util.List plugins )
164 {
165 this.plugins = plugins;
166 }
167
168
169
170 java.util.Map reportPluginMap;
171
172
173
174
175 public void flushReportPluginMap()
176 {
177 this.reportPluginMap = null;
178 }
179
180
181
182
183
184 public java.util.Map getReportPluginsAsMap()
185 {
186 if ( reportPluginMap == null )
187 {
188 reportPluginMap = new java.util.LinkedHashMap();
189 if ( getPlugins() != null )
190 {
191 for ( java.util.Iterator it = getPlugins().iterator(); it.hasNext(); )
192 {
193 ReportPlugin reportPlugin = (ReportPlugin) it.next();
194 reportPluginMap.put( reportPlugin.getKey(), reportPlugin );
195 }
196 }
197 }
198
199 return reportPluginMap;
200 }
201
202 public boolean isExcludeDefaults()
203 {
204 return excludeDefaultsValue != null ? excludeDefaultsValue.booleanValue() : false;
205 }
206
207 public void setExcludeDefaults( boolean excludeDefaults )
208 {
209 excludeDefaultsValue = excludeDefaults ? Boolean.TRUE : Boolean.FALSE;
210 }
211
212 public void setExcludeDefaultsValue( String excludeDefaults )
213 {
214 excludeDefaultsValue = excludeDefaults != null ? Boolean.valueOf( excludeDefaults ) : null;
215 }
216
217
218 private String modelEncoding = "UTF-8";
219
220
221
222
223
224
225 public void setModelEncoding( String modelEncoding )
226 {
227 this.modelEncoding = modelEncoding;
228 }
229
230
231
232
233 public String getModelEncoding()
234 {
235 return modelEncoding;
236 }
237 }