create changelog entry
[debian/openrocket] / core / src / net / sf / openrocket / plugin / SwingConfigurator.java
1 package net.sf.openrocket.plugin;
2
3 import java.awt.Component;
4
5 import net.xeoh.plugins.base.Plugin;
6
7 /**
8  * Interface that defined a Swing configurator for a plugin.
9  * The implemeting class should be a plugin that provides the
10  * capability "<pluginID>:config" where <pluginID> is the
11  * plugin ID of the plugin to configure.
12  * <p>
13  * 
14  * @param <P> The plugin class that is being configured
15  * @author Sampo Niskanen <sampo.niskanen@iki.fi>
16  */
17 public interface SwingConfigurator<P> extends Plugin {
18         
19         /**
20          * Return whether this plugin is configurable or not.
21          * 
22          * @param plugin        the plugin to test.
23          * @return                      whether the plugin has a configuration component.
24          */
25         public boolean isConfigurable(P plugin);
26         
27         /**
28          * Return the configuration component for configuring the
29          * provided plugin.
30          * 
31          * @param plugin        the plugin to configure.
32          * @return                      a Swing component for configuring the plugin.
33          */
34         public Component getConfigurationComponent(P plugin);
35         
36         
37 }