16 using namespace lcio ;
21 int main(
int argc,
char** argv ){
31 LCReader*
lcReader = LCFactory::getInstance()->createLCReader() ;
33 lcReader->open(
FILEN ) ;
39 while( (evt = lcReader->readNextEvent()) != 0 ) {
46 const StringVec* colNames = evt->getCollectionNames() ;
48 for(
unsigned int i=0 ; i < colNames->size() ; i++ ){
50 LCCollection* col = evt->getCollection( (*colNames)[i] ) ;
52 if( col->getParameters().getStringVal(
"TypeName") ==
"CalibrationConstant" ) {
56 for(
int j=0;j<col->getNumberOfElements();j++){
60 std::cout <<
" calibration for cellid: " << cal.getCellID()
61 <<
" offset: " << cal.getOffset()
62 <<
" gain: " << cal.getGain()
std::vector< std::string > StringVec
Vector of strings.
static const char * FILEN
int main(int argc, char **argv)
Simple program that opens existing LCIO files and appends the records needed for direct access - if t...
Example for a simple calibration class based on the LCFixedObject template.