Stream.h
1 /*
2  * Medical Image Registration ToolKit (MIRTK)
3  *
4  * Copyright 2013-2015 Imperial College London
5  * Copyright 2013-2015 Andreas Schuh
6  *
7  * Licensed under the Apache License, Version 2.0 (the "License");
8  * you may not use this file except in compliance with the License.
9  * You may obtain a copy of the License at
10  *
11  * http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing, software
14  * distributed under the License is distributed on an "AS IS" BASIS,
15  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16  * See the License for the specific language governing permissions and
17  * limitations under the License.
18  */
19 
20 #ifndef MIRTK_Stream_H
21 #define MIRTK_Stream_H
22 
23 // Import common C/C++ library stream functions/types into mirtk namespace
24 // such that they can be used within this namespace without std:: prefix
25 
26 #include <iostream>
27 #include <iomanip>
28 #include <fstream>
29 #include <sstream>
30 
31 namespace mirtk {
32 
33 using std::ios;
34 using std::ios_base;
35 using std::getline;
36 
37 // Input streams
38 using std::istream;
39 using std::ifstream;
40 using std::istringstream;
41 
42 // Output streams
43 using std::ostream;
44 using std::ofstream;
45 using std::ostringstream;
46 using std::cin;
47 using std::cout;
48 using std::cerr;
49 using std::flush;
50 
51 // Bidirectional stream
52 using std::iostream;
53 using std::stringstream;
54 
55 // Output manipulators
56 using std::streamsize;
57 using std::setw;
58 using std::setprecision;
59 using std::left;
60 using std::right;
61 using std::fixed;
62 using std::scientific;
63 using std::endl;
64 
65 
66 } // namespace mirtk
67 
68 #endif // MIRTK_Stream_H
Definition: IOConfig.h:41