Subversion Repositories Kolibri OS

Rev

Go to most recent revision | Blame | Last modification | View Log | RSS feed

  1. /*      Copyright (C) 2004 Garrett A. Kajmowicz
  2.  
  3.         This file is part of the uClibc++ Library.
  4.  
  5.         This library is free software; you can redistribute it and/or
  6.         modify it under the terms of the GNU Lesser General Public
  7.         License as published by the Free Software Foundation; either
  8.         version 2.1 of the License, or (at your option) any later version.
  9.  
  10.         This library is distributed in the hope that it will be useful,
  11.         but WITHOUT ANY WARRANTY; without even the implied warranty of
  12.         MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  13.         Lesser General Public License for more details.
  14.  
  15.         You should have received a copy of the GNU Lesser General Public
  16.         License along with this library; if not, write to the Free Software
  17.         Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
  18. */
  19.  
  20. #include <basic_definitions>
  21.  
  22. #ifndef __HEADER_STD_IOSTREAM
  23. #define __HEADER_STD_IOSTREAM 1
  24.  
  25. #include <iosfwd>
  26. #include <ios>
  27. #include <istream>
  28. #include <ostream>
  29. #include <fstream>
  30. #include <string_iostream>
  31.  
  32. #pragma GCC visibility push(default)
  33.  
  34. namespace std{
  35. #ifdef __UCLIBCXX_SUPPORT_CIN__
  36.         extern istream cin;
  37. #endif
  38. #ifdef __UCLIBCXX_SUPPORT_COUT__
  39.         extern ostream cout;
  40. #endif
  41. #ifdef __UCLIBCXX_SUPPORT_CERR__
  42.         extern ostream cerr;
  43. #endif
  44. #ifdef __UCLIBCXX_SUPPORT_CLOG__
  45.         extern ostream clog;
  46. #endif
  47. #ifdef __UCLIBCXX_SUPPORT_WCIN__
  48.         extern wistream wcin;
  49. #endif
  50. #ifdef __UCLIBCXX_SUPPORT_WCOUT__
  51.         extern wostream wcout;
  52. #endif
  53. #ifdef __UCLIBCXX_SUPPORT_WCERR__
  54.         extern wostream wcerr;
  55. #endif
  56. #ifdef __UCLIBCXX_SUPPORT_WCLOG__
  57.         extern wostream wclog;
  58. #endif
  59.  
  60.  
  61.         template <class charT, class traits> class _UCXXEXPORT basic_iostream :
  62.                 public basic_istream<charT,traits>, public basic_ostream<charT,traits>
  63.         {
  64.         public:
  65.                 // constructor/destructor
  66.                 explicit _UCXXEXPORT basic_iostream(basic_streambuf<charT,traits>* sb);
  67.                 virtual _UCXXEXPORT ~basic_iostream();  //Below
  68.         };
  69.  
  70.         template <class charT, class traits> _UCXXEXPORT
  71.                 basic_iostream<charT, traits>:: basic_iostream(basic_streambuf<charT,traits>* sb)
  72.                 : basic_ios<charT, traits>(sb), basic_istream<charT,traits>(sb), basic_ostream<charT,traits>(sb)
  73.         {
  74.                 return;
  75.         }
  76.  
  77.  
  78.         template <class charT, class traits> _UCXXEXPORT basic_iostream<charT, traits>::~basic_iostream(){
  79.                 return;
  80.         }
  81.  
  82.  
  83. #ifdef __UCLIBCXX_EXPAND_OSTREAM_CHAR__
  84. #ifdef __UCLIBCXX_EXPAND_ISTREAM_CHAR__
  85. #ifndef __UCLIBCXX_COMPILE_IOSTREAM__
  86.  
  87.         template <> _UCXXEXPORT basic_iostream<char, char_traits<char> >::
  88.                 basic_iostream(basic_streambuf<char, char_traits<char> >* sb);
  89.         template <> _UCXXEXPORT basic_iostream<char, char_traits<char> >::~basic_iostream();
  90.  
  91. #endif
  92. #endif
  93. #endif
  94.  
  95.  
  96.  
  97. }
  98.  
  99. #pragma GCC visibility pop
  100.  
  101. #endif
  102.