Interface PluginState

All Known Implementing Classes:
PluginStateImpl

public interface PluginState
This object provides information the current state of the plugin, and provides various mechanisms to query and control plugins and their integration with the client at a low-level. Most plugins will have no need to interact with this object - it is primarily used by the client for plugin management.
Since:
3.1.1.1
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Returns true if there was a problem loading or initialising the plugin.
    boolean
    Built-in plugins are those used internally by the client, for example the UPnP plugin.
    boolean
    Returns true if the plugin has been marked as disabled, and prevented from initialising.
    boolean
     
    boolean
    Returns true if the plugin is set to load at startup, false otherwise.
    boolean
    Whether or not this is a mandatory plugin.
    boolean
    Returns true if the plugin is running, returns false if the plugin isn't running for some reason.
    boolean
     
    boolean
     
    boolean
     
    boolean
     
    void
     
    void
    setDisabled(boolean disabled)
    Sets whether the plugin can be loaded or not.
    void
    setLoadedAtStartup(boolean load_at_startup)
    Sets whether the plugin is loaded at startup or not.
    void
    setRestartPending(boolean b)
     
    void
    Uninstall this plugin if it has been loaded from a plugin directory.
    void
     
  • Method Details

    • isLoadedAtStartup

      boolean isLoadedAtStartup()
      Returns true if the plugin is set to load at startup, false otherwise.
    • setLoadedAtStartup

      void setLoadedAtStartup(boolean load_at_startup)
      Sets whether the plugin is loaded at startup or not.
    • hasFailed

      boolean hasFailed()
      Returns true if there was a problem loading or initialising the plugin.
    • isDisabled

      boolean isDisabled()
      Returns true if the plugin has been marked as disabled, and prevented from initialising.
    • setDisabled

      void setDisabled(boolean disabled)
      Sets whether the plugin can be loaded or not. If you are trying to affect if the plugin can be loaded at startup - use setLoadedAtStartup(boolean) instead. This needs to be called prior to a plugin's initialisation to take effect.
      Parameters:
      disabled -
    • isBuiltIn

      boolean isBuiltIn()
      Built-in plugins are those used internally by the client, for example the UPnP plugin.
    • isMandatory

      boolean isMandatory()
      Whether or not this is a mandatory plugin. Mandatory plugins take priority over update checks, for example, over optional ones.
    • isOperational

      boolean isOperational()
      Returns true if the plugin is running, returns false if the plugin isn't running for some reason.
    • isInitialisationComplete

      boolean isInitialisationComplete()
    • isRestartPending

      boolean isRestartPending()
    • setRestartPending

      void setRestartPending(boolean b)
    • uninstall

      void uninstall() throws PluginException
      Uninstall this plugin if it has been loaded from a plugin directory. Deletes the plugin directory.
      Throws:
      PluginException
    • isShared

      boolean isShared()
    • isUnloadable

      boolean isUnloadable()
    • isUnloaded

      boolean isUnloaded()
    • unload

      void unload() throws PluginException
      Throws:
      PluginException
    • reload

      void reload() throws PluginException
      Throws:
      PluginException