sparql 1.0.8 → 1.1.0p0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (44) hide show
  1. checksums.yaml +14 -6
  2. data/README.md +57 -25
  3. data/VERSION +1 -1
  4. data/lib/sinatra/sparql.rb +5 -3
  5. data/lib/sparql/algebra/aggregate.rb +67 -0
  6. data/lib/sparql/algebra/evaluatable.rb +49 -4
  7. data/lib/sparql/algebra/expression.rb +6 -4
  8. data/lib/sparql/algebra/extensions.rb +99 -9
  9. data/lib/sparql/algebra/operator/and.rb +7 -4
  10. data/lib/sparql/algebra/operator/asc.rb +6 -3
  11. data/lib/sparql/algebra/operator/avg.rb +36 -0
  12. data/lib/sparql/algebra/operator/bnode.rb +5 -4
  13. data/lib/sparql/algebra/operator/bound.rb +5 -2
  14. data/lib/sparql/algebra/operator/coalesce.rb +6 -3
  15. data/lib/sparql/algebra/operator/concat.rb +6 -3
  16. data/lib/sparql/algebra/operator/count.rb +30 -0
  17. data/lib/sparql/algebra/operator/exists.rb +39 -0
  18. data/lib/sparql/algebra/operator/exprlist.rb +6 -3
  19. data/lib/sparql/algebra/operator/extend.rb +3 -1
  20. data/lib/sparql/algebra/operator/filter.rb +2 -1
  21. data/lib/sparql/algebra/operator/group.rb +101 -0
  22. data/lib/sparql/algebra/operator/group_concat.rb +55 -0
  23. data/lib/sparql/algebra/operator/if.rb +5 -5
  24. data/lib/sparql/algebra/operator/in.rb +7 -4
  25. data/lib/sparql/algebra/operator/max.rb +38 -0
  26. data/lib/sparql/algebra/operator/min.rb +38 -0
  27. data/lib/sparql/algebra/operator/minus.rb +51 -16
  28. data/lib/sparql/algebra/operator/negate.rb +31 -0
  29. data/lib/sparql/algebra/operator/notexists.rb +37 -0
  30. data/lib/sparql/algebra/operator/notin.rb +7 -4
  31. data/lib/sparql/algebra/operator/or.rb +7 -4
  32. data/lib/sparql/algebra/operator/order.rb +2 -2
  33. data/lib/sparql/algebra/operator/sample.rb +32 -0
  34. data/lib/sparql/algebra/operator/strlang.rb +1 -1
  35. data/lib/sparql/algebra/operator/sum.rb +36 -0
  36. data/lib/sparql/algebra/operator/table.rb +44 -0
  37. data/lib/sparql/algebra/operator.rb +37 -2
  38. data/lib/sparql/algebra.rb +1 -0
  39. data/lib/sparql/grammar/meta.rb +1143 -696
  40. data/lib/sparql/grammar/parser11.rb +178 -32
  41. data/lib/sparql/grammar/terminals11.rb +2 -2
  42. data/lib/sparql/grammar.rb +0 -2
  43. data/lib/sparql/results.rb +55 -0
  44. metadata +78 -81
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sparql
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.8
4
+ version: 1.1.0p0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gregg Kellogg
@@ -9,258 +9,244 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-05-21 00:00:00.000000000 Z
12
+ date: 2013-06-18 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rdf
16
16
  requirement: !ruby/object:Gem::Requirement
17
17
  requirements:
18
- - - '>='
18
+ - - ! '>='
19
19
  - !ruby/object:Gem::Version
20
- version: 1.0.6
20
+ version: 1.0.7
21
21
  type: :runtime
22
22
  prerelease: false
23
23
  version_requirements: !ruby/object:Gem::Requirement
24
24
  requirements:
25
- - - '>='
25
+ - - ! '>='
26
26
  - !ruby/object:Gem::Version
27
- version: 1.0.6
27
+ version: 1.0.7
28
28
  - !ruby/object:Gem::Dependency
29
29
  name: rdf-aggregate-repo
30
30
  requirement: !ruby/object:Gem::Requirement
31
31
  requirements:
32
- - - '>='
32
+ - - ! '>='
33
33
  - !ruby/object:Gem::Version
34
34
  version: '0'
