Skip to content

Commit 35953db

Browse files
committed
Update MC header when using event pool generator
1 parent ab73e40 commit 35953db

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

Generators/include/Generators/GeneratorFromFile.h

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,11 +87,11 @@ class GeneratorFromO2Kine : public o2::eventgen::Generator
8787
void SetStartEvent(int start);
8888

8989
void setContinueMode(bool val) { mContinueMode = val; };
90-
91-
private:
9290
/** methods that can be overridden **/
9391
void updateHeader(o2::dataformats::MCEventHeader* eventHeader) override;
9492

93+
private:
94+
9595
TFile* mEventFile = nullptr; //! the file containing the persistent events
9696
TBranch* mEventBranch = nullptr; //! the branch containing the persistent events
9797
TBranch* mMCHeaderBranch = nullptr; //! branch containing MC event headers
@@ -143,6 +143,11 @@ class GeneratorFromEventPool : public o2::eventgen::Generator
143143
return import_good;
144144
}
145145

146+
void updateHeader(o2::dataformats::MCEventHeader* eventHeader) override
147+
{
148+
mO2KineGenerator->updateHeader(eventHeader);
149+
}
150+
146151
// determine the collection of available files
147152
std::vector<std::string> setupFileUniverse(std::string const& path) const;
148153

0 commit comments

Comments
 (0)