AliRoot Core  a565103 (a565103)
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
AliMpStringObjMap Class Reference

Substitutes map <string, TObject> which ALICE does not allow to use. More...

#include <AliMpStringObjMap.h>

Inheritance diagram for AliMpStringObjMap:

Public Member Functions

 AliMpStringObjMap (Bool_t isOwner=false)
 
virtual ~AliMpStringObjMap ()
 
Bool_t Add (const TString &first, TObject *second)
 
TObject * Get (const TString &first) const
 
Int_t GetNofItems () const
 
virtual void Clear (Option_t *="")
 
virtual void Print (const char *="") const
 
void Print (const TString &key, ofstream &out) const
 
void First ()
 
void Next ()
 
TObject * CurrentItem ()
 
TString CurrentKey ()
 
Bool_t IsDone () const
 

Private Member Functions

 AliMpStringObjMap (const AliMpStringObjMap &rhs)
 Not implemented. More...
 
AliMpStringObjMapoperator= (const AliMpStringObjMap &rhs)
 Not implemented. More...
 

Static Private Member Functions

static const TString & GetUndefinedKey ()
 

Private Attributes

Int_t fNofItems
 number of items More...
 
TObjArray fFirstArray
 first item array More...
 
TObjArray fSecondArray
 second item array More...
 
Int_t fCurrentIndex
 current item index (for iteration) More...
 

Detailed Description

Substitutes map <string, TObject> which ALICE does not allow to use.

The map is not optimised for large data size

Author
Ivana Hrivnacova, IPN Orsay

Definition at line 23 of file AliMpStringObjMap.h.

Constructor & Destructor Documentation

AliMpStringObjMap::AliMpStringObjMap ( Bool_t  isOwner = false)

Standard constructor

Definition at line 58 of file AliMpStringObjMap.cxx.

AliMpStringObjMap::~AliMpStringObjMap ( )
virtual

Destructor

Definition at line 72 of file AliMpStringObjMap.cxx.

AliMpStringObjMap::AliMpStringObjMap ( const AliMpStringObjMap rhs)
private

Not implemented.

Member Function Documentation

Bool_t AliMpStringObjMap::Add ( const TString &  first,
TObject *  second 
)

Add map element if first not yet present

Definition at line 84 of file AliMpStringObjMap.cxx.

Referenced by AliMpSegmentation::CreateMpSegmentation().

void AliMpStringObjMap::Clear ( Option_t *  = "")
virtual

Delete the elements

Definition at line 123 of file AliMpStringObjMap.cxx.

TObject * AliMpStringObjMap::CurrentItem ( )

Set iterator to the first item and return its object

Definition at line 183 of file AliMpStringObjMap.cxx.

TString AliMpStringObjMap::CurrentKey ( )

Set iterator to the first item and return its object

Definition at line 194 of file AliMpStringObjMap.cxx.

void AliMpStringObjMap::First ( )

Set iterator to the first item and return its object

Definition at line 164 of file AliMpStringObjMap.cxx.

TObject * AliMpStringObjMap::Get ( const TString &  first) const

Find the element with specified key (first)

Definition at line 102 of file AliMpStringObjMap.cxx.

Referenced by Add(), AliMpSegmentation::CreateMpSegmentation(), and AliMpSegmentation::GetMpSegmentation().

Int_t AliMpStringObjMap::GetNofItems ( ) const

Return the number of elements

Definition at line 115 of file AliMpStringObjMap.cxx.

const TString & AliMpStringObjMap::GetUndefinedKey ( )
staticprivate

Undefined key string

Definition at line 46 of file AliMpStringObjMap.cxx.

Referenced by CurrentKey().

Bool_t AliMpStringObjMap::IsDone ( ) const

Return true if the iterator reached the end of map

Definition at line 205 of file AliMpStringObjMap.cxx.

void AliMpStringObjMap::Next ( )

Set iterator to the next item and return its object Return 0 if there are no more items

Definition at line 173 of file AliMpStringObjMap.cxx.

AliMpStringObjMap& AliMpStringObjMap::operator= ( const AliMpStringObjMap rhs)
private

Not implemented.

void AliMpStringObjMap::Print ( const char *  = "") const
virtual

Print the map elements

Definition at line 133 of file AliMpStringObjMap.cxx.

void AliMpStringObjMap::Print ( const TString &  key,
ofstream &  out 
) const

Special printing

Definition at line 149 of file AliMpStringObjMap.cxx.

Member Data Documentation

Int_t AliMpStringObjMap::fCurrentIndex
private

current item index (for iteration)

Definition at line 57 of file AliMpStringObjMap.h.

Referenced by CurrentItem(), CurrentKey(), First(), IsDone(), and Next().

TObjArray AliMpStringObjMap::fFirstArray
private

first item array

Definition at line 55 of file AliMpStringObjMap.h.

Referenced by Add(), AliMpStringObjMap(), Clear(), CurrentKey(), Get(), Print(), and ~AliMpStringObjMap().

Int_t AliMpStringObjMap::fNofItems
private

number of items

Definition at line 54 of file AliMpStringObjMap.h.

Referenced by Add(), Clear(), CurrentItem(), CurrentKey(), Get(), GetNofItems(), IsDone(), and Print().

TObjArray AliMpStringObjMap::fSecondArray
private

second item array

Definition at line 56 of file AliMpStringObjMap.h.

Referenced by Add(), AliMpStringObjMap(), Clear(), CurrentItem(), Get(), and Print().


The documentation for this class was generated from the following files: