Reimplemented in Impala::Util::IOBufferChannel, and Impala::Util::IOBufferFile. Definition at line 325 of file IOBuffer.h. References Available(), mBuffer, and mPosition. Referenced by Impala::Util::IOBufferFile::Gets(), Impala::Core::Array::ReadRawHeader(), and Impala::Core::Array::ReadRawListVarIndex(). 00326 { 00327 Int64 available = Available(); 00328 if (available < bytesToRead) 00329 bytesToRead = available; 00330 PositionType start = mPosition; 00331 Int64 i = 0; 00332 while ((i < bytesToRead) && (mBuffer[start+i] != '\n')) 00333 { 00334 buf[i] = mBuffer[start+i]; 00335 i++; 00336 } 00337 bytesToRead = i; 00338 mPosition += bytesToRead; 00339 if (mBuffer[start+i] == '\n') 00340 mPosition++; 00341 return bytesToRead; 00342 }
Here is the call graph for this function: ![]()
|