共用方式為


basic_streambuf::getloc

加入basic_streambuf物件的地區設定。

locale getloc( ) const;

傳回值

儲存的地區設定物件。

備註

如需相關資訊,請參閱 ios_base:: getloc

範例

// basic_streambuf_getloc.cpp
// compile with: /EHsc
#include <iostream>

int main( ) 
{
   using namespace std;
   cout << cout.rdbuf( )->getloc( ).name( ).c_str( ) << endl;
}
  

需求

標題: <streambuf>

命名空間: std

請參閱

參考

basic_streambuf Class

iostream 程式設計

iostreams 慣例