Skip to content

Commit 08c07c0

Browse files
committed
Finish 3.1.11
2 parents b3a258f + c412806 commit 08c07c0

11 files changed

Lines changed: 971 additions & 1135 deletions

File tree

Gemfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,6 @@ group :test do
3131
gem "rake"
3232
gem "equivalent-xml"
3333
gem 'fasterer'
34-
gem 'simplecov', require: false, platforms: :mri
35-
gem 'coveralls', '~> 0.8', require: false, platforms: :mri
34+
gem 'simplecov', '~> 0.16', platforms: :mri
35+
gem 'coveralls', '~> 0.8', platforms: :mri
3636
end

README.md

Lines changed: 33 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,26 @@ This is a pure-Ruby library for working with [Resource Description Framework
1010
[![Coverage Status](https://coveralls.io/repos/ruby-rdf/rdf/badge.svg?branch=develop)](https://coveralls.io/github/ruby-rdf/rdf?branch=develop)
1111
[![Gitter chat](https://badges.gitter.im/ruby-rdf/rdf.png)](https://gitter.im/ruby-rdf/rdf)
1212

13+
## Table of contents
14+
15+
1. [Features](#features)
16+
2. [Differences between RDF 1.0 and RDF 1.1](#differences-between-rdf-1-0-and-rdf-1-1)
17+
3. [Tutorials](#tutorials)
18+
4. [Command Line](#command-line)
19+
5. [Examples](#examples)
20+
6. [Reader/Writer convenience methods](#reader/writer-convenience-methods)
21+
7. [RDF* (RDFStar)](#rdf*-(rdfstar))
22+
8. [Documentation](#documentation)
23+
9. [Dependencies](#dependencies)
24+
10. [Installation](#installation)
25+
11. [Download](#download)
26+
12. [Resources](#resources)
27+
13. [Mailing List](#mailing-list)
28+
14. [Authors](#authors)
29+
15. [Contributors](#contributors)
30+
16. [Contributing](#contributing)
31+
17. [License](#license)
32+
1333
## Features
1434

1535
* 100% pure Ruby with minimal dependencies and no bloat.
@@ -41,7 +61,7 @@ middleware.
4161

4262
See {RDF::Util::File} for configuring other mechanisms for retrieving resources.
4363

44-
### Term caching and configuration.
64+
### Term caching and configuration
4565

4666
RDF.rb uses a weak-reference cache for storing internalized versions of URIs and Nodes. This is particularly useful for Nodes as two nodes are equivalent only if they're the same node.
4767

@@ -76,7 +96,7 @@ the 1.1 release of RDF.rb:
7696
* {RDF::Util::File.open\_file} now performs redirects and manages `base_uri` based on W3C recommendations:
7797
* `base_uri` is set to the original URI if a status 303 is provided, otherwise any other redirect will set `base_uri` to the redirected location.
7898
* `base_uri` is set to the content of the `Location` header if status is _success_.
79-
* Additionally, {RDF::Util::File.open\_file} sets the result encoding from `charset` if provided, defaulting to `UTF-8`. Other access methods include `last_modified` and `content_type`,
99+
* Additionally, {RDF::Util::File.open\_file} sets the result encoding from `charset` if provided, defaulting to `UTF-8`. Other access methods include `last_modified` and `content_type`,
80100
* {RDF::StrictVocabulary} added with an easy way to keep vocabulary definitions up to date based on their OWL or RDFS definitions. Most vocabularies are now StrictVocabularies meaning that an attempt to resolve a particular term in that vocabulary will error if the term is not defined in the vocabulary.
81101
* New vocabulary definitions have been added for [ICal](http://www.w3.org/2002/12/cal/icaltzd#), [Media Annotations (MA)](http://www.w3.org/ns/ma-ont#), [Facebook OpenGraph (OG)](http://ogp.me/ns#), [PROV](http://www.w3.org/ns/prov#), [SKOS-XL (SKOSXL)](http://www.w3.org/2008/05/skos-xl#), [Data Vocabulary (V)](http://rdf.data-vocabulary.org/), [VCard](http://www.w3.org/2006/vcard/ns#), [VOID](http://rdfs.org/ns/void#http://rdfs.org/ns/void#), [Powder-S (WDRS)](http://www.w3.org/2007/05/powder-s#), and [XHV](http://www.w3.org/1999/xhtml/vocab#).
82102

@@ -89,6 +109,7 @@ Notably, {RDF::Queryable#query} and {RDF::Query#execute} are now completely symm
89109
* [Getting started with RDF and SPARQL using 4store and RDF.rb](https://www.jenitennison.com/blog/node/152)
90110

91111
## Command Line
112+
92113
When installed, RDF.rb includes a `rdf` shell script which acts as a wrapper to perform a number of different
93114
operations on RDF files using available readers and writers.
94115

@@ -112,7 +133,7 @@ Different RDF gems will augment the `rdf` script with more capabilities, which m
112133
require 'rdf/ntriples'
113134
graph = RDF::Graph.new << [:hello, RDF::RDFS.label, "Hello, world!"]
114135
graph.dump(:ntriples)
115-
136+
116137
or
117138

118139
RDF::Writer.open("hello.nt") { |writer| writer << graph }
@@ -121,7 +142,7 @@ or
121142

122143
require 'rdf/ntriples'
123144
graph = RDF::Graph.load("https://ruby-rdf.github.com/rdf/etc/doap.nt")
124-
145+
125146
or
126147

127148
RDF::Reader.open("https://ruby-rdf.github.com/rdf/etc/doap.nt") do |reader|
@@ -131,19 +152,20 @@ or
131152
end
132153

133154
### Reading RDF data in other formats
155+
134156
{RDF::Reader.open} and {RDF::Repository.load} use a number of mechanisms to determine the appropriate reader
135157
to use when loading a file. The specific format to use can be forced using, e.g. `format: :ntriples`
136158
option where the specific format symbol is determined by the available readers. Both also use
137159
MimeType or file extension, where available.
138160

139161
require 'rdf/nquads'
140-
162+
141163
graph = RDF::Graph.load("https://ruby-rdf.github.com/rdf/etc/doap.nq", format: :nquads)
142164

143165
A specific sub-type of Reader can also be invoked directly:
144166

145167
require 'rdf/nquads'
146-
168+
147169
RDF::NQuads::Reader.open("https://ruby-rdf.github.com/rdf/etc/doap.nq") do |reader|
148170
reader.each_statement do |statement|
149171
puts statement.inspect
@@ -157,6 +179,7 @@ be detected from filename or other options, or that more than one format is iden
157179
match will be used to read the input.
158180

159181
### Writing RDF data using other formats
182+
160183
{RDF::Writer.open}, {RDF::Enumerable#dump}, {RDF::Writer.dump} take similar options to {RDF::Reader.open} to determine the
161184
appropriate writer to use.
162185

@@ -176,6 +199,7 @@ A specific sub-type of Writer can also be invoked directly:
176199
File.open("hello.nq", "w") {|f| f << repo.dump(:nquads)}
177200

178201
## Reader/Writer convenience methods
202+
179203
{RDF::Enumerable} implements `to_{format}` for each available instance of {RDF::Reader}.
180204
For example, if `rdf/turtle` is loaded, this allows the following:
181205

@@ -195,7 +219,7 @@ Note that no prefixes are loaded automatically, however they can be provided as
195219
### Querying RDF data using basic graph patterns (BGPs)
196220

197221
require 'rdf/ntriples'
198-
222+
199223
graph = RDF::Graph.load("https://ruby-rdf.github.com/rdf/etc/doap.nt")
200224
query = RDF::Query.new({
201225
person: {
@@ -204,7 +228,7 @@ Note that no prefixes are loaded automatically, however they can be provided as
204228
FOAF.mbox => :email,
205229
}
206230
}, **{})
207-
231+
208232
query.execute(graph) do |solution|
209233
puts "name=#{solution.name} email=#{solution.email}"
210234
end
@@ -451,7 +475,6 @@ This repository uses [Git Flow](https://github.com/nvie/gitflow) to mange develo
451475
which you will be asked to agree to on the first commit to a repo within the organization.
452476
Note that the agreement applies to all repos in the [Ruby RDF](https://github.com/ruby-rdf/) organization.
453477

454-
455478
## License
456479

457480
This is free and unencumbered public domain software. For more information,
@@ -492,4 +515,4 @@ see <https://unlicense.org/> or the accompanying {file:UNLICENSE} file.
492515
[JSON::LD]: https://ruby-rdf.github.com/json-ld
493516
[RestClient]: https://rubygems.org/gems/rest-client
494517
[RestClient Components]: https://rubygems.org/gems/rest-client-components
495-
[Rack::Cache]: https://rtomayko.github.io/rack-cache/
518+
[Rack::Cache]: https://rtomayko.github.io/rack-cache/

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
3.1.10
1+
3.1.11

0 commit comments

Comments
 (0)