EMMA Coverage Report (generated Tue Feb 12 22:23:49 ICT 2008)
[all classes][net.sourceforge.hivegui.dialog]

COVERAGE SUMMARY FOR SOURCE FILE [CommandPanelAdderFactory.java]

nameclass, %method, %block, %line, %
CommandPanelAdderFactory.java0%   (0/1)0%   (0/4)0%   (0/34)0%   (0/10)

COVERAGE BREAKDOWN BY CLASS AND METHOD

nameclass, %method, %block, %line, %
     
class CommandPanelAdderFactory0%   (0/1)0%   (0/4)0%   (0/34)0%   (0/10)
<static initializer> 0%   (0/1)0%   (0/17)0%   (0/5)
CommandPanelAdderFactory (): void 0%   (0/1)0%   (0/3)0%   (0/2)
getAdder (JComponent): CommandPanelAdder 0%   (0/1)0%   (0/7)0%   (0/1)
registerAdder (CommandPanelAdder): void 0%   (0/1)0%   (0/7)0%   (0/2)

1//  Copyright 2004-2007 Jean-Francois Poilpret
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7//     http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14 
15package net.sourceforge.hivegui.dialog;
16 
17import java.awt.LayoutManager;
18import java.util.HashMap;
19import java.util.Map;
20 
21import javax.swing.JComponent;
22 
23final public class CommandPanelAdderFactory
24{
25        private CommandPanelAdderFactory()
26        {
27        }
28 
29        static
30        {
31                _adders = new HashMap<Class<? extends LayoutManager>, CommandPanelAdder>();
32                registerAdder(new BorderCommandPanelAdder());
33                registerAdder(new GridBagCommandPanelAdder());
34                registerAdder(new DesignGridCommandPanelAdder());
35        }
36        
37        static public void        registerAdder(CommandPanelAdder adder)
38        {
39                _adders.put(adder.getLayoutClass(), adder);
40        }
41        
42        static public CommandPanelAdder        getAdder(JComponent container)
43        {
44                return _adders.get(container.getLayout().getClass());
45        }
46        
47        static final private Map<Class<? extends LayoutManager>, CommandPanelAdder>        _adders;
48}

[all classes][net.sourceforge.hivegui.dialog]
EMMA 2.0.5312 (C) Vladimir Roubtsov