本文整理汇总了C++中TFile::GetCreationDate方法的典型用法代码示例。如果您正苦于以下问题:C++ TFile::GetCreationDate方法的具体用法?C++ TFile::GetCreationDate怎么用?C++ TFile::GetCreationDate使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类TFile
的用法示例。
在下文中一共展示了TFile::GetCreationDate方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: TDatime
Int_t MergeV1(TString fileNameDigits="digits.root",
TString fileNameSDigitsSig="sig.sdigits.root",
TString fileNameSDigitsBgr="bgr.sdigits.root",
Int_t nEvents = 1, Int_t iITS = 2, Int_t iTPC = 0,
Int_t iTRD = 0, Int_t iPHOS = 0, Int_t iMUON = 0,
Int_t iRICH = 0, Int_t iCopy = 1)
{
// delete the current gAlice object, the one from input file
// will be used
if(gAlice){
delete gAlice;
gAlice = 0;
} // end if gAlice
// Connect the Root Galice file containing Geometry, Kine and Hits
TFile *file = (TFile*)gROOT->GetListOfFiles()->FindObject(fileNameSDigitsSig.Data());
if(!file) file = new TFile(fileNameSDigitsSig.Data());
TDatime *ct0 = new TDatime(2002,04,26,00,00,00), ct = file->GetCreationDate();
// Get AliRun object from file or create it if not on file
if(!gAlice) {
gAlice = (AliRun*)file->Get("gAlice");
if(gAlice) printf("AliRun object found on file\n");
if(!gAlice) gAlice = new AliRun("gAlice","Alice test program");
} // end if !gAlice
AliRunDigitizer * manager = new AliRunDigitizer(2,1);
manager->SetInputStream(0,fileNameSDigitsSig.Data());
manager->SetInputStream(1,fileNameSDigitsBgr.Data());
if (fileNameDigits != "") {
// if (iCopy) {
// AliCopyN(fileNameSDigitsSig,fileNameDigits);
// }
manager->SetOutputFile(fileNameDigits);
}
manager->SetNrOfEventsToWrite(nEvents);
if (iITS) {
AliITSDigitizer *dITS = new AliITSDigitizer(manager);
if (iITS == 2) dITS->SetByRegionOfInterestFlag(1);
if(ct0->GetDate()>ct.GetDate()){
// For old files, must change SDD noise.
AliITS *ITS = (AliITS*) gAlice->GetDetector("ITS");
AliITSresponseSDD *resp1 = ITS->DetType(1)->GetResponseModel();
resp1->SetNoiseParam();
resp1->SetNoiseAfterElectronics();
Float_t n,b;
Int_t cPar[8];
resp1->GetNoiseParam(n,b);
n = resp1->GetNoiseAfterElectronics();
cPar[0]=0;
cPar[1]=0;
cPar[2]=(Int_t)(b + 2.*n + 0.5);
cPar[3]=(Int_t)(b + 2.*n + 0.5);
cPar[4]=0;
cPar[5]=0;
cPar[6]=0;
cPar[7]=0;
resp1->SetCompressParam(cPar);
} // end if
}
if (iTPC) AliTPCDigitizer *dTPC = new AliTPCDigitizer(manager);
if (iTRD) AliTRDdigitizer *dTRD = new AliTRDdigitizer(manager);
if (iPHOS) AliPHOSDigitizer *dPHOS = new AliPHOSDigitizer(manager);
if (iMUON) AliMUONDigitizer *dMUON = new AliMUONDigitizer(manager);
if (iRICH) AliRICHDigitizer *dRICH = new AliRICHDigitizer(manager);
TStopwatch timer;
timer.Start();
manager->Exec("deb all");
timer.Stop();
timer.Print();
// delete gAlice;
// gAlice = 0;
delete manager;
}