35
35
  type: :runtime
36
36
  prerelease: false
37
37
  version_requirements: !ruby/object:Gem::Requirement
38
38
  requirements:
39
- - - '>='
39
+ - - ! '>='
40
40
  - !ruby/object:Gem::Version
41
41
  version: '0'
42
42
  - !ruby/object:Gem::Dependency
43
43
  name: ebnf
44
44
  requirement: !ruby/object:Gem::Requirement
45
45
  requirements:
46
- - - '>='
46
+ - - ! '>='
47
47
  - !ruby/object:Gem::Version
48
48
  version: 0.3.0
49
49
  type: :runtime
50
50
  prerelease: false
51
51
  version_requirements: !ruby/object:Gem::Requirement
52
52
  requirements:
53
- - - '>='
53
+ - - ! '>='
54
54
  - !ruby/object:Gem::Version
55
55
  version: 0.3.0
56
56
  - !ruby/object:Gem::Dependency
57
57
  name: builder
58
58
  requirement: !ruby/object:Gem::Requirement
59
59
  requirements:
60
- - - '>='
60
+ - - ! '>='
61
61
  - !ruby/object:Gem::Version
62
62
  version: '3.0'
63
63
  type: :runtime
64
64
  prerelease: false
65
65
  version_requirements: !ruby/object:Gem::Requirement
66
66
  requirements:
67
- - - '>='
67
+ - - ! '>='
68
68
  - !ruby/object:Gem::Version
69
69
  version: '3.0'
70
70
  - !ruby/object:Gem::Dependency
71
71
  name: json
72
72
  requirement: !ruby/object:Gem::Requirement
73
73
  requirements:
74
- - - '>='
74
+ - - ! '>='
75
75
  - !ruby/object:Gem::Version
76
76
  version: '1.7'
77
77
  type: :runtime
78
78
  prerelease: false
79
79
  version_requirements: !ruby/object:Gem::Requirement
80
80
  requirements:
81
- - - '>='
81
+ - - ! '>='
82
82
  - !ruby/object:Gem::Version
83
83
  version: '1.7'
84
84
  - !ruby/object:Gem::Dependency
85
85
  name: sxp
86
86
  requirement: !ruby/object:Gem::Requirement
87
87
  requirements:
88
- - - '>='
88
+ - - ! '>='
89
89
  - !ruby/object:Gem::Version
90
- version: 0.1.0
90
+ version: 0.1.3
91
91
  type: :runtime
92
92
  prerelease: false
93
93
  version_requirements: !ruby/object:Gem::Requirement
94
94
  requirements:
95
- - - '>='
95
+ - - ! '>='
96
96
  - !ruby/object:Gem::Version
97
- version: 0.1.0
97
+ version: 0.1.3
98
98
  - !ruby/object:Gem::Dependency
99
99
  name: sparql-client
100
100
  requirement: !ruby/object:Gem::Requirement
101
101
  requirements:
102
- - - '>='
102
+ - - ! '>='
103
103
  - !ruby/object:Gem::Version
104
- version: '1.0'
104
+ version: 1.0.3
105
105
  type: :runtime
106
106
  prerelease: false
107
107
  version_requirements: !ruby/object:Gem::Requirement
108
108
  requirements:
109
- - - '>='
109
+ - - ! '>='
110
110
  - !ruby/object:Gem::Version
111
- version: '1.0'
111
+ version: 1.0.3
112
112
  - !ruby/object:Gem::Dependency
113
113
  name: rdf-xsd
114
114
  requirement: !ruby/object:Gem::Requirement
115
115
  requirements:
116
- - - '>='
116
+ - - ! '>='
117
117
  - !ruby/object:Gem::Version
118
- version: '1.0'
118
+ version: 1.0.2
119
119
  type: :runtime
120
120
  prerelease: false
121
121
  version_requirements: !ruby/object:Gem::Requirement
122
122
  requirements:
123
- - - '>='
123
+ - - ! '>='
124
124
  - !ruby/object:Gem::Version
125
- version: '1.0'
125
+ version: 1.0.2
126
126
  - !ruby/object:Gem::Dependency
127
127
  name: sinatra
128
128
  requirement: !ruby/object:Gem::Requirement
129
129
  requirements:
