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

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

Reimplemented from Impala::Util::IOBuffer.

Definition at line 122 of file IOBufferChannel.h.

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

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

Here is the call graph for this function:


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