Package org.gvsig.andami
Interface PluginsManager
- All Known Implementing Classes:
DefaultPluginsManager
public interface PluginsManager
-
Method Summary
Modifier and TypeMethodDescriptionvoidaddShutdownTask(String name, Runnable task, boolean in_event_thread, int priority) This method allows plugins register task to do after close the application.voidaddStartupTask(String name, Runnable task, boolean in_event_thread, int priority) This method allows plugins register task to do before initializacion of all gvSIG plugins.booleandesktopBrowse(URI uri) Browses to a given URIbooleandesktopOpen(File file) Open a given filevoidThis method executes registered task to run after the close of the application.voidThis method executes registered task to run before the initialization of all plugins.Returns the main application folder, where the application is installed.Returns the application folder in the home of user.Returns the default folder where the internationalization files are installed.org.gvsig.installer.lib.api.VersionReturn the ExclusiveUIExtension installed in the application or null.getExtension(Class<? extends IExtension> extension) Gets the instance of the extension whose class is provided.getExtension(String extension) Gets the instance of the extension whose class name is provided.Return an iterator over al extensions loaded in the application.Returns the default folder with the installable package bundles.org.gvsig.installer.lib.api.PackageInfoGet the package info associated to the application.org.gvsig.installer.lib.api.PackageInfogetPackageInfo(Class<? extends IExtension> extension) Get the package info associated to the plugin of the extension.org.gvsig.installer.lib.api.PackageInfogetPackageInfo(String pluginName) Get the package info associated to the plugin with the specified name.getPlugin(Class<? extends IExtension> extension) Return the associated pluginServices to the extension class passed as parameter.Return the associated pluginServices to the object passed as parameter.Return the associated pluginServices to the extension plugin.getPluginHomeFolder(String pluginName) Return the list of plugins loaded in the applicationReturns the plugins folder.Returns a list of folder on the plugins are instaleds.getTempFile(String name) Get the file name in the temporary folder of the plugins framework.getTempFile(String name, String sufix) Create a unique file name in the temporary folder of the plugins framework.Gets the temporary folder of the plugins framework.Return a list of unsaved datavoidsaveUnsavedData(List<IUnsavedData> unsavedData) Save the provided unsaved data as parametervoidsetExclusiveUIExtension(ExclusiveUIExtension extension) Set an extension to control the visivility of all the extensions of the application.Translate the message key to the current language used in the application.
-
Method Details
-
getApplicationName
String getApplicationName() -
getPlugin
Return the associated pluginServices to the extension class passed as parameter.- Parameters:
extension-- Returns:
- plugin services
-
getPlugin
Return the associated pluginServices to the object passed as parameter.- Parameters:
object-- Returns:
- plugin services
-
getPlugin
Return the associated pluginServices to the extension plugin.- Parameters:
pluginName- , name of the plugin- Returns:
- plugin services
-
getPluginHomeFolder
-
getPackageInfo
Get the package info associated to the plugin of the extension.- Parameters:
extension- extension of the plugin- Returns:
- plugin package info
-
getPackageInfo
Get the package info associated to the plugin with the specified name.- Parameters:
pluginName- , name of the plugin- Returns:
- plugin package info
-
getPackageInfo
org.gvsig.installer.lib.api.PackageInfo getPackageInfo()Get the package info associated to the application.- Returns:
- application package info
-
getPlugins
List<PluginServices> getPlugins()Return the list of plugins loaded in the application- Returns:
- list of plugins
-
getExtension
Gets the instance of the extension whose class is provided.- Parameters:
extension- , class of the extension to retrieve- Returns:
- The instance of the extension, or null if the instance does not exist.
-
getExtension
Gets the instance of the extension whose class name is provided.- Parameters:
extension- , class name of the extension to retrieve- Returns:
- The instance of the extension, or null if the instance does not exist.
-
getExtensions
Iterator<IExtension> getExtensions()Return an iterator over al extensions loaded in the application.- Returns:
- iterator over extensions
-
setExclusiveUIExtension
Set an extension to control the visivility of all the extensions of the application.- Parameters:
extension-
-
getExclusiveUIExtension
ExclusiveUIExtension getExclusiveUIExtension()Return the ExclusiveUIExtension installed in the application or null.- Returns:
-
getText
-
translate
Translate the message key to the current language used in the application.- Parameters:
msg- key to translate- Returns:
- message traslated or the key
-
getApplicationFolder
File getApplicationFolder()Returns the main application folder, where the application is installed.- Returns:
- the main application folder
-
getInstallFolder
File getInstallFolder()Returns the default folder with the installable package bundles.- Returns:
- the default folder with the installable package bundles
-
getApplicationHomeFolder
File getApplicationHomeFolder()Returns the application folder in the home of user.- Returns:
- the main application folder
-
getApplicationI18nFolder
File getApplicationI18nFolder()Returns the default folder where the internationalization files are installed.- Returns:
- the default folder where the internationalization files are installed.
-
getPluginsFolder
File getPluginsFolder()Returns the plugins folder.- Returns:
- the plugins folder
-
getPluginsFolders
Returns a list of folder on the plugins are instaleds.- Returns:
- list of folders File of the plugins.
-
getPluginsDirectory
File getPluginsDirectory() -
addStartupTask
This method allows plugins register task to do before initializacion of all gvSIG plugins. Task with higher priority value are executed after.- Parameters:
name- of the tasktask- runnable with the code of the taskin_event_thread- , true if the task shoul run in the AWT event thread.priority- of the task.
-
addShutdownTask
This method allows plugins register task to do after close the application. Task with higher priority value are executed after.- Parameters:
name- of the tasktask- runnable with the code of the taskin_event_thread- , true if the task shoul run in the AWT event thread.priority- of the task.
-
executeStartupTasks
void executeStartupTasks()This method executes registered task to run before the initialization of all plugins. The tasks are sorted according to the priority and executed in a separated thread. -
executeShutdownTasks
void executeShutdownTasks()This method executes registered task to run after the close of the application. The tasks are sorted according to the priority and executed in a separated thread. -
getFirewallConfiguration
FirewallConfiguration getFirewallConfiguration() -
getApplicationVersion
org.gvsig.installer.lib.api.Version getApplicationVersion() -
getUnsavedData
List<IUnsavedData> getUnsavedData()Return a list of unsaved data- Returns:
-
saveUnsavedData
Save the provided unsaved data as parameter- Parameters:
unsavedData-- Throws:
UnsavedDataException
-
getTempFolder
File getTempFolder()Gets the temporary folder of the plugins framework.- Returns:
- the temp folder
-
getTempFile
Get the file name in the temporary folder of the plugins framework.- Parameters:
name-- Returns:
-
getTempFile
Create a unique file name in the temporary folder of the plugins framework.- Parameters:
name- base name used for create the unique file namesufix- to add the the unique file name- Returns:
-
desktopBrowse
Browses to a given URI- Parameters:
uri-- Returns:
-
desktopOpen
Open a given file- Parameters:
file-- Returns:
-
getArguments
Arguments getArguments()
-