https://github.com/cran/ff
Raw File
Tip revision: b82d64dd58ab43c37e8364118746a9398280d69e authored by Jens Oehlschl\xe4gel on 29 March 2012, 00:00:00 UTC
version 2.2-9
Tip revision: b82d64d
open.ff.rd
\name{open.ff}
\alias{open.ff}
\alias{open.ffdf}
\title{ Opening an ff file }
\description{
  \command{open.ff} opens an ff file, optionally marking it readonly and optionally specifying a caching scheme.
}
\usage{
 \method{open}{ff}(con, readonly = FALSE, pagesize = NULL, caching = NULL, \dots)
 \method{open}{ffdf}(con, readonly = FALSE, pagesize = NULL, caching = NULL, \dots)
}
\arguments{
  \item{con}{ an \code{\link{ff}} or \code{\link{ffdf}} object }
  \item{readonly}{ \code{readonly} }
  \item{pagesize}{ number of bytes to use as pagesize or NULL to take the pagesize stored in the \code{\link[=physical.ff]{physical}} attribute of the ff object, see \code{\link{getalignedpagesize}} }
  \item{caching}{ one of 'mmnoflush' or 'mmeachflush', see \code{\link{ff}} }
  \item{\dots}{ further arguments (not used) }
}
\details{
  ff objects will be opened automatically when accessing their content and the file is still closed.
  Opening ffdf objects will open all of their \code{\link[=physical.ffdf]{physical}} components including their \code{\link[=row.names.ffdf]{row.names}} if they are \code{\link{is.ff}}
}
\value{
  TRUE if object could be opened, FALSE if it was opened already (or NA if not all components of an ffdf returned FALSE or TRUE on opening)
}
\author{ Jens Oehlschl‰gel }
\seealso{ \code{\link{ff}}, \code{\link{close.ff}}, \code{\link{delete}}, \code{\link{deleteIfOpen}}, \code{\link{getalignedpagesize}} }
\examples{
  x <- ff(1:12)
  close(x)
  is.open(x)
  open(x)
  is.open(x)
  close(x)
  is.open(x)
  x[]
  is.open(x)
  y <- x
  close(y)
  is.open(x)
  rm(x,y); gc()
}
\keyword{ IO }
\keyword{ data }
back to top