std::basic_stringbuf
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. |
Elemento definito nell'header <sstream> | ||
template< class charT, | ||
std::basic_stringbuf
è un std::basic_streambuf cui associata sequenza di caratteri è un residente in memoria la sequenza di caratteri arbitrari, che possono essere inizializzati o resi disponibili come istanza di std::basic_string.Original:
std::basic_stringbuf
is a std::basic_streambuf whose associated character sequence is a memory-resident sequence of arbitrary characters, which can be initialized from or made available as an instance of std::basic_string.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.
Implementazioni tipiche di
std::basic_stringbuf
in possesso di un oggetto di tipo std::basic_string direttamente come membro dati e utilizzarlo come sia la sequenza di caratteri controllata (la matrice in cui i sei indicatori di std::basic_streambuf puntano ad) e come la sequenza di caratteri associata (la fonte di caratteri per tutti operazioni di input e obiettivo per l'uscita). In aggiunta, una tipica implementazione contiene un membro dati di tipo std::ios_base::openmode per indicare lo stato del flusso (input-only, uscita solo output, o ingresso /).Original:
Typical implementations of
std::basic_stringbuf
hold an object of type std::basic_string directly as a data member and use it as both the controlled character sequence (the array where the six pointers of std::basic_streambuf are pointing to) and as the associated character sequence (the source of characters for all input operations and the target for the output). In addition, a typical implementation holds a data member of type std::ios_base::openmode to indicate the status of the stream (input-only, output-only, or input/output).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.
Due specializzazioni per i tipi di caratteri comuni sono anche definiti:
Original:
Two specializations for common character types are also 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.
Definizione nell'header <sstream> | |
Tipo 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 |
stringbuf | basic_stringbuf<char> |
wstringbuf | basic_stringbuf<wchar_t> |
[modifica]Membri tipi
Membro tipo Original: Member 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 |
traits_type | Traits |
int_type | Traits::int_type |
pos_type | Traits::pos_type |
off_type | Traits::off_type |
allocator_type | Allocator(dal C++11) |
[modifica]Membri funzioni
Original: Public member functions The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | |
costruisce un oggetto basic_stringbuf Original: constructs a basic_stringbuf object The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (metodo pubblico) | |
(C++11) | assigns a basic_stringbuf object (metodo pubblico) |
(C++11) | swap due oggetti basic_stringbuf Original: swaps two basic_stringbuf objects The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (metodo pubblico) |
(destructor) [virtuale](dichiarato in modo implicito) | destructs a basic_stringbuf object and the string it holds (metodo pubblico virtuale) |
sostituisce o ottiene una copia della stringa di caratteri associata Original: replaces or obtains a copy of the associated character string The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (metodo pubblico) | |
Original: Protected member functions The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | |
[virtuale] | restituisce il carattere successivo disponibile della sequenza di ingresso Original: returns the next character available in the input sequence The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (virtuale protetto funzione membro) |
[virtuale] | mette un carattere indietro nella sequenza di input Original: puts a character back into the input sequence The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (virtuale protetto funzione membro) |
[virtuale] | aggiunge un carattere alla sequenza di uscita Original: appends a character to the output sequence The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (virtuale protetto funzione membro) |
[virtuale] | i tentativi di sostituire la sequenza di caratteri controllata con un array Original: attempts to replace the controlled character sequence with an array The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (virtuale protetto funzione membro) |
[virtuale] | riposiziona il puntatore successivo nella sequenza di input, sequenza di emissione, o entrambi, utilizzando l'indirizzamento relativo Original: repositions the next pointer in the input sequence, output sequence, or both, using relative addressing The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (virtuale protetto funzione membro) |
[virtuale] | riposiziona il puntatore successivo nella sequenza di input, sequenza di emissione, o entrambi utilizzando indirizzamento assoluto Original: repositions the next pointer in the input sequence, output sequence, or both using absolute addressing The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (virtuale protetto funzione membro) |
[modifica]Non membri funzioni
specializzata l'algoritmo std::swap Original: specializes the std::swap algorithm The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (funzione di modello) |
Inherited from std::basic_streambuf
Member types
Membro tipo Original: Member 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 |
traits_type | Traits |
int_type | Traits::int_type |
pos_type | Traits::pos_type |
off_type | Traits::off_type |
Member functions
[virtuale] | distrugge l'oggetto basic_streambuf Original: destructs the basic_streambuf object The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (metodo pubblico virtuale) |
Original: Locales The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | |
Invoca imbue() Original: invokes imbue() The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (metodo pubblico) | |
ottiene una copia del locale associato Original: obtains a copy of the associated locale The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (metodo pubblico) | |
Original: Positioning The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | |
Invoca setbuf() Original: invokes setbuf() The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (metodo pubblico) | |
Invoca seekoff() Original: invokes seekoff() The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (metodo pubblico) | |
Invoca seekpos() Original: invokes seekpos() The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (metodo pubblico) | |
Invoca sync() Original: invokes sync() The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (metodo pubblico) | |
Original: Get area The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | |
ottiene il numero di caratteri immediatamente disponibili nella zona get Original: obtains the number of characters immediately available in the get area The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (metodo pubblico) | |
avanza la sequenza di input, quindi legge un carattere senza avanzare di nuovo Original: advances the input sequence, then reads one character without advancing again The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (metodo pubblico) | |
legge un carattere dalla sequenza di input e fa avanzare la sequenza Original: reads one character from the input sequence and advances the sequence The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (metodo pubblico) | |
stossc (deprecato) | avanza la sequenza di ingresso come se chiamando sbumpc() e scartando il risultato Original: advances the input sequence as if by calling sbumpc() and discarding the result The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (metodo pubblico) |
legge un carattere dalla sequenza di input senza avanzare la sequenza Original: reads one character from the input sequence without advancing the sequence The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (metodo pubblico) | |
Invoca xsgetn() Original: invokes xsgetn() The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (metodo pubblico) | |
Original: Put area The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | |
scrive un carattere alla zona mettere e fa avanzare il puntatore successivo Original: writes one character to the put area and advances the next pointer The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (metodo pubblico) | |
Invoca xsputn() Original: invokes xsputn() The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (metodo pubblico) | |
Original: Putback The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | |
mette un carattere indietro nella sequenza di input Original: puts one character back in the input sequence The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (metodo pubblico) | |
sposta il puntatore successivo nella sequenza di input retro di uno Original: moves the next pointer in the input sequence back by one The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (metodo pubblico) |
Protected member functions
costruisce un oggetto basic_streambuf Original: constructs a basic_streambuf object The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (protetto funzione membro) | |
(C++11) | sostituisce un oggetto basic_streambuf Original: replaces a basic_streambuf object The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (protetto funzione membro) |
(C++11) | swap due oggetti basic_streambuf Original: swaps two basic_streambuf objects The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (protetto funzione membro) |
Original: Locales The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | |
[virtuale] | cambia il linguaggio associato Original: changes the associated locale The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (virtuale protetto funzione of std::basic_streambuf membro) |
Original: Positioning The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | |
[virtuale] | sostituisce il buffer definite dall'utente matrice, se consentito Original: replaces the buffer with user-defined array, if permitted The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (virtuale protetto funzione of std::basic_streambuf membro) |
[virtuale] | riposiziona il puntatore successivo nella sequenza di input, sequenza di emissione, o entrambi, utilizzando l'indirizzamento relativo Original: repositions the next pointer in the input sequence, output sequence, or both, using relative addressing The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (virtuale protetto funzione of std::basic_streambuf membro) |
[virtuale] | riposiziona il puntatore successivo nella sequenza di input, sequenza di emissione, o entrambi utilizzando indirizzamento assoluto Original: repositions the next pointer in the input sequence, output sequence, or both using absolute addressing The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (virtuale protetto funzione of std::basic_streambuf membro) |
[virtuale] | sincronizza i buffer con la sequenza di caratteri associata Original: synchronizes the buffers with the associated character sequence The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (virtuale protetto funzione of std::basic_streambuf membro) |
Original: Get area The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | |
[virtuale] | ottiene il numero di caratteri disponibili per l'ingresso nella sequenza di input associato, se noto Original: obtains the number of characters available for input in the associated input sequence, if known The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (virtuale protetto funzione of std::basic_streambuf membro) |
[virtuale] | legge caratteri dalla sequenza di input associato alla zona get Original: reads characters from the associated input sequence to the get area The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (virtuale protetto funzione of std::basic_streambuf membro) |
[virtuale] | legge i caratteri della sequenza di input associato alla zona get e fa avanzare il puntatore successivo Original: reads characters from the associated input sequence to the get area and advances the next pointer The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (virtuale protetto funzione of std::basic_streambuf membro) |
[virtuale] | legge più caratteri dalla sequenza di input Original: reads multiple characters from the input sequence The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (virtuale protetto funzione of std::basic_streambuf membro) |
restituisce un puntatore all'inizio, carattere corrente e la fine dell'area get Original: returns a pointer to the beginning, current character and the end of the get area The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (protetto funzione membro) | |
fa avanzare il puntatore successivo nella sequenza di input Original: advances the next pointer in the input sequence The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (protetto funzione membro) | |
riposiziona puntatori l'inizio, poi, e la fine della sequenza di input Original: repositions the beginning, next, and end pointers of the input sequence The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (protetto funzione membro) | |
Original: Put area The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | |
[virtuale] | writes multiple characters to the output sequence (virtuale protetto funzione of std::basic_streambuf membro) |
[virtuale] | scrive caratteri della sequenza di emissione associato dalla zona put Original: writes characters to the associated output sequence from the put area The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (virtuale protetto funzione of std::basic_streambuf membro) |
restituisce un puntatore all'inizio, carattere corrente e la fine dell'area messo Original: returns a pointer to the beginning, current character and the end of the put area The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (protetto funzione membro) | |
avanza il puntatore successiva della sequenza di emissione Original: advances the next pointer of the output sequence The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (protetto funzione membro) | |
riposiziona puntatori l'inizio, poi, e la fine della sequenza di emissione Original: repositions the beginning, next, and end pointers of the output sequence The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (protetto funzione membro) | |
Original: Putback The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | |
[virtuale] | mette un carattere indietro nella sequenza di ingresso, eventualmente modificando la sequenza di ingresso Original: puts a character back into the input sequence, possibly modifying the input sequence The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (virtuale protetto funzione of std::basic_streambuf membro) |