1
//////////////////////////////////////////////////////////////////////////////
2
//////////////////////////////////////////////////////////////////////////////
4
// copyright : (C) 2008 by Eran Ifrah
5
// file name : pipedprocess.h
7
// -------------------------------------------------------------------------
10
// / __ \ | | | | (_) |
11
// | / \/ ___ __| | ___| | _| |_ ___
12
// | | / _ \ / _ |/ _ \ | | | __/ _ )
13
// | \__/\ (_) | (_| | __/ |___| | || __/
14
// \____/\___/ \__,_|\___\_____/_|\__\___|
18
// This program is free software; you can redistribute it and/or modify
19
// it under the terms of the GNU General Public License as published by
20
// the Free Software Foundation; either version 2 of the License, or
21
// (at your option) any later version.
23
//////////////////////////////////////////////////////////////////////////////
24
//////////////////////////////////////////////////////////////////////////////
25
#ifndef PipedProcess_H
26
#define PipedProcess_H
28
#include "wx/process.h"
29
#include "wx/string.h"
31
class PipedProcess : public wxProcess
38
* Constructs a process object. id is only used in the case you want to use wxWidgets events.
39
* It identifies this object, or another window that will receive the event.
41
PipedProcess(int id, const wxString &cmdLine);
43
virtual ~PipedProcess();
46
* \return return the process id
51
* \param set the process ID
53
void SetPid(long pid);
62
* \return the process id
64
virtual long Start(bool hide = true);
66
virtual bool HasInput(wxString &input);
69
* \brief read all input from the process output stream
71
* \return true if some data was read, false otherwise
73
virtual bool ReadAll(wxString &input);
76
#endif // PipedProcess_H