-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[RFC] Modernizing product retrieval from Event #25664
Comments
A new Issue was created by @makortel Matti Kortelainen. @davidlange6, @Dr15Jones, @smuzaffar, @fabiocos, @kpedro88 can you please review it and eventually sign/assign? Thanks. cms-bot commands are listed here |
I love that "issue", that interface would be a great update to the framework! What would you think of shortening |
We should add to the contract of |
The use of a auto handle = makeValid(iEvent.getHandle(token_)); as this avoid coupling |
assign core |
New categories assigned: core @Dr15Jones,@smuzaffar you have been requested to review this Pull request/Issue and eventually sign? Thanks |
With mechanism like #16481 (comment) the restriction above would not be needed. |
+1 |
This issue is fully signed and ready to be closed. |
Currently products can be retrieved from
edm::Event
withIn above the
token_
can also be the untypededm::EDGetToken
(oredm::InputTag
withgetByLabel()
).These retrieval calls could be modernized by introducing
edm::ValidHandle<T>
, which would check the existence of the product in its constructor. Compared toedm::Handle
, it would be faster to use as its accessors would not need any further checks. Compared toconst
reference, it would still provide access to the provenance. It would be accompanied with the following interfaceThese interfaces would support only the typed
edm::EDGetTokenT<T>
.The text was updated successfully, but these errors were encountered: