com.android.ide.common.process
Class DefaultProcessExecutor

java.lang.Object
  extended by com.android.ide.common.process.DefaultProcessExecutor
All Implemented Interfaces:
ProcessExecutor

public class DefaultProcessExecutor
extends java.lang.Object
implements ProcessExecutor

Simple implementation of ProcessExecutor, using the standard Java Process(Builder) API.


Constructor Summary
DefaultProcessExecutor(com.android.utils.ILogger logger)
           
 
Method Summary
 ProcessResult execute(ProcessInfo processInfo, ProcessOutputHandler processOutputHandler)
          Executes an external process as specified by the ProcessInfo.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultProcessExecutor

public DefaultProcessExecutor(com.android.utils.ILogger logger)
Method Detail

execute

@NonNull
public ProcessResult execute(@NonNull
                                     ProcessInfo processInfo,
                                     @NonNull
                                     ProcessOutputHandler processOutputHandler)
Description copied from interface: ProcessExecutor
Executes an external process as specified by the ProcessInfo. The process always returns, even when the execution failed. The various possible outcomes of the execution can be queried through the ProcessResult instance.

Specified by:
execute in interface ProcessExecutor
Parameters:
processInfo - the specification of what to run.
processOutputHandler - the output handler
Returns:
the ProcessResult