Mercurial > octave
annotate libinterp/corefcn/oct-prcstrm.h @ 21739:c4ab2e54f100
use namespace for oct_mach_info class
* mach-info.h, mach-info.cc: Put oct_mach_info in octave namespace and
rename to mach_info. Change all uses.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Thu, 19 May 2016 01:59:35 -0400 |
parents | 1473547f50f5 |
children | bac0d6f07a3e |
rev | line source |
---|---|
2081 | 1 /* |
2 | |
19697
4197fc428c7d
maint: Update copyright notices for 2015.
John W. Eaton <jwe@octave.org>
parents:
17822
diff
changeset
|
3 Copyright (C) 1996-2015 John W. Eaton |
2081 | 4 |
5 This file is part of Octave. | |
6 | |
7 Octave is free software; you can redistribute it and/or modify it | |
8 under the terms of the GNU General Public License as published by the | |
7016 | 9 Free Software Foundation; either version 3 of the License, or (at your |
10 option) any later version. | |
2081 | 11 |
12 Octave is distributed in the hope that it will be useful, but WITHOUT | |
13 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | |
14 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License | |
15 for more details. | |
16 | |
17 You should have received a copy of the GNU General Public License | |
7016 | 18 along with Octave; see the file COPYING. If not, see |
19 <http://www.gnu.org/licenses/>. | |
2081 | 20 |
21 */ | |
22 | |
20791
f7084eae3318
maint: Use Octave coding conventions for #if statements.
Rik <rik@octave.org>
parents:
19697
diff
changeset
|
23 #if ! defined (octave_oct_prcstrm_h) |
17822
ebb3ef964372
maint: Use common #define syntax "octave_filename_h" in h_files.
Rik <rik@octave.org>
parents:
17787
diff
changeset
|
24 #define octave_oct_prcstrm_h 1 |
2081 | 25 |
21244
1473547f50f5
include octave-config.h in public header files
John W. Eaton <jwe@octave.org>
parents:
20791
diff
changeset
|
26 #include "octave-config.h" |
1473547f50f5
include octave-config.h in public header files
John W. Eaton <jwe@octave.org>
parents:
20791
diff
changeset
|
27 |
2081 | 28 #include "oct-stdstrm.h" |
29 | |
17787
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
30 // FIXME: why don't these classes use iprocstream and oprocstream, |
175b392e91fe
Use GNU style coding conventions for code in libinterp/
Rik <rik@octave.org>
parents:
17744
diff
changeset
|
31 // which in turn use the octave_procbuf class? |
3652 | 32 |
2081 | 33 class |
4327 | 34 octave_iprocstream : public octave_stdiostream |
2081 | 35 { |
36 public: | |
37 | |
3523 | 38 octave_iprocstream (const std::string& n, |
10313 | 39 std::ios::openmode arg_md = std::ios::in, |
21739
c4ab2e54f100
use namespace for oct_mach_info class
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
40 octave::mach_info::float_format flt_fmt |
c4ab2e54f100
use namespace for oct_mach_info class
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
41 = octave::mach_info::native_float_format ()); |
2081 | 42 |
3340 | 43 static octave_stream |
3544 | 44 create (const std::string& n, std::ios::openmode arg_md = std::ios::in, |
21739
c4ab2e54f100
use namespace for oct_mach_info class
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
45 octave::mach_info::float_format flt_fmt |
c4ab2e54f100
use namespace for oct_mach_info class
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
46 = octave::mach_info::native_float_format ()); |
3340 | 47 |
48 protected: | |
49 | |
2081 | 50 ~octave_iprocstream (void); |
51 | |
52 private: | |
53 | |
54 // No copying! | |
55 | |
56 octave_iprocstream (const octave_iprocstream&); | |
57 | |
58 octave_iprocstream& operator = (const octave_iprocstream&); | |
59 }; | |
60 | |
61 class | |
4327 | 62 octave_oprocstream : public octave_stdiostream |
2081 | 63 { |
64 public: | |
65 | |
3523 | 66 octave_oprocstream (const std::string& n, |
10313 | 67 std::ios::openmode arg_md = std::ios::out, |
21739
c4ab2e54f100
use namespace for oct_mach_info class
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
68 octave::mach_info::float_format flt_fmt |
c4ab2e54f100
use namespace for oct_mach_info class
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
69 = octave::mach_info::native_float_format ()); |
2081 | 70 |
3340 | 71 static octave_stream |
3544 | 72 create (const std::string& n, std::ios::openmode arg_md = std::ios::out, |
21739
c4ab2e54f100
use namespace for oct_mach_info class
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
73 octave::mach_info::float_format flt_fmt |
c4ab2e54f100
use namespace for oct_mach_info class
John W. Eaton <jwe@octave.org>
parents:
21244
diff
changeset
|
74 = octave::mach_info::native_float_format ()); |
3340 | 75 |
76 protected: | |
77 | |
2081 | 78 ~octave_oprocstream (void); |
79 | |
80 private: | |
81 | |
82 // No copying! | |
83 | |
84 octave_oprocstream (const octave_oprocstream&); | |
85 | |
86 octave_oprocstream& operator = (const octave_oprocstream&); | |
87 }; | |
88 | |
89 #endif |