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

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

Reimplemented from Impala::Util::IOBuffer.

Definition at line 123 of file IOBufferChannel.h.

References Impala::Util::IOBuffer::Available(), Impala::Util::IOBuffer::GetPosition(), Read(), and SetPosition().

00124     {
00125         Int64 available = Available();
00126         if (available < bytesToRead)
00127             bytesToRead = available;
00128         PositionType start = GetPosition();
00129         Int64 nrRead = Read(buf, bytesToRead); // does SetPosition
00130         Int64 i = 0;
00131         while ((i < bytesToRead) && (buf[i] != '\n'))
00132             i++;
00133         bytesToRead = i;
00134         if (buf[i] == '\n')
00135             i++;
00136         SetPosition(start + i);
00137         return bytesToRead;
00138     }

Here is the call graph for this function:


Generated on Thu Jan 13 09:24:15 2011 for ImpalaSrc by  doxygen 1.5.1