|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
XWiki21Parser | Line # 45 | 5 | 0% | 5 | 0 | 100% |
1.0
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||
(29) | |||
Result | |||
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1.0
|
org.xwiki.rendering.test.integration.RenderingTest.execute org.xwiki.rendering.test.integration.RenderingTest.execute | 1 PASS | |
1 | /* | |
2 | * See the NOTICE file distributed with this work for additional | |
3 | * information regarding copyright ownership. | |
4 | * | |
5 | * This is free software; you can redistribute it and/or modify it | |
6 | * under the terms of the GNU Lesser General Public License as | |
7 | * published by the Free Software Foundation; either version 2.1 of | |
8 | * the License, or (at your option) any later version. | |
9 | * | |
10 | * This software is distributed in the hope that it will be useful, | |
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
13 | * Lesser General Public License for more details. | |
14 | * | |
15 | * You should have received a copy of the GNU Lesser General Public | |
16 | * License along with this software; if not, write to the Free | |
17 | * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA | |
18 | * 02110-1301 USA, or see the FSF site: http://www.fsf.org. | |
19 | */ | |
20 | package org.xwiki.rendering.internal.parser.xwiki21; | |
21 | ||
22 | import javax.inject.Inject; | |
23 | import javax.inject.Named; | |
24 | import javax.inject.Singleton; | |
25 | ||
26 | import org.xwiki.rendering.wikimodel.IWikiParser; | |
27 | import org.xwiki.rendering.wikimodel.xwiki.xwiki21.XWikiParser; | |
28 | import org.xwiki.component.annotation.Component; | |
29 | import org.xwiki.rendering.internal.parser.wikimodel.AbstractWikiModelParser; | |
30 | import org.xwiki.rendering.internal.parser.wikimodel.XWikiGeneratorListener; | |
31 | import org.xwiki.rendering.listener.Listener; | |
32 | import org.xwiki.rendering.parser.ResourceReferenceParser; | |
33 | import org.xwiki.rendering.syntax.Syntax; | |
34 | import org.xwiki.rendering.util.IdGenerator; | |
35 | ||
36 | /** | |
37 | * Parses XWiki Syntax 2.1. | |
38 | * | |
39 | * @version $Id: dc631ec9ffb9fe5a20a12ee20d4c94b2575586ad $ | |
40 | * @since 2.5M2 | |
41 | */ | |
42 | @Component | |
43 | @Named("xwiki/2.1") | |
44 | @Singleton | |
45 | public class XWiki21Parser extends AbstractWikiModelParser | |
46 | { | |
47 | /** | |
48 | * @see #getLinkReferenceParser() | |
49 | */ | |
50 | @Inject | |
51 | @Named("link") | |
52 | private ResourceReferenceParser linkReferenceParser; | |
53 | ||
54 | /** | |
55 | * @see #getImageReferenceParser() | |
56 | */ | |
57 | @Inject | |
58 | @Named("image") | |
59 | private ResourceReferenceParser imageReferenceParser; | |
60 | ||
61 | 33 | @Override |
62 | public Syntax getSyntax() | |
63 | { | |
64 | 33 | return Syntax.XWIKI_2_1; |
65 | } | |
66 | ||
67 | 33 | @Override |
68 | public IWikiParser createWikiModelParser() | |
69 | { | |
70 | 33 | return new XWikiParser(); |
71 | } | |
72 | ||
73 | /** | |
74 | * {@inheritDoc} | |
75 | * | |
76 | * @see org.xwiki.rendering.internal.parser.wikimodel.AbstractWikiModelParser#getLinkReferenceParser() | |
77 | * @since 2.5RC1 | |
78 | */ | |
79 | 33 | @Override |
80 | public ResourceReferenceParser getLinkReferenceParser() | |
81 | { | |
82 | 33 | return this.linkReferenceParser; |
83 | } | |
84 | ||
85 | /** | |
86 | * {@inheritDoc} | |
87 | * | |
88 | * @see org.xwiki.rendering.internal.parser.wikimodel.AbstractWikiModelParser#getImageReferenceParser() | |
89 | * @since 2.5RC1 | |
90 | */ | |
91 | 33 | @Override |
92 | public ResourceReferenceParser getImageReferenceParser() | |
93 | { | |
94 | 33 | return this.imageReferenceParser; |
95 | } | |
96 | ||
97 | 33 | @Override |
98 | public XWikiGeneratorListener createXWikiGeneratorListener(Listener listener, IdGenerator idGenerator) | |
99 | { | |
100 | 33 | return new XWiki21XWikiGeneratorListener(getLinkLabelParser(), listener, getLinkReferenceParser(), |
101 | getImageReferenceParser(), this.plainRendererFactory, idGenerator, getSyntax()); | |
102 | } | |
103 | } |
|