130
- - - '>='
130
+ - - ! '>='
131
131
  - !ruby/object:Gem::Version
132
132
  version: 1.3.3
133
133
  type: :development
134
134
  prerelease: false
135
135
  version_requirements: !ruby/object:Gem::Requirement
136
136
  requirements:
137
- - - '>='
137
+ - - ! '>='
138
138
  - !ruby/object:Gem::Version
139
139
  version: 1.3.3
140
140
  - !ruby/object:Gem::Dependency
141
141
  name: rack
142
142
  requirement: !ruby/object:Gem::Requirement
143
143
  requirements:
144
- - - '>='
144
+ - - ! '>='
145
145
  - !ruby/object:Gem::Version
146
146
  version: 1.4.4
147
147
  type: :development
148
148
  prerelease: false
149
149
  version_requirements: !ruby/object:Gem::Requirement
150
150
  requirements:
151
- - - '>='
151
+ - - ! '>='
152
152
  - !ruby/object:Gem::Version
153
153
  version: 1.4.4
154
154
  - !ruby/object:Gem::Dependency
155
155
  name: rack-test
156
156
  requirement: !ruby/object:Gem::Requirement
157
157
  requirements:
158
- - - '>='
158
+ - - ! '>='
159
159
  - !ruby/object:Gem::Version
160
160
  version: 0.6.2
161
161
  type: :development
162
162
  prerelease: false
163
163
  version_requirements: !ruby/object:Gem::Requirement
164
164
  requirements:
165
- - - '>='
165
+ - - ! '>='
166
166
  - !ruby/object:Gem::Version
167
167
  version: 0.6.2
168
168
  - !ruby/object:Gem::Dependency
169
169
  name: rdf-turtle
170
170
  requirement: !ruby/object:Gem::Requirement
171
171
  requirements:
172
- - - '>='
172
+ - - ! '>='
173
173
  - !ruby/object:Gem::Version
174
- version: 1.0.4
174
+ version: 1.0.7
175
175
  type: :development
176
176
  prerelease: false
177
177
  version_requirements: !ruby/object:Gem::Requirement
178
178
  requirements:
179
- - - '>='
179
+ - - ! '>='
180
180
  - !ruby/object:Gem::Version
181
- version: 1.0.4
181
+ version: 1.0.7
182
182
  - !ruby/object:Gem::Dependency
183
- name: linkeddata
184
- requirement: !ruby/object:Gem::Requirement
185
- requirements:
186
- - - '>='
187
- - !ruby/object:Gem::Version
188
- version: '0'
189
- type: :development
190
- prerelease: false
191
- version_requirements: !ruby/object:Gem::Requirement
192
- requirements:
193
- - - '>='
194
- - !ruby/object:Gem::Version
195
- version: '0'
196
- - !ruby/object:Gem::Dependency
197
- name: rdf-spec
183
+ name: rdf-trig
198
184
  requirement: !ruby/object:Gem::Requirement
199
185
  requirements:
200
- - - '>='
186
+ - - ! '>='
201
187
  - !ruby/object:Gem::Version
202
- version: '1.0'
188
+ version: 1.0.1
203
189
  type: :development
204
190
  prerelease: false
205
191
  version_requirements: !ruby/object:Gem::Requirement
206
192
  requirements:
207
- - - '>='
193
+ - - ! '>='
208
194
  - !ruby/object:Gem::Version
209
- version: '1.0'
195
+ version: 1.0.1
210
196
  - !ruby/object:Gem::Dependency
211
- name: open-uri-cached
197
+ name: linkeddata
212
198
  requirement: !ruby/object:Gem::Requirement
213
199
  requirements:
214
- - - '>='
200
+ - - ! '>='
215
201
  - !ruby/object:Gem::Version
216
- version: 0.0.5
202
+ version: '0'
217
203
  type: :development
218
204
  prerelease: false
219
205
  version_requirements: !ruby/object:Gem::Requirement
220
206
  requirements:
221
- - - '>='
207
+ - - ! '>='
222
208
  - !ruby/object:Gem::Version
223
- version: 0.0.5
209
+ version: '0'
224
210
  - !ruby/object:Gem::Dependency
225
- name: equivalent-xml
211
+ name: rdf-spec
226
212
  requirement: !ruby/object:Gem::Requirement
