12#ifndef ROOT_TVirtualCollectionIterators
13#define ROOT_TVirtualCollectionIterators
55 ::Fatal(
"TIterators::TIterators",
"Created with out a collection proxy!\n");
114 virtual operator bool()
const = 0;
131 fNext( proxy->GetFunctionNext(read_from_file) ),
168 if ( ! (
bool)*
this )
return 0;
253 ::Fatal(
"TIterators::TIterators",
"Created with out a collection proxy!\n");
282 static void *
Next(
void *iter,
const void *end)
287 void **ptr = (
void**)internal_iter->
fNext(internal_iter->
fIter,internal_end->
fIter);
305 void *newiter = internal_source->
fCopy(
dest,internal_source->
fIter);
306 if (newiter ==
dest) {
309 internal_dest->
fIter = newiter;
310 return internal_dest;
352 std::vector<char> *vec = (std::vector<char>*)collection;
359#ifdef R__VISUAL_CPLUSPLUS
360 fEnd = &(*(vec->end()-1)) + 1;
363 fEnd = &(*vec->end());
void Fatal(const char *location, const char *msgfmt,...)
TVirtualCollectionProxy::Next_t Next_t
virtual void * operator*() const
RegularIterator(void *collection, TVirtualCollectionProxy *proxy, Bool_t read_from_file)
VectorIterator(void *collection, TVirtualCollectionProxy *proxy, Bool_t read_from_file)
virtual void * operator*() const
TVirtualCollectionIterators fIterators
TGenericCollectionIterator(const TGenericCollectionIterator &)=delete
TGenericCollectionIterator & operator++()
TGenericCollectionIterator()=delete
static TGenericCollectionIterator * New(void *collection, TVirtualCollectionProxy *proxy)
virtual void * operator*() const =0
TGenericCollectionIterator(void *collection, TVirtualCollectionProxy *proxy, Bool_t read_from_file=kTRUE)
virtual ~TGenericCollectionIterator()
Small helper class to generically acquire and release iterators.
TVirtualCollectionIterators(const TVirtualCollectionIterators &)=delete
TVirtualCollectionProxy::CreateIterators_t CreateIterators_t
void CreateIterators(void *collection, TVirtualCollectionProxy *proxy)
TVirtualCollectionIterators(TVirtualCollectionProxy *proxy, Bool_t read_from_file=kTRUE)
DeleteTwoIterators_t fDeleteTwoIterators
TVirtualCollectionProxy::DeleteTwoIterators_t DeleteTwoIterators_t
char fEndBuffer[TVirtualCollectionProxy::fgIteratorArenaSize]
TVirtualCollectionIterators()=delete
CreateIterators_t fCreateIterators
~TVirtualCollectionIterators()
TVirtualCollectionIterators(CreateIterators_t creator, DeleteTwoIterators_t destruct)
char fBeginBuffer[TVirtualCollectionProxy::fgIteratorArenaSize]
void(* CreateIterators_t)(void *collection, void **begin_arena, void **end_arena, TVirtualCollectionProxy *proxy)
void *(* CopyIterator_t)(void *dest, const void *source)
void *(* Next_t)(void *iter, const void *end)
virtual Int_t GetCollectionType() const =0
virtual Next_t GetFunctionNext(Bool_t read=kTRUE)=0
virtual DeleteTwoIterators_t GetFunctionDeleteTwoIterators(Bool_t read=kTRUE)=0
void(* DeleteTwoIterators_t)(void *begin, void *end)
void(* DeleteIterator_t)(void *iter)
static const Int_t fgIteratorArenaSize
virtual CreateIterators_t GetFunctionCreateIterators(Bool_t read=kTRUE)=0
virtual DeleteIterator_t GetFunctionDeleteIterator(Bool_t read=kTRUE)=0
virtual CopyIterator_t GetFunctionCopyIterator(Bool_t read=kTRUE)=0
TVirtualCollectionPtrIterators(const TVirtualCollectionPtrIterators &)
TVirtualCollectionProxy::DeleteIterator_t Delete_t
char fRawBeginBuffer[TVirtualCollectionProxy::fgIteratorArenaSize]
TVirtualCollectionProxy::CreateIterators_t CreateIterators_t
TVirtualCollectionProxy::Next_t Next_t
DeleteTwoIterators_t fDeleteTwoIterators
void CreateIterators(void *collection, TVirtualCollectionProxy *proxy)
TVirtualCollectionPtrIterators()
static void DeleteIterator(void *iter)
TVirtualCollectionPtrIterators(TVirtualCollectionProxy *proxy)
TVirtualCollectionProxy::DeleteTwoIterators_t DeleteTwoIterators_t
TInternalIterator fBeginBuffer
TVirtualCollectionProxy::CopyIterator_t Copy_t
char fRawEndBuffer[TVirtualCollectionProxy::fgIteratorArenaSize]
static void * Next(void *iter, const void *end)
TInternalIterator fEndBuffer
CreateIterators_t fCreateIterators
static void * CopyIterator(void *dest, const void *source)
~TVirtualCollectionPtrIterators()
TInternalIterator & operator=(const TInternalIterator &)
TInternalIterator(const TInternalIterator &source)
TVirtualVectorIterators(TVirtualCollectionProxy *)
void CreateIterators(void *collection)
TVirtualCollectionProxy::CreateIterators_t CreateIterators_t
TVirtualVectorIterators(const TVirtualVectorIterators &)
TVirtualVectorIterators(CreateIterators_t)
TVirtualVectorIterators()
#define dest(otri, vertexptr)