SH::DiskList Class Reference

an interface for listing directory contents, locally or on a file server More...

#include <DiskList.h>

Inheritance diagram for SH::DiskList:
SH::DiskListEOS SH::DiskListLocal SH::DiskListSRM SH::DiskListXRD

List of all members.

Public Member Functions

void testInvariant () const
 test the invariant of this object
virtual ~DiskList ()
 standard destructor
bool next ()
 get the next list entry
std::string path () const
 the path for the current entry.
std::string fileName () const
 the filename for the current entry
DiskListopenDir () const
 make a new list object for the sub-directory
std::string dirname () const
 the base path for the directory listed

Protected Member Functions

 DiskList ()
 standard constructor
virtual bool getNext ()=0
virtual std::string getPath () const =0
virtual DiskListdoOpenDir () const =0
virtual std::string getDirname () const =0

Detailed Description

an interface for listing directory contents, locally or on a file server

Rationale:
this interface was introduced to allow the various data discovery methods to work with the various kinds of file servers without having to specialize them all individually.

Constructor & Destructor Documentation

SH::DiskList::~DiskList (  )  [virtual]

standard destructor

Guarantee
no-fail
Rationale
virtual destructor for base class
SH::DiskList::DiskList (  )  [protected]

standard constructor

Guarantee
strong
Failures
out of memory I

Member Function Documentation

std::string SH::DiskList::dirname (  )  const

the base path for the directory listed

Guarantee
strong
Failures
out of memory II
virtual DiskList* SH::DiskList::doOpenDir (  )  const [protected, pure virtual]

make a new list object for the sub-directory

Returns:
a new list object for the sub-directory, or NULL if it is not a directory
Precondition:
(soft) next() has been called successfully
Guarantee
strong
Failures
out of memory III

Rationale
the virtual part of DiskList::openDir()

Implemented in SH::DiskListEOS, SH::DiskListLocal, SH::DiskListSRM, and SH::DiskListXRD.

std::string SH::DiskList::fileName (  )  const

the filename for the current entry

Returns:
the filename for the current entry
Precondition:
(soft) next() has been called successfully
Guarantee
strong
Failures
out of memory III
virtual std::string SH::DiskList::getDirname (  )  const [protected, pure virtual]

the base path for the directory listed

Guarantee
strong
Failures
out of memory II

Rationale
the virtual part of DiskList::dirname()

Implemented in SH::DiskListEOS, SH::DiskListLocal, SH::DiskListSRM, and SH::DiskListXRD.

virtual bool SH::DiskList::getNext (  )  [protected, pure virtual]

get the next list entry

Returns:
whether we found another entry
Guarantee
basic
Failures
i/o errors

Rationale
the virtual part of DiskList::next()

Implemented in SH::DiskListEOS, SH::DiskListLocal, SH::DiskListSRM, and SH::DiskListXRD.

virtual std::string SH::DiskList::getPath (  )  const [protected, pure virtual]

the path for the current entry.

Returns:
the path for the current entry
Precondition:
(soft) next() has been called successfully
Guarantee
strong failures: out of memory III

Rationale
the virtual part of DiskList::path()

Implemented in SH::DiskListEOS, SH::DiskListLocal, SH::DiskListSRM, and SH::DiskListXRD.

bool SH::DiskList::next (  ) 

get the next list entry

Returns:
whether we found another entry
Guarantee
basic
Failures
i/o errors
DiskList * SH::DiskList::openDir (  )  const

make a new list object for the sub-directory

Returns:
a new list object for the sub-directory, or NULL if it is not a directory
Precondition:
(soft) next() has been called successfully
Guarantee
strong
Failures
out of memory III
std::string SH::DiskList::path ( void   )  const

the path for the current entry.

Returns:
the path for the current entry
Precondition:
(soft) next() has been called successfully
Guarantee
strong failures: out of memory III
void SH::DiskList::testInvariant (  )  const

test the invariant of this object

Guarantee
no-fail

Reimplemented in SH::DiskListEOS, SH::DiskListLocal, SH::DiskListSRM, and SH::DiskListXRD.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on 1 Dec 2017 for RootCore Packages by  doxygen 1.6.1