1. Project Clover database Tue Dec 20 2016 21:24:09 CET
  2. Package com.xpn.xwiki.internal.template

File DefaultTemplateManager.java

 

Coverage histogram

../../../../../img/srcFileCovDistChart4.png
78% of files have more coverage

Code metrics

0
19
19
1
157
111
19
1
1
19
1

Classes

Class Line # Actions
DefaultTemplateManager 39 19 0% 19 26
0.3157894631.6%
 

Contributing tests

This file is covered by 23 tests. .

Source view

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 com.xpn.xwiki.internal.template;
21   
22    import java.io.Writer;
23   
24    import javax.inject.Inject;
25    import javax.inject.Singleton;
26   
27    import org.xwiki.component.annotation.Component;
28    import org.xwiki.rendering.block.XDOM;
29    import org.xwiki.skin.Skin;
30    import org.xwiki.template.Template;
31    import org.xwiki.template.TemplateManager;
32   
33    /**
34    * @version $Id: 174e7cfaf06c72816633fbae4ff1f8be51a0faff $
35    * @since 7.0M1
36    */
37    @Component
38    @Singleton
 
39    public class DefaultTemplateManager implements TemplateManager
40    {
41    @Inject
42    private InternalTemplateManager templateManager;
43   
 
44  0 toggle @Override
45    public XDOM getXDOMNoException(Template template)
46    {
47  0 return this.templateManager.getXDOMNoException(template);
48    }
49   
 
50  149 toggle @Override
51    public XDOM getXDOMNoException(String templateName)
52    {
53  149 return this.templateManager.getXDOMNoException(templateName);
54    }
55   
 
56  0 toggle @Override
57    public XDOM getXDOM(Template template) throws Exception
58    {
59  0 return this.templateManager.getXDOM(template);
60    }
61   
 
62  0 toggle @Override
63    public XDOM getXDOM(String templateName) throws Exception
64    {
65  0 return this.templateManager.getXDOM(templateName);
66    }
67   
 
68  0 toggle @Override
69    public String renderNoException(String templateName)
70    {
71  0 return this.templateManager.renderNoException(templateName);
72    }
73   
 
74  78827 toggle @Override
75    public String render(String templateName) throws Exception
76    {
77  78822 return this.templateManager.render(templateName);
78    }
79   
 
80  2 toggle @Override
81    public String renderFromSkin(String templateName, Skin skin) throws Exception
82    {
83  2 return this.templateManager.renderFromSkin(templateName, skin);
84    }
85   
 
86  0 toggle @Override
87    public void renderNoException(Template template, Writer writer)
88    {
89  0 this.templateManager.renderNoException(template, writer);
90    }
91   
 
92  0 toggle @Override
93    public void renderNoException(String templateName, Writer writer)
94    {
95  0 this.templateManager.renderNoException(templateName, writer);
96    }
97   
 
98  0 toggle @Override
99    public void render(Template template, Writer writer) throws Exception
100    {
101  0 this.templateManager.render(template, writer);
102    }
103   
 
104  0 toggle @Override
105    public void render(String template, Writer writer) throws Exception
106    {
107  0 this.templateManager.render(template, writer);
108    }
109   
 
110  0 toggle @Override
111    public void renderFromSkin(String templateName, Skin skin, Writer writer) throws Exception
112    {
113  0 this.templateManager.renderFromSkin(templateName, skin, writer);
114    }
115   
 
116  0 toggle @Override
117    public XDOM executeNoException(Template template)
118    {
119  0 return this.templateManager.executeNoException(template);
120    }
121   
 
122  0 toggle @Override
123    public XDOM executeNoException(String templateName)
124    {
125  0 return this.templateManager.executeNoException(templateName);
126    }
127   
 
128  0 toggle @Override
129    public XDOM execute(Template template) throws Exception
130    {
131  0 return this.templateManager.execute(template);
132    }
133   
 
134  841 toggle @Override
135    public XDOM execute(String templateName) throws Exception
136    {
137  841 return this.templateManager.execute(templateName);
138    }
139   
 
140  0 toggle @Override
141    public Template getSkinTemplate(String templateName, Skin skin)
142    {
143  0 return this.templateManager.getResourceTemplate(templateName, skin);
144    }
145   
 
146  6750 toggle @Override
147    public Template getTemplate(String templateName, Skin skin)
148    {
149  6750 return this.templateManager.getTemplate(templateName, skin);
150    }
151   
 
152  12795 toggle @Override
153    public Template getTemplate(String templateName)
154    {
155  12789 return this.templateManager.getTemplate(templateName);
156    }
157    }