1\name{GDALDriver-class}
2\docType{class}
3\alias{GDALDriver-class}
4\alias{getGDALDriverNames}
5\alias{gdalDrivers}
6\alias{getDriverName}
7\alias{getDriverLongName}
8\alias{initialize,GDALDriver-method}
9\alias{getGDALVersionInfo}
10\alias{getGDAL_DATA_Path}
11\alias{getGDALCheckVersion}
12\alias{getGDALwithGEOS}
13\alias{getCPLConfigOption}
14\alias{setCPLConfigOption}
15\alias{rgdal_extSoftVersion}
16\alias{get_cached_orig_PROJ_LIB}
17\alias{get_cached_set_PROJ_LIB}
18\alias{get_cached_orig_GDAL_DATA}
19\alias{get_cached_set_GDAL_DATA}
20\title{Class "GDALDriver": GDAL Driver Object}
21
22\description{\code{GDALDriver} objects encapsulate GDAL file format
23  drivers. \code{GDALDriver} inherits from \code{\link{GDALMajorObject-class}}.}
24
25\section{Objects from the Class}{
26Objects can be created by calls of the form \code{new("GDALDriver", name, handle)}, where name: a string giving the name of a GDAL driver, handle: used internally; not for public consumption (default = NULL).
27}
28
29\section{Slots}{
30  \describe{
31    \item{\code{handle}:}{Object of class \code{"externalptr", from class "GDALMajorObject"}, used internally; not for public consumption}
32  }
33}
34\section{Extends}{
35Class \code{"GDALMajorObject"}, directly.
36}
37\section{Methods}{
38  \describe{
39    \item{initialize}{\code{signature(.Object = "GDALDriver")}: drivername: a string giving the name of a GDAL driver, handle: used internally; not for public consumption (default = NULL) }
40  }
41}
42\usage{
43getGDALDriverNames()
44gdalDrivers()
45getDriverName(driver)
46getDriverLongName(driver)
47getGDALVersionInfo(str = "--version")
48getGDALCheckVersion()
49getGDALwithGEOS()
50rgdal_extSoftVersion()
51getCPLConfigOption(ConfigOption)
52setCPLConfigOption(ConfigOption, value)
53get_cached_orig_PROJ_LIB()
54get_cached_orig_GDAL_DATA()
55get_cached_set_PROJ_LIB()
56get_cached_set_GDAL_DATA()
57}
58\arguments{
59  \item{driver}{An object inheriting from class 'GDALDriver'}
60  \item{str}{A string, may be one of \code{"--version"}, \code{"VERSION_NUM"}, \code{"RELEASE_DATE"}, \code{"RELEASE_NAME"}}
61  \item{ConfigOption}{CPL configure option documented in \url{https://trac.osgeo.org/gdal/wiki/ConfigOptions} and elsewhere in GDAL source code}
62  \item{value}{a string value to set a CPL option; NULL is used to unset the CPL option}
63}
64
65\details{
66  \describe{
67    \item{\code{getGDALDriverNames, gdalDrivers}:}{returns all driver names currently installed in GDAL, with their declared create and copy status (some drivers can create datasets, others can only copy from a prototype with a different driver.}
68
69    \item{\code{getDriverName}:}{returns the GDAL driver name associated
70      with the driver object.}
71
72    \item{\code{getDriverLongName}:}{returns a longer driver name.}
73    \item{\code{getGDALVersionInfo}:}{returns the version of the GDAL runtime shared object.}
74    \item{\code{getGDALCheckVersion}:}{checks the version of the GDAL headers used when building the package (GDAL_VERSION_MAJOR, GDAL_VERSION_MINOR) - if the two versions differ, problems may arise (the C++ API/ABI may have changed), and rgdal should be re-installed}
75    \item{\code{getGDALwithGEOS}:}{because drivers may behave differently if GDAL itself was built with GEOS support, the function uses a heuristic to check whether GDAL has access to the GEOS Union function or not}
76    \item{\code{get_cached_orig_PROJ_LIB}, \code{get_cached_orig_GDAL_DATA}}{The values of environment variables PROJ_LIB and GDAL_DATA as read when this package was loaded}
77    \item{\code{get_cached_set_PROJ_LIB}, \code{get_cached_set_GDAL_DATA}}{If not \code{""}, the values set when loading this package to point to metadata files included in CRAN binary packages}
78}
79}
80
81\note{Loading the rgdal package changes the \code{GDAL\_DATA} environmental variable to the GDAL support files bundled with the package.}
82
83\author{Timothy H. Keitt, modified by Roger Bivand}
84
85\seealso{\code{\link{GDALMajorObject-class}}}
86
87\examples{
88gdalDrivers()
89logo <- system.file("pictures/logo.jpg", package="rgdal")[1]
90x <- new("GDALReadOnlyDataset", logo)
91getDriver(x)
92getDriverLongName(getDriver(x))
93GDAL.close(x)
94}
95\keyword{classes}
96