1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71
|
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/rdf.R
\name{rdf}
\alias{rdf}
\title{Initialize an \code{rdf} Object}
\usage{
rdf(
storage = c("memory", "BDB", "sqlite", "postgres", "mysql", "virtuoso"),
host = NULL,
port = NULL,
user = NULL,
password = NULL,
database = NULL,
charset = NULL,
dir = NULL,
dsn = "Local Virtuoso",
name = "rdflib",
new_db = FALSE,
fallback = TRUE
)
}
\arguments{
\item{storage}{Storage backend to use; see details}
\item{host}{host address for mysql, postgres, or virtuoso storage}
\item{port}{port for mysql (mysql storage defaults to mysql standard port, 3306)
or postgres (postgres storage defaults to postgres standard port, 4321)}
\item{user}{user name for postgres, mysql, or virtuoso}
\item{password}{password for postgres, mysql, or virtuoso}
\item{database}{name of the database to be created/used}
\item{charset}{charset for virtuoso database, if desired}
\item{dir}{directory of where to write sqlite or berkeley database.}
\item{dsn}{Virtuoso dsn, either "Local Virtuoso" or "Remote Virtuoso"}
\item{name}{name for the storage object created. Default is usually fine.}
\item{new_db}{logical, default FALSE. Create new database or connect to existing?}
\item{fallback}{logical, default TRUE. If requested storage system cannot initialize,
should \code{rdf()} fall back on memory (default) or throw an error (fallback=FALSE)?}
}
\value{
an rdf object
}
\description{
Initialize an \code{rdf} Object
}
\details{
an rdf Object is a list of class 'rdf', consisting of
three pointers to external C objects managed by the redland library.
These are the \code{world} object: basically a top-level pointer for
all RDF models, and a \code{model} object: a collection of RDF statements,
and a \code{storage} object, indicating how these statements are stored.
\code{rdflib} defaults to an in-memory hash-based storage structure.
which should be best for most use cases. For very large triplestores,
disk-based storage will be necessary. Enabling external storage devices
will require additional libraries and custom compiling. See the storage
vignette for details.
}
\examples{
x <- rdf()
}
|