EMMA Coverage Report (generated Fri Sep 15 10:32:43 EDT 2006)
[all classes][org.apache.pluto.driver.services.impl.resource]

COVERAGE SUMMARY FOR SOURCE FILE [OneStartRenderConfigServiceImpl.java]

nameclass, %method, %block, %line, %
OneStartRenderConfigServiceImpl.java100% (1/1)14%  (1/7)6%   (3/47)7%   (1/14)

COVERAGE BREAKDOWN BY CLASS AND METHOD

nameclass, %method, %block, %line, %
     
class OneStartRenderConfigServiceImpl100% (1/1)14%  (1/7)6%   (3/47)7%   (1/14)
addPage (PageConfig): void 0%   (0/1)0%   (0/6)0%   (0/2)
destroy (): void 0%   (0/1)0%   (0/4)0%   (0/2)
getDefaultPage (): PageConfig 0%   (0/1)0%   (0/6)0%   (0/1)
getPage (String): PageConfig 0%   (0/1)0%   (0/6)0%   (0/1)
getPages (): List 0%   (0/1)0%   (0/5)0%   (0/1)
init (ServletContext): void 0%   (0/1)0%   (0/17)0%   (0/6)
OneStartRenderConfigServiceImpl (): void 100% (1/1)100% (3/3)100% (1/1)

1package org.apache.pluto.driver.services.impl.resource;
2 
3import java.io.InputStream;
4import java.util.List;
5import java.util.Set;
6 
7import javax.servlet.ServletContext;
8 
9import org.apache.pluto.driver.config.DriverConfigurationException;
10import org.apache.pluto.driver.services.portal.PageConfig;
11import org.apache.pluto.driver.services.portal.PortletApplicationConfig;
12import org.apache.pluto.driver.services.portal.PortletWindowConfig;
13import org.apache.pluto.driver.services.portal.RenderConfigService;
14import org.apache.pluto.driver.services.portal.admin.RenderConfigAdminService;
15 
16public class OneStartRenderConfigServiceImpl implements RenderConfigService, RenderConfigAdminService {
17 
18 
19    private ResourceConfig config;
20    
21//
22// Lifecycle Methods
23//
24    /**
25     * Initialization Lifecycle Method
26     * @param ctx
27     */
28    public void init(ServletContext ctx) {
29        try {
30            InputStream in = ctx.getResourceAsStream(OneStartResourceConfigReader.CONFIG_FILE);
31            config = OneStartResourceConfigReader.getFactory().parse(in);
32        }
33        catch(Exception e) {
34            throw new DriverConfigurationException(e);
35        }
36    }
37 
38    /**
39     * Shutdown the ResourceService.
40     */
41    public void destroy() {
42        config = null;
43    }
44 
45//
46//    public String getPortalName() {
47//        return config.getPortalName();
48//    }
49//
50//    public String getPortalVersion() {
51//        return config.getPortalVersion();
52//    }
53//
54//    public String getContainerName() {
55//        return config.getContainerName();
56//    }
57//
58//    public Set getSupportedPortletModes() {
59//        return config.getSupportedPortletModes();
60//    }
61//
62//    public Set getSupportedWindowStates() {
63//        return config.getSupportedWindowStates();
64//    }
65//
66//    public Set getPortletApplications() {
67//        return config.getPortletApplications();
68//    }
69//
70//    public PortletApplicationConfig getPortletApplication(String id) {
71//        return config.getPortletApp(id);
72//    }
73//
74//    public PortletWindowConfig getPortletWindowConfig(String id) {
75//        return config.getPortletWindowConfig(id);
76//    }
77//
78//    public PortletWindowConfig getPortlet(String id) {
79//        return config.getPortletWindowConfig(id);
80//    }
81 
82    public List getPages() {
83        return config.getRenderConfig().getPages();
84    }
85 
86    public PageConfig getDefaultPage() {
87        return config.getRenderConfig().getPageConfig(null);
88    }
89 
90    public PageConfig getPage(String id) {
91        return config.getRenderConfig().getPageConfig(id);
92    }
93 
94    public void addPage(PageConfig pageConfig) {
95        config.getRenderConfig().addPage(pageConfig);
96    }
97    
98}

[all classes][org.apache.pluto.driver.services.impl.resource]
EMMA 2.0.5312 (C) Vladimir Roubtsov