blob: 3fe377ea93719b794f4d557d9aefe8bf5a1d76e2 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
/*
* CENA C++ Utilities
*
* by Stephane Chatty
*
* Copyright 1991, 1992
* Laboratoire de Recherche en Informatique (LRI)
* Centre d'Etudes de la Navigation Aerienne (CENA)
*
* management of search paths
*
* $Id$
* $CurLog$
*/
#ifndef DirPath_H_
#define DirPath_H_
#include "cplus_bugs.h"
#include "List.h"
class CcuDirPath : public CcuList {
public:
enum alloc_mode { DontAllocNames, DoAllocNames };
private:
alloc_mode Alloc;
public:
CcuDirPath ();
CcuDirPath (alloc_mode);
CcuDirPath (const char*);
CcuDirPath (const char*, const char*, ...);
~CcuDirPath ();
void Append (const char*);
void Prepend (const char*);
void AppendEnvPath (const char*, char sep = ':');
int Remove (const char*);
inline void SetAlloc (alloc_mode alloc) { Alloc = alloc; }
const char* FindFile (const char*, alloc_mode);
inline const char* FindFile (const char* fn) { return FindFile (fn, Alloc); }
};
#endif /* DirPath_H_ */
|