ATLAS Offline Software
Loading...
Searching...
No Matches
DiskList.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef SAMPLE_HANDLER__DISK_LIST_H
6#define SAMPLE_HANDLER__DISK_LIST_H
7
8//
9// Distributed under the Boost Software License, Version 1.0.
10// (See accompanying file LICENSE_1_0.txt or copy at
11// http://www.boost.org/LICENSE_1_0.txt)
12
13// Please feel free to contact me (krumnack@iastate.edu) for bug
14// reports, feature suggestions, praise and complaints.
15
16
17
19
20#include <string>
21
22namespace SH
23{
32 {
33 //
34 // public interface
35 //
36
41 public:
42 void testInvariant () const;
43
44
51 public:
52 virtual ~DiskList ();
53
54
62 public:
63 bool next ();
64
65
73 public:
74 std::string path () const;
75
76
85 public:
86 std::string fileName () const;
87
88
98 public:
99 DiskList *openDir () const;
100
101
107 public:
108 std::string dirname () const;
109
110
111
112 //
113 // protected interface
114 //
115
122 protected:
123 DiskList ();
124
125
126
127 //
128 // virtual interface
129 //
130
134 protected:
135 virtual bool getNext () = 0;
136
137
141 protected:
142 virtual std::string getPath () const = 0;
143
144
148 protected:
149 virtual DiskList *doOpenDir () const = 0;
150
151
155 protected:
156 virtual std::string getDirname () const = 0;
157
158
159
160 //
161 // private interface
162 //
163
165 private:
173
175 };
176}
177
178#endif
virtual DiskList * doOpenDir() const =0
make a new list object for the sub-directory
std::string path() const
the path for the current entry.
Definition DiskList.cxx:78
virtual std::string getDirname() const =0
the base path for the directory listed
State
the current state
Definition DiskList.h:167
@ S_VALID
holding a valid entry
Definition DiskList.h:169
@ S_DONE
finished reading entries
Definition DiskList.h:170
@ S_BROKEN
an error occured
Definition DiskList.h:171
@ S_BLANK
just initialized
Definition DiskList.h:168
State m_state
the current state
Definition DiskList.h:174
std::string fileName() const
the filename for the current entry
Definition DiskList.cxx:88
virtual ~DiskList()
standard destructor
Definition DiskList.cxx:37
virtual std::string getPath() const =0
the path for the current entry.
virtual bool getNext()=0
get the next list entry
void testInvariant() const
test the invariant of this object
Definition DiskList.cxx:30
DiskList * openDir() const
make a new list object for the sub-directory
Definition DiskList.cxx:101
bool next()
get the next list entry
Definition DiskList.cxx:54
DiskList()
standard constructor
Definition DiskList.cxx:45
std::string dirname() const
the base path for the directory listed
Definition DiskList.cxx:111
This module provides a lot of global definitions, forward declarations and includes that are used by ...
Definition PrunDriver.h:15