|
ATLAS Offline Software
|
Go to the documentation of this file.
5 #include <TVirtualCollectionProxy.h>
22 const ::TClass*
cl,
size_t size,
size_t,
24 : IAuxTypeVector( auxid, isLinked ),
26 m_proxy(
cl->GetCollectionProxy()->Generate() ), m_vec(
cl->New() ) {
30 ::Fatal(
"xAOD::TAuxVector::TAuxVector",
43 : IAuxTypeVector(
parent ),
44 m_factory(
parent.m_factory ), m_proxy(
parent.m_proxy->Generate() ),
45 m_vec(
parent.m_proxy->GetCollectionClass()->New() ) {
60 const void* parentPtr =
parent.toPtr();
74 if(
this == &
other ) {
82 IAuxTypeVector::operator=(
other );
98 const void* otherPtr =
other.toPtr();
109 return std::make_unique< TAuxVector >( *
this );
135 const void* orig =
toPtr();
137 return toPtr() == orig;
173 size_t eltsz =
m_proxy->GetIncrement();
176 if( -offs >
static_cast< ptrdiff_t
>(
pos ) ) {
179 char*
beg =
reinterpret_cast< char*
>(
m_proxy->At( 0 ) );
181 beg + eltsz * (
pos + offs ),
186 }
else if( offs > 0 ) {
188 size_t oldsz =
m_proxy->Size();
189 m_proxy->Allocate( oldsz + offs,
false );
190 char*
beg =
reinterpret_cast< char*
>(
m_proxy->At( 0 ) );
192 beg + eltsz * (
pos + offs ),
204 size_t eltsz =
m_proxy->GetIncrement();
205 const void* orig = this->
toPtr();
207 char* begp =
reinterpret_cast<char*
> (
beg);
208 char* endp =
reinterpret_cast<char*
> (
end);
209 size_t nelt = (endp-begp) / eltsz;
216 reinterpret_cast<char*
>(this->
toPtr()) + pos*eltsz,
218 return this->
toPtr() == orig;
236 size_t eltsz =
m_proxy->GetIncrement();
239 if(
m_proxy->GetValueClass() ) {
244 memset( dst, 0,
n * eltsz );
virtual void copy(SG::auxid_t auxid, SG::AuxVectorData &dst, size_t dst_index, const SG::AuxVectorData &src, size_t src_index, size_t n) const override
Copy elements from one location to another.
virtual void reserve(size_t sz) override
Change the capacity of the vector.
virtual void * toVector() override
Return a pointer to the STL vector itself.
virtual bool insertMove(size_t pos, void *beg, void *end, SG::IAuxStore &srcStore) override
Insert a range of elements via move.
Make an AuxVectorData object from either a raw vector or an aux store.
std::unique_ptr<::TVirtualCollectionProxy > m_proxy
ROOT's description of the vector type Cloned from the proxy held by the TClass and permanently bound ...
ICaloAffectedTool is abstract interface for tools checking if 4 mom is in calo affected region.
void clear(void *dst, size_t dst_index, size_t n) const
Clear the payload of a given range inside a vector.
virtual void * toPtr() override
Return a pointer to the start of the vector's data.
size_t auxid_t
Identifier for a particular aux data item.
virtual std::unique_ptr< SG::IAuxTypeVector > clone() const override
Copy the managed vector.
TAuxVector(const TAuxVectorFactory *factory, SG::auxid_t auxid, const ::TClass *cl, size_t size, size_t capacity, bool isLinked)
Constructor.
TAuxVector & operator=(const TAuxVector &other)
Assignment operator.
Auxiliary vector type for types known to ROOT.
Manage lookup of vectors of auxiliary data.
Auxiliary vector factory based on a ROOT dictionary.
virtual size_t size() const override
Return the size of the vector.
virtual bool resize(size_t sz) override
Change the size of the vector.
auxid_t auxid() const
Return the auxid of the variable this vector represents.
Interface for non-const operations on an auxiliary store.
Make an AuxVectorData object from either a raw array or an aux store.
Interface for factory objects that create vectors.
virtual bool shift(size_t pos, ptrdiff_t offs) override
Shift the elements of the vector.
void clearRange(void *dst, size_t n)
void * m_vec
Pointer to the vector object.
void copyRange(const void *src, void *dst, size_t n)
Function copying the payload of a range to a new location.
cl
print [x.__class__ for x in toList(dqregion.getSubRegions()) ]
const TAuxVectorFactory * m_factory
The parent factory object.