Learn R Programming

dataone (version 2.2.2)

getObject: Get the bytes associated with an object on this Node.

Description

Get the bytes associated with an object on this Node.

Usage

getObject(x, ...)

# S4 method for CNode getObject(x, pid)

# S4 method for MNode getObject(x, pid, check = as.logical(FALSE))

Arguments

x

The Node instance from which the pid will be downloaded

...

(Not yet used).

pid

The identifier of the object to be downloaded

check

A logical value, if TRUE check if this object has been obsoleted by another object in DataONE.

Value

the bytes of the object

Details

This operation acts as the 'public' anonymous user unless an X.509 certificate is present in the default location of the file system, in which case the access will be authenticated.

See Also

D1Node-class{D1Node} class description.

Examples

Run this code
# NOT RUN {
library(dataone)
cn <- CNode()
mn <- getMNode(cn, "urn:node:KNB")
pid <- "solson.5.1"
obj <- getObject(mn, pid)
df <- read.csv(text=rawToChar(obj))
# }

Run the code above in your browser using DataLab