Class ProcessIO


  • public class ProcessIO
    extends java.lang.Object
    A POJO that contains the results of the ProcessHelper.
    • Constructor Summary

      Constructors 
      Constructor Description
      ProcessIO​(boolean ok, java.lang.String stdout, java.lang.String stderr)
      Create an immutable instance.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getStderr()
      Access the stderr produced by running a Process.
      java.lang.String getStdout()
      Access the stdout produced by running a Process.
      boolean isOk()
      Access the binary flag that indicates the success or failure of running a native operating system Process.
      java.lang.String toString()
      Map this instance to its String representation.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • ProcessIO

        public ProcessIO​(boolean ok,
                         java.lang.String stdout,
                         java.lang.String stderr)
        Create an immutable instance.
        Parameters:
        ok - A binary flag indicating the success or failure of running a native operating system Process.
        stdout - The output message produced by the successful running of a native operating system Process.
        stderr - The error message produced by the unsuccessful running of a native operating system Process.
    • Method Detail

      • isOk

        public boolean isOk()
        Access the binary flag that indicates the success or failure of running a native operating system Process.
        Returns:
        true if the process ran without errors. Otherwise, false.
      • getStdout

        public java.lang.String getStdout()
        Access the stdout produced by running a Process.
        Returns:
        The output message produced by the successful running of a native operating system Process.
      • getStderr

        public java.lang.String getStderr()
        Access the stderr produced by running a Process.
        Returns:
        The error message produced by the unsuccessful running of a native operating system Process.
      • toString

        public java.lang.String toString()
        Map this instance to its String representation.
        Overrides:
        toString in class java.lang.Object
        Returns:
        A String of the form: „ProcessIO{ok=true, stdout='foo...', stderr='boo...'}“.