williamr@4
|
1 |
#ifndef _STLP_INTERNAL_IOSFWD
|
williamr@4
|
2 |
#define _STLP_INTERNAL_IOSFWD
|
williamr@4
|
3 |
|
williamr@4
|
4 |
#if defined (__sgi) && !defined (__GNUC__) && !defined (_STANDARD_C_PLUS_PLUS)
|
williamr@4
|
5 |
# error This header file requires the -LANG:std option
|
williamr@4
|
6 |
#endif
|
williamr@4
|
7 |
|
williamr@4
|
8 |
// This file provides forward declarations of the most important I/O
|
williamr@4
|
9 |
// classes. Note that almost all of those classes are class templates,
|
williamr@4
|
10 |
// with default template arguments. According to the C++ standard,
|
williamr@4
|
11 |
// if a class template is declared more than once in the same scope
|
williamr@4
|
12 |
// then only one of those declarations may have default arguments.
|
williamr@4
|
13 |
|
williamr@4
|
14 |
// <iosfwd> contains the same declarations as other headers, and including
|
williamr@4
|
15 |
// both <iosfwd> and (say) <iostream> is permitted. This means that only
|
williamr@4
|
16 |
// one header may contain those default template arguments.
|
williamr@4
|
17 |
|
williamr@4
|
18 |
// In this implementation, the declarations in <iosfwd> contain default
|
williamr@4
|
19 |
// template arguments. All of the other I/O headers include <iosfwd>.
|
williamr@4
|
20 |
|
williamr@4
|
21 |
#ifndef _STLP_CHAR_TRAITS_H
|
williamr@4
|
22 |
# include <stl/char_traits.h>
|
williamr@4
|
23 |
#endif
|
williamr@4
|
24 |
|
williamr@4
|
25 |
_STLP_BEGIN_NAMESPACE
|
williamr@4
|
26 |
|
williamr@4
|
27 |
class ios_base;
|
williamr@4
|
28 |
|
williamr@4
|
29 |
template <class _CharT, _STLP_DFL_TMPL_PARAM(_Traits , char_traits<_CharT>) >
|
williamr@4
|
30 |
class basic_ios;
|
williamr@4
|
31 |
|
williamr@4
|
32 |
template <class _CharT, _STLP_DFL_TMPL_PARAM(_Traits , char_traits<_CharT>) >
|
williamr@4
|
33 |
class basic_streambuf;
|
williamr@4
|
34 |
|
williamr@4
|
35 |
template <class _CharT, _STLP_DFL_TMPL_PARAM(_Traits , char_traits<_CharT>) >
|
williamr@4
|
36 |
class basic_istream;
|
williamr@4
|
37 |
|
williamr@4
|
38 |
template <class _CharT, _STLP_DFL_TMPL_PARAM(_Traits , char_traits<_CharT>) >
|
williamr@4
|
39 |
class basic_ostream;
|
williamr@4
|
40 |
|
williamr@4
|
41 |
template <class _CharT, _STLP_DFL_TMPL_PARAM(_Traits , char_traits<_CharT>) >
|
williamr@4
|
42 |
class basic_iostream;
|
williamr@4
|
43 |
|
williamr@4
|
44 |
template <class _CharT, _STLP_DFL_TMPL_PARAM( _Traits , char_traits<_CharT>),
|
williamr@4
|
45 |
_STLP_DFL_TMPL_PARAM(_Allocator , allocator<_CharT>) >
|
williamr@4
|
46 |
class basic_stringbuf;
|
williamr@4
|
47 |
|
williamr@4
|
48 |
template <class _CharT, _STLP_DFL_TMPL_PARAM(_Traits , char_traits<_CharT>),
|
williamr@4
|
49 |
_STLP_DFL_TMPL_PARAM(_Allocator , allocator<_CharT>) >
|
williamr@4
|
50 |
class basic_istringstream;
|
williamr@4
|
51 |
|
williamr@4
|
52 |
template <class _CharT, _STLP_DFL_TMPL_PARAM(_Traits , char_traits<_CharT>),
|
williamr@4
|
53 |
_STLP_DFL_TMPL_PARAM(_Allocator , allocator<_CharT>) >
|
williamr@4
|
54 |
class basic_ostringstream;
|
williamr@4
|
55 |
|
williamr@4
|
56 |
template <class _CharT, _STLP_DFL_TMPL_PARAM(_Traits , char_traits<_CharT>),
|
williamr@4
|
57 |
_STLP_DFL_TMPL_PARAM(_Allocator , allocator<_CharT>) >
|
williamr@4
|
58 |
class basic_stringstream;
|
williamr@4
|
59 |
|
williamr@4
|
60 |
template <class _CharT, _STLP_DFL_TMPL_PARAM(_Traits , char_traits<_CharT>) >
|
williamr@4
|
61 |
class basic_filebuf;
|
williamr@4
|
62 |
|
williamr@4
|
63 |
template <class _CharT, _STLP_DFL_TMPL_PARAM(_Traits , char_traits<_CharT>) >
|
williamr@4
|
64 |
class basic_ifstream;
|
williamr@4
|
65 |
|
williamr@4
|
66 |
template <class _CharT, _STLP_DFL_TMPL_PARAM(_Traits , char_traits<_CharT>) >
|
williamr@4
|
67 |
class basic_ofstream;
|
williamr@4
|
68 |
|
williamr@4
|
69 |
template <class _CharT, _STLP_DFL_TMPL_PARAM(_Traits , char_traits<_CharT>) >
|
williamr@4
|
70 |
class basic_fstream;
|
williamr@4
|
71 |
|
williamr@4
|
72 |
template <class _CharT, _STLP_DFL_TMPL_PARAM(_Traits , char_traits<_CharT>) >
|
williamr@4
|
73 |
class istreambuf_iterator;
|
williamr@4
|
74 |
|
williamr@4
|
75 |
template <class _CharT, _STLP_DFL_TMPL_PARAM(_Traits , char_traits<_CharT>) >
|
williamr@4
|
76 |
class ostreambuf_iterator;
|
williamr@4
|
77 |
|
williamr@4
|
78 |
typedef basic_ios<char, char_traits<char> > ios;
|
williamr@4
|
79 |
|
williamr@4
|
80 |
#if !defined (_STLP_NO_WCHAR_T)
|
williamr@4
|
81 |
typedef basic_ios<wchar_t, char_traits<wchar_t> > wios;
|
williamr@4
|
82 |
#endif
|
williamr@4
|
83 |
|
williamr@4
|
84 |
// Forward declaration of class locale, and of the most important facets.
|
williamr@4
|
85 |
class locale;
|
williamr@4
|
86 |
#if defined (_STLP_NO_EXPLICIT_FUNCTION_TMPL_ARGS)
|
williamr@4
|
87 |
template <class _Facet>
|
williamr@4
|
88 |
struct _Use_facet {
|
williamr@4
|
89 |
const locale& __loc;
|
williamr@4
|
90 |
_Use_facet(const locale& __p_loc) : __loc(__p_loc) {}
|
williamr@4
|
91 |
inline const _Facet& operator *() const;
|
williamr@4
|
92 |
};
|
williamr@4
|
93 |
# define use_facet *_Use_facet
|
williamr@4
|
94 |
#else
|
williamr@4
|
95 |
template <class _Facet> inline const _Facet& use_facet(const locale&);
|
williamr@4
|
96 |
#endif
|
williamr@4
|
97 |
|
williamr@4
|
98 |
template <class _CharT> class ctype;
|
williamr@4
|
99 |
template <class _CharT> class ctype_byname;
|
williamr@4
|
100 |
template <class _CharT> class collate;
|
williamr@4
|
101 |
template <class _CharT> class collate_byname;
|
williamr@4
|
102 |
|
williamr@4
|
103 |
_STLP_TEMPLATE_NULL class _STLP_CLASS_DECLSPEC ctype<char>;
|
williamr@4
|
104 |
_STLP_TEMPLATE_NULL class _STLP_CLASS_DECLSPEC ctype_byname<char>;
|
williamr@4
|
105 |
_STLP_TEMPLATE_NULL class _STLP_CLASS_DECLSPEC collate<char>;
|
williamr@4
|
106 |
_STLP_TEMPLATE_NULL class _STLP_CLASS_DECLSPEC collate_byname<char>;
|
williamr@4
|
107 |
|
williamr@4
|
108 |
#if !defined (_STLP_NO_WCHAR_T)
|
williamr@4
|
109 |
_STLP_TEMPLATE_NULL class _STLP_CLASS_DECLSPEC ctype<wchar_t>;
|
williamr@4
|
110 |
_STLP_TEMPLATE_NULL class _STLP_CLASS_DECLSPEC ctype_byname<wchar_t>;
|
williamr@4
|
111 |
_STLP_TEMPLATE_NULL class _STLP_CLASS_DECLSPEC collate<wchar_t>;
|
williamr@4
|
112 |
_STLP_TEMPLATE_NULL class _STLP_CLASS_DECLSPEC collate_byname<wchar_t>;
|
williamr@4
|
113 |
#endif
|
williamr@4
|
114 |
|
williamr@4
|
115 |
#if !(defined (__SUNPRO_CC) && __SUNPRO_CC < 0x500 )
|
williamr@4
|
116 |
// Typedefs for ordinary (narrow-character) streams.
|
williamr@4
|
117 |
//_STLP_TEMPLATE_NULL class _STLP_CLASS_DECLSPEC basic_streambuf<char, char_traits<char> >;
|
williamr@4
|
118 |
#endif
|
williamr@4
|
119 |
|
williamr@4
|
120 |
typedef basic_istream<char, char_traits<char> > istream;
|
williamr@4
|
121 |
typedef basic_ostream<char, char_traits<char> > ostream;
|
williamr@4
|
122 |
typedef basic_iostream<char, char_traits<char> > iostream;
|
williamr@4
|
123 |
typedef basic_streambuf<char,char_traits<char> > streambuf;
|
williamr@4
|
124 |
|
williamr@4
|
125 |
typedef basic_stringbuf<char, char_traits<char>, allocator<char> > stringbuf;
|
williamr@4
|
126 |
typedef basic_istringstream<char, char_traits<char>, allocator<char> > istringstream;
|
williamr@4
|
127 |
typedef basic_ostringstream<char, char_traits<char>, allocator<char> > ostringstream;
|
williamr@4
|
128 |
typedef basic_stringstream<char, char_traits<char>, allocator<char> > stringstream;
|
williamr@4
|
129 |
|
williamr@4
|
130 |
typedef basic_filebuf<char, char_traits<char> > filebuf;
|
williamr@4
|
131 |
typedef basic_ifstream<char, char_traits<char> > ifstream;
|
williamr@4
|
132 |
typedef basic_ofstream<char, char_traits<char> > ofstream;
|
williamr@4
|
133 |
typedef basic_fstream<char, char_traits<char> > fstream;
|
williamr@4
|
134 |
|
williamr@4
|
135 |
#if !defined (_STLP_NO_WCHAR_T)
|
williamr@4
|
136 |
// Typedefs for wide-character streams.
|
williamr@4
|
137 |
typedef basic_streambuf<wchar_t, char_traits<wchar_t> > wstreambuf;
|
williamr@4
|
138 |
typedef basic_istream<wchar_t, char_traits<wchar_t> > wistream;
|
williamr@4
|
139 |
typedef basic_ostream<wchar_t, char_traits<wchar_t> > wostream;
|
williamr@4
|
140 |
typedef basic_iostream<wchar_t, char_traits<wchar_t> > wiostream;
|
williamr@4
|
141 |
|
williamr@4
|
142 |
typedef basic_stringbuf<wchar_t, char_traits<wchar_t>, allocator<wchar_t> > wstringbuf;
|
williamr@4
|
143 |
typedef basic_istringstream<wchar_t, char_traits<wchar_t>, allocator<wchar_t> > wistringstream;
|
williamr@4
|
144 |
typedef basic_ostringstream<wchar_t, char_traits<wchar_t>, allocator<wchar_t> > wostringstream;
|
williamr@4
|
145 |
typedef basic_stringstream<wchar_t, char_traits<wchar_t>, allocator<wchar_t> > wstringstream;
|
williamr@4
|
146 |
|
williamr@4
|
147 |
typedef basic_filebuf<wchar_t, char_traits<wchar_t> > wfilebuf;
|
williamr@4
|
148 |
typedef basic_ifstream<wchar_t, char_traits<wchar_t> > wifstream;
|
williamr@4
|
149 |
typedef basic_ofstream<wchar_t, char_traits<wchar_t> > wofstream;
|
williamr@4
|
150 |
typedef basic_fstream<wchar_t, char_traits<wchar_t> > wfstream;
|
williamr@4
|
151 |
#endif
|
williamr@4
|
152 |
|
williamr@4
|
153 |
_STLP_END_NAMESPACE
|
williamr@4
|
154 |
|
williamr@4
|
155 |
#endif
|
williamr@4
|
156 |
|
williamr@4
|
157 |
// Local Variables:
|
williamr@4
|
158 |
// mode:C++
|
williamr@4
|
159 |
// End:
|