cplusplus
.com
教程
參考
文章
論壇
C++
教程
參考
文章
論壇
參考
C 庫
<cassert> (assert.h)
<cctype> (ctype.h)
<cerrno> (errno.h)
C++11
<cfenv> (fenv.h)
<cfloat> (float.h)
C++11
<cinttypes> (inttypes.h)
<ciso646> (iso646.h)
<climits> (limits.h)
<clocale> (locale.h)
<cmath> (math.h)
<csetjmp> (setjmp.h)
<csignal> (signal.h)
<cstdarg> (stdarg.h)
C++11
<cstdbool> (stdbool.h)
<cstddef> (stddef.h)
C++11
<cstdint> (stdint.h)
<cstdio> (stdio.h)
<cstdlib> (stdlib.h)
<cstring> (string.h)
C++11
<ctgmath> (tgmath.h)
<ctime> (time.h)
C++11
<cuchar> (uchar.h)
<cwchar> (wchar.h)
<cwctype> (wctype.h)
容器
C++11
<array>
<deque>
C++11
<forward_list>
<list>
<map>
<queue>
<set>
<stack>
C++11
<unordered_map>
C++11
<unordered_set>
<vector>
輸入/輸出
<fstream>
<iomanip>
<ios>
<iosfwd>
<iostream>
<istream>
<ostream>
<sstream>
<streambuf>
多執行緒
C++11
<atomic>
C++11
<condition_variable>
C++11
<future>
C++11
<mutex>
C++11
<thread>
其他
<algorithm>
<bitset>
C++11
<chrono>
C++11
<codecvt>
<complex>
<exception>
<functional>
C++11
<initializer_list>
<iterator>
<limits>
<locale>
<memory>
<new>
<numeric>
C++11
<random>
C++11
<ratio>
C++11
<regex>
<stdexcept>
<string>
C++11
<system_error>
C++11
<tuple>
C++11
<type_traits>
C++11
<typeindex>
<typeinfo>
<utility>
<valarray>
<iostream>
物件
、cerr
cin
、clog
、cout
、wcerr
wcin
、wclog
、wcout
參考
<iostream>
、wclog
物件
<iostream>
std::
wclog
extern basic_ostream<wchar_t> wclog;
用於日誌記錄的標準輸出流(寬字元)
類
wostream
的物件,代表面向寬字元(型別為
wchar_t
)的
標準日誌流
。它與
wcerr
一起對應於
C流
stderr
。
標準日誌流
是由環境確定的字元目標。此目標可能由多個標準物件(例如
wcout
或
wcerr
)共享。
作為
basic_ostream
類的物件,可以透過插入運算子(
operator<<
)以格式化資料的方式,或使用
write
等成員函式以非格式化資料的方式向其寫入字元。
該物件在標頭檔案
<iostream>
中宣告,具有
外部連結
和
靜態儲存期
:它在程式的整個生命週期內都存在。
就
靜態初始化順序
而言,
wclog
保證在
ios_base::Init
型別物件的第一次構造時或之前被正確構造和初始化。
就
靜態初始化順序
而言,
wclog
保證在
ios_base::Init
型別物件的第一次構造時或之前被正確構造和初始化,其中包含
<iostream>
就至少一次具有
靜態儲存期
的物件初始化。
wclog
未
繫結
到任何其他流(參見
basic_ios::tie
)。
預設情況下,
clog
與
stderr
同步(參見
ios_base::sync_with_stdio
)。
程式不應將
wclog
上的輸出操作與
clog
或
cerr
上的輸出操作(或與
stderr
上的其他窄方向輸出操作)混合:一旦在任一上執行了輸出操作,
標準日誌流
就會獲得一個方向(
窄
或
寬
),該方向只能透過對
stderr
呼叫
freopen
來安全地更改。
有關
wclog
支援的操作的更多資訊,請參見其型別的參考:
basic_ostream
。
另見
ostream
輸出流
(類)
、clog
標準日誌輸出流
(物件)
、wcout
標準輸出流 (寬)
(物件)
、wcerr
標準錯誤輸出流 (寬字元)
(物件)
wcin
標準輸入流 (寬)
(物件)