|
ATLAS Offline Software
|
Go to the documentation of this file.
5 #ifndef ATHLINKS_DATALINK_H
6 #define ATHLINKS_DATALINK_H
15 #include "AthLinks/DataLinkBase.h"
16 #include "AthLinks/tools/selection_ns.h"
23 template<
class STORABLE >
38 template<
typename STORABLE >
85 template<
typename T >
153 typedef typename ROOT_SELECTION_NS::DataLink< STORABLE >::self
DictSel;
162 template<
class STORABLE >
163 class DataLink :
public SelectNoInstance
171 ROOT_SELECTION_NS::MemberAttributes< kTransient >
m_object;
173 ROOT_SELECTION_NS::MemberAttributes< kTransient >
m_event;
179 template<
typename STORABLE >
184 template<
typename STORABLE >
193 #endif // ATHLINKS_DATALINK_H
Base interface for getting objects out of the input file.
char data[hepevt_bytes_allocation_ATLAS]
bool operator!=(const DataLink< STORABLE > &a, const DataLink< STORABLE > &b)
Non-equality checker operator.
DataLink(const_reference data, xAOD::TVirtualEvent *event=0)
Constructor receiving a reference to the target object.
const STORABLE & const_reference
Constant reference type for the object being handled.
const_pointer m_object
Cached pointer to the object.
xAOD::TVirtualEvent * m_event
Pointer to the event object.
STORABLE * __attribute__((deprecated)) pointer
Pointer type for the object being handled.
const ID_type & dataID() const
Get the key that we reference, as a string.
ICaloAffectedTool is abstract interface for tools checking if 4 mom is in calo affected region.
DataLink()
Default constructor, creating a null pointer basically.
uint32_t sgkey_t
Integer identifier for the object in the event.
STORABLE value_type
Type of the object being handled.
DataLink(const ID_type &id, xAOD::TVirtualEvent *event=0)
Constructor receiving a user-readable ID for the target object.
EXIT_ROOT_SELECTION_NS bool operator==(const DataLink< STORABLE > &a, const DataLink< STORABLE > &b)
Equality checker operator.
void toDefaultObject()
Set the link to the default object of this type in the event.
POOL::TEvent event(POOL::TEvent::kClassAccess)
void toStorableObject(const_reference data)
Set the link to a data object that's already in the event.
Object reference supporting deferred reading from StoreGate.
ROOT_SELECTION_NS::MemberAttributes< kTransient > m_object
Declare m_object as transient.
DataLink(sgkey_t key, xAOD::TVirtualEvent *event=0)
Constructor receiving a hashed ID for the target object.
uint32_t persKey() const
Get the key/identifier of the referenced container.
void toIdentifiedObject(const ID_type &id)
Set the link using a user readable ID for the target object.
DataLink(const_pointer data, xAOD::TVirtualEvent *event=0)
Constructor receiving a pointer to the target object.
const_pointer operator->() const
Get a pointer to the target object.
bool isValid() const
Check if the object can be found.
bool toPersistent()
Prepare the object to be written out.
ROOT_SELECTION_NS::MemberAttributes< kTransient > m_event
Declare m_event as transient.
xAOD::TVirtualEvent * source() const
Get the data source for the reference.
bool operator!() const
Another convenience validity checker.
const_pointer cptr() const
Dereference the link.
DataLink(xAOD::TVirtualEvent *event)
Constructor taking an alternative TVirtualEvent object to use.
void toIdentifiedObject(sgkey_t key)
Set the link using a hashed ID for the target object.
STORABLE & __attribute__((deprecated)) reference
Reference type for the object being handled.
SG::DataProxyHolder::sgkey_t sgkey_t
Type of hashed keys.
SG::DataProxyHolder::ID_type ID_type
Type of string keys.
ROOT_SELECTION_NS::DataLink< STORABLE >::self DictSel
Needed to take the Reflex/Cling specifications into account.
std::string ID_type
Type of the "regular" identifiers in the event.
DataLink(const DataLink< T > &parent)
Copy constructor.
void findIdentifier()
Find the identifier of the object being pointed to.
sgkey_t key() const
Get the key that we reference, as a hash.
virtual bool toTransient()
Reset the object's internal cache.
Interface for const operations on an auxiliary store.
setBGCode setTAP setLVL2ErrorBits bool
const_reference operator*() const
Get a reference to the target object. May throw an exception.
Type-independent part of DataLink; holds the persistent state.
const STORABLE * const_pointer
Constant pointer type for the object being handled.