2081
|
1 /* |
|
2 |
7017
|
3 Copyright (C) 1996, 1997, 1999, 2000, 2003, 2004, 2005, 2006, 2007 |
|
4 John W. Eaton |
2081
|
5 |
|
6 This file is part of Octave. |
|
7 |
|
8 Octave is free software; you can redistribute it and/or modify it |
|
9 under the terms of the GNU General Public License as published by the |
7016
|
10 Free Software Foundation; either version 3 of the License, or (at your |
|
11 option) any later version. |
2081
|
12 |
|
13 Octave is distributed in the hope that it will be useful, but WITHOUT |
|
14 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
|
15 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
|
16 for more details. |
|
17 |
|
18 You should have received a copy of the GNU General Public License |
7016
|
19 along with Octave; see the file COPYING. If not, see |
|
20 <http://www.gnu.org/licenses/>. |
2081
|
21 |
|
22 */ |
|
23 |
|
24 #if !defined (octave_octave_procstream_h) |
|
25 #define octave_octave_procstream_h 1 |
|
26 |
|
27 #include "oct-stdstrm.h" |
|
28 |
5775
|
29 // FIXME -- why don't these classes use iprocstream and |
3652
|
30 // oprocstream, which in turn use the octave_procbuf class? |
|
31 |
2081
|
32 class |
4327
|
33 octave_iprocstream : public octave_stdiostream |
2081
|
34 { |
|
35 public: |
|
36 |
3523
|
37 octave_iprocstream (const std::string& n, |
3544
|
38 std::ios::openmode arg_md = std::ios::in, |
5015
|
39 oct_mach_info::float_format flt_fmt |
|
40 = oct_mach_info::native_float_format ()); |
2081
|
41 |
3340
|
42 static octave_stream |
3544
|
43 create (const std::string& n, std::ios::openmode arg_md = std::ios::in, |
5015
|
44 oct_mach_info::float_format flt_fmt |
|
45 = oct_mach_info::native_float_format ()); |
3340
|
46 |
|
47 protected: |
|
48 |
2081
|
49 ~octave_iprocstream (void); |
|
50 |
|
51 private: |
|
52 |
|
53 // No copying! |
|
54 |
|
55 octave_iprocstream (const octave_iprocstream&); |
|
56 |
|
57 octave_iprocstream& operator = (const octave_iprocstream&); |
|
58 }; |
|
59 |
|
60 class |
4327
|
61 octave_oprocstream : public octave_stdiostream |
2081
|
62 { |
|
63 public: |
|
64 |
3523
|
65 octave_oprocstream (const std::string& n, |
3544
|
66 std::ios::openmode arg_md = std::ios::out, |
5015
|
67 oct_mach_info::float_format flt_fmt |
|
68 = oct_mach_info::native_float_format ()); |
2081
|
69 |
3340
|
70 static octave_stream |
3544
|
71 create (const std::string& n, std::ios::openmode arg_md = std::ios::out, |
5015
|
72 oct_mach_info::float_format flt_fmt |
|
73 = oct_mach_info::native_float_format ()); |
3340
|
74 |
|
75 protected: |
|
76 |
2081
|
77 ~octave_oprocstream (void); |
|
78 |
|
79 private: |
|
80 |
|
81 // No copying! |
|
82 |
|
83 octave_oprocstream (const octave_oprocstream&); |
|
84 |
|
85 octave_oprocstream& operator = (const octave_oprocstream&); |
|
86 }; |
|
87 |
|
88 #endif |
|
89 |
|
90 /* |
|
91 ;;; Local Variables: *** |
|
92 ;;; mode: C++ *** |
|
93 ;;; End: *** |
|
94 */ |