LibPkg
auto_dir.h
Go to the documentation of this file.
1 // This file is part of the LibPkg.
2 //
3 // Copyright 2003-2020 Graham Shaw
4 //
5 // Licensed under the Apache License, Version 2.0 (the "License");
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
8 //
9 // http://www.apache.org/licenses/LICENSE-2.0
10 //
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an "AS IS" BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
16 
17 #ifndef LIBPKG_AUTO_DIR
18 #define LIBPKG_AUTO_DIR
19 
20 #include <string>
21 
22 namespace pkg {
23 
24 using std::string;
25 
31 class auto_dir
32 {
33 private:
35  string _pathname;
36 public:
40  auto_dir();
41 
45  ~auto_dir();
46 
52  void operator()(const string& pathname);
53 };
54 
55 }; /* namespace pkg */
56 
57 #endif
The namespace used to hold the package management library.
Definition: auto_dir.cc:23
A class for automatically creating and deleting directories.
Definition: auto_dir.h:31
~auto_dir()
Destroy auto-directory object.
Definition: auto_dir.cc:50
void operator()(const string &pathname)
Move to new pathname.
Definition: auto_dir.cc:53
auto_dir()
Construct auto-directory object.
Definition: auto_dir.cc:47

Reference Manual LibPkg Version 0.9.0 (4 Sep 2020)