Class AbstractProcessExecutor

java.lang.Object
de.hybris.platform.mediaconversion.os.process.AbstractProcessExecutor
All Implemented Interfaces:
ProcessExecutor
Direct Known Subclasses:
BasicProcessExecutor, LimitedProcessExecutor, ProcessExecutorClient

public abstract class AbstractProcessExecutor extends Object implements ProcessExecutor
Abstract ProcessExecutor providing the standard implementation of execute(String[], String[], File, Drain, Drain).
  • Constructor Details

    • AbstractProcessExecutor

      public AbstractProcessExecutor()
  • Method Details

    • execute

      public int execute(String[] command, String[] environment, File directory, Drain stdOutput, Drain stdError) throws IOException
      Shortcut method calling this.execute(new ProcessContext(command, environment, directory, stdOutput, stdError));.

      Synchronously executes the given command in the given environment and directory.

      Specified by:
      execute in interface ProcessExecutor
      Parameters:
      command - the command line to execute/
      environment - the environment to use
      directory - the directory to execute the command in
      stdOutput - callback handle to process the processes standard output
      stdError - callback handle to process the processes standard error output
      Returns:
      the exit code of the process
      Throws:
      IOException - on any error executing the process.
      See Also: