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