[#bsl-basic_istringstream-getline-04] = xref:bsl.adoc[bsl]::xref:bsl/basic_istringstream.adoc[basic_istringstream]::getline :relfileprefix: ../../ :mrdocs: String extraction. == Synopsis Declared in `<bslstl_istringstream.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- __istream_type& getline( char_type* __s, streamsize __n, char_type __delim); ---- == Description Extracts and stores characters into ___s_ until one of the following happens. Note that these criteria are required to be tested in the order listed here, to allow an input line to exactly fill the ___s_ array without setting failbit. ‐# the input sequence reaches end‐of‐file, in which case eofbit is set in the stream error state ‐# the next character equals `__delim,` in which case the character is extracted (and therefore counted in `gcount())` but not stored ‐# `__n‐1` characters are stored, in which case failbit is set in the stream error state If no characters are extracted, failbit is set. (An empty line of input should therefore not cause failbit to be set.) In any case, a null character is stored in the next location in the array. == Return Value *this == Parameters [cols="1,4"] |=== | Name| Description | *__s* | A character array in which to store the data. | *__n* | Maximum number of characters to extract. | *__delim* | A "stop" character. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#