PTP
Release 5.0

org.eclipse.ptp.remote.core
Class AbstractRemoteProcess

java.lang.Object
  extended by java.lang.Process
      extended by org.eclipse.ptp.remote.core.AbstractRemoteProcess
All Implemented Interfaces:
IRemoteProcess

public abstract class AbstractRemoteProcess
extends java.lang.Process
implements IRemoteProcess


Constructor Summary
AbstractRemoteProcess()
           
 
Method Summary
 void destroy()
          Terminate the process
 int exitValue()
          Returns the exit value for the process
 java.io.InputStream getErrorStream()
          Gets the error output stream of the process
 java.io.InputStream getInputStream()
          Gets an InputStream which can be used to read the standard output stream of the process
 java.io.OutputStream getOutputStream()
          Gets an output stream which can be used to write to the standard input stream of the process
 boolean isCompleted()
          Check if the remote process has completed
 int waitFor()
          Wait until the process has terminated
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractRemoteProcess

public AbstractRemoteProcess()
Method Detail

destroy

public void destroy()
Description copied from interface: IRemoteProcess
Terminate the process

Specified by:
destroy in interface IRemoteProcess
Specified by:
destroy in class java.lang.Process

exitValue

public int exitValue()
Description copied from interface: IRemoteProcess
Returns the exit value for the process

Specified by:
exitValue in interface IRemoteProcess
Specified by:
exitValue in class java.lang.Process
Returns:
the exit value

getErrorStream

public java.io.InputStream getErrorStream()
Description copied from interface: IRemoteProcess
Gets the error output stream of the process

Specified by:
getErrorStream in interface IRemoteProcess
Specified by:
getErrorStream in class java.lang.Process
Returns:
the output stream connected to the standard error of the process

getInputStream

public java.io.InputStream getInputStream()
Description copied from interface: IRemoteProcess
Gets an InputStream which can be used to read the standard output stream of the process

Specified by:
getInputStream in interface IRemoteProcess
Specified by:
getInputStream in class java.lang.Process
Returns:
the input stream connected to the standard output of the process

getOutputStream

public java.io.OutputStream getOutputStream()
Description copied from interface: IRemoteProcess
Gets an output stream which can be used to write to the standard input stream of the process

Specified by:
getOutputStream in interface IRemoteProcess
Specified by:
getOutputStream in class java.lang.Process
Returns:
the output stream connected to the standard input of the process

waitFor

public int waitFor()
            throws java.lang.InterruptedException
Description copied from interface: IRemoteProcess
Wait until the process has terminated

Specified by:
waitFor in interface IRemoteProcess
Specified by:
waitFor in class java.lang.Process
Returns:
the exit value of the process
Throws:
java.lang.InterruptedException - if the current thread is interrupted by another thread while it is waiting

isCompleted

public boolean isCompleted()
Check if the remote process has completed

Specified by:
isCompleted in interface IRemoteProcess
Returns:
true if remote process has completed

PTP
Release 5.0

Copyright (c) 2011 IBM Corporation and others. All Rights Reserved.