Logo ROOT  
Reference Guide
TObjectLevelIter Class Reference

Iterator over list of elements, designed for support TBrowser usage.

Definition at line 37 of file TObjectElement.cxx.

Public Member Functions

 TObjectLevelIter ()
 
virtual ~TObjectLevelIter ()=default
 
void AddElement (std::shared_ptr< RElement > &&elem)
 
bool CanItemHaveChilds () const override
 Returns true if current item can have childs. More...
 
std::unique_ptr< RItemCreateItem () override
 Create element for the browser. More...
 
bool Find (const std::string &name, int indx=-1) override
 Find item with specified name Default implementation, should work for all If index specified, not only name but also index should match. More...
 
std::shared_ptr< RElementGetElement () override
 Returns full information for current element. More...
 
std::string GetItemName () const override
 Returns current entry name
More...
 
bool Next () override
 Shift to next entry. More...
 
auto NumElements () const
 
- Public Member Functions inherited from ROOT::Experimental::Browsable::RLevelIter
virtual ~RLevelIter ()=default
 
virtual bool CanItemHaveChilds () const
 Returns true if current item can have childs. More...
 
virtual std::unique_ptr< RItemCreateItem ()
 Create generic description item for RBrowser. More...
 
virtual bool Find (const std::string &name, int indx=-1)
 Find item with specified name Default implementation, should work for all If index specified, not only name but also index should match. More...
 
virtual std::shared_ptr< RElementGetElement ()=0
 Create RElement for current entry - may take much time to load object or open file. More...
 
virtual std::string GetItemName () const =0
 Returns current entry name
More...
 
virtual bool Next ()=0
 Shift to next entry. More...
 

Private Attributes

int fCounter {-1}
 
std::vector< std::shared_ptr< RElement > > fElements
 
Inheritance diagram for TObjectLevelIter:
[legend]

Constructor & Destructor Documentation

◆ TObjectLevelIter()

TObjectLevelIter::TObjectLevelIter ( )
inlineexplicit

Definition at line 44 of file TObjectElement.cxx.

◆ ~TObjectLevelIter()

virtual TObjectLevelIter::~TObjectLevelIter ( )
virtualdefault

Member Function Documentation

◆ AddElement()

void TObjectLevelIter::AddElement ( std::shared_ptr< RElement > &&  elem)
inline

Definition at line 48 of file TObjectElement.cxx.

◆ CanItemHaveChilds()

bool TObjectLevelIter::CanItemHaveChilds ( ) const
inlineoverridevirtual

Returns true if current item can have childs.

Reimplemented from ROOT::Experimental::Browsable::RLevelIter.

Definition at line 62 of file TObjectElement.cxx.

◆ CreateItem()

std::unique_ptr< RItem > TObjectLevelIter::CreateItem ( )
inlineoverridevirtual

Create element for the browser.

Reimplemented from ROOT::Experimental::Browsable::RLevelIter.

Definition at line 69 of file TObjectElement.cxx.

◆ Find()

bool TObjectLevelIter::Find ( const std::string &  name,
int  indx = -1 
)
inlineoverridevirtual

Find item with specified name Default implementation, should work for all If index specified, not only name but also index should match.

Reimplemented from ROOT::Experimental::Browsable::RLevelIter.

Definition at line 101 of file TObjectElement.cxx.

◆ GetElement()

std::shared_ptr< RElement > TObjectLevelIter::GetElement ( )
inlineoverridevirtual

Returns full information for current element.

Implements ROOT::Experimental::Browsable::RLevelIter.

Definition at line 96 of file TObjectElement.cxx.

◆ GetItemName()

std::string TObjectLevelIter::GetItemName ( ) const
inlineoverridevirtual

Returns current entry name

Implements ROOT::Experimental::Browsable::RLevelIter.

Definition at line 60 of file TObjectElement.cxx.

◆ Next()

bool TObjectLevelIter::Next ( )
inlineoverridevirtual

Shift to next entry.

Implements ROOT::Experimental::Browsable::RLevelIter.

Definition at line 55 of file TObjectElement.cxx.

◆ NumElements()

auto TObjectLevelIter::NumElements ( ) const
inline

Definition at line 53 of file TObjectElement.cxx.

Member Data Documentation

◆ fCounter

int TObjectLevelIter::fCounter {-1}
private

Definition at line 41 of file TObjectElement.cxx.

◆ fElements

std::vector<std::shared_ptr<RElement> > TObjectLevelIter::fElements
private

Definition at line 39 of file TObjectElement.cxx.


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