FACT++  1.0
virtual void fits::WriteRowToCopyFile ( size_t  row)
inlinevirtual

Reimplemented in zfits.

Definition at line 759 of file fits.h.

References Checksum::add(), fits::Table::bytes_per_row, and clear().

760  {
761  if (row==fRow+1)
762  {
763  const uint8_t offset = (row*fTable.bytes_per_row)%4;
764 
766  if (fCopy.is_open() && fCopy.good())
767  fCopy.write(fBufferRow.data()+offset, fTable.bytes_per_row);
768  if (!fCopy)
769  clear(rdstate()|std::ios::badbit);
770  }
771  else
772  if (fCopy.is_open())
773  clear(rdstate()|std::ios::badbit);
774  }
size_t bytes_per_row
Definition: fits.h:96
std::ofstream fCopy
Definition: fits.h:499
Checksum fChkData
Definition: fits.h:517
Table fTable
Definition: fits.h:502
size_t fRow
Definition: fits.h:514
std::vector< char > fBufferRow
Definition: fits.h:511
void clear()
Definition: HeadersFTM.h:216
bool add(const char *buf, size_t len, bool big_endian=true)
Definition: checksum.h:49

+ Here is the call graph for this function: