Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 12:44:55

0001 #include "Alignment/Geners/interface/CatalogIO.hh"
0002 
0003 namespace gs {
0004   bool writeBinaryCatalog(std::ostream &os,
0005                           const unsigned compressionCode,
0006                           const unsigned mergeLevel,
0007                           const std::vector<std::string> &annotations,
0008                           const AbsCatalog &catalog,
0009                           const unsigned formatId) {
0010     os.seekp(0, std::ios_base::beg);
0011 
0012     const unsigned endianness = 0x01020304;
0013     const unsigned char sizelong = sizeof(long);
0014 
0015     write_pod(os, formatId);
0016     write_pod(os, endianness);
0017     write_pod(os, sizelong);
0018     write_pod(os, compressionCode);
0019     write_pod(os, mergeLevel);
0020     write_pod_vector(os, annotations);
0021 
0022     return !os.fail() && catalog.classId().write(os) && catalog.write(os);
0023   }
0024 }  // namespace gs