EMMA Coverage Report (generated Sun Feb 05 10:43:15 CET 2012)
[all classes][de.uka.ipd.sdq.dsexplore.designdecisions]

COVERAGE SUMMARY FOR SOURCE FILE [NewCandidateFactory.java]

nameclass, %method, %block, %line, %
NewCandidateFactory.java0%   (0/1)0%   (0/4)0%   (0/44)0%   (0/13)

COVERAGE BREAKDOWN BY CLASS AND METHOD

nameclass, %method, %block, %line, %
     
class NewCandidateFactory0%   (0/1)0%   (0/4)0%   (0/44)0%   (0/13)
<static initializer> 0%   (0/1)0%   (0/8)0%   (0/4)
NewCandidateFactory (): void 0%   (0/1)0%   (0/3)0%   (0/1)
getAllNewCandidateExtensions (): List 0%   (0/1)0%   (0/31)0%   (0/8)
getInstance (): NewCandidateFactory 0%   (0/1)0%   (0/2)0%   (0/1)

1package de.uka.ipd.sdq.dsexplore.designdecisions;
2 
3import java.util.ArrayList;
4import java.util.Collection;
5import java.util.Iterator;
6import java.util.List;
7 
8import org.apache.log4j.Logger;
9import org.eclipse.core.runtime.CoreException;
10import org.eclipse.core.runtime.IConfigurationElement;
11import de.uka.ipd.sdq.dsexplore.helper.ExtensionHelper;
12 
13/**
14 * Handles the loading of the plugins with the extension <extension-point id="de.uka.idd.sdq.dsexplore.newcandidates" name="de.uka.idd.sdq.dsexplore.newcandidates" schema="schema/de.uka.idd.sdq.dsexplore.newcandidates.exsd"/>.
15 * 
16 * See also the tutorial at http://www.ibm.com/developerworks/xml/library/x-wxxm29.html, where the idea is described.
17 * @author Anne
18 *
19 */
20@Deprecated
21public class NewCandidateFactory {
22        
23        /** Logger for log4j. */
24        private static Logger logger = 
25                Logger.getLogger("de.uka.ipd.sdq.dsexplore");
26        
27        protected IConfigurationElement element;
28        private List<INewCandidates> nc;
29        
30        private static NewCandidateFactory instance = new NewCandidateFactory();
31 
32        public List<INewCandidates> getAllNewCandidateExtensions() throws CoreException{
33                if (nc == null){
34                        Collection<Object> extensions = ExtensionHelper.loadExtension("de.uka.ipd.sdq.dsexplore.newcandidates");
35                        nc = new ArrayList<INewCandidates>();
36                        for (Iterator<Object> iterator = extensions.iterator(); iterator
37                                        .hasNext();) {
38                                nc.add((INewCandidates)iterator.next());
39                                logger.debug("Added an extension de.uka.ipd.sdq.dsexplore.newcandidates");
40                        }
41                }
42                return nc;
43        }
44        
45        public static NewCandidateFactory getInstance(){
46                return instance;
47        }
48        
49    
50 
51}

[all classes][de.uka.ipd.sdq.dsexplore.designdecisions]
EMMA 2.0.9414 (unsupported private build) (C) Vladimir Roubtsov