[ Web Proxy ]
URL:
Viewing: https://fr.cppreference.com/cpp/string/multibyte [Back]  [Original]

Null-terminated multibyte strings cppreference.com
cppreference.com
Espaces de noms
Variantes

Null-terminated multibyte strings

De cppreference.com
 
 
Bibliothque de chanes de caractres
Chanes zro terminal
Original:
Null-terminated strings
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Les chanes d'octets
Chaines multi-octets
Les chanes tendues
Classes
Original:
Classes
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
basic_string
char_traits
 
Chanes zro terminal multi-octets
Large / multi-octets conversions
Original:
Wide/multibyte conversions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
mbsinit
Types
Original:
Types
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
mbstate_t
 

Une chane multi-octets termine par NUL ( NUL terminated multi-byte string , ou NTMBS), ou simplement  chane multi-octets , est une squence d'octets non nuls suivi par un octet de valeur zro (le caractre NUL final).

Chaque caractre stock dans la chane peut occuper plus d'un octet. Le codage utilis pour reprsenter les caractres dans une chane de caractres multi-octets est spcifique aux paramtres rgionaux : il peut tre UTF-8, GB18030, EUC-JP, Shift-JIS, etc. Par exemple, le tableau de caractres {'\xe4','\xbd','\xa0','\xe5','\xa5','\xbd','\0'} est un NTMBS contenant la chane en encodage UTF-8 multi-octets : les trois premiers octets codent le caractre   , les trois octets suivants encodent le caractre   . La mme chane code en GB18030 est le tableau de caractres {'\xc4', '\xe3', '\xba', '\xc3', '\0'}, o chacun des deux caractres est cod en tant que squence de deux octets.

Dans certains encodages multi-octets, une squence de caractres multi-octets donne peut reprsenter des caractres diffrents selon la squence d'octets prcdents, appele  squence de dcalage . Ce type d'encodage est connu comme dpendant de l'tat : la connaissance de l'tat de dcalage courant est ncessaire pour interprter chaque caractre. Une NTMBS n'est alors valide que si elle commence et se termine dans l'tat initial : si une squence de dcalage a t utilise, la squence de dcalage inverse correspondante doit tre prsente avant le caractre nul final. Des exemples de ces codages sont les JIS 7-bits, BOCU-1 et SCSU.

Une chane de caractres multi-octets est compatible avec la disposition chane d'octets termine par NULL (NTBS), c'est--dire peut tre stocke, copie, et manpule en utilisant les mmes oprations, sauf pour le calcul du nombre de caractres. Si les paramtres rgionaux corrects sont en vigueur, les fonctions d'entre/sortie grent les chanes multi-octets. Les chanes multi-octets peuvent tre converties en des chanes tendues l'aide des fonctions membres, std::codecvt, std::wstring_convert, ou les fonctions suivantes de conversion dpendant des paramtres rgionaux :

Multi-octets / conversions de caractres larges

Defined in header <cstdlib>
renvoie le nombre d'octets dans le prochain caractre multi-octets
Original:
returns the number of bytes in the next multibyte character
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(fonction) [edit]
convertit le caractre multi-octets suivante de caractres larges
Original:
converts the next multibyte character to wide character
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(fonction) [edit]
convertit le caractre large de sa reprsentation multi-octets
Original:
converts a wide character to its multibyte representation
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(fonction) [edit]
convertit une chane de caractres multi-octets en une chane de caractre troit de large
Original:
converts a narrow multibyte character string to wide string
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(fonction) [edit]
convertit une chane large pour rduire chane de caractres multi-octets
Original:
converts a wide string to narrow multibyte 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) [edit]
Defined in header <cwchar>
Vrifie si l'objet mbstate_t reprsente tat initial
Original:
checks if the mbstate_t object represents initial shift state
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(fonction) [edit]
largit un caractre simple octet troite pour les caractres larges, si possible
Original:
widens a single-byte narrow character to wide character, if possible
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(fonction) [edit]
rtrcit un caractre large un caractre sur un octet troit, si possible
Original:
narrows a wide character to a single-byte narrow character, if possible
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(fonction) [edit]
renvoie le nombre d'octets dans le prochain caractre multi-octets, tat donn
Original:
returns the number of bytes in the next multibyte character, given state
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(fonction) [edit]
convertit le caractre multi-octets suivante caractre large, tat donn
Original:
converts the next multibyte character to wide character, given state
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(fonction) [edit]
convertit le caractre large de sa reprsentation multi-octets, tat donn
Original:
converts a wide character to its multibyte representation, given state
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(fonction) [edit]
convertit une chane de caractres multi-octets en une chane de caractre troit de large, tat donn
Original:
converts a narrow multibyte character string to wide string, given state
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(fonction) [edit]
convertit une chane large de chane de caractres multi-octets troite, tat donn
Original:
converts a wide string to narrow multibyte character string, given state
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(fonction) [edit]
Defined in header <cuchar>
(C++11)
gnrer le prochain 16-bits pour les caractres larges partir d'une chane multi-octets troite
Original:
generate the next 16-bit wide character from a narrow multibyte string
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(fonction) [edit]
(C++11)
convertir un caractre large de 16 bits pour affiner chane multi-octets
Original:
convert a 16-bit wide character to narrow multibyte string
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(fonction) [edit]
(C++11)
gnrer le prochain 32-bit caractre large depuis une chane multi troite
Original:
generate the next 32-bit wide character from a narrow multibyte string
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(fonction) [edit]
(C++11)
convertir un caractre de 32 bits de large pour rduire chane multi-octets
Original:
convert a 32-bit wide character to narrow multibyte string
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(fonction) [edit]

Types

Defined in header <cwchar>
informations sur l'tat de conversion ncessaire pour parcourir les chanes de caractres multi-octets
Original:
conversion state information necessary to iterate multibyte character strings
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(classe) [edit]

Macros

Defined in header <climits>
MB_LEN_MAX
nombre maximal d'octets dans un caractre multi-octets
Original:
maximum number of bytes in a multibyte character
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(constante macro) [edit]
Defined in header <cstdlib>
MB_CUR_MAX
nombre maximal d'octets dans un caractre multi-octets dans le courant C locale
(
variable de macro
Original:
macro variable
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
)
Original:
maximum number of bytes in a multibyte character in the current C locale
(
variable de macro
Original:
macro variable
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
)
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
[edit]
Defined in header <cuchar>
__STDC_UTF_16__
indique que l'encodage UTF-16 est utilis par mbrtoc16 et c16rtomb
(constante macro)
__STDC_UTF_32__
indique que l'encodage UTF-32 est utilis par mbrtoc32 et c32rtomb
(constante macro)

Web Proxy Viewer  |  New URL  |  Original Page