4 // Class AliMpPadIteratorPtr
5 // --------------------------
6 // Pointer to the virtual pad iterator;
7 // enables to allocate the virtual pad iterator on stack.
9 // AliMpVIndexed* myIndexed = MyIndexed()
10 // MVIterator& it = *AliMpPadIteratorPtr(myIndexed->CreateIterator());
12 // Authors: David Guez, Ivana Hrivnacova; IPN Orsay
14 #ifndef ALI_MP_PAD_ITERATOR_PTR_H
15 #define ALI_MP_PAD_ITERATOR_PTR_H
19 class AliMpVPadIterator;
21 class AliMpPadIteratorPtr : public TObject
24 AliMpPadIteratorPtr(AliMpVPadIterator* it);
25 // AliMpPadIteratorPtr(const AliMpPadIteratorPtr& right); --> private
26 virtual ~AliMpPadIteratorPtr();
28 AliMpVPadIterator* operator->() { return fIterator; }
29 AliMpVPadIterator& operator*() { return *fIterator; }
32 AliMpPadIteratorPtr(const AliMpPadIteratorPtr& right);
35 AliMpPadIteratorPtr& operator=(const AliMpPadIteratorPtr& right);
36 // copy and assignment are disallowed to avoid
37 // multiple deletion of fIterator
41 AliMpVPadIterator* fIterator; //The pad iterator
43 ClassDef(AliMpPadIteratorPtr,1) // Pointer to abstract pad iterator
46 #endif // ALI_MP_PAD_ITERATOR_PTR_H