56 |
* -1: error |
* -1: error |
57 |
*/ |
*/ |
58 |
int |
int |
59 |
gpath_open(dbpath, mode) |
gpath_open(const char *dbpath, int mode) |
|
const char *dbpath; |
|
|
int mode; |
|
60 |
{ |
{ |
61 |
assert(opened == 0); |
assert(opened == 0); |
62 |
/* |
/* |
86 |
* i) path path name |
* i) path path name |
87 |
*/ |
*/ |
88 |
void |
void |
89 |
gpath_put(path) |
gpath_put(const char *path) |
|
const char *path; |
|
90 |
{ |
{ |
91 |
char fid[32]; |
char fid[32]; |
92 |
|
|
106 |
* r) file id |
* r) file id |
107 |
*/ |
*/ |
108 |
const char * |
const char * |
109 |
gpath_path2fid(path) |
gpath_path2fid(const char *path) |
|
const char *path; |
|
110 |
{ |
{ |
111 |
assert(opened == 1); |
assert(opened == 1); |
112 |
return dbop_get(dbop, path); |
return dbop_get(dbop, path); |
118 |
* r) path name |
* r) path name |
119 |
*/ |
*/ |
120 |
const char * |
const char * |
121 |
gpath_fid2path(fid) |
gpath_fid2path(const char *fid) |
|
const char *fid; |
|
122 |
{ |
{ |
123 |
return dbop_get(dbop, fid); |
return dbop_get(dbop, fid); |
124 |
} |
} |
128 |
* i) path path name |
* i) path path name |
129 |
*/ |
*/ |
130 |
void |
void |
131 |
gpath_delete(path) |
gpath_delete(const char *path) |
|
const char *path; |
|
132 |
{ |
{ |
133 |
const char *fid; |
const char *fid; |
134 |
|
|
190 |
* gfind_open: start iterator using GPATH. |
* gfind_open: start iterator using GPATH. |
191 |
*/ |
*/ |
192 |
void |
void |
193 |
gfind_open(dbpath, local) |
gfind_open(const char *dbpath, const char *local) |
|
const char *dbpath; |
|
|
const char *local; |
|
194 |
{ |
{ |
195 |
assert(gfind_opened == 0); |
assert(gfind_opened == 0); |
196 |
assert(gfind_first == 0); |
assert(gfind_first == 0); |