summaryrefslogtreecommitdiff
path: root/libopie2/opiecore/oprocess.h
Unidiff
Diffstat (limited to 'libopie2/opiecore/oprocess.h') (more/less context) (ignore whitespace changes)
-rw-r--r--libopie2/opiecore/oprocess.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/libopie2/opiecore/oprocess.h b/libopie2/opiecore/oprocess.h
index e23f98c..be1436c 100644
--- a/libopie2/opiecore/oprocess.h
+++ b/libopie2/opiecore/oprocess.h
@@ -25,49 +25,49 @@ _;:,     .>    :=|. This program is free software; you can
25   --        :-=` this library; see the file COPYING.LIB. 25   --        :-=` this library; see the file COPYING.LIB.
26 If not, write to the Free Software Foundation, 26 If not, write to the Free Software Foundation,
27 Inc., 59 Temple Place - Suite 330, 27 Inc., 59 Temple Place - Suite 330,
28 Boston, MA 02111-1307, USA. 28 Boston, MA 02111-1307, USA.
29*/ 29*/
30 30
31#ifndef OPROCESS_H 31#ifndef OPROCESS_H
32#define OPROCESS_H 32#define OPROCESS_H
33 33
34/* QT */ 34/* QT */
35#include <qcstring.h> 35#include <qcstring.h>
36#include <qobject.h> 36#include <qobject.h>
37#include <qvaluelist.h> 37#include <qvaluelist.h>
38 38
39/* STD */ 39/* STD */
40#include <sys/types.h> // for pid_t 40#include <sys/types.h> // for pid_t
41#include <sys/wait.h> 41#include <sys/wait.h>
42#include <signal.h> 42#include <signal.h>
43#include <unistd.h> 43#include <unistd.h>
44 44
45class QSocketNotifier; 45class QSocketNotifier;
46 46
47namespace Opie { 47namespace Opie {
48namespace Core { 48namespace Core {
49namespace Private { 49namespace Internal {
50class OProcessController; 50class OProcessController;
51class OProcessPrivate; 51class OProcessPrivate;
52} 52}
53 53
54/** 54/**
55 * Child process invocation, monitoring and control. 55 * Child process invocation, monitoring and control.
56 * 56 *
57 * @sect General usage and features 57 * @sect General usage and features
58 * 58 *
59 *This class allows a KDE and OPIE application to start child processes without having 59 *This class allows a KDE and OPIE application to start child processes without having
60 *to worry about UN*X signal handling issues and zombie process reaping. 60 *to worry about UN*X signal handling issues and zombie process reaping.
61 * 61 *
62 *@see KProcIO 62 *@see KProcIO
63 * 63 *
64 *Basically, this class distinguishes three different ways of running 64 *Basically, this class distinguishes three different ways of running
65 *child processes: 65 *child processes:
66 * 66 *
67 *@li OProcess::DontCare -- The child process is invoked and both the child 67 *@li OProcess::DontCare -- The child process is invoked and both the child
68 *process and the parent process continue concurrently. 68 *process and the parent process continue concurrently.
69 * 69 *
70 *Starting a DontCare child process means that the application is 70 *Starting a DontCare child process means that the application is
71 *not interested in any notification to determine whether the 71 *not interested in any notification to determine whether the
72 *child process has already exited or not. 72 *child process has already exited or not.
73 * 73 *
@@ -702,60 +702,60 @@ protected:
702 /** 702 /**
703 * Called by "slotChildOutput" this function copies data arriving from the 703 * Called by "slotChildOutput" this function copies data arriving from the
704 * child process's stdout to the respective buffer and emits the signal 704 * child process's stdout to the respective buffer and emits the signal
705 * "@ref receivedStderr". 705 * "@ref receivedStderr".
706 */ 706 */
707 int childOutput( int fdno ); 707 int childOutput( int fdno );
708 708
709 /** 709 /**
710 * Called by "slotChildOutput" this function copies data arriving from the 710 * Called by "slotChildOutput" this function copies data arriving from the
711 * child process's stdout to the respective buffer and emits the signal 711 * child process's stdout to the respective buffer and emits the signal
712 * "@ref receivedStderr" 712 * "@ref receivedStderr"
713 */ 713 */
714 int childError( int fdno ); 714 int childError( int fdno );
715 715
716 // information about the data that has to be sent to the child: 716 // information about the data that has to be sent to the child:
717 717
718 const char *input_data; // the buffer holding the data 718 const char *input_data; // the buffer holding the data
719 int input_sent; // # of bytes already transmitted 719 int input_sent; // # of bytes already transmitted
720 int input_total; // total length of input_data 720 int input_total; // total length of input_data
721 721
722 /** 722 /**
723 * @ref OProcessController is a friend of OProcess because it has to have 723 * @ref OProcessController is a friend of OProcess because it has to have
724 * access to various data members. 724 * access to various data members.
725 */ 725 */
726 friend class Private::OProcessController; 726 friend class Internal::OProcessController;
727 727
728private: 728private:
729 /** 729 /**
730 * Searches for a valid shell. 730 * Searches for a valid shell.
731 * Here is the algorithm used for finding an executable shell: 731 * Here is the algorithm used for finding an executable shell:
732 * 732 *
733 * @li Try the executable pointed to by the "SHELL" environment 733 * @li Try the executable pointed to by the "SHELL" environment
734 * variable with white spaces stripped off 734 * variable with white spaces stripped off
735 * 735 *
736 * @li If your process runs with uid != euid or gid != egid, a shell 736 * @li If your process runs with uid != euid or gid != egid, a shell
737 * not listed in /etc/shells will not used. 737 * not listed in /etc/shells will not used.
738 * 738 *
739 * @li If no valid shell could be found, "/bin/sh" is used as a last resort. 739 * @li If no valid shell could be found, "/bin/sh" is used as a last resort.
740 */ 740 */
741 QCString searchShell(); 741 QCString searchShell();
742 742
743 /** 743 /**
744 * Used by @ref searchShell in order to find out whether the shell found 744 * Used by @ref searchShell in order to find out whether the shell found
745 * is actually executable at all. 745 * is actually executable at all.
746 */ 746 */
747 bool isExecutable( const QCString &filename ); 747 bool isExecutable( const QCString &filename );
748 748
749 // Disallow assignment and copy-construction 749 // Disallow assignment and copy-construction
750 OProcess( const OProcess& ); 750 OProcess( const OProcess& );
751 OProcess& operator= ( const OProcess& ); 751 OProcess& operator= ( const OProcess& );
752 752
753private: 753private:
754 void init ( ); 754 void init ( );
755 Private::OProcessPrivate *d; 755 Internal::OProcessPrivate *d;
756}; 756};
757} 757}
758} 758}
759 759
760#endif 760#endif
761 761