Loading...
Searching...
No Matches
gisinit.c File Reference

GIS Library - Handles program initialization. More...

`#include <stdio.h>`
`#include <stdlib.h>`
`#include <string.h>`
`#include <ctype.h>`
`#include <unistd.h>`
`#include <fcntl.h>`
`#include <sys/stat.h>`
`#include <locale.h>`
`#include <grass/gis.h>`
`#include <grass/glocale.h>`
`#include "G.h"`
`#include "gis_local_proto.h"`
Include dependency graph for gisinit.c:

Go to the source code of this file.

## Functions

void | G__gisinit (const char *version, const char *pgm)
| Initialize GIS Library and ensures a valid mapset is available.
void | G__no_gisinit (const char *version)
| Initialize GIS Library.
void | G__check_gisinit (void)
| Checks to see if GIS engine is initialized.
void | G_init_all (void)
| Initialize environment.

## Variables

struct G__ | G__

## Detailed Description

GIS Library - Handles program initialization.

(C) 2001-2008, 2011 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.

Author
  GRASS Development Team

Definition in file gisinit.c.

## Function Documentation

## G__check_gisinit()

void G__check_gisinit | ( | void |  | ) |

Checks to see if GIS engine is initialized.

Definition at line 148 of file gisinit.c.

References G_sleep(), and G_warning().

Referenced by G_init_all().

## G__gisinit()

void G__gisinit | ( | const char * | version,
|  | const char * | pgm )

Initialize GIS Library and ensures a valid mapset is available.

Parameters

  version |
  pgm | program (module) name

Returns
  always returns 0 on success
  G_fatal_error() is called on error

Definition at line 62 of file gisinit.c.

References G_fatal_error(), G_location_path(), G_mapset(), G_mapset_permissions(), G_set_program_name(), and G_warning().

## G__no_gisinit()

void G__no_gisinit | ( | const char * | version | ) |

Initialize GIS Library.

Initializes GIS engine, but does not check for a valid mapset.

Definition at line 116 of file gisinit.c.

References G_fatal_error(), and G_warning().

## G_init_all()

void G_init_all | ( | void |  | ) |

Initialize environment.

Definition at line 191 of file gisinit.c.

References G__check_gisinit(), G__get_list_of_mapsets(), G__home(), G__init_window(), G__machine_name(), G_init_debug(), G_init_env(), G_init_locale(), G_init_logging(), G_init_tempfile(), G_read_datum_table(), G_read_ellipsoid_table(), G_verbose(), and G_whoami().

## Variable Documentation

## G__

struct G__ G__

Definition at line 37 of file gisinit.c.