Go forward to Istream Housekeeping.
Go backward to String Input.
Go up to Istream.
Repositioning an `istream'
--------------------------
Use these methods to control the current input position:
- Method: streampos istream::tellg ()
Return the current read position, so that you can save it and
return to it later with `istream::seekg'.
- Method: istream& istream::seekg (streampos P)
Reset the input pointer (if the input device permits it) to P,
usually the result of an earlier call to `istream::tellg'.
- Method: istream& istream::seekg (streamoff OFFSET, ios::seek_dir REF)
Reset the input pointer (if the input device permits it) to OFFSET
characters from the beginning of the input, the current position,
or the end of input. Specify how to interpret OFFSET with one of
these values for the second argument:
`ios::beg'
Interpret LOC as an absolute offset from the beginning of the
file.
`ios::cur'
Interpret LOC as an offset relative to the current output
position.
`ios::end'
Interpret LOC as an offset from the current end of the output
stream.