Revision 38564 branches/v2_0_0_prep/frameworks/_fwAndami/src/org/gvsig/andami/plugins/Extension.java
Extension.java | ||
---|---|---|
3 | 3 |
import org.gvsig.andami.PluginServices; |
4 | 4 |
import org.gvsig.andami.PluginsLocator; |
5 | 5 |
import org.gvsig.andami.plugins.status.IExtensionStatus; |
6 |
import org.slf4j.Logger; |
|
7 |
import org.slf4j.LoggerFactory; |
|
6 | 8 |
|
7 | 9 |
/* gvSIG. Sistema de Informaci?n Geogr?fica de la Generalitat Valenciana |
8 | 10 |
* |
... | ... | |
86 | 88 |
* |
87 | 89 |
* @author Jorge Piera Llodr? (piera_jor@gva.es) |
88 | 90 |
*/ |
89 |
public abstract class Extension implements IExtension { |
|
91 |
public abstract class Extension implements IExtension, IExtensionQueryByAction, IExtensionExecuteWithArgs {
|
|
90 | 92 |
|
93 |
private static Logger logger = LoggerFactory.getLogger(Extension.class); |
|
91 | 94 |
/* |
92 | 95 |
* (non-Javadoc) |
93 | 96 |
* @see com.iver.andami.plugins.IExtension#terminate() |
... | ... | |
127 | 130 |
return PluginsLocator.getManager().getPlugin(this.getClass()); |
128 | 131 |
} |
129 | 132 |
|
133 |
public boolean isEnabled(String action) { |
|
134 |
return isEnabled(); |
|
135 |
} |
|
136 |
|
|
137 |
public boolean isVisible(String action) { |
|
138 |
return isVisible(); |
|
139 |
} |
|
140 |
|
|
141 |
public boolean canQueryByAction() { |
|
142 |
return false; |
|
143 |
} |
|
144 |
|
|
145 |
public void execute(String command, Object[] args) { |
|
146 |
if( args!= null && args.length>0 ) { |
|
147 |
logger.info("callong execute with args in a extension that not support ("+this.getClass().getSimpleName()+")."); |
|
148 |
} |
|
149 |
execute(command); |
|
150 |
} |
|
130 | 151 |
} |
131 | 152 |
|
Also available in: Unified diff