21 #include <grass/gis.h>
42 return rename(oldname, newname);
62 int G_rename(
const char *element,
const char *oldname,
const char *newname)
66 char from[512], to[512];
71 && strcmp(mapset, xmapset))
74 && strcmp(mapset, xmapset))
78 if (access(
G__file_name(from, element, oldname, mapset), 0) != 0)
char * G_mapset(void)
current mapset name
int G_rename(const char *element, const char *oldname, const char *newname)
Rename a database file.
char * G__file_name(char *path, const char *element, const char *name, const char *mapset)
Builds full path names to GIS data files.
int G_rename_file(const char *oldname, const char *newname)
Rename a file in the filesystem.
int G__name_is_fully_qualified(const char *fullname, char *name, char *mapset)
Check if map name is fully qualified (map @ mapset)