basic_streambuf::setg

void setg(E *gbeg, E *gnext, E *gend);

The member function stores gbeg in the beginning pointer, gnext in the next pointer, and gend in the end pointer for the input buffer.