std::make_error_condition(std::io_errc)
Da cppreference.com.
|
|
Questa pagina è stata tradotta in modo automatico dalla versione in ineglese della wiki usando Google Translate.
La traduzione potrebbe contenere errori e termini strani. Muovi il puntatore sopra al testo per vedere la versione originale. Puoi aiutarci a correggere gli gli errori. Per ulteriori istruzioni clicca qui. |
<metanoindex/>
<tbody> </tbody>| Elemento definito nell'header <ios>
|
||
std::error_condition make_error_condition( std::io_errc e ); |
(dal C++11) | |
Constructs an std::error_condition object from a value of type std::io_errc as if by return std::error_condition(static_cast<int>(e), std::iostream_category()).
Parametri
| e | - | Errore di numero di codice
Original: error code number The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
Valore di ritorno
Un valore di tipo std::error_condition che contiene il numero di codice di errore da
e associata alla categoria di errore "iostream".Original:
A value of type std::error_condition that holds the error code number from
e associated with the error category "iostream".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.
Esempio
#include <iostream>
#include <system_error>
int main()
{
std::error_condition ec = std::make_error_condition(std::io_errc::stream);
std::cout << "error condition for io_errc::stream has value " << ec.value()
<< "\nand message \"" << ec.message() << "\"\n";
}
Output:
error condition for io_errc::stream has value 1
and message "unspecified iostream_category error"
Vedi anche
(C++11) |
crea un oggetto condizione di errore di error_category specificato Original: creates an error condition object of specified error_category The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (funzione) |
(C++11) |
contiene un codice di errore portatile Original: holds a portable error code The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (classe) |
(C++11) |
il flusso IO codici di errore Original: the IO stream error codes The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (enum) |