名前空間
変種
操作

std::locale::id

提供: cppreference.com
< cpp‎ | locale‎ | locale

 
 
ローカライゼーションライブラリ
ロケールおよびファセット
Original:
Locales and facets
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
locale
文字分類
Original:
Character classification
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
変換
Original:
Conversions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
ファセットカテゴリの基底クラスです
Original:
Facet category base classes
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
ファセットカテゴリ
Original:
Facet categories
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
ロケール固有のファセット
Original:
Locale-specific facets
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
コー​​ド変換ファセット
Original:
Code conversion facets
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
codecvt_utf8(C++11)
codecvt_utf16(C++11)
Cロケール
Original:
C locale
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
 
std::locale
メンバータイプ
Original:
Member types
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
locale::id
locale::facet
メンバ関数
Original:
Member functions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
locale::locale
locale::~locale
locale::operator=
locale::combine
locale::name
locale::operator==
locale::operator!=
locale::operator()
静的メンバ関数
Original:
Static member functions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
locale::global
locale::classic
 
Defined in header <locale>
class locale::id;
クラスstd::locale::idは、ロケールファセットの実装固有の識別を提供します。 std::locale::facetから派生した各クラスは、型std::locale::idのpublic staticメンバを持っている必要があり、各std::localeオブジェクトはそれらのidsによって索引をつけられて、それが実装するファセットのリストを保持してい.
Original:
The class std::locale::id provides implementation-specific identification of a locale facet. Each class derived from std::locale::facet must have a public static member of type std::locale::id and each std::locale object maintains a list of facets it implements, indexed by their ids.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

[編集] メンバ関数

新しいIDを作成します
Original:
constructs a new id
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(パブリックメンバ関数)
operator=
コピー代入演算子が削除されます
Original:
copy assignment operator is deleted
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(パブリックメンバ関数)

[編集]

次の例では、最小限のカスタムファセットを構築する方法を示しています。.
Original:
The following example shows how to construct a minimal custom facet.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

#include <iostream>
#include <locale>
#include <iostream>
#include <locale>
 
struct myfacet : std::locale::facet
{
    myfacet(std::size_t refs=0) : facet(refs) {}
    static std::locale::id id;
};
 
std::locale::id myfacet::id;
 
int main()
{
    std::locale myloc(std::locale(), new myfacet);
    std::cout << "has_facet<myloc, myfacet> returns " << std::boolalpha
              << std::has_facet<myfacet>(myloc) << '\n';
}

Output:

has_facet<myloc, myfacet> returns true

[編集] も参照してください

すべてのファセットカテゴリの基底クラス:いずれかのカテゴリの各ファセットは、この型から派生しています
Original:
the base class for all facet categories: each facet of any category is derived from this type
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(クラス) [edit]