1 |
|
|
2 |
|
|
3 |
|
|
4 |
|
|
5 |
|
|
6 |
|
|
7 |
|
|
8 |
|
|
9 |
|
|
10 |
|
|
11 |
|
|
12 |
|
|
13 |
|
|
14 |
|
|
15 |
|
|
16 |
|
|
17 |
|
|
18 |
|
|
19 |
|
|
20 |
|
package org.xwiki.rendering.internal.renderer.wikimodel; |
21 |
|
|
22 |
|
import java.util.ArrayDeque; |
23 |
|
import java.util.ArrayList; |
24 |
|
import java.util.Collections; |
25 |
|
import java.util.Deque; |
26 |
|
import java.util.List; |
27 |
|
import java.util.Map; |
28 |
|
|
29 |
|
import org.xwiki.rendering.internal.parser.wikimodel.DefaultXWikiGeneratorListener; |
30 |
|
import org.xwiki.rendering.listener.Format; |
31 |
|
import org.xwiki.rendering.listener.HeaderLevel; |
32 |
|
import org.xwiki.rendering.listener.ListType; |
33 |
|
import org.xwiki.rendering.listener.Listener; |
34 |
|
import org.xwiki.rendering.listener.MetaData; |
35 |
|
import org.xwiki.rendering.listener.reference.ResourceReference; |
36 |
|
import org.xwiki.rendering.syntax.Syntax; |
37 |
|
import org.xwiki.rendering.wikimodel.IWemConstants; |
38 |
|
import org.xwiki.rendering.wikimodel.IWemListener; |
39 |
|
import org.xwiki.rendering.wikimodel.WikiFormat; |
40 |
|
import org.xwiki.rendering.wikimodel.WikiParameter; |
41 |
|
import org.xwiki.rendering.wikimodel.WikiParameters; |
42 |
|
|
43 |
|
|
44 |
|
|
45 |
|
|
46 |
|
@version |
47 |
|
@since |
48 |
|
|
|
|
| 35.5% |
Uncovered Elements: 109 (169) |
Complexity: 74 |
Complexity Density: 0.68 |
|
49 |
|
public class WikiModelGeneratorListener implements Listener |
50 |
|
{ |
51 |
|
private IWemListener wikimodelListener; |
52 |
|
|
53 |
|
private int docLevel = 1; |
54 |
|
|
55 |
|
private Deque<Context> context = new ArrayDeque<Context>(); |
56 |
|
|
|
|
| - |
Uncovered Elements: 0 (0) |
Complexity: 0 |
Complexity Density: - |
|
57 |
|
private class Context |
58 |
|
{ |
59 |
|
int headerLevel; |
60 |
|
} |
61 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
62 |
12 |
public WikiModelGeneratorListener(IWemListener wikimodelListener)... |
63 |
|
{ |
64 |
12 |
this.wikimodelListener = wikimodelListener; |
65 |
|
} |
66 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
67 |
24 |
private Context getContext()... |
68 |
|
{ |
69 |
24 |
return this.context.peek(); |
70 |
|
} |
71 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (3) |
Complexity: 1 |
Complexity Density: 0.33 |
|
72 |
12 |
private Context pushContext()... |
73 |
|
{ |
74 |
12 |
Context ctx = new Context(); |
75 |
12 |
this.context.push(ctx); |
76 |
12 |
return ctx; |
77 |
|
} |
78 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
79 |
12 |
private Context popContext()... |
80 |
|
{ |
81 |
12 |
return this.context.pop(); |
82 |
|
} |
83 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (3) |
Complexity: 1 |
Complexity Density: 0.33 |
|
84 |
12 |
@Override... |
85 |
|
public void beginDocument(MetaData metadata) |
86 |
|
{ |
87 |
12 |
pushContext(); |
88 |
|
|
89 |
12 |
this.wikimodelListener.beginDocument(WikiParameters.EMPTY); |
90 |
12 |
this.wikimodelListener.beginSection(this.docLevel++, getContext().headerLevel++, WikiParameters.EMPTY); |
91 |
|
} |
92 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (3) |
Complexity: 1 |
Complexity Density: 0.33 |
|
93 |
12 |
@Override... |
94 |
|
public void endDocument(MetaData metadata) |
95 |
|
{ |
96 |
12 |
this.wikimodelListener.endSection(this.docLevel--, getContext().headerLevel, WikiParameters.EMPTY); |
97 |
12 |
this.wikimodelListener.endDocument(WikiParameters.EMPTY); |
98 |
|
|
99 |
12 |
popContext(); |
100 |
|
} |
101 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
102 |
0 |
@Override... |
103 |
|
public void beginGroup(Map<String, String> parameters) |
104 |
|
{ |
105 |
0 |
this.wikimodelListener.beginDocument(createWikiParameters(parameters)); |
106 |
|
} |
107 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
108 |
0 |
@Override... |
109 |
|
public void endGroup(Map<String, String> parameters) |
110 |
|
{ |
111 |
0 |
this.wikimodelListener.endDocument(createWikiParameters(parameters)); |
112 |
|
} |
113 |
|
|
|
|
| 0% |
Uncovered Elements: 25 (25) |
Complexity: 9 |
Complexity Density: 0.36 |
|
114 |
0 |
@Override... |
115 |
|
public void beginFormat(Format format, Map<String, String> parameters) |
116 |
|
{ |
117 |
0 |
switch (format) { |
118 |
0 |
case BOLD: |
119 |
0 |
this.wikimodelListener.beginFormat(new WikiFormat(IWemConstants.STRONG, |
120 |
|
createWikiParameters(parameters).toList())); |
121 |
0 |
break; |
122 |
0 |
case ITALIC: |
123 |
0 |
this.wikimodelListener.beginFormat(new WikiFormat(IWemConstants.EM, createWikiParameters(parameters) |
124 |
|
.toList())); |
125 |
0 |
break; |
126 |
0 |
case STRIKEDOUT: |
127 |
0 |
this.wikimodelListener.beginFormat(new WikiFormat(IWemConstants.STRIKE, |
128 |
|
createWikiParameters(parameters).toList())); |
129 |
0 |
break; |
130 |
0 |
case UNDERLINED: |
131 |
0 |
this.wikimodelListener.beginFormat(new WikiFormat(IWemConstants.INS, createWikiParameters(parameters) |
132 |
|
.toList())); |
133 |
0 |
break; |
134 |
0 |
case MONOSPACE: |
135 |
0 |
this.wikimodelListener.beginFormat(new WikiFormat(IWemConstants.MONO, createWikiParameters(parameters) |
136 |
|
.toList())); |
137 |
0 |
break; |
138 |
0 |
case SUBSCRIPT: |
139 |
0 |
this.wikimodelListener.beginFormat(new WikiFormat(IWemConstants.SUB, createWikiParameters(parameters) |
140 |
|
.toList())); |
141 |
0 |
break; |
142 |
0 |
case SUPERSCRIPT: |
143 |
0 |
this.wikimodelListener.beginFormat(new WikiFormat(IWemConstants.SUP, createWikiParameters(parameters) |
144 |
|
.toList())); |
145 |
0 |
break; |
146 |
0 |
case NONE: |
147 |
0 |
this.wikimodelListener.beginFormat(new WikiFormat(createWikiParameters(parameters).toList())); |
148 |
0 |
break; |
149 |
|
} |
150 |
|
} |
151 |
|
|
|
|
| 0% |
Uncovered Elements: 25 (25) |
Complexity: 9 |
Complexity Density: 0.36 |
|
152 |
0 |
@Override... |
153 |
|
public void endFormat(Format format, Map<String, String> parameters) |
154 |
|
{ |
155 |
0 |
switch (format) { |
156 |
0 |
case BOLD: |
157 |
0 |
this.wikimodelListener.endFormat(new WikiFormat(IWemConstants.STRONG, createWikiParameters(parameters) |
158 |
|
.toList())); |
159 |
0 |
break; |
160 |
0 |
case ITALIC: |
161 |
0 |
this.wikimodelListener.endFormat(new WikiFormat(IWemConstants.EM, createWikiParameters(parameters) |
162 |
|
.toList())); |
163 |
0 |
break; |
164 |
0 |
case STRIKEDOUT: |
165 |
0 |
this.wikimodelListener.endFormat(new WikiFormat(IWemConstants.STRIKE, createWikiParameters(parameters) |
166 |
|
.toList())); |
167 |
0 |
break; |
168 |
0 |
case UNDERLINED: |
169 |
0 |
this.wikimodelListener.endFormat(new WikiFormat(IWemConstants.INS, createWikiParameters(parameters) |
170 |
|
.toList())); |
171 |
0 |
break; |
172 |
0 |
case MONOSPACE: |
173 |
0 |
this.wikimodelListener.endFormat(new WikiFormat(IWemConstants.MONO, createWikiParameters(parameters) |
174 |
|
.toList())); |
175 |
0 |
break; |
176 |
0 |
case SUBSCRIPT: |
177 |
0 |
this.wikimodelListener.endFormat(new WikiFormat(IWemConstants.SUB, createWikiParameters(parameters) |
178 |
|
.toList())); |
179 |
0 |
break; |
180 |
0 |
case SUPERSCRIPT: |
181 |
0 |
this.wikimodelListener.endFormat(new WikiFormat(IWemConstants.SUP, createWikiParameters(parameters) |
182 |
|
.toList())); |
183 |
0 |
break; |
184 |
0 |
case NONE: |
185 |
0 |
this.wikimodelListener.endFormat(new WikiFormat(createWikiParameters(parameters).toList())); |
186 |
0 |
break; |
187 |
|
} |
188 |
|
} |
189 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
190 |
17 |
@Override... |
191 |
|
public void beginList(ListType type, Map<String, String> parameters) |
192 |
|
{ |
193 |
17 |
this.wikimodelListener.beginList(createWikiParameters(parameters), type == ListType.NUMBERED); |
194 |
|
} |
195 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
196 |
30 |
@Override... |
197 |
|
public void beginListItem() |
198 |
|
{ |
199 |
30 |
this.wikimodelListener.beginListItem(); |
200 |
|
} |
201 |
|
|
|
|
| - |
Uncovered Elements: 0 (0) |
Complexity: 1 |
Complexity Density: - |
|
202 |
0 |
@Override... |
203 |
|
public void beginMacroMarker(String name, Map<String, String> parameters, String content, boolean isInline) |
204 |
|
{ |
205 |
|
|
206 |
|
|
207 |
|
} |
208 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
209 |
9 |
@Override... |
210 |
|
public void beginParagraph(Map<String, String> parameters) |
211 |
|
{ |
212 |
9 |
this.wikimodelListener.beginParagraph(createWikiParameters(parameters)); |
213 |
|
} |
214 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
215 |
0 |
@Override... |
216 |
|
public void beginSection(Map<String, String> parameters) |
217 |
|
{ |
218 |
0 |
this.wikimodelListener |
219 |
|
.beginSection(this.docLevel, getContext().headerLevel++, createWikiParameters(parameters)); |
220 |
|
} |
221 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
222 |
0 |
@Override... |
223 |
|
public void beginHeader(HeaderLevel level, String id, Map<String, String> parameters) |
224 |
|
{ |
225 |
0 |
this.wikimodelListener.beginHeader(level.getAsInt(), createWikiParameters(parameters)); |
226 |
|
} |
227 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
228 |
17 |
@Override... |
229 |
|
public void endList(ListType type, Map<String, String> parameters) |
230 |
|
{ |
231 |
17 |
this.wikimodelListener.endList(createWikiParameters(parameters), type == ListType.NUMBERED); |
232 |
|
} |
233 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
234 |
30 |
@Override... |
235 |
|
public void endListItem() |
236 |
|
{ |
237 |
30 |
this.wikimodelListener.endListItem(); |
238 |
|
} |
239 |
|
|
|
|
| - |
Uncovered Elements: 0 (0) |
Complexity: 1 |
Complexity Density: - |
|
240 |
0 |
@Override... |
241 |
|
public void endMacroMarker(String name, Map<String, String> parameters, String content, boolean isInline) |
242 |
|
{ |
243 |
|
|
244 |
|
|
245 |
|
} |
246 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
247 |
9 |
@Override... |
248 |
|
public void endParagraph(Map<String, String> parameters) |
249 |
|
{ |
250 |
9 |
this.wikimodelListener.endParagraph(createWikiParameters(parameters)); |
251 |
|
} |
252 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
253 |
0 |
@Override... |
254 |
|
public void endSection(Map<String, String> parameters) |
255 |
|
{ |
256 |
0 |
this.wikimodelListener |
257 |
|
.beginSection(this.docLevel, getContext().headerLevel--, createWikiParameters(parameters)); |
258 |
|
} |
259 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
260 |
0 |
@Override... |
261 |
|
public void endHeader(HeaderLevel level, String id, Map<String, String> parameters) |
262 |
|
{ |
263 |
0 |
this.wikimodelListener.endHeader(level.getAsInt(), createWikiParameters(parameters)); |
264 |
|
} |
265 |
|
|
|
|
| - |
Uncovered Elements: 0 (0) |
Complexity: 1 |
Complexity Density: - |
|
266 |
0 |
@Override... |
267 |
|
public void beginLink(ResourceReference reference, boolean freestanding, Map<String, String> parameters) |
268 |
|
{ |
269 |
|
|
270 |
|
|
271 |
|
} |
272 |
|
|
|
|
| - |
Uncovered Elements: 0 (0) |
Complexity: 1 |
Complexity Density: - |
|
273 |
0 |
@Override... |
274 |
|
public void endLink(ResourceReference reference, boolean freestanding, Map<String, String> parameters) |
275 |
|
{ |
276 |
|
|
277 |
|
|
278 |
|
} |
279 |
|
|
|
|
| 0% |
Uncovered Elements: 5 (5) |
Complexity: 2 |
Complexity Density: 0.67 |
|
280 |
0 |
@Override... |
281 |
|
public void onMacro(String id, Map<String, String> parameters, String content, boolean inline) |
282 |
|
{ |
283 |
0 |
if (inline) { |
284 |
0 |
this.wikimodelListener.onMacroInline(id, createWikiParameters(parameters), content); |
285 |
|
} else { |
286 |
0 |
this.wikimodelListener.onMacroBlock(id, createWikiParameters(parameters), content); |
287 |
|
} |
288 |
|
} |
289 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
290 |
0 |
@Override... |
291 |
|
public void onNewLine() |
292 |
|
{ |
293 |
|
|
294 |
0 |
this.wikimodelListener.onNewLine(); |
295 |
|
} |
296 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
297 |
46 |
@Override... |
298 |
|
public void onSpace() |
299 |
|
{ |
300 |
46 |
this.wikimodelListener.onSpace(" "); |
301 |
|
} |
302 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
303 |
0 |
@Override... |
304 |
|
public void onSpecialSymbol(char symbol) |
305 |
|
{ |
306 |
0 |
this.wikimodelListener.onSpecialSymbol("" + symbol); |
307 |
|
} |
308 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
309 |
88 |
@Override... |
310 |
|
public void onWord(String word) |
311 |
|
{ |
312 |
88 |
this.wikimodelListener.onWord(word); |
313 |
|
} |
314 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
315 |
0 |
@Override... |
316 |
|
public void onId(String name) |
317 |
|
{ |
318 |
0 |
this.wikimodelListener.onExtensionBlock(DefaultXWikiGeneratorListener.EXT_ID, createWikiParameters(Collections |
319 |
|
.singletonMap("name", name))); |
320 |
|
} |
321 |
|
|
|
|
| - |
Uncovered Elements: 0 (0) |
Complexity: 1 |
Complexity Density: - |
|
322 |
0 |
@Override... |
323 |
|
public void onRawText(String text, Syntax syntax) |
324 |
|
{ |
325 |
|
|
326 |
|
} |
327 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
328 |
0 |
@Override... |
329 |
|
public void onHorizontalLine(Map<String, String> parameters) |
330 |
|
{ |
331 |
0 |
this.wikimodelListener.onHorizontalLine(createWikiParameters(parameters)); |
332 |
|
} |
333 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
334 |
0 |
@Override... |
335 |
|
public void onEmptyLines(int count) |
336 |
|
{ |
337 |
0 |
this.wikimodelListener.onEmptyLines(count); |
338 |
|
} |
339 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (5) |
Complexity: 2 |
Complexity Density: 0.67 |
|
340 |
2 |
@Override... |
341 |
|
public void onVerbatim(String content, boolean inline, Map<String, String> parameters) |
342 |
|
{ |
343 |
2 |
if (inline) { |
344 |
|
|
345 |
|
|
346 |
1 |
this.wikimodelListener.onVerbatimInline(content, WikiParameters.EMPTY); |
347 |
|
} else { |
348 |
1 |
this.wikimodelListener.onVerbatimBlock(content, createWikiParameters(parameters)); |
349 |
|
} |
350 |
|
} |
351 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
352 |
0 |
@Override... |
353 |
|
public void beginDefinitionList(Map<String, String> parameters) |
354 |
|
{ |
355 |
0 |
this.wikimodelListener.beginDefinitionList(createWikiParameters(parameters)); |
356 |
|
} |
357 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
358 |
0 |
@Override... |
359 |
|
public void endDefinitionList(Map<String, String> parameters) |
360 |
|
{ |
361 |
0 |
this.wikimodelListener.endDefinitionList(createWikiParameters(parameters)); |
362 |
|
} |
363 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
364 |
0 |
@Override... |
365 |
|
public void beginDefinitionTerm() |
366 |
|
{ |
367 |
0 |
this.wikimodelListener.beginDefinitionTerm(); |
368 |
|
} |
369 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
370 |
0 |
@Override... |
371 |
|
public void beginDefinitionDescription() |
372 |
|
{ |
373 |
0 |
this.wikimodelListener.beginDefinitionDescription(); |
374 |
|
} |
375 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
376 |
0 |
@Override... |
377 |
|
public void endDefinitionTerm() |
378 |
|
{ |
379 |
0 |
this.wikimodelListener.endDefinitionTerm(); |
380 |
|
} |
381 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
382 |
0 |
@Override... |
383 |
|
public void endDefinitionDescription() |
384 |
|
{ |
385 |
0 |
this.wikimodelListener.endDefinitionDescription(); |
386 |
|
} |
387 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
388 |
0 |
@Override... |
389 |
|
public void beginQuotation(Map<String, String> parameters) |
390 |
|
{ |
391 |
0 |
this.wikimodelListener.beginQuotation(createWikiParameters(parameters)); |
392 |
|
} |
393 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
394 |
0 |
@Override... |
395 |
|
public void endQuotation(Map<String, String> parameters) |
396 |
|
{ |
397 |
0 |
this.wikimodelListener.endQuotation(createWikiParameters(parameters)); |
398 |
|
} |
399 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
400 |
0 |
@Override... |
401 |
|
public void beginQuotationLine() |
402 |
|
{ |
403 |
0 |
this.wikimodelListener.beginQuotationLine(); |
404 |
|
} |
405 |
|
|
|
|
| 0% |
Uncovered Elements: 1 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
406 |
0 |
@Override... |
407 |
|
public void endQuotationLine() |
408 |
|
{ |
409 |
0 |
this.wikimodelListener.endQuotationLine(); |
410 |
|
} |
411 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
412 |
1 |
@Override... |
413 |
|
public void beginTable(Map<String, String> parameters) |
414 |
|
{ |
415 |
1 |
this.wikimodelListener.beginTable(createWikiParameters(parameters)); |
416 |
|
} |
417 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
418 |
4 |
@Override... |
419 |
|
public void beginTableCell(Map<String, String> parameters) |
420 |
|
{ |
421 |
4 |
this.wikimodelListener.beginTableCell(false, createWikiParameters(parameters)); |
422 |
|
} |
423 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
424 |
2 |
@Override... |
425 |
|
public void beginTableHeadCell(Map<String, String> parameters) |
426 |
|
{ |
427 |
2 |
this.wikimodelListener.beginTableCell(true, createWikiParameters(parameters)); |
428 |
|
} |
429 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
430 |
3 |
@Override... |
431 |
|
public void beginTableRow(Map<String, String> parameters) |
432 |
|
{ |
433 |
3 |
this.wikimodelListener.beginTableRow(createWikiParameters(parameters)); |
434 |
|
} |
435 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
436 |
1 |
@Override... |
437 |
|
public void endTable(Map<String, String> parameters) |
438 |
|
{ |
439 |
1 |
this.wikimodelListener.endTable(createWikiParameters(parameters)); |
440 |
|
} |
441 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
442 |
4 |
@Override... |
443 |
|
public void endTableCell(Map<String, String> parameters) |
444 |
|
{ |
445 |
4 |
this.wikimodelListener.endTableCell(false, createWikiParameters(parameters)); |
446 |
|
} |
447 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
448 |
2 |
@Override... |
449 |
|
public void endTableHeadCell(Map<String, String> parameters) |
450 |
|
{ |
451 |
2 |
this.wikimodelListener.endTableCell(true, createWikiParameters(parameters)); |
452 |
|
} |
453 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
454 |
3 |
@Override... |
455 |
|
public void endTableRow(Map<String, String> parameters) |
456 |
|
{ |
457 |
3 |
this.wikimodelListener.endTableRow(createWikiParameters(parameters)); |
458 |
|
} |
459 |
|
|
|
|
| - |
Uncovered Elements: 0 (0) |
Complexity: 1 |
Complexity Density: - |
|
460 |
0 |
@Override... |
461 |
|
public void onImage(ResourceReference reference, boolean freestanding, Map<String, String> parameters) |
462 |
|
{ |
463 |
|
|
464 |
|
|
465 |
|
|
466 |
|
} |
467 |
|
|
|
|
| - |
Uncovered Elements: 0 (0) |
Complexity: 1 |
Complexity Density: - |
|
468 |
0 |
@Override... |
469 |
|
public void beginMetaData(MetaData metadata) |
470 |
|
{ |
471 |
|
|
472 |
|
|
473 |
|
|
474 |
|
} |
475 |
|
|
|
|
| - |
Uncovered Elements: 0 (0) |
Complexity: 1 |
Complexity Density: - |
|
476 |
0 |
@Override... |
477 |
|
public void endMetaData(MetaData metadata) |
478 |
|
{ |
479 |
|
|
480 |
|
|
481 |
|
|
482 |
|
} |
483 |
|
|
|
|
| 75% |
Uncovered Elements: 1 (4) |
Complexity: 1 |
Complexity Density: 0.25 |
|
484 |
73 |
private WikiParameters createWikiParameters(Map<String, String> parameters)... |
485 |
|
{ |
486 |
73 |
List<WikiParameter> wikiParams = new ArrayList<WikiParameter>(); |
487 |
73 |
for (Map.Entry<String, String> entry : parameters.entrySet()) { |
488 |
0 |
wikiParams.add(new WikiParameter(entry.getKey(), entry.getValue())); |
489 |
|
} |
490 |
|
|
491 |
73 |
return new WikiParameters(wikiParams); |
492 |
|
} |
493 |
|
} |