rdf-n3 0.3.8 → 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- data/History.markdown +1 -1
- data/README.markdown +3 -3
- data/VERSION +1 -1
- data/lib/rdf/n3/reader.rb +1 -1
- data/lib/rdf/n3/writer.rb +2 -2
- metadata +153 -141
data/History.markdown
CHANGED
@@ -84,7 +84,7 @@
|
|
84
84
|
* Compatible with RDF.rb 0.2.1
|
85
85
|
|
86
86
|
## 0.0.3
|
87
|
-
* Replace require against rdf/rdfxml/patches
|
87
|
+
* Replace require against rdf/rdfxml/patches/* with rdf/n3/patches/*
|
88
88
|
|
89
89
|
## 0.0.2
|
90
90
|
* N3 parsing and Turtle serialization substantially complete.
|
data/README.markdown
CHANGED
@@ -68,13 +68,13 @@ The parser is driven through a rules table contained in lib/rdf/n3/reader/meta.r
|
|
68
68
|
branch rules to indicate productions to be taken based on a current production. Terminals are denoted
|
69
69
|
through a set of regular expressions used to match each type of terminal.
|
70
70
|
|
71
|
-
The [meta.rb]
|
71
|
+
The [meta.rb][file:lib/rdf/n3/reader/meta.rb] file is generated from lib/rdf/n3/reader/n3-selectors.n3
|
72
72
|
(taken from http://www.w3.org/2000/10/swap/grammar/n3-selectors.n3) which is the result of parsing
|
73
73
|
http://www.w3.org/2000/10/swap/grammar/n3.n3 (along with bnf-rules.n3) using cwm using the following command sequence:
|
74
74
|
|
75
75
|
cwm n3.n3 bnf-rules.n3 --think --purge --data > n3-selectors.n3
|
76
76
|
|
77
|
-
[n3-selectors.n3]
|
77
|
+
[n3-selectors.n3][file:lib/rdf/n3/reader/n3-selectors.rb] is itself used to generate meta.rb using script/build_meta.
|
78
78
|
|
79
79
|
## TODO
|
80
80
|
* Generate Formulae and solutions using BGP and SPARQL CONSTRUCT mechanisms
|
@@ -145,7 +145,7 @@ see <http://unlicense.org/> or the accompanying {file:UNLICENSE} file.
|
|
145
145
|
* <http://lists.w3.org/Archives/Public/public-rdf-ruby/>
|
146
146
|
|
147
147
|
[RDF.rb]: http://rdf.rubyforge.org/
|
148
|
-
[RDF::Turtle]
|
148
|
+
[RDF::Turtle] http://github.com/ruby-rdf/rdf-turtle/
|
149
149
|
[N3]: http://www.w3.org/DesignIssues/Notation3.html "Notation-3"
|
150
150
|
[Turtle]: http://www.w3.org/TeamSubmission/turtle/
|
151
151
|
[N-Triples]: http://www.w3.org/2001/sw/RDFCore/ntriples/
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.
|
1
|
+
1.0.0
|
data/lib/rdf/n3/reader.rb
CHANGED
@@ -43,7 +43,7 @@ module RDF::N3
|
|
43
43
|
# @yield [reader] `self`
|
44
44
|
# @yieldparam [RDF::Reader] reader
|
45
45
|
# @yieldreturn [void] ignored
|
46
|
-
# @raise [Error] Raises RDF::ReaderError if validating and an error is found
|
46
|
+
# @raise [Error]:: Raises RDF::ReaderError if validating and an error is found
|
47
47
|
def initialize(input = $stdin, options = {}, &block)
|
48
48
|
super do
|
49
49
|
input.rewind if input.respond_to?(:rewind)
|
data/lib/rdf/n3/writer.rb
CHANGED
@@ -78,7 +78,7 @@ module RDF::N3
|
|
78
78
|
# @option options [Boolean] :standard_prefixes (false)
|
79
79
|
# Add standard prefixes to @prefixes, if necessary.
|
80
80
|
# @option options [String] :default_namespace (nil)
|
81
|
-
# URI to use as default namespace, same as
|
81
|
+
# URI to use as default namespace, same as prefixes[nil]
|
82
82
|
# @yield [writer] `self`
|
83
83
|
# @yieldparam [RDF::Writer] writer
|
84
84
|
# @yieldreturn [void]
|
@@ -291,7 +291,7 @@ module RDF::N3
|
|
291
291
|
def top_classes; [RDF::RDFS.Class]; end
|
292
292
|
|
293
293
|
# Defines order of predicates to to emit at begninning of a resource description. Defaults to
|
294
|
-
#
|
294
|
+
# [rdf:type, rdfs:label, dc:title]
|
295
295
|
# @return [Array<URI>]
|
296
296
|
def predicate_order; [RDF.type, RDF::RDFS.label, RDF::DC.title]; end
|
297
297
|
|
metadata
CHANGED
@@ -1,167 +1,168 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: rdf-n3
|
3
|
-
version: !ruby/object:Gem::Version
|
4
|
-
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
hash: 23
|
5
5
|
prerelease:
|
6
|
+
segments:
|
7
|
+
- 1
|
8
|
+
- 0
|
9
|
+
- 0
|
10
|
+
version: 1.0.0
|
6
11
|
platform: ruby
|
7
|
-
authors:
|
12
|
+
authors:
|
8
13
|
- Gregg
|
9
14
|
- Kellogg
|
10
15
|
autorequire:
|
11
16
|
bindir: bin
|
12
17
|
cert_chain: []
|
13
|
-
|
14
|
-
|
15
|
-
|
18
|
+
|
19
|
+
date: 2013-01-19 00:00:00 Z
|
20
|
+
dependencies:
|
21
|
+
- !ruby/object:Gem::Dependency
|
16
22
|
name: rdf
|
17
|
-
requirement: !ruby/object:Gem::Requirement
|
18
|
-
none: false
|
19
|
-
requirements:
|
20
|
-
- - ! '>='
|
21
|
-
- !ruby/object:Gem::Version
|
22
|
-
version: 0.3.11
|
23
|
-
type: :runtime
|
24
23
|
prerelease: false
|
25
|
-
|
26
|
-
none: false
|
27
|
-
requirements:
|
28
|
-
- -
|
29
|
-
- !ruby/object:Gem::Version
|
30
|
-
|
31
|
-
|
24
|
+
requirement: &id001 !ruby/object:Gem::Requirement
|
25
|
+
none: false
|
26
|
+
requirements:
|
27
|
+
- - ">="
|
28
|
+
- !ruby/object:Gem::Version
|
29
|
+
hash: 15
|
30
|
+
segments:
|
31
|
+
- 1
|
32
|
+
- 0
|
33
|
+
version: "1.0"
|
34
|
+
type: :runtime
|
35
|
+
version_requirements: *id001
|
36
|
+
- !ruby/object:Gem::Dependency
|
32
37
|
name: open-uri-cached
|
33
|
-
requirement: !ruby/object:Gem::Requirement
|
34
|
-
none: false
|
35
|
-
requirements:
|
36
|
-
- - ! '>='
|
37
|
-
- !ruby/object:Gem::Version
|
38
|
-
version: 0.0.5
|
39
|
-
type: :development
|
40
38
|
prerelease: false
|
41
|
-
|
42
|
-
none: false
|
43
|
-
requirements:
|
44
|
-
- -
|
45
|
-
- !ruby/object:Gem::Version
|
39
|
+
requirement: &id002 !ruby/object:Gem::Requirement
|
40
|
+
none: false
|
41
|
+
requirements:
|
42
|
+
- - ">="
|
43
|
+
- !ruby/object:Gem::Version
|
44
|
+
hash: 21
|
45
|
+
segments:
|
46
|
+
- 0
|
47
|
+
- 0
|
48
|
+
- 5
|
46
49
|
version: 0.0.5
|
47
|
-
- !ruby/object:Gem::Dependency
|
48
|
-
name: spira
|
49
|
-
requirement: !ruby/object:Gem::Requirement
|
50
|
-
none: false
|
51
|
-
requirements:
|
52
|
-
- - ! '>='
|
53
|
-
- !ruby/object:Gem::Version
|
54
|
-
version: 0.0.12
|
55
50
|
type: :development
|
51
|
+
version_requirements: *id002
|
52
|
+
- !ruby/object:Gem::Dependency
|
53
|
+
name: spira
|
56
54
|
prerelease: false
|
57
|
-
|
58
|
-
none: false
|
59
|
-
requirements:
|
60
|
-
- -
|
61
|
-
- !ruby/object:Gem::Version
|
55
|
+
requirement: &id003 !ruby/object:Gem::Requirement
|
56
|
+
none: false
|
57
|
+
requirements:
|
58
|
+
- - ">="
|
59
|
+
- !ruby/object:Gem::Version
|
60
|
+
hash: 7
|
61
|
+
segments:
|
62
|
+
- 0
|
63
|
+
- 0
|
64
|
+
- 12
|
62
65
|
version: 0.0.12
|
63
|
-
- !ruby/object:Gem::Dependency
|
64
|
-
name: rspec
|
65
|
-
requirement: !ruby/object:Gem::Requirement
|
66
|
-
none: false
|
67
|
-
requirements:
|
68
|
-
- - ! '>='
|
69
|
-
- !ruby/object:Gem::Version
|
70
|
-
version: 2.12.0
|
71
66
|
type: :development
|
67
|
+
version_requirements: *id003
|
68
|
+
- !ruby/object:Gem::Dependency
|
69
|
+
name: rspec
|
72
70
|
prerelease: false
|
73
|
-
|
74
|
-
none: false
|
75
|
-
requirements:
|
76
|
-
- -
|
77
|
-
- !ruby/object:Gem::Version
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
- - ! '>='
|
85
|
-
- !ruby/object:Gem::Version
|
86
|
-
version: 0.3.11
|
71
|
+
requirement: &id004 !ruby/object:Gem::Requirement
|
72
|
+
none: false
|
73
|
+
requirements:
|
74
|
+
- - ">="
|
75
|
+
- !ruby/object:Gem::Version
|
76
|
+
hash: 47
|
77
|
+
segments:
|
78
|
+
- 2
|
79
|
+
- 8
|
80
|
+
- 0
|
81
|
+
version: 2.8.0
|
87
82
|
type: :development
|
83
|
+
version_requirements: *id004
|
84
|
+
- !ruby/object:Gem::Dependency
|
85
|
+
name: rdf-spec
|
88
86
|
prerelease: false
|
89
|
-
|
90
|
-
none: false
|
91
|
-
requirements:
|
92
|
-
- -
|
93
|
-
- !ruby/object:Gem::Version
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
requirements:
|
100
|
-
- - ! '>='
|
101
|
-
- !ruby/object:Gem::Version
|
102
|
-
version: 0.3.9
|
87
|
+
requirement: &id005 !ruby/object:Gem::Requirement
|
88
|
+
none: false
|
89
|
+
requirements:
|
90
|
+
- - ">="
|
91
|
+
- !ruby/object:Gem::Version
|
92
|
+
hash: 15
|
93
|
+
segments:
|
94
|
+
- 1
|
95
|
+
- 0
|
96
|
+
version: "1.0"
|
103
97
|
type: :development
|
98
|
+
version_requirements: *id005
|
99
|
+
- !ruby/object:Gem::Dependency
|
100
|
+
name: rdf-rdfxml
|
104
101
|
prerelease: false
|
105
|
-
|
106
|
-
none: false
|
107
|
-
requirements:
|
108
|
-
- -
|
109
|
-
- !ruby/object:Gem::Version
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
none: false
|
115
|
-
requirements:
|
116
|
-
- - ! '>='
|
117
|
-
- !ruby/object:Gem::Version
|
118
|
-
version: 0.3.2
|
102
|
+
requirement: &id006 !ruby/object:Gem::Requirement
|
103
|
+
none: false
|
104
|
+
requirements:
|
105
|
+
- - ">="
|
106
|
+
- !ruby/object:Gem::Version
|
107
|
+
hash: 3
|
108
|
+
segments:
|
109
|
+
- 0
|
110
|
+
version: "0"
|
119
111
|
type: :development
|
112
|
+
version_requirements: *id006
|
113
|
+
- !ruby/object:Gem::Dependency
|
114
|
+
name: rdf-turtle
|
120
115
|
prerelease: false
|
121
|
-
|
122
|
-
none: false
|
123
|
-
requirements:
|
124
|
-
- -
|
125
|
-
- !ruby/object:Gem::Version
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
none: false
|
131
|
-
requirements:
|
132
|
-
- - ! '>='
|
133
|
-
- !ruby/object:Gem::Version
|
134
|
-
version: 0.3.4
|
116
|
+
requirement: &id007 !ruby/object:Gem::Requirement
|
117
|
+
none: false
|
118
|
+
requirements:
|
119
|
+
- - ">="
|
120
|
+
- !ruby/object:Gem::Version
|
121
|
+
hash: 3
|
122
|
+
segments:
|
123
|
+
- 0
|
124
|
+
version: "0"
|
135
125
|
type: :development
|
126
|
+
version_requirements: *id007
|
127
|
+
- !ruby/object:Gem::Dependency
|
128
|
+
name: rdf-isomorphic
|
136
129
|
prerelease: false
|
137
|
-
|
138
|
-
none: false
|
139
|
-
requirements:
|
140
|
-
- -
|
141
|
-
- !ruby/object:Gem::Version
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
none: false
|
147
|
-
requirements:
|
148
|
-
- - ! '>='
|
149
|
-
- !ruby/object:Gem::Version
|
150
|
-
version: 0.8.3
|
130
|
+
requirement: &id008 !ruby/object:Gem::Requirement
|
131
|
+
none: false
|
132
|
+
requirements:
|
133
|
+
- - ">="
|
134
|
+
- !ruby/object:Gem::Version
|
135
|
+
hash: 3
|
136
|
+
segments:
|
137
|
+
- 0
|
138
|
+
version: "0"
|
151
139
|
type: :development
|
140
|
+
version_requirements: *id008
|
141
|
+
- !ruby/object:Gem::Dependency
|
142
|
+
name: yard
|
152
143
|
prerelease: false
|
153
|
-
|
154
|
-
none: false
|
155
|
-
requirements:
|
156
|
-
- -
|
157
|
-
- !ruby/object:Gem::Version
|
144
|
+
requirement: &id009 !ruby/object:Gem::Requirement
|
145
|
+
none: false
|
146
|
+
requirements:
|
147
|
+
- - ">="
|
148
|
+
- !ruby/object:Gem::Version
|
149
|
+
hash: 57
|
150
|
+
segments:
|
151
|
+
- 0
|
152
|
+
- 8
|
153
|
+
- 3
|
158
154
|
version: 0.8.3
|
155
|
+
type: :development
|
156
|
+
version_requirements: *id009
|
159
157
|
description: RDF::N3 is an Notation-3 reader/writer for the RDF.rb library suite.
|
160
158
|
email: public-rdf-ruby@w3.org
|
161
159
|
executables: []
|
160
|
+
|
162
161
|
extensions: []
|
162
|
+
|
163
163
|
extra_rdoc_files: []
|
164
|
-
|
164
|
+
|
165
|
+
files:
|
165
166
|
- README.markdown
|
166
167
|
- History.markdown
|
167
168
|
- AUTHORS
|
@@ -178,29 +179,40 @@ files:
|
|
178
179
|
- lib/rdf/n3/writer.rb
|
179
180
|
- lib/rdf/n3.rb
|
180
181
|
homepage: http://github.com/ruby-rdf/rdf-n3
|
181
|
-
licenses:
|
182
|
+
licenses:
|
182
183
|
- Public Domain
|
183
184
|
post_install_message:
|
184
185
|
rdoc_options: []
|
185
|
-
|
186
|
+
|
187
|
+
require_paths:
|
186
188
|
- lib
|
187
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
189
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
188
190
|
none: false
|
189
|
-
requirements:
|
190
|
-
- -
|
191
|
-
- !ruby/object:Gem::Version
|
191
|
+
requirements:
|
192
|
+
- - ">="
|
193
|
+
- !ruby/object:Gem::Version
|
194
|
+
hash: 53
|
195
|
+
segments:
|
196
|
+
- 1
|
197
|
+
- 8
|
198
|
+
- 1
|
192
199
|
version: 1.8.1
|
193
|
-
required_rubygems_version: !ruby/object:Gem::Requirement
|
200
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
194
201
|
none: false
|
195
|
-
requirements:
|
196
|
-
- -
|
197
|
-
- !ruby/object:Gem::Version
|
198
|
-
|
202
|
+
requirements:
|
203
|
+
- - ">="
|
204
|
+
- !ruby/object:Gem::Version
|
205
|
+
hash: 3
|
206
|
+
segments:
|
207
|
+
- 0
|
208
|
+
version: "0"
|
199
209
|
requirements: []
|
210
|
+
|
200
211
|
rubyforge_project: rdf-n3
|
201
212
|
rubygems_version: 1.8.24
|
202
213
|
signing_key:
|
203
214
|
specification_version: 3
|
204
215
|
summary: Notation3 reader/writer for RDF.rb.
|
205
216
|
test_files: []
|
217
|
+
|
206
218
|
has_rdoc: false
|