std::wscanf, std::fwscanf, std::swscanf
来自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. |
| Defined in header <cwchar>
|
||
| int wscanf( const wchar_t* format, ... ); |
(1) | (C++11 起) |
| int fwscanf( FILE *stream, const wchar_t* format, ... ); |
(2) | (C++11 起) |
| int swscanf( const wchar_t* buffer, const wchar_t* format, ... ); |
(3) | (C++11 起) |
从各种来源中读取数据,解释它根据
format,并将结果存储到特定地点.....Original:
Reads data from the a variety of sources, interprets it according to
format and stores the results into given locations.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.
1)
读取的数据stdin.
Original:
Reads the data from stdin.
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.
2)
读取文件中的数据流
stream.Original:
Reads the data from file stream
stream.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.
3)
读取数据从NULL结尾的宽字符串
buffer.Original:
Reads the data from null-terminated wide string
buffer.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.
目录 |
[编辑] 参数
| stream | - | 输入文件流中读取
Original: input file stream to read from The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | ||||
| buffer | - | 指针指向一个空结尾的宽字符串读取
Original: pointer to a null-terminated wide string to read from The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | ||||
| format | - | 指定如何读取输入一个空结尾的宽字符串的指针指向。
Original: pointer to a null-terminated wide string specifying how to read the input.
The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | ||||
| ... | - | 接收参数
Original: receiving arguments The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
[编辑] 返回值
成功读取的参数个数,或EOF如果发生故障之前,先接收参数被分配.
Original:
Number of arguments successfully read, or EOF if failure occurs before the first receiving argument was assigned.
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.
[编辑] 为例
| 本节是不完整的 原因: no example |
[编辑] 另请参阅
| (C++11) (C++11) (C++11) |
stdin,的文件stream 或使用可变参数列表的缓冲区读取格式的宽字符输入 Original: reads formatted wide character input from stdin, a file stream or a buffer using variable argument list The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (函数) |
| C documentation for wscanf, fwscanf, swscanf
| |