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

COVERAGE SUMMARY FOR SOURCE FILE [DatasourceListLabelProvider.java]

nameclass, %method, %block, %line, %
DatasourceListLabelProvider.java0%   (0/1)0%   (0/4)0%   (0/62)0%   (0/9)

COVERAGE BREAKDOWN BY CLASS AND METHOD

nameclass, %method, %block, %line, %
     
class DatasourceListLabelProvider0%   (0/1)0%   (0/4)0%   (0/62)0%   (0/9)
DatasourceListLabelProvider (): void 0%   (0/1)0%   (0/3)0%   (0/1)
dataSetRepresentation (IDAOFactory): String 0%   (0/1)0%   (0/18)0%   (0/1)
getImage (Object): Image 0%   (0/1)0%   (0/11)0%   (0/3)
getText (Object): String 0%   (0/1)0%   (0/30)0%   (0/4)

1/**
2 * 
3 */
4package de.uka.ipd.sdq.sensorframework.dialogs.dataset;
5 
6import org.eclipse.jface.viewers.LabelProvider;
7import org.eclipse.swt.graphics.Image;
8 
9import de.uka.ipd.sdq.sensorframework.dialogs.DialogsImages;
10import de.uka.ipd.sdq.sensorframework.entities.dao.IDAOFactory;
11 
12public class DatasourceListLabelProvider extends LabelProvider {
13 
14        /* (non-Javadoc)
15         * @see org.eclipse.jface.viewers.LabelProvider#getText(java.lang.Object)
16         */
17        @Override
18        public String getText(Object element) {
19                if (element instanceof IDAOFactory) {
20                        IDAOFactory factory = (IDAOFactory) element;
21                        return factory.getName() + " - " + factory.getDescription() + " [" + factory.getID()+ "]";
22                }
23                return super.getText(element);
24        }
25 
26        @Override
27        public Image getImage(Object element) {
28                if (element instanceof IDAOFactory)
29                        return DialogsImages.imageRegistry.get(DialogsImages.TREEROOT);
30                return super.getImage(element);
31        }
32        
33        public static String dataSetRepresentation(IDAOFactory dataSet){
34                return dataSet.getName() + " [" + dataSet.getID()+ "] - " + dataSet.getPersistendInfo(); 
35        }
36}

[all classes][de.uka.ipd.sdq.sensorframework.dialogs.dataset]
EMMA 2.0.9414 (unsupported private build) (C) Vladimir Roubtsov