Logo Search packages:      
Sourcecode: djvulibre version File versions

size_t UnicodeByteStream::read ( void *  buffer,
size_t  size 
) [virtual]

Physically reads the specified bytes, and truncate the read ahead buffer.

Reimplemented from ByteStream.

Definition at line 121 of file UnicodeByteStream.cpp.

References bs, and GUTF8String::get_remainder().

Referenced by gets().

{
  bufferpos=0;
  const int retval=bs->read(buf,size);
  if(retval)
  {
    buffer=GUTF8String::create(
      (unsigned char const *)buf,retval,buffer.get_remainder());
  }else
  {
    buffer=GUTF8String::create(0,0,buffer.get_remainder());
  }
  return retval;
}


Generated by  Doxygen 1.6.0   Back to index