1 19 20 package com.sslexplorer.extensions.types; 21 22 import org.apache.commons.logging.Log; 23 import org.apache.commons.logging.LogFactory; 24 import org.jdom.Element; 25 26 import com.sslexplorer.extensions.ExtensionDescriptor; 27 import com.sslexplorer.extensions.ExtensionException; 28 29 34 public class DefaultPlugin extends AbstractPlugin { 35 36 final static Log log = LogFactory.getLog(DefaultPlugin.class); 37 38 private PluginDefinition definition; 39 40 46 public DefaultPlugin(String tilesConfigFile, boolean canStop) { 47 super(tilesConfigFile, canStop); 48 } 49 50 53 public void startPlugin(PluginDefinition definition, ExtensionDescriptor descriptor, Element element) throws ExtensionException { 54 this.definition = definition; 55 if (log.isInfoEnabled()) 56 log.info("Starting plugin '" + definition.getName() + "'"); 57 } 58 59 62 public void activatePlugin() throws ExtensionException { 63 if (log.isInfoEnabled()) 64 log.info("Activating plugin '" + definition.getName() + "'"); 65 } 66 67 70 public void stopPlugin() throws ExtensionException { 71 if (log.isInfoEnabled()) 72 log.info("Stopping plugin '" + definition.getName() + "'"); 73 } 74 75 82 public PluginDefinition getPluginDefinition() { 83 return definition; 84 } 85 86 } 87 | Popular Tags |