Home || Architecture || Video Search || Visual Search || Scripts || Applications || Important Messages || OGL || Src

virtual Int64 Impala::Util::IOBuffer::Gets ( char *  buf,
Int64  bytesToRead 
) [inline, virtual]

Reimplemented in Impala::Util::IOBufferChannel, and Impala::Util::IOBufferFile.

Definition at line 209 of file IOBuffer.h.

References Available(), mBuffer, and mPosition.

Referenced by Impala::Util::IOBufferFile::Gets(), Impala::Core::Array::ReadRaw(), Impala::Core::Array::ReadRawList(), Impala::Core::Array::ReadRawListVar(), and Impala::Core::Array::ReadRawListVarIndex().

00210     {
00211         Int64 available = Available();
00212         if (available < bytesToRead)
00213             bytesToRead = available;
00214         PositionType start = mPosition;
00215         Int64 i = 0;
00216         while ((i < bytesToRead) && (mBuffer[start+i] != '\n'))
00217         {
00218             buf[i] = mBuffer[start+i];
00219             i++;
00220         }
00221         bytesToRead = i;
00222         mPosition += bytesToRead;
00223         if (mBuffer[start+i] == '\n')
00224             mPosition++;
00225         return bytesToRead;
00226     }

Here is the call graph for this function:


Generated on Fri Mar 19 11:40:07 2010 for ImpalaSrc by  doxygen 1.5.1