CMS 3D CMS Logo

StreamerOutputModuleBase.cc File Reference

#include "IOPool/Streamer/interface/StreamerOutputModuleBase.h"
#include "IOPool/Streamer/interface/InitMsgBuilder.h"
#include "IOPool/Streamer/interface/EventMsgBuilder.h"
#include "FWCore/RootAutoLibraryLoader/interface/RootAutoLibraryLoader.h"
#include "FWCore/Framework/interface/EventPrincipal.h"
#include "FWCore/Framework/interface/EventSelector.h"
#include "FWCore/ParameterSet/interface/Registry.h"
#include "FWCore/Utilities/interface/DebugMacros.h"
#include "FWCore/Utilities/interface/GetReleaseVersion.h"
#include "DataFormats/Common/interface/TriggerResults.h"
#include "DataFormats/Provenance/interface/ParameterSetID.h"
#include <string>
#include "zlib.h"

Go to the source code of this file.

Namespaces

namespace  edm

Functions

void packIntoString (std::vector< unsigned char > const &source, std::vector< unsigned char > &package)
void printBits (unsigned char c)

Variables

static SerializeDataBuffer serialize_databuffer


Function Documentation

void @10020::packIntoString ( std::vector< unsigned char > const &  source,
std::vector< unsigned char > &  package 
) [static]

Definition at line 31 of file StreamerOutputModuleBase.cc.

References i.

Referenced by edm::StreamerOutputModuleBase::setHltMask().

00032                                                          {
00033      if (source.size() < 1) {return;}
00034      unsigned int packInOneByte = 4; 
00035      unsigned int sizeOfPackage = 1+((source.size()-1)/packInOneByte); //Two bits per HLT
00036     
00037      package.resize(sizeOfPackage); 
00038      memset(&package[0], 0x00, sizeOfPackage);
00039  
00040      for (std::vector<unsigned char>::size_type i=0; i != source.size() ; ++i) { 
00041        unsigned int whichByte = i/packInOneByte;
00042        unsigned int indxWithinByte = i % packInOneByte;
00043        package[whichByte] = package[whichByte] | (source[i] << (indxWithinByte*2));
00044      }
00045     //for (unsigned int i=0; i !=package.size() ; ++i)
00046     //   printBits(package[i]);
00047     // std::cout << std::endl;
00048 
00049   }

void @10020::printBits ( unsigned char  c  )  [static]

Definition at line 24 of file StreamerOutputModuleBase.cc.

References GenMuonPlsPt100GeV_cfg::cout, and i.

00024                                   {
00025     for (int i = 7; i >= 0; --i) {
00026       int bit = ((c >> i) & 1);
00027       std::cout << " " << bit; 
00028     } 
00029   }   


Variable Documentation

SerializeDataBuffer serialize_databuffer [static]

Definition at line 19 of file StreamerOutputModuleBase.cc.


Generated on Tue Jun 9 17:54:28 2009 for CMSSW by  doxygen 1.5.4