Pol  Revision:4b29d2b
dirfunc.h
Go to the documentation of this file.
1 #ifndef __DIRFUNC_H
2 
3 #define __DIRFUNC_H
4 
5 #if defined( WINDOWS )
6 #include "Header_Windows.h"
7 #include <stdlib.h>
8 #else
9 #include <dir.h>
10 #endif
11 namespace Pol
12 {
13 namespace Clib
14 {
15 #define MAXFULLDIR ( MAXDRIVE + MAXDIR - 1 )
16 
17 #define MAXFNAME ( MAXFILE + MAXEXT - 1 )
18 
19 typedef char Directory[MAXFULLDIR];
20 typedef char File1[MAXFILE];
21 typedef char FFile[MAXFNAME];
22 typedef char Pathname[MAXPATH];
23 
24 extern char temp_path[MAXPATH];
25 extern char temp_drive[MAXDRIVE];
26 extern char temp_dir[MAXDIR];
27 extern char temp_fname[MAXFILE];
28 extern char temp_ext[MAXEXT];
29 
30 int fullsplit( const char* path );
31 char* fullmerge( char* path );
32 char* mergeFnExt( char* path );
33 
34 char* nodefile( const char* directory, const char* filename, int node );
35 char* buildfn( const char* directory, const char* filename );
36 char* buildfnext( const char* dir, const char* file, const char* ext );
37 void normalize_dir( char* dir );
38 
39 
40 enum
41 {
47 };
48 
49 extern int mydir_errno;
50 
51 int copyFile( const char* src, const char* dst );
52 int copyFileNoRep( const char* src, const char* dst );
53 
54 int moveFile( const char* src, const char* dst );
55 int moveFileNoRep( const char* src, const char* dst );
56 
57 int chddir( const char* directory );
58 }
59 }
60 #endif
int moveFileNoRep(const char *src, const char *dst)
Definition: dirfunc.cpp:287
int copyFileNoRep(const char *src, const char *dst)
Definition: dirfunc.cpp:261
char temp_ext[MAXEXT]
Definition: dirfunc.cpp:32
char * buildfnext(const char *directory, const char *filename, const char *extension)
Definition: dirfunc.cpp:144
char * buildfn(const char *directory, const char *filename)
Definition: dirfunc.cpp:134
#define MAXFULLDIR
Definition: dirfunc.h:15
char temp_dir[MAXDIR]
Definition: dirfunc.cpp:30
int moveFile(const char *src, const char *dst)
Definition: dirfunc.cpp:282
char temp_drive[MAXDRIVE]
Definition: dirfunc.cpp:29
int mydir_errno
Definition: dirfunc.cpp:169
char FFile[MAXFNAME]
Definition: dirfunc.h:21
void normalize_dir(char *dir)
Definition: dirfunc.cpp:159
int copyFile(const char *src, const char *dst)
Definition: dirfunc.cpp:255
char temp_path[MAXPATH]
Definition: dirfunc.cpp:28
int chddir(const char *dir)
Definition: dirfunc.cpp:76
char * nodefile(const char *directory, const char *filename, int node)
Definition: dirfunc.cpp:123
char * fullmerge(char *path)
Definition: dirfunc.cpp:50
#define MAXFNAME
Definition: dirfunc.h:17
char temp_fname[MAXFILE]
Definition: dirfunc.cpp:31
int fullsplit(const char *path)
Definition: dirfunc.cpp:34
char * mergeFnExt(char *fname)
Definition: dirfunc.cpp:65
char Pathname[MAXPATH]
Definition: dirfunc.h:22
char Directory[MAXFULLDIR]
Definition: dirfunc.h:19
char File1[MAXFILE]
Definition: dirfunc.h:20
Definition: berror.cpp:12