madkit.action

## Class GlobalAction

- java.lang.Object
- - madkit.action.GlobalAction

-     public class GlobalAction
      extends Object

  Global actions that can be triggered from anywhere during execution.
  Since:
    MaDKit 5.0.1
  Version:
    0.9
  Author:
    Fabien Michel

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static Action` | `DEBUG` An action that enable or disable the debugging mode.
    `static Action` | `JCONSOLE` An action that Launches the jconsole tool if it is available.
    `static Action` | `LAUNCH_MAIN` An action that launch the main method of the class which name is obtained using `ActionEvent.getActionCommand()` on the received event, i.e. the action command of the button.
    `static Action` | `LAUNCH_MDK_CONFIG` An action that launches a new MaDKit instance using the configuration file which name is obtained using `ActionEvent.getActionCommand()` on the received event, i.e. the action command of the button.
    `static Action` | `LOAD_JAR_FILE` Opens a dialog for selecting the jar file to add.
    `static Action` | `LOAD_LOCAL_DEMOS` Load the jar files which are in the "demos" directory if there is one in the working directory
    `static Action` | `LOG_FILES` An action that create a log file for each agent having a non `null` logger.

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `GlobalAction()`

  - ### Method Summary

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### JCONSOLE

          public static final Action JCONSOLE

      An action that Launches the jconsole tool if it is available. It is set to `null` if jconsole is unavailable. jconsole is available on environments containing the oracle JDK.

    - #### DEBUG

          public static final Action DEBUG

      An action that enable or disable the debugging mode. When activated, all the active agent loggers set their level to `Level.ALL`. When disabled, all the loggers are set to `Level.INFO`.

    - #### LOG_FILES

          public static final Action LOG_FILES

      An action that create a log file for each agent having a non `null` logger.

    - #### LAUNCH_MAIN

          public static final Action LAUNCH_MAIN

      An action that launch the main method of the class which name is obtained using `ActionEvent.getActionCommand()` on the received event, i.e. the action command of the button.

    - #### LOAD_JAR_FILE

          public static final Action LOAD_JAR_FILE

      Opens a dialog for selecting the jar file to add.

    - #### LOAD_LOCAL_DEMOS

          public static final Action LOAD_LOCAL_DEMOS

      Load the jar files which are in the "demos" directory if there is one in the working directory

    - #### LAUNCH_MDK_CONFIG

          public static final Action LAUNCH_MDK_CONFIG

      An action that launches a new MaDKit instance using the configuration file which name is obtained using `ActionEvent.getActionCommand()` on the received event, i.e. the action command of the button.

  - ### Constructor Detail

    - #### GlobalAction

          public GlobalAction()

Fabien Michel, Olivier Gutknecht, Jacques Ferber