% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/archive.R
\name{archive}
\alias{archive}
\alias{set_archive}
\alias{get_archive}
\title{Session-wide archive directory}
\usage{
set_archive(dir_archive, create = T)

get_archive()
}
\arguments{
\item{dir_archive}{character, directory to the \code{getSpatialData} archive folder.}

\item{create}{logical, whether to create directory, if not existing or not.}
}
\description{
Functions that set and get a session-wide archive directory that can be used by all \code{getSpatialData} functions.
}
\details{
\code{set_archive} defines the session directory on your machine (or an external device) where getSpatialData should build up its donwload data archive. Since getSpatialData handles big amounts of data, it is recommended to once define a location where enough free storage is available and then afterwards to not change the archive location. You need to define the archives location for each session after loading getSpatialData. It will then be remembered for the duration of the session. Apart from the archive location, you can manually define a download path when calling the *_data functions. If you do not define a path there, getSpatialData will direct the download to the defined archive. The archive is structred by sensors.

\code{get_archive} returns the currently defined archive directory.
}
\examples{
## set archive directory
dir.arc <- tempdir()
set_archive(dir.arc)

## return current archive directory
get_archive()

}
\seealso{
get_data \link{get_previews}
}
\author{
Jakob Schwalb-Willmann
}
