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
6
7#ifndef SAMPLE_HANDLER__DISK_LIST_H
8#define SAMPLE_HANDLER__DISK_LIST_H
9
11
12#include <memory>
13#include <string>
14
15namespace SH
16{
25 {
26 //
27 // public interface
28 //
29
34 public:
35 void testInvariant () const;
36
37
44 public:
45 virtual ~DiskList ();
46
47
55 public:
56 bool next ();
57
58
66 public:
67 std::string path () const;
68
69
78 public:
79 std::string fileName () const;
80
81
91 public:
92 [[deprecated("use openDirUnique() instead")]]
93 DiskList *openDir () const;
94
95
105 public:
106 std::unique_ptr<DiskList> openDirUnique () const;
107
108
114 public:
115 std::string dirname () const;
116
117
118
119 //
120 // protected interface
121 //
122
129 protected:
130 DiskList ();
131
132
133
134 //
135 // virtual interface
136 //
137
141 protected:
142 virtual bool getNext () = 0;
143
144
148 protected:
149 virtual std::string getPath () const = 0;
150
151
155 protected:
156 virtual DiskList *doOpenDir () const = 0;
157
158
162 protected:
163 virtual std::string getDirname () const = 0;
164
165
166
167 //
168 // private interface
169 //
170
172 private:
180
182 };
183}
184
185#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:71
virtual std::string getDirname() const =0
the base path for the directory listed
State
the current state
Definition DiskList.h:174
@ S_VALID
holding a valid entry
Definition DiskList.h:176
@ S_DONE
finished reading entries
Definition DiskList.h:177
@ S_BROKEN
an error occured
Definition DiskList.h:178
@ S_BLANK
just initialized
Definition DiskList.h:175
State m_state
the current state
Definition DiskList.h:181
std::string fileName() const
the filename for the current entry
Definition DiskList.cxx:81
virtual ~DiskList()
standard destructor
Definition DiskList.cxx:30
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:23
DiskList * openDir() const
make a new list object for the sub-directory
Definition DiskList.cxx:94
bool next()
get the next list entry
Definition DiskList.cxx:47
std::unique_ptr< DiskList > openDirUnique() const
make a new list object for the sub-directory
Definition DiskList.cxx:104
DiskList()
standard constructor
Definition DiskList.cxx:38
std::string dirname() const
the base path for the directory listed
Definition DiskList.cxx:114
This module provides a lot of global definitions, forward declarations and includes that are used by ...
Definition PrunDriver.h:15