A vector of RDF resources with descriptions held in an orthogonal table.

resource(uri = character(), description = data.frame(uri = unique(uri)))

is_resource(x)

Arguments

uri

A character vector of URIs

description

A data frame of descriptions (must have a uri column)

x

Any vector

Value

An S3 vector of class ldf_resource.

Examples

resource("http://example.net")
#> <ldf_resource[1]> #> [1] http://example.net #> Description: uri
uris <- c("http://example.net/id/apple", "http://example.net/id/banana", "http://example.net/id/carrot") labels <- c("Apple","Banana","Carrot") description <- data.frame(uri=uris, label=labels) r <- resource(uris, description)