-rw-r--r-- | libopie/oprocess.h | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/libopie/oprocess.h b/libopie/oprocess.h index f2853b0..af7cddb 100644 --- a/libopie/oprocess.h +++ b/libopie/oprocess.h @@ -213,198 +213,192 @@ public: The use of this function is now deprecated. -- Please use the "operator<<" instead of "setExecutable". Sets the executable to be started with this OProcess object. Returns false if the process is currently running (in that case the executable remains unchanged.) @see operator<< */ bool setExecutable(const QString& proc); /** * Sets the executable and the command line argument list for this process. * * For example, doing an "ls -l /usr/local/bin" can be achieved by: * <pre> * OProcess p; * ... * p << "ls" << "-l" << "/usr/local/bin" * </pre> * **/ OProcess &operator<<(const QString& arg); /** * Similar to previous method, takes a char *, supposed to be in locale 8 bit already. */ OProcess &operator<<(const char * arg); /** * Similar to previous method, takes a QCString, supposed to be in locale 8 bit already. */ OProcess &operator<<(const QCString & arg); /** * Sets the executable and the command line argument list for this process, * in a single method call, or add a list of arguments. **/ OProcess &operator<<(const QStringList& args); /** * Clear a command line argument list that has been set by using * the "operator<<". */ void clearArguments(); /** * Starts the process. * For a detailed description of the * various run modes and communication semantics, have a look at the * general description of the OProcess class. * * The following problems could cause this function to * return false: * * @li The process is already running. * @li The command line argument list is empty. * @li The starting of the process failed (could not fork). * @li The executable was not found. * * @param comm Specifies which communication links should be * established to the child process (stdin/stdout/stderr). By default, * no communication takes place and the respective communication * signals will never get emitted. * * @return true on success, false on error * (see above for error conditions) **/ virtual bool start(RunMode runmode = NotifyOnExit, Communication comm = NoCommunication); /** * Stop the process (by sending it a signal). * * @param signo The signal to send. The default is SIGTERM. * @return @p true if the signal was delivered successfully. */ virtual bool kill(int signo = SIGTERM); /** @return @p true if the process is (still) considered to be running */ bool isRunning() const; /** Returns the process id of the process. * * If it is called after * the process has exited, it returns the process id of the last * child process that was created by this instance of OProcess. * * Calling it before any child process has been started by this * OProcess instance causes pid() to return 0. **/ pid_t pid() const; /** - * Use pid(). - * @deprecated - */ - pid_t getPid() const { return pid(); } - - /** * Suspend processing of data from stdout of the child process. */ void suspend(); /** * Resume processing of data from stdout of the child process. */ void resume(); /** * @return @p true if the process has already finished and has exited * "voluntarily", ie: it has not been killed by a signal. * * Note that you should check @ref OProcess::exitStatus() to determine * whether the process completed its task successful or not. */ bool normalExit() const; /** * Returns the exit status of the process. * * Please use * @ref OProcess::normalExit() to check whether the process has exited * cleanly (i.e., @ref OProcess::normalExit() returns @p true) before calling * this function because if the process did not exit normally, * it does not have a valid exit status. */ int exitStatus() const; /** * Transmit data to the child process's stdin. * * OProcess::writeStdin may return false in the following cases: * * @li The process is not currently running. * * @li Communication to stdin has not been requested in the @ref start() call. * * @li Transmission of data to the child process by a previous call to * @ref writeStdin() is still in progress. * * Please note that the data is sent to the client asynchronously, * so when this function returns, the data might not have been * processed by the child process. * * If all the data has been sent to the client, the signal * @ref wroteStdin() will be emitted. * * Please note that you must not free "buffer" or call @ref writeStdin() * again until either a @ref wroteStdin() signal indicates that the * data has been sent or a @ref processHasExited() signal shows that * the child process is no longer alive... **/ bool writeStdin(const char *buffer, int buflen); void flushStdin(); /** * This causes the stdin file descriptor of the child process to be * closed indicating an "EOF" to the child. * * @return @p false if no communication to the process's stdin * had been specified in the call to @ref start(). */ bool closeStdin(); /** * This causes the stdout file descriptor of the child process to be * closed. * * @return @p false if no communication to the process's stdout * had been specified in the call to @ref start(). */ bool closeStdout(); /** * This causes the stderr file descriptor of the child process to be * closed. * * @return @p false if no communication to the process's stderr * had been specified in the call to @ref start(). */ bool closeStderr(); /** * Lets you see what your arguments are for debugging. */ const QValueList<QCString> &args() { return arguments; } /** * Controls whether the started process should drop any * setuid/segid privileges or whether it should keep them * * The default is @p false : drop privileges |