Logo ROOT  
Reference Guide
TDirectoryLevelIter Class Reference

Iterator over keys in TDirectory.

Definition at line 42 of file TDirectoryElement.cxx.

Public Member Functions

 TDirectoryLevelIter (TDirectory *dir)
 
virtual ~TDirectoryLevelIter ()=default
 
bool CanItemHaveChilds () const override
 Returns true if current item can have childs. More...
 
std::unique_ptr< RItemCreateItem () override
 Create item for the client. More...
 
std::shared_ptr< RElementGetDirElement (bool read_dir)
 Return element for current TKey object in TDirectory. 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...
 
- 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 Member Functions

bool CreateIter ()
 
bool NextDirEntry ()
 

Private Attributes

std::string fCurrentName
 ! current key name More...
 
TDirectoryfDir {nullptr}
 ! current directory handle More...
 
std::unique_ptr< TIteratorfIter
 ! created iterator More...
 
TKeyfKey {nullptr}
 ! currently selected key More...
 
bool fKeysIter {true}
 ! iterating over keys list (default) More...
 
TObjectfObj {nullptr}
 ! currently selected object More...
 
bool fOnlyLastCycle {false}
 ! show only last cycle in list of keys More...
 
Inheritance diagram for TDirectoryLevelIter:
[legend]

Constructor & Destructor Documentation

◆ TDirectoryLevelIter()

TDirectoryLevelIter::TDirectoryLevelIter ( TDirectory dir)
inlineexplicit

Definition at line 138 of file TDirectoryElement.cxx.

◆ ~TDirectoryLevelIter()

virtual TDirectoryLevelIter::~TDirectoryLevelIter ( )
virtualdefault

Member Function Documentation

◆ CanItemHaveChilds()

bool TDirectoryLevelIter::CanItemHaveChilds ( ) const
inlineoverridevirtual

Returns true if current item can have childs.

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

Definition at line 166 of file TDirectoryElement.cxx.

◆ CreateItem()

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

Create item for the client.

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

Definition at line 181 of file TDirectoryElement.cxx.

◆ CreateIter()

bool TDirectoryLevelIter::CreateIter ( )
inlineprivate

Definition at line 51 of file TDirectoryElement.cxx.

◆ GetDirElement()

std::shared_ptr< RElement > TDirectoryLevelIter::GetDirElement ( bool  read_dir)

Return element for current TKey object in TDirectory.

Definition at line 542 of file TDirectoryElement.cxx.

◆ GetElement()

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

Returns full information for current element.

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

Definition at line 199 of file TDirectoryElement.cxx.

◆ GetItemName()

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

Returns current entry name

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

Definition at line 164 of file TDirectoryElement.cxx.

◆ Next()

bool TDirectoryLevelIter::Next ( )
inlineoverridevirtual

Shift to next entry.

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

Definition at line 159 of file TDirectoryElement.cxx.

◆ NextDirEntry()

bool TDirectoryLevelIter::NextDirEntry ( )
inlineprivate

Definition at line 70 of file TDirectoryElement.cxx.

Member Data Documentation

◆ fCurrentName

std::string TDirectoryLevelIter::fCurrentName
private

! current key name

Definition at line 49 of file TDirectoryElement.cxx.

◆ fDir

TDirectory* TDirectoryLevelIter::fDir {nullptr}
private

! current directory handle

Definition at line 43 of file TDirectoryElement.cxx.

◆ fIter

std::unique_ptr<TIterator> TDirectoryLevelIter::fIter
private

! created iterator

Definition at line 44 of file TDirectoryElement.cxx.

◆ fKey

TKey* TDirectoryLevelIter::fKey {nullptr}
private

! currently selected key

Definition at line 47 of file TDirectoryElement.cxx.

◆ fKeysIter

bool TDirectoryLevelIter::fKeysIter {true}
private

! iterating over keys list (default)

Definition at line 45 of file TDirectoryElement.cxx.

◆ fObj

TObject* TDirectoryLevelIter::fObj {nullptr}
private

! currently selected object

Definition at line 48 of file TDirectoryElement.cxx.

◆ fOnlyLastCycle

bool TDirectoryLevelIter::fOnlyLastCycle {false}
private

! show only last cycle in list of keys

Definition at line 46 of file TDirectoryElement.cxx.


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