Interface Commandline

  • All Known Implementing Classes:
    CommandlineImpl

    public interface Commandline
    • Field Detail

      • DEFAULT_TIMEOUT

        static final long DEFAULT_TIMEOUT
        Default process timeout = 1 minute
        See Also:
        Constant Field Values
    • Method Detail

      • execute

        ProcessOutput execute​(java.lang.String cmd,
                              java.lang.String[] environment,
                              java.io.File dir)
                       throws java.io.IOException,
                              java.lang.InterruptedException
        Execute command line
        Parameters:
        dir - file working directory
        cmd - command line
        Returns:
        output of command
        Throws:
        java.io.IOException
        java.lang.InterruptedException
      • execute

        ProcessOutput execute​(java.lang.String cmd,
                              java.lang.String[] environment)
                       throws java.io.IOException,
                              java.lang.InterruptedException
        Execute command line
        Parameters:
        cmd - command line
        Returns:
        output of command
        Throws:
        java.io.IOException
        java.lang.InterruptedException
      • execute

        ProcessOutput execute​(java.lang.String cmd,
                              java.io.File dir)
                       throws java.io.IOException,
                              java.lang.InterruptedException
        Execute command line
        Parameters:
        dir - file working directory
        cmd - command line
        Returns:
        output of command
        Throws:
        java.io.IOException
        java.lang.InterruptedException
      • execute

        ProcessOutput execute​(java.lang.String cmd)
                       throws java.io.IOException,
                              java.lang.InterruptedException
        Execute command line
        Parameters:
        cmd - command line
        Returns:
        output of command
        Throws:
        java.io.IOException
        java.lang.InterruptedException
      • execute

        ProcessOutput execute​(java.lang.String[] cmd,
                              java.lang.String[] environment,
                              java.io.File dir)
                       throws java.io.IOException,
                              java.lang.InterruptedException
        Execute command line
        Parameters:
        dir - file working directory
        cmd - command line
        Returns:
        output of command
        Throws:
        java.io.IOException
        java.lang.InterruptedException
      • execute

        ProcessOutput execute​(java.lang.String[] cmd,
                              java.lang.String[] environment)
                       throws java.io.IOException,
                              java.lang.InterruptedException
        Execute command line
        Parameters:
        cmd - command line
        Returns:
        output of command
        Throws:
        java.io.IOException
        java.lang.InterruptedException
      • execute

        ProcessOutput execute​(java.lang.String[] cmd,
                              java.io.File dir)
                       throws java.io.IOException,
                              java.lang.InterruptedException
        Execute command line
        Parameters:
        dir - file working directory
        cmd - command line
        Returns:
        output of command
        Throws:
        java.io.IOException
        java.lang.InterruptedException
      • execute

        ProcessOutput execute​(java.lang.String[] cmd)
                       throws java.io.IOException,
                              java.lang.InterruptedException
        Execute command line
        Parameters:
        cmd - command line
        Returns:
        output of command
        Throws:
        java.io.IOException
        java.lang.InterruptedException
      • getTimeout

        long getTimeout()
        Returns:
      • setTimeout

        void setTimeout​(long timeout)
      • isLogEnabled

        boolean isLogEnabled()
        Returns:
      • log

        void log​(java.lang.String text)
        Print some log information.
        Parameters:
        text -