ROOT 6.10/09 Reference Guide |
Smart pointer for the return type of actions.
A wrapper around the result of TDataFrame actions able to trigger calculations lazily.
T | Type of the action result |
A smart pointer which allows to access the result of a TDataFrame action. The methods of the encapsulated object can be accessed via the arrow operator. Upon invocation of the arrow operator or dereferencing (operator*
), the loop on the events and calculations of all scheduled actions are executed if needed. It is possible to iterate on the result proxy if the proxied object is a collection.
If iteration is not supported by the type of the proxied object, a compilation error is thrown.
Definition at line 25 of file TResultProxy.hxx.
Public Member Functions | |
TResultProxy ()=delete | |
TIterationHelper< T >::Iterator_t | begin () |
Return an iterator to the beginning of the contained object if this makes sense, throw a compilation error otherwise. More... | |
TIterationHelper< T >::Iterator_t | end () |
Return an iterator to the end of the contained object if this makes sense, throw a compilation error otherwise. More... | |
const T & | GetValue () |
Get a const reference to the encapsulated object. More... | |
T & | operator* () |
Get a pointer to the encapsulated object. More... | |
T * | operator-> () |
Get a pointer to the encapsulated object. More... | |
Private Types | |
using | ShrdPtrBool_t = std::shared_ptr< bool > |
using | SPT_t = std::shared_ptr< T > |
using | SPTLM_t = std::shared_ptr< TDFDetail::TLoopManager > |
using | WPTLM_t = std::weak_ptr< TDFDetail::TLoopManager > |
Private Member Functions | |
TResultProxy (const SPT_t &objPtr, const ShrdPtrBool_t &readiness, const SPTLM_t &firstData) | |
T * | Get () |
Get the pointer to the encapsulated result. More... | |
void | TriggerRun () |
Triggers the event loop in the TLoopManager instance to which it's associated via the fImplWeakPtr. More... | |
Private Attributes | |
WPTLM_t | fImplWeakPtr |
Points to the TLoopManager at the root of the functional graph. More... | |
SPT_t | fObjPtr |
Shared pointer encapsulating the wrapped result. More... | |
ShrdPtrBool_t | fReadiness |
State registered also in the TLoopManager until the event loop is executed. More... | |
Friends | |
template<typename W > | |
TResultProxy< W > | TDFDetail::MakeResultProxy (const std::shared_ptr< W > &, const SPTLM_t &) |
#include <ROOT/TResultProxy.hxx>
|
private |
Definition at line 82 of file TResultProxy.hxx.
|
private |
Definition at line 79 of file TResultProxy.hxx.
|
private |
Definition at line 80 of file TResultProxy.hxx.
|
private |
Definition at line 81 of file TResultProxy.hxx.
|
inlineprivate |
Definition at line 103 of file TResultProxy.hxx.
|
delete |
|
inline |
Return an iterator to the beginning of the contained object if this makes sense, throw a compilation error otherwise.
Definition at line 129 of file TResultProxy.hxx.
|
inline |
Return an iterator to the end of the contained object if this makes sense, throw a compilation error otherwise.
Definition at line 137 of file TResultProxy.hxx.
|
inlineprivate |
Get the pointer to the encapsulated result.
Ownership is not transferred to the caller. Triggers event loop and execution of all actions booked in the associated TLoopManager.
Definition at line 97 of file TResultProxy.hxx.
|
inline |
Get a const reference to the encapsulated object.
Triggers event loop and execution of all actions booked in the associated TLoopManager.
Definition at line 113 of file TResultProxy.hxx.
|
inline |
Get a pointer to the encapsulated object.
Triggers event loop and execution of all actions booked in the associated TLoopManager.
Definition at line 120 of file TResultProxy.hxx.
|
inline |
Get a pointer to the encapsulated object.
Ownership is not transferred to the caller. Triggers event loop and execution of all actions booked in the associated TLoopManager.
Definition at line 125 of file TResultProxy.hxx.
|
private |
Triggers the event loop in the TLoopManager instance to which it's associated via the fImplWeakPtr.
Definition at line 145 of file TResultProxy.hxx.
|
friend |
|
private |
Points to the TLoopManager at the root of the functional graph.
Definition at line 88 of file TResultProxy.hxx.
|
private |
Shared pointer encapsulating the wrapped result.
Definition at line 89 of file TResultProxy.hxx.
|
private |
State registered also in the TLoopManager until the event loop is executed.
Definition at line 86 of file TResultProxy.hxx.