Class GFLauncherInfo


  • public class GFLauncherInfo
    extends Object
    Author:
    Byron Nevins
    • Method Detail

      • addArgs

        public void addArgs​(String... args)
        Add the string arguments in the order given.
        Parameters:
        args - The string arguments
      • setPrebootCommandsFile

        public void setPrebootCommandsFile​(String file)
        Sets the file containing commands to be run preboot.
        Parameters:
        file -
      • setpostbootCommandsFile

        public void setpostbootCommandsFile​(File file)
        Sets the file containing commands to be run postboot.
        Parameters:
        file -
      • setpostbootCommandsFile

        public void setpostbootCommandsFile​(String file)
        Sets the file containing commands to be run postboot.
        Parameters:
        file -
      • setDomainName

        public void setDomainName​(String domainName)
        Set the (optional) domain name. This can also be sent in as a String arg like so: "-domainname" "theName"
        Parameters:
        domainName -
      • setDomainParentDir

        public void setDomainParentDir​(String domainParentName)
        Set the (optional) domain parent directory. This can also be sent in as a String arg like so: "-domaindir" "parentDirPath"
        Parameters:
        domainParentName - The parent directory of the domain
      • setVerbose

        public void setVerbose​(boolean b)
        Starts the server in verbose mode
        Parameters:
        b -
      • setWatchdog

        public void setWatchdog​(boolean b)
        Starts the server in watchdog mode. This is only useful if verbose is false. It does the same thing as verbose -- except without the dumping of output to standard out and err streams.
        Parameters:
        b -
        Since:
        3.2
      • setDebug

        public void setDebug​(boolean b)
        Starts the server in debug mode
        Parameters:
        b -
      • setUpgrade

        public void setUpgrade​(boolean b)
        Starts the server in upgrade mode
        Parameters:
        b -
      • setDomainRootDir

        public void setDomainRootDir​(File f)
      • setInstanceName

        public void setInstanceName​(String name)
      • setInstanceRootDir

        public void setInstanceRootDir​(File f)
      • setDropInterruptedCommands

        public void setDropInterruptedCommands​(boolean dropInterruptedCommands)
      • isDomain

        public final boolean isDomain()
      • isInstance

        public final boolean isInstance()
      • isVerbose

        public boolean isVerbose()
        Returns:
        true if verbose mode is on.
      • isWatchdog

        public boolean isWatchdog()
        Returns:
        true if watchdog mode is on.
      • isDebug

        public boolean isDebug()
        Returns:
        true if debug mode is on.
      • isUpgrade

        public boolean isUpgrade()
        Returns:
        true if upgrade mode is on.
      • getDomainName

        public String getDomainName()
        Returns:
        The domain name
      • getPrebootCommandsFile

        public File getPrebootCommandsFile()
        Returns:
        The file that contains the commands to be run preboot
      • getPostbootCommandsFile

        public File getPostbootCommandsFile()
        Returns the file that contains the commands to be executed postboot
        Returns:
      • getConfigFile

        public File getConfigFile()
      • getDomainRootDir

        public File getDomainRootDir()
      • getInstanceName

        public String getInstanceName()
      • getConfigDir

        public File getConfigDir()
      • isDropInterruptedCommands

        public boolean isDropInterruptedCommands()
      • getArgsAsStringArray

        public String[] getArgsAsStringArray()
                                      throws GFLauncherException
        TEMPORARY. The guts of HK2 and V3 bootstrapping wants String[] -- this will be changed soon, but it is messy to change it right now. so temporarily we will humor HK2 by sending in String[]
        Returns:
        an array of String arguments
        Throws:
        GFLauncherException
      • setRespawnInfo

        public void setRespawnInfo​(String classname,
                                   String classpath,
                                   String[] args)
      • addSecurityToken

        public void addSecurityToken​(String name,
                                     String value)
        Adds the given name value pair as a security token. This is what will be put on the launched process's stdin to securely pass it on. The value is accepted as a String and it may be insecure. A string formed by concatenating name, '=' and value is written to the stdin as a single line delimited by newline character. To get the value of the token, the server should parse the line knowing this. None of the parameters may be null.
        Parameters:
        name - String representing name of the token
        value - String representing the value (should we call it a password?)
        Throws:
        NullPointerException - if any of the parameters are null