PTLib Version 2.12.9

- Main Page
- Related Pages
- Namespaces
- Classes
- Files

- File List
- File Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
conchan.h
Go to the documentation of this file.
1 /*
2 * conchan.h
3 *
4 * Console I/O channel class.
5 *
6 * Portable Windows Library
7 *
8 * Copyright (c) 1993-1998 Equivalence Pty. Ltd.
9 *
10 * The contents of this file are subject to the Mozilla Public License
11 * Version 1.0 (the "License"); you may not use this file except in
12 * compliance with the License. You may obtain a copy of the License at
13 * http://www.mozilla.org/MPL/
14 *
15 * Software distributed under the License is distributed on an "AS IS"
16 * basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
17 * the License for the specific language governing rights and limitations
18 * under the License.
19 *
20 * The Original Code is Portable Windows Library.
21 *
22 * The Initial Developer of the Original Code is Equivalence Pty. Ltd.
23 *
24 * Portions are Copyright (C) 1993 Free Software Foundation, Inc.
25 * All Rights Reserved.
26 *
27 * Contributor(s): ______________________________________.
28 *
29 * $Revision: 28740 $
30 * $Author: rjongbloed $
31 * $Date: 2013-01-02 18:58:47 +1100 (Wed, 02 Jan 2013) $
32 */
33
34 #ifndef PTLIB_CONSOLECHANNEL_H
35 #define PTLIB_CONSOLECHANNEL_H
36
37 #ifdef P_USE_PRAGMA
38 #pragma interface
39 #endif
40
41 P_PUSH_MSVC_WARNINGS(4250)
42
43
44 // Console Channel
45
46
48 class PConsoleChannel : public PChannel
49 {
50 PCLASSINFO(PConsoleChannel, PChannel);
51
52 public:
53 enum ConsoleType {
54 StandardInput,
55 StandardOutput,
56 StandardError
57 };
58
61
62 PConsoleChannel();
63
65 PConsoleChannel(
66 ConsoleType type
67 );
69
79 virtual bool SetLocalEcho(
80 bool localEcho
81 );
83
90 virtual PBoolean Open(
91 ConsoleType type
92 );
94
95
96 // Include platform dependent part of class
97 #ifdef _WIN32
98 #include "msos/ptlib/conchan.h"
99 #else
100 #include "unix/ptlib/conchan.h"
101 #endif
102
103 };
104
105
106 #endif // PTLIB_CONSOLECHANNEL_H
107
108
109 // End Of File ///////////////////////////////////////////////////////////////