std::regex_traits
De cppreference.com
![]() | This page has been machine-translated from the English version of the wiki using Google Translate. The translation may contain errors and awkward wording. Hover over text to see the original version. You can help to fix errors and improve the translation. For instructions click here. |
Déclaré dans l'en-tête <regex> | ||
template<class CharT > class regex_traits; | (depuis C++11) | |
Le modèle type de trait
regex_traits
fournitures std::basic_regex avec l'ensemble des types et des fonctions nécessaires pour opérer sur le CharT
type .Original:
The type trait template
regex_traits
supplies std::basic_regex with the set of types and functions necessary to operate on the type CharT
.The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
Comme un grand nombre d'opérations de regex sont sensibles aux paramètres régionaux (lorsque l'indicateur est réglé std::regex_constants::collate), la classe regex_traits détient généralement une instance d'une std::locale en tant que membre privé .
Original:
Since many of regex operations are locale-sensitive (when std::regex_constants::collate flag is set), the regex_traits class typically holds an instance of a std::locale as a private member.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
[modifier]Spécialisations standard
Deux spécialisations de
std::regex_traits
sont définies par la bibliothèque standard:Original:
Two specializations of
std::regex_traits
are defined by the standard library:The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
std::regex_traits<char> | |
std::regex_traits<wchar_t> |
Ces spécialisations permettent d'utiliser std::basic_regex<char> (aka std::regex) et std::basic_regex<wchar_t> (aka std::wregex), mais dans le but d'utiliser, par exemple, std::basic_regex<char32_t>, fourni par l'utilisateur std::regex_traits<char32_t> specializtion doit être défini .
Original:
These specializations make it possible to use std::basic_regex<char> (aka std::regex) and std::basic_regex<wchar_t> (aka std::wregex), but in order to use, for example, std::basic_regex<char32_t>, user-provided specializtion std::regex_traits<char32_t> needs to be defined.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
[modifier]Types de membres
Type d' Original: Type The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | Definition |
char_type | CharT |
string_type | std::basic_string<CharT> |
locale_type | Les paramètres régionaux utilisés pour comportement localisé dans l'expression régulière. Doit être CopyConstructible Original: The locale used for localized behavior in the regular expression. Must be CopyConstructible The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
char_class_type | Représente une classification de caractères et est capable de contenir un ensemble spécifique renvoyé par la mise en oeuvre lookup_classname . Doit être un BitmaskType .Original: Represents a character classification and is capable of holding an implementation specific set returned by lookup_classname . Must be a BitmaskType .The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
[modifier]Fonctions membres
construit l'objet regex_traits Original: constructs the regex_traits object The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction membre publique) | |
[ statique ]Original: static The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | calcule la longueur d'une chaîne de caractères à zéro terminal Original: calculates the length of a null-terminated character string The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction membre publique statique) |
détermine la clé de l'équivalence d'un caractère Original: determines the equivalence key for a character The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction membre publique) | |
détermine la clé de la casse d'équivalence pour un caractère Original: determines the case-insensitive equivalence key for a character The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction membre publique) | |
détermine la clé de tri pour la chaîne donnée, utilisé pour fournir ordre de classement Original: determines the sort key for the given string, used to provide collation order The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction membre publique) | |
détermine la clé de tri primaire de la séquence de caractères, permet de déterminer la classe d'équivalence Original: determines the primary sort key for the character sequence, used to determine equivalence class The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction membre publique) | |
devient un élément de classement par nom Original: gets a collation element by name The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction membre publique) | |
obtient une classe de caractères par nom Original: gets a character class by name The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction membre publique) | |
indique l'appartenance à une classe de caractères localisée Original: indicates membership in a localized character class The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction membre publique) | |
traduit le caractère représentant un caractère numérique en une valeur entière Original: translates the character representing a numeric digit into an integral value The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction membre publique) | |
définit les paramètres régionaux Original: sets the locale The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction membre publique) | |
obtient les paramètres régionaux Original: gets the locale The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (fonction membre publique) |