GRASS Programmer's Manual  6.5.svn(2014)-r66266
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
target.c File Reference
#include <stdio.h>
#include <grass/gis.h>
#include <grass/imagery.h>
#include <grass/glocale.h>
Include dependency graph for target.c:

Go to the source code of this file.

Functions

int I_get_target (const char *group, char *location, char *mapset)
 read target information More...
 
int I_put_target (const char *group, const char *location, const char *mapset)
 write target information More...
 

Function Documentation

int I_get_target ( const char *  group,
char *  location,
char *  mapset 
)

read target information

Reads the target location and mapset from the TARGET file for the specified group. Returns 1 if successful; 0 otherwise (and prints a diagnostic error). This routine is used by i.points and i.rectify and probably should not be used by other programs. Note. This routine does not validate the target information.

Parameters
group
location
mapset
Returns
int

Definition at line 22 of file target.c.

References fclose(), fd, G_suppress_warnings(), G_warning(), I_fopen_group_file_old(), and NULL.

int I_put_target ( const char *  group,
const char *  location,
const char *  mapset 
)

write target information

Writes the target location and mapset to the TARGET file for the specified group. Returns 1 if successful; 0 otherwise (but no error messages are printed). This routine is used by i.target and probably should not be used by other programs. Note. This routine does not validate the target information.

Parameters
group
location
mapset
Returns
int

Definition at line 62 of file target.c.

References fclose(), fd, I_fopen_group_file_new(), and NULL.