227
213
  requirements:
228
- - - '>='
214
+ - - ! '>='
229
215
  - !ruby/object:Gem::Version
230
- version: '0'
216
+ version: 1.0.7
231
217
  type: :development
232
218
  prerelease: false
233
219
  version_requirements: !ruby/object:Gem::Requirement
234
220
  requirements:
235
- - - '>='
221
+ - - ! '>='
236
222
  - !ruby/object:Gem::Version
237
- version: '0'
223
+ version: 1.0.7
238
224
  - !ruby/object:Gem::Dependency
239
- name: nokogiri
225
+ name: open-uri-cached
240
226
  requirement: !ruby/object:Gem::Requirement
241
227
  requirements:
242
- - - '>='
228
+ - - ! '>='
243
229
  - !ruby/object:Gem::Version
244
- version: 1.5.0
230
+ version: 0.0.5
245
231
  type: :development
246
232
  prerelease: false
247
233
  version_requirements: !ruby/object:Gem::Requirement
248
234
  requirements:
249
- - - '>='
235
+ - - ! '>='
250
236
  - !ruby/object:Gem::Version
251
- version: 1.5.0
237
+ version: 0.0.5
252
238
  - !ruby/object:Gem::Dependency
253
239
  name: rspec
254
240
  requirement: !ruby/object:Gem::Requirement
255
241
  requirements:
256
- - - '>='
242
+ - - ! '>='
257
243
  - !ruby/object:Gem::Version
258
244
  version: 2.12.0
259
245
  type: :development
260
246
  prerelease: false
261
247
  version_requirements: !ruby/object:Gem::Requirement
262
248
  requirements:
263
- - - '>='
249
+ - - ! '>='
264
250
  - !ruby/object:Gem::Version
265
251
  version: 2.12.0
266
252
  - !ruby/object:Gem::Dependency
@@ -281,20 +267,18 @@ dependencies:
281
267
  name: yard
282
268
  requirement: !ruby/object:Gem::Requirement
283
269
  requirements:
284
- - - '>='
270
+ - - ! '>='
285
271
  - !ruby/object:Gem::Version
286
272
  version: 0.8.3
287
273
  type: :development
288
274
  prerelease: false
289
275
  version_requirements: !ruby/object:Gem::Requirement
290
276
  requirements:
291
- - - '>='
277
+ - - ! '>='
292
278
  - !ruby/object:Gem::Version
293
279
  version: 0.8.3
294
- description: |2-
295
-
296
- Implements SPARQL grammar parsing to SPARQL Algebra, SPARQL Algebra processing
297
- and includes SPARQL Client for accessing remote repositories.
280
+ description: ! "\n Implements SPARQL grammar parsing to SPARQL Algebra, SPARQL
281
+ Algebra processing\n and includes SPARQL Client for accessing remote repositories."
298
282
  email: public-rdf-ruby@w3.org
299
283
  executables:
300
284
  - sparql
@@ -311,6 +295,7 @@ files:
311
295
  - lib/rack/sparql.rb
312
296
  - lib/sinatra/sparql/extensions.rb
313
297
  - lib/sinatra/sparql.rb
298
+ - lib/sparql/algebra/aggregate.rb
314
299
  - lib/sparql/algebra/evaluatable.rb
315
300
  - lib/sparql/algebra/expression.rb
316
301
  - lib/sparql/algebra/extensions.rb
@@ -319,6 +304,7 @@ files:
319
304
  - lib/sparql/algebra/operator/and.rb
320
305
  - lib/sparql/algebra/operator/asc.rb
321
306
  - lib/sparql/algebra/operator/ask.rb
307
+ - lib/sparql/algebra/operator/avg.rb
322
308
  - lib/sparql/algebra/operator/base.rb
323
309
  - lib/sparql/algebra/operator/bgp.rb
324
310
  - lib/sparql/algebra/operator/bnode.rb
@@ -329,6 +315,7 @@ files:
329
315
  - lib/sparql/algebra/operator/concat.rb
330
316
  - lib/sparql/algebra/operator/construct.rb
331
317
  - lib/sparql/algebra/operator/contains.rb
318
+ - lib/sparql/algebra/operator/count.rb
332
319
  - lib/sparql/algebra/operator/dataset.rb
333
320
  - lib/sparql/algebra/operator/datatype.rb
334
321
  - lib/sparql/algebra/operator/day.rb
@@ -338,6 +325,7 @@ files:
338
325
  - lib/sparql/algebra/operator/divide.rb
339
326
  - lib/sparql/algebra/operator/encode_for_uri.rb
340
327
  - lib/sparql/algebra/operator/equal.rb
328
+ - lib/sparql/algebra/operator/exists.rb
341
329
  - lib/sparql/algebra/operator/exprlist.rb
342
330
  - lib/sparql/algebra/operator/extend.rb
343
331
  - lib/sparql/algebra/operator/filter.rb
@@ -345,6 +333,8 @@ files:
345
333
  - lib/sparql/algebra/operator/graph.rb
346
334
  - lib/sparql/algebra/operator/greater_than.rb
347
335
  - lib/sparql/algebra/operator/greater_than_or_equal.rb
336
+ - lib/sparql/algebra/operator/group.rb
337
+ - lib/sparql/algebra/operator/group_concat.rb
348
338
  - lib/sparql/algebra/operator/hours.rb
349
339
  - lib/sparql/algebra/operator/if.rb
350
340
  - lib/sparql/algebra/operator/in.rb
@@ -360,13 +350,17 @@ files:
360
350
  - lib/sparql/algebra/operator/left_join.rb
361
351
  - lib/sparql/algebra/operator/less_than.rb
362
352
  - lib/sparql/algebra/operator/less_than_or_equal.rb
353
+ - lib/sparql/algebra/operator/max.rb
363
354
  - lib/sparql/algebra/operator/md5.rb
355
+ - lib/sparql/algebra/operator/min.rb
364
356
  - lib/sparql/algebra/operator/minus.rb
365
357
  - lib/sparql/algebra/operator/minutes.rb
366
358
  - lib/sparql/algebra/operator/month.rb
367
359
  - lib/sparql/algebra/operator/multiply.rb
360
+ - lib/sparql/algebra/operator/negate.rb
368
361
  - lib/sparql/algebra/operator/not.rb
369
362
  - lib/sparql/algebra/operator/not_equal.rb
363
+ - lib/sparql/algebra/operator/notexists.rb
370
364
  - lib/sparql/algebra/operator/notin.rb
371
365
  - lib/sparql/algebra/operator/now.rb
372
366
  - lib/sparql/algebra/operator/or.rb
@@ -380,6 +374,7 @@ files:
380
374
  - lib/sparql/algebra/operator/replace.rb
381
375
  - lib/sparql/algebra/operator/round.rb
382
376
  - lib/sparql/algebra/operator/same_term.rb
377
+ - lib/sparql/algebra/operator/sample.rb
383
378
  - lib/sparql/algebra/operator/seconds.rb
384
379
  - lib/sparql/algebra/operator/sha1.rb
385
380
  - lib/sparql/algebra/operator/sha256.rb
@@ -397,6 +392,8 @@ files:
397
392
  - lib/sparql/algebra/operator/struuid.rb
398
393
  - lib/sparql/algebra/operator/substr.rb
399
394
  - lib/sparql/algebra/operator/subtract.rb
395
+ - lib/sparql/algebra/operator/sum.rb
396
+ - lib/sparql/algebra/operator/table.rb
400
397
  - lib/sparql/algebra/operator/timezone.rb
401
398
  - lib/sparql/algebra/operator/tz.rb
402
399
  - lib/sparql/algebra/operator/ucase.rb
@@ -426,14 +423,14 @@ require_paths:
426
423
  - lib
427
424
  required_ruby_version: !ruby/object:Gem::Requirement
428
425
  requirements:
429
- - - '>='
426
+ - - ! '>='
430
427
  - !ruby/object:Gem::Version
431
428
  version: 1.9.2
432
429
  required_rubygems_version: !ruby/object:Gem::Requirement
433
430
  requirements:
434
- - - '>='
431
+ - - ! '>'
435
432
  - !ruby/object:Gem::Version
436
- version: '0'
433
+ version: 1.3.1
437
434
  requirements: []
438
435
  rubyforge_project: sparql
439
436
  rubygems_version: 2.0.3