Enum Class ServerShell.Supervisor

java.lang.Object
java.lang.Enum<ServerShell.Supervisor>
com.iizix.server.ServerShell.Supervisor
All Implemented Interfaces:
Serializable, Comparable<ServerShell.Supervisor>, Constable
Enclosing class:
ServerShell

public static enum ServerShell.Supervisor extends Enum<ServerShell.Supervisor>
Who supervises the server process: what relaunches it when it exits with ServerExit.RESTART, and runs the updater first at ServerExit.UPDATE_RESTART. Named by the start option -supervisor script|wrapper|iiziGo; absent means unsupervised, and a restart is then refused rather than leaving a dead server.
Author:
Christopher Mindus
  • Enum Constant Details

    • NONE

      public static final ServerShell.Supervisor NONE
      No supervisor: the server cannot restart itself.
    • SCRIPT

      public static final ServerShell.Supervisor SCRIPT
      The POSIX iiziServer.sh loop or the Windows iiziServer.bat loop.
    • WRAPPER

      public static final ServerShell.Supervisor WRAPPER
      The Java service wrapper under SrvAny: a Windows service.
    • IIZIGO

      public static final ServerShell.Supervisor IIZIGO
      iiziGo, which relaunches its development-server launch configuration: a restart, never an update (the iiziGo-bundled server is pure development).
  • Field Details

    • option

      public final String option
      The value of the start option.
  • Method Details

    • values

      public static ServerShell.Supervisor[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static ServerShell.Supervisor valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • parse

      public static ServerShell.Supervisor parse(String value)
      Parses the value of the start option, case insensitive.
      Parameters:
      value - The value of -supervisor.
      Returns:
      The supervisor, or null for an unknown value (NONE is not an option value).