rename.c File Reference

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <grass/gis.h>

Include dependency graph for rename.c:

Go to the source code of this file.

Functions

int G_rename (char *element, char *oldname, char *newname)
 rename a database file


Function Documentation

int G_rename ( char *  element,
char *  oldname,
char *  newname 
)

rename a database file

The file or directory old under the database element directory in the current mapset is renamed to new. Returns 1 if successful, 0 if old does not exist, and -1 if there was an error. Bug. This routine does not check to see if the new name is a valid database file name.

Parameters:
element 
old 
new 
Returns:
int

Definition at line 39 of file rename.c.

References G__file_name(), G__name_is_fully_qualified(), and G_mapset().


Generated on Sun Apr 6 17:32:25 2008 for GRASS by  doxygen 1.5.5