Skip to content

GetSubEventHeader() method in CRVDataDecoder? #59

@sam-grant

Description

@sam-grant

I have a module which uses the CRV data decoder, like this:

auto decodersHandle = e.getValidHandle<std::vector<mu2e::CRVDataDecoder>>(decoderTag_);
size_t nSubEvents = decodersHandle->size();

// Process the decoder objects, each contains data from one subevent (see DTCLib::DTC_SubEvent)
for(size_t iSubEvent = 0; iSubEvent < nSubEvents; ++iSubEvent)
{
	const mu2e::CRVDataDecoder& decoder((*decodersHandle)[iSubEvent]);
	decoder.setup_event();

	// Access the SubEventHeader through the internal event_ member
	// Can we add a GetSubEventHeader() method to the CRVDataDecoder?
	auto subEventHeader = decoder.event_.GetHeader();

       ...
}

I need the subEventHeader from the decoder object so that I can access the ROC latency for that subevent, but so far I am retrieving it in an odd way.

Am I doing this wrong, or should we add a GetSubEventHeader() method to CRVDataDecoder?

Thanks, Sam

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions