GRASS GIS 8 Programmer's Manual  8.4.0dev(2024)-535c39c9fc
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

◆ I_get_target()

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 g.gui.gcp 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 _, G_suppress_warnings(), G_warning(), I_fopen_group_file_old(), and NULL.

◆ I_put_target()

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 61 of file target.c.

References I_fopen_group_file_new(), and NULL.