GIS library - find GRASS data base files. More...
#include <string.h>
#include <unistd.h>
#include <grass/gis.h>
#include <grass/glocale.h>
Go to the source code of this file.
Functions | |
char * | G_find_file (const char *element, char *name, const char *mapset) |
searches for a file from the mapset search list or in a specified mapset. returns the mapset name where the file was found. | |
char * | G_find_file_misc (const char *dir, const char *element, char *name, const char *mapset) |
char * | G_find_file2 (const char *element, const char *name, const char *mapset) |
searches for a file from the mapset search list or in a specified mapset. (look but don't touch) returns the mapset name where the file was found. | |
char * | G_find_file2_misc (const char *dir, const char *element, const char *name, const char *mapset) |
GIS library - find GRASS data base files.
(C) 2001-2008 by the GRASS Development Team
This program is free software under the GNU General Public License (>=v2). Read the file COPYING that comes with GRASS for details.
Definition in file find_file.c.
char* G_find_file | ( | const char * | element, |
char * | name, | ||
const char * | mapset | ||
) |
searches for a file from the mapset search list or in a specified mapset. returns the mapset name where the file was found.
notes:
If the user specifies a fully qualified element (name) which exists, then G_find_file() modifies name by removing the "@<i>mapset</i>" part.
Rejects all names that begin with "."
If name is of the form nnn in ppp then only mapset ppp is searched.
const | char *element database element (eg, "cell", "cellhd", "colr", etc) |
char | *name file name to look for |
const | char *mapset mapset to search. if mapset is "" will search in mapset search list |
Definition at line 159 of file find_file.c.
References NULL.
Referenced by G_find_cell(), and G_find_vector().
char* G_find_file2 | ( | const char * | element, |
const char * | name, | ||
const char * | mapset | ||
) |
searches for a file from the mapset search list or in a specified mapset. (look but don't touch) returns the mapset name where the file was found.
Exactly the same as G_find_file() except that if name is in the form "<i>name@mapset</i>", and is found, G_find_file2() will not alter name by removing the "@<i>mapset</i>" part.
note: rejects all names that begin with "."
char | *element database element (eg, "cell", "cellhd", "colr", etc) |
char | *name file name to look for |
char | *mapset mapset to search. if mapset is "" will search in mapset search list |
Definition at line 191 of file find_file.c.
References NULL.
Referenced by G_find_cell2(), G_find_vector2(), and G_get_3dview().
char* G_find_file2_misc | ( | const char * | dir, |
const char * | element, | ||
const char * | name, | ||
const char * | mapset | ||
) |
Definition at line 196 of file find_file.c.
Referenced by G__raster_misc_read_line(), G_read_fp_range(), G_read_histogram(), and G_read_range().
char* G_find_file_misc | ( | const char * | dir, |
const char * | element, | ||
char * | name, | ||
const char * | mapset | ||
) |
Definition at line 164 of file find_file.c.