Logo Search packages:      
Sourcecode: djvulibre version File versions  Download package

void ByteStream::write16 ( unsigned int  card16  )  [inherited]

Writes a two-bytes integer to a ByteStream. The integer most significant byte is written first, regardless of the processor endianness.

Definition at line 514 of file ByteStream.cpp.

References ByteStream::writall().

Referenced by DjVuInfo::encode(), DjVmDir0::encode(), and DjVmDir::encode().

  unsigned char c[2];
  c[0] = (card>>8) & 0xff;
  c[1] = (card) & 0xff;
  if (writall((void*)c, sizeof(c)) != sizeof(c))
    G_THROW(strerror(errno));   //  (No error in the DjVuMessageFile)

Generated by  Doxygen 1.6.0   Back to index