rdf-trig 1.0.1 → 1.0.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- ZDA3NjJmMDc1ZGIyYjJiZTczOTNkZjdkYjEyZWVjMDlmNWMyMGI2MA==
4
+ MGVhMGZhZDM0NTU3NmNlMTMwNGQyNTEwMzFkODlmNmEzNWE0MmU4Mg==
5
5
  data.tar.gz: !binary |-
6
- ZmQ1OTM5MGExOTYxNzc1NTQwN2Y1YTRhMTJkZTk3MDc1YWViNmQyYQ==
6
+ MjQ4YmNhMTZiN2RhZjc5OTBiZWQ5NWEyMTAwM2NlMDhkMWQ0NTFkNQ==
7
7
  !binary "U0hBNTEy":
8
8
  metadata.gz: !binary |-
9
- NzI2YzNmYTczZGI3ZDNhNGNmNDdmZTA0ZDIyNzFjNjJkOTJhMjc0MTNjYWVh
10
- ZjMzYTZlMzZkMmEyZmQ5YmU1OTE4MDc5MTI4MGUxNTdhODQ0ZGYxZjk0MjBi
11
- NjZmOTNlNmI4ZTg4ZjgyMWNhN2M2MDMwMmJiMTNjZWU2NjBjNDg=
9
+ MjFlMTM1YzYxYjNhNTg3NGQ1M2M2YzBjYWNmOTk2MDM3YTk2NTgwYTEzNzYx
10
+ ZDYzMzBhYzBmMDM0NWYzYzFmNzkzNjAyMTcyODQwMzdhODE4NDkxNGVjYTdl
11
+ NTQzZjBiYTY4MWM2MzVhNGU1NzY4Y2E3ZWQxNDExZTVkZDdhNTY=
12
12
  data.tar.gz: !binary |-
13
- OGZhYjUwNTlmN2Q1Nzg0MTBjZDQ1YWJhNjllZWMwMTAzNmY3YzEyMGY2NTky
14
- YzQ2OTBiM2Y2ZjEwYzAyMGM5NmEwZTdjMmIzMmNiYzU3ZjQ4ODRkNzE2NThj
15
- MjhhZWRkYmU4MTkzYmEwMzc0ZGE4YjU5YmJiY2U0OGM2M2UxY2U=
13
+ ZjU0MWNlYzZiMDQ0ODk2MjQ0Y2U5MTE0YmFiNzRiYmZkOGUyNzM3YjE5MTUw
14
+ MjhmZjZjNjQ3NzY4MzQ0ZDQ0ZTMyNzMzNjJkYzc1NTE2Mjk1ZjhiMjVjMjM2
15
+ YzgwYzMzZTY2ZTU2MWZhM2IwZDE2YWNhYWE3YjdiYjRlMDRmMTQ=
data/README.md CHANGED
@@ -16,6 +16,7 @@ Install with `gem install rdf-trig`
16
16
  * 100% free and unencumbered [public domain](http://unlicense.org/) software.
17
17
  * Implements a complete parser and serializer for [TriG][].
18
18
  * Compatible with Ruby 1.8.7+, Ruby 1.9.x, and JRuby 1.7+.
19
+ * Optional streaming writer, to serialize large graphs
19
20
 
20
21
  ## Usage
21
22
  Instantiate a reader from a local file:
@@ -43,20 +44,14 @@ Full documentation available on [Rubydoc.info][TriG doc].
43
44
  * {RDF::TriG::Reader}
44
45
  * {RDF::TriG::Writer}
45
46
 
46
- ### Interpretations of the spec
47
-
48
- It is still not defined what the interpretation of multiple uses of the same `graphIri` mean. This implementation takes
49
- the use of multiple graphs having the same `graphIri` to be additive, meaning that the statements from each graph
50
- are combined together to create a single graph.
51
-
52
- Graphs are written with `context` set to the associated `graphIri`.
53
-
54
- Although `RDF::Repository` allows any `RDF::Value`, such as a BNode, literal or variable to be used as a context, TriG
55
- only allows the use of an IRI.
56
47
 
57
48
  ## Implementation Notes
58
49
  The reader uses the [Turtle][Turtle doc] parser, which is based on the LL1::Parser with minor updates for the TriG grammar.
59
50
  The writer also is based on the Turtle writer.
51
+
52
+ The syntax is compatible with placing default triples within `{}`, but the writer does not use this for writing triples in the default graph.
53
+
54
+ There is a new `:stream` option to {RDF::TriG::Writer} which is more efficient for streaming large datasets.
60
55
 
61
56
  ## Dependencies
62
57
 
@@ -101,7 +96,7 @@ see <http://unlicense.org/> or the accompanying {file:UNLICENSE} file.
101
96
  [PDD]: http://lists.w3.org/Archives/Public/public-rdf-ruby/2010May/0013.html
102
97
  [RDF.rb]: http://rubydoc.info/github/ruby-rdf/rdf/master/frames
103
98
  [Backports]: http://rubygems.org/gems/backports
104
- [TriG]: http://dvcs.w3.org/hg/rdf/raw-file/default/trig/index.html
99
+ [TriG]: http://www.w3.org/TR/trig/
105
100
  [TriG doc]: http://rubydoc.info/github/ruby-rdf/rdf-trig/master/file/README.markdown
106
101
  [TriG EBNF]: http://dvcs.w3.org/hg/rdf/raw-file/default/trig/trig.bnf
107
102
  [Turtle doc]: http://rubydoc.info/github/ruby-rdf/rdf-turtle/master/file/README.markdown
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.0.1
1
+ 1.0.3
data/lib/rdf/trig.rb CHANGED
@@ -1,4 +1,5 @@
1
1
  require 'rdf'
2
+ require 'ebnf'
2
3
 
3
4
  module RDF
4
5
  ##
@@ -16,7 +17,7 @@ module RDF
16
17
  #
17
18
  # @see http://rubydoc.info/github/ruby-rdf/rdf-turtle/
18
19
  # @see http://rubydoc.info/github/ruby-rdf/rdf/master/
19
- # @see http://dvcs.w3.org/hg/rdf/raw-file/default/trig/index.html
20
+ # @see http://www.w3.org/TR/trig/
20
21
  #
21
22
  # @author [Gregg Kellogg](http://greggkellogg.net/)
22
23
  module TriG
data/lib/rdf/trig/meta.rb CHANGED
@@ -1,4 +1,4 @@
1
- # This file is automatically generated by /Users/gregg/.rvm/gems/ruby-1.9.3-p429/gems/ebnf-0.3.0/bin/ebnf
1
+ # This file is automatically generated by /Users/gregg/.rvm/gems/ruby-1.9.3-p448/gems/ebnf-0.3.1/bin/ebnf
2
2
  # BRANCH derived from etc/trig.bnf
3
3
  module RDF::TriG::Meta
4
4
  START = :trigDoc
@@ -70,19 +70,41 @@ module RDF::TriG::Meta
70
70
  :BASE => [:BASE, :IRIREF, :_base_1],
71
71
  },
72
72
  :_base_1 => {
73
+ "(" => [],
73
74
  "." => ["."],
74
75
  :ANON => [],
75
76
  :BASE => [],
76
77
  :BLANK_NODE_LABEL => [],
78
+ :GRAPH => [],
77
79
  :IRIREF => [],
78
80
  :PNAME_LN => [],
79
81
  :PNAME_NS => [],
80
82
  :PREFIX => [],
83
+ "[" => [],
81
84
  "{" => [],
82
85
  },
86
+ :blank => {
87
+ "(" => [:collection],
88
+ :ANON => [:BlankNode],
89
+ :BLANK_NODE_LABEL => [:BlankNode],
90
+ },
83
91
  :blankNodePropertyList => {
84
92
  "[" => ["[", :predicateObjectList, "]"],
85
93
  },
94
+ :block => {
95
+ "(" => [:triples2],
96
+ :ANON => [:triplesOrGraph],
97
+ :BLANK_NODE_LABEL => [:triplesOrGraph],
98
+ :GRAPH => [:_block_1],
99
+ :IRIREF => [:triplesOrGraph],
100
+ :PNAME_LN => [:triplesOrGraph],
101
+ :PNAME_NS => [:triplesOrGraph],
102
+ "[" => [:triples2],
103
+ "{" => [:wrappedGraph],
104
+ },
105
+ :_block_1 => {
106
+ :GRAPH => [:GRAPH, :labelOrSubject, :wrappedGraph],
107
+ },
86
108
  :collection => {
87
109
  "(" => ["(", :_collection_1, ")"],
88
110
  },
@@ -127,54 +149,18 @@ module RDF::TriG::Meta
127
149
  :BASE => [:base],
128
150
  :PREFIX => [:prefixID],
129
151
  },
130
- :graph => {
131
- :ANON => [:_graph_1, "{", :_graph_2, "}"],
132
- :BLANK_NODE_LABEL => [:_graph_1, "{", :_graph_2, "}"],
133
- :IRIREF => [:_graph_1, "{", :_graph_2, "}"],
134
- :PNAME_LN => [:_graph_1, "{", :_graph_2, "}"],
135
- :PNAME_NS => [:_graph_1, "{", :_graph_2, "}"],
136
- "{" => [:_graph_1, "{", :_graph_2, "}"],
152
+ :iri => {
153
+ :IRIREF => [:IRIREF],
154
+ :PNAME_LN => [:PrefixedName],
155
+ :PNAME_NS => [:PrefixedName],
137
156
  },
138
- :graphName => {
157
+ :labelOrSubject => {
139
158
  :ANON => [:BlankNode],
140
159
  :BLANK_NODE_LABEL => [:BlankNode],
141
160
  :IRIREF => [:iri],
142
161
  :PNAME_LN => [:iri],
143
162
  :PNAME_NS => [:iri],
144
163
  },
145
- :_graph_1 => {
146
- :ANON => [:graphName],
147
- :BLANK_NODE_LABEL => [:graphName],
148
- :IRIREF => [:graphName],
149
- :PNAME_LN => [:graphName],
150
- :PNAME_NS => [:graphName],
151
- "{" => [],
152
- },
153
- :_graph_2 => {
154
- "(" => [:triplesBlock],
155
- :ANON => [:triplesBlock],
156
- :BLANK_NODE_LABEL => [:triplesBlock],
157
- :IRIREF => [:triplesBlock],
158
- :PNAME_LN => [:triplesBlock],
159
- :PNAME_NS => [:triplesBlock],
160
- "[" => [:triplesBlock],
161
- "}" => [],
162
- },
163
- :graph_statement => {
164
- :ANON => [:graph],
165
- :BASE => [:directive],
166
- :BLANK_NODE_LABEL => [:graph],
167
- :IRIREF => [:graph],
168
- :PNAME_LN => [:graph],
169
- :PNAME_NS => [:graph],
170
- :PREFIX => [:directive],
171
- "{" => [:graph],
172
- },
173
- :iri => {
174
- :IRIREF => [:IRIREF],
175
- :PNAME_LN => [:PrefixedName],
176
- :PNAME_NS => [:PrefixedName],
177
- },
178
164
  :literal => {
179
165
  :DECIMAL => [:NumericLiteral],
180
166
  :DOUBLE => [:NumericLiteral],
@@ -187,9 +173,9 @@ module RDF::TriG::Meta
187
173
  "true" => [:BooleanLiteral],
188
174
  },
189
175
  :object => {
190
- "(" => [:collection],
191
- :ANON => [:BlankNode],
192
- :BLANK_NODE_LABEL => [:BlankNode],
176
+ "(" => [:blank],
177
+ :ANON => [:blank],
178
+ :BLANK_NODE_LABEL => [:blank],
193
179
  :DECIMAL => [:literal],
194
180
  :DOUBLE => [:literal],
195
181
  :INTEGER => [:literal],
@@ -278,43 +264,65 @@ module RDF::TriG::Meta
278
264
  :PREFIX => [:PREFIX, :PNAME_NS, :IRIREF, :_prefixID_1],
279
265
  },
280
266
  :_prefixID_1 => {
267
+ "(" => [],
281
268
  "." => ["."],
282
269
  :ANON => [],
283
270
  :BASE => [],
284
271
  :BLANK_NODE_LABEL => [],
272
+ :GRAPH => [],
285
273
  :IRIREF => [],
286
274
  :PNAME_LN => [],
287
275
  :PNAME_NS => [],
288
276
  :PREFIX => [],
277
+ "[" => [],
289
278
  "{" => [],
290
279
  },
291
280
  :subject => {
292
- "(" => [:collection],
293
- :ANON => [:BlankNode],
294
- :BLANK_NODE_LABEL => [:BlankNode],
281
+ "(" => [:blank],
282
+ :ANON => [:blank],
283
+ :BLANK_NODE_LABEL => [:blank],
295
284
  :IRIREF => [:iri],
296
285
  :PNAME_LN => [:iri],
297
286
  :PNAME_NS => [:iri],
298
287
  },
299
288
  :trigDoc => {
300
- :ANON => [:_trigDoc_1],
301
- :BASE => [:_trigDoc_1],
302
- :BLANK_NODE_LABEL => [:_trigDoc_1],
303
- :IRIREF => [:_trigDoc_1],
304
- :PNAME_LN => [:_trigDoc_1],
305
- :PNAME_NS => [:_trigDoc_1],
306
- :PREFIX => [:_trigDoc_1],
307
- "{" => [:_trigDoc_1],
289
+ "(" => [:_trigDoc_2],
290
+ :ANON => [:_trigDoc_2],
291
+ :BASE => [:_trigDoc_2],
292
+ :BLANK_NODE_LABEL => [:_trigDoc_2],
293
+ :GRAPH => [:_trigDoc_2],
294
+ :IRIREF => [:_trigDoc_2],
295
+ :PNAME_LN => [:_trigDoc_2],
296
+ :PNAME_NS => [:_trigDoc_2],
297
+ :PREFIX => [:_trigDoc_2],
298
+ "[" => [:_trigDoc_2],
299
+ "{" => [:_trigDoc_2],
308
300
  },
309
301
  :_trigDoc_1 => {
310
- :ANON => [:graph_statement, :trigDoc],
311
- :BASE => [:graph_statement, :trigDoc],
312
- :BLANK_NODE_LABEL => [:graph_statement, :trigDoc],
313
- :IRIREF => [:graph_statement, :trigDoc],
314
- :PNAME_LN => [:graph_statement, :trigDoc],
315
- :PNAME_NS => [:graph_statement, :trigDoc],
316
- :PREFIX => [:graph_statement, :trigDoc],
317
- "{" => [:graph_statement, :trigDoc],
302
+ "(" => [:block],
303
+ :ANON => [:block],
304
+ :BASE => [:directive],
305
+ :BLANK_NODE_LABEL => [:block],
306
+ :GRAPH => [:block],
307
+ :IRIREF => [:block],
308
+ :PNAME_LN => [:block],
309
+ :PNAME_NS => [:block],
310
+ :PREFIX => [:directive],
311
+ "[" => [:block],
312
+ "{" => [:block],
313
+ },
314
+ :_trigDoc_2 => {
315
+ "(" => [:_trigDoc_1, :trigDoc],
316
+ :ANON => [:_trigDoc_1, :trigDoc],
317
+ :BASE => [:_trigDoc_1, :trigDoc],
318
+ :BLANK_NODE_LABEL => [:_trigDoc_1, :trigDoc],
319
+ :GRAPH => [:_trigDoc_1, :trigDoc],
320
+ :IRIREF => [:_trigDoc_1, :trigDoc],
321
+ :PNAME_LN => [:_trigDoc_1, :trigDoc],
322
+ :PNAME_NS => [:_trigDoc_1, :trigDoc],
323
+ :PREFIX => [:_trigDoc_1, :trigDoc],
324
+ "[" => [:_trigDoc_1, :trigDoc],
325
+ "{" => [:_trigDoc_1, :trigDoc],
318
326
  },
319
327
  :triples => {
320
328
  "(" => [:_triples_1],
@@ -325,6 +333,21 @@ module RDF::TriG::Meta
325
333
  :PNAME_NS => [:_triples_1],
326
334
  "[" => [:_triples_2],
327
335
  },
336
+ :triples2 => {
337
+ "(" => [:_triples2_1, :_triples2_2, "."],
338
+ "[" => [:_triples2_1, :_triples2_2, "."],
339
+ },
340
+ :_triples2_1 => {
341
+ "(" => [:collection],
342
+ "[" => [:blankNodePropertyList],
343
+ },
344
+ :_triples2_2 => {
345
+ "." => [],
346
+ :IRIREF => [:predicateObjectList],
347
+ :PNAME_LN => [:predicateObjectList],
348
+ :PNAME_NS => [:predicateObjectList],
349
+ "a" => [:predicateObjectList],
350
+ },
328
351
  :triplesBlock => {
329
352
  "(" => [:triples, :_triplesBlock_1],
330
353
  :ANON => [:triples, :_triplesBlock_1],
@@ -351,6 +374,26 @@ module RDF::TriG::Meta
351
374
  "[" => [:triplesBlock],
352
375
  "}" => [],
353
376
  },
377
+ :triplesOrGraph => {
378
+ :ANON => [:labelOrSubject, :_triplesOrGraph_1],
379
+ :BLANK_NODE_LABEL => [:labelOrSubject, :_triplesOrGraph_1],
380
+ :IRIREF => [:labelOrSubject, :_triplesOrGraph_1],
381
+ :PNAME_LN => [:labelOrSubject, :_triplesOrGraph_1],
382
+ :PNAME_NS => [:labelOrSubject, :_triplesOrGraph_1],
383
+ },
384
+ :_triplesOrGraph_1 => {
385
+ :IRIREF => [:_triplesOrGraph_2],
386
+ :PNAME_LN => [:_triplesOrGraph_2],
387
+ :PNAME_NS => [:_triplesOrGraph_2],
388
+ "a" => [:_triplesOrGraph_2],
389
+ "{" => [:wrappedGraph],
390
+ },
391
+ :_triplesOrGraph_2 => {
392
+ :IRIREF => [:predicateObjectList, "."],
393
+ :PNAME_LN => [:predicateObjectList, "."],
394
+ :PNAME_NS => [:predicateObjectList, "."],
395
+ "a" => [:predicateObjectList, "."],
396
+ },
354
397
  :_triples_1 => {
355
398
  "(" => [:subject, :predicateObjectList],
356
399
  :ANON => [:subject, :predicateObjectList],
@@ -376,6 +419,19 @@ module RDF::TriG::Meta
376
419
  :PNAME_NS => [:predicate],
377
420
  "a" => ["a"],
378
421
  },
422
+ :wrappedGraph => {
423
+ "{" => ["{", :_wrappedGraph_1, "}"],
424
+ },
425
+ :_wrappedGraph_1 => {
426
+ "(" => [:triplesBlock],
427
+ :ANON => [:triplesBlock],
428
+ :BLANK_NODE_LABEL => [:triplesBlock],
429
+ :IRIREF => [:triplesBlock],
430
+ :PNAME_LN => [:triplesBlock],
431
+ :PNAME_NS => [:triplesBlock],
432
+ "[" => [:triplesBlock],
433
+ "}" => [],
434
+ },
379
435
  }.freeze
380
436
  TERMINALS = [
381
437
  "(",
@@ -388,6 +444,7 @@ module RDF::TriG::Meta
388
444
  :BLANK_NODE_LABEL,
389
445
  :DECIMAL,
390
446
  :DOUBLE,
447
+ :GRAPH,
391
448
  :INTEGER,
392
449
  :IRIREF,
393
450
  :LANGTAG,
@@ -454,6 +511,10 @@ module RDF::TriG::Meta
454
511
  :_base_3 => [
455
512
  ".",
456
513
  :_eps],
514
+ :blank => [
515
+ :BLANK_NODE_LABEL,
516
+ :ANON,
517
+ "("],
457
518
  :blankNodePropertyList => [
458
519
  "["],
459
520
  :_blankNodePropertyList_1 => [
@@ -463,17 +524,37 @@ module RDF::TriG::Meta
463
524
  :PNAME_NS],
464
525
  :_blankNodePropertyList_2 => [
465
526
  "]"],
527
+ :block => [
528
+ "{",
529
+ :GRAPH,
530
+ :IRIREF,
531
+ :BLANK_NODE_LABEL,
532
+ :ANON,
533
+ "[",
534
+ "(",
535
+ :PNAME_LN,
536
+ :PNAME_NS],
537
+ :_block_1 => [
538
+ :GRAPH],
539
+ :_block_2 => [
540
+ :IRIREF,
541
+ :BLANK_NODE_LABEL,
542
+ :ANON,
543
+ :PNAME_LN,
544
+ :PNAME_NS],
545
+ :_block_3 => [
546
+ "{"],
466
547
  :collection => [
467
548
  "("],
468
549
  :_collection_1 => [
469
550
  :_eps,
470
551
  :IRIREF,
471
- :BLANK_NODE_LABEL,
472
- :ANON,
473
- "(",
474
552
  "[",
475
553
  :PNAME_LN,
476
554
  :PNAME_NS,
555
+ :BLANK_NODE_LABEL,
556
+ :ANON,
557
+ "(",
477
558
  :INTEGER,
478
559
  :DECIMAL,
479
560
  :DOUBLE,
@@ -485,12 +566,12 @@ module RDF::TriG::Meta
485
566
  :STRING_LITERAL_LONG_QUOTE],
486
567
  :_collection_2 => [
487
568
  :IRIREF,
488
- :BLANK_NODE_LABEL,
489
- :ANON,
490
- "(",
491
569
  "[",
492
570
  :PNAME_LN,
493
571
  :PNAME_NS,
572
+ :BLANK_NODE_LABEL,
573
+ :ANON,
574
+ "(",
494
575
  :INTEGER,
495
576
  :DECIMAL,
496
577
  :DOUBLE,
@@ -503,12 +584,12 @@ module RDF::TriG::Meta
503
584
  :_collection_3 => [
504
585
  ")",
505
586
  :IRIREF,
506
- :BLANK_NODE_LABEL,
507
- :ANON,
508
- "(",
509
587
  "[",
510
588
  :PNAME_LN,
511
589
  :PNAME_NS,
590
+ :BLANK_NODE_LABEL,
591
+ :ANON,
592
+ "(",
512
593
  :INTEGER,
513
594
  :DECIMAL,
514
595
  :DOUBLE,
@@ -521,12 +602,12 @@ module RDF::TriG::Meta
521
602
  :_collection_4 => [
522
603
  :_eps,
523
604
  :IRIREF,
524
- :BLANK_NODE_LABEL,
525
- :ANON,
526
- "(",
527
605
  "[",
528
606
  :PNAME_LN,
529
607
  :PNAME_NS,
608
+ :BLANK_NODE_LABEL,
609
+ :ANON,
610
+ "(",
530
611
  :INTEGER,
531
612
  :DECIMAL,
532
613
  :DOUBLE,
@@ -543,61 +624,16 @@ module RDF::TriG::Meta
543
624
  :BASE],
544
625
  :_empty => [
545
626
  :_eps],
546
- :graph => [
547
- "{",
548
- :IRIREF,
549
- :BLANK_NODE_LABEL,
550
- :ANON,
551
- :PNAME_LN,
552
- :PNAME_NS],
553
- :graphName => [
554
- :IRIREF,
555
- :BLANK_NODE_LABEL,
556
- :ANON,
557
- :PNAME_LN,
558
- :PNAME_NS],
559
- :_graph_1 => [
560
- :_eps,
561
- :IRIREF,
562
- :BLANK_NODE_LABEL,
563
- :ANON,
564
- :PNAME_LN,
565
- :PNAME_NS],
566
- :_graph_2 => [
567
- :_eps,
568
- "[",
569
- :IRIREF,
570
- :BLANK_NODE_LABEL,
571
- :ANON,
572
- "(",
573
- :PNAME_LN,
574
- :PNAME_NS],
575
- :_graph_3 => [
576
- "{"],
577
- :_graph_4 => [
578
- "}",
579
- "[",
627
+ :iri => [
580
628
  :IRIREF,
581
- :BLANK_NODE_LABEL,
582
- :ANON,
583
- "(",
584
629
  :PNAME_LN,
585
630
  :PNAME_NS],
586
- :_graph_5 => [
587
- "}"],
588
- :graph_statement => [
589
- :PREFIX,
590
- :BASE,
591
- "{",
631
+ :labelOrSubject => [
592
632
  :IRIREF,
593
633
  :BLANK_NODE_LABEL,
594
634
  :ANON,
595
635
  :PNAME_LN,
596
636
  :PNAME_NS],
597
- :iri => [
598
- :IRIREF,
599
- :PNAME_LN,
600
- :PNAME_NS],
601
637
  :literal => [
602
638
  :INTEGER,
603
639
  :DECIMAL,
@@ -610,12 +646,12 @@ module RDF::TriG::Meta
610
646
  :STRING_LITERAL_LONG_QUOTE],
611
647
  :object => [
612
648
  :IRIREF,
613
- :BLANK_NODE_LABEL,
614
- :ANON,
615
- "(",
616
649
  "[",
617
650
  :PNAME_LN,
618
651
  :PNAME_NS,
652
+ :BLANK_NODE_LABEL,
653
+ :ANON,
654
+ "(",
619
655
  :INTEGER,
620
656
  :DECIMAL,
621
657
  :DOUBLE,
@@ -627,12 +663,12 @@ module RDF::TriG::Meta
627
663
  :STRING_LITERAL_LONG_QUOTE],
628
664
  :objectList => [
629
665
  :IRIREF,
630
- :BLANK_NODE_LABEL,
631
- :ANON,
632
- "(",
633
666
  "[",
634
667
  :PNAME_LN,
635
668
  :PNAME_NS,
669
+ :BLANK_NODE_LABEL,
670
+ :ANON,
671
+ "(",
636
672
  :INTEGER,
637
673
  :DECIMAL,
638
674
  :DOUBLE,
@@ -657,12 +693,12 @@ module RDF::TriG::Meta
657
693
  ","],
658
694
  :_objectList_6 => [
659
695
  :IRIREF,
660
- :BLANK_NODE_LABEL,
661
- :ANON,
662
- "(",
663
696
  "[",
664
697
  :PNAME_LN,
665
698
  :PNAME_NS,
699
+ :BLANK_NODE_LABEL,
700
+ :ANON,
701
+ "(",
666
702
  :INTEGER,
667
703
  :DECIMAL,
668
704
  :DOUBLE,
@@ -701,12 +737,12 @@ module RDF::TriG::Meta
701
737
  :PNAME_NS],
702
738
  :_predicateObjectList_6 => [
703
739
  :IRIREF,
704
- :BLANK_NODE_LABEL,
705
- :ANON,
706
- "(",
707
740
  "[",
708
741
  :PNAME_LN,
709
742
  :PNAME_NS,
743
+ :BLANK_NODE_LABEL,
744
+ :ANON,
745
+ "(",
710
746
  :INTEGER,
711
747
  :DECIMAL,
712
748
  :DOUBLE,
@@ -727,12 +763,12 @@ module RDF::TriG::Meta
727
763
  :PNAME_NS],
728
764
  :_predicateObjectList_9 => [
729
765
  :IRIREF,
730
- :BLANK_NODE_LABEL,
731
- :ANON,
732
- "(",
733
766
  "[",
734
767
  :PNAME_LN,
735
768
  :PNAME_NS,
769
+ :BLANK_NODE_LABEL,
770
+ :ANON,
771
+ "(",
736
772
  :INTEGER,
737
773
  :DECIMAL,
738
774
  :DOUBLE,
@@ -756,56 +792,95 @@ module RDF::TriG::Meta
756
792
  :_eps],
757
793
  :subject => [
758
794
  :IRIREF,
795
+ :PNAME_LN,
796
+ :PNAME_NS,
759
797
  :BLANK_NODE_LABEL,
760
798
  :ANON,
761
- "(",
762
- :PNAME_LN,
763
- :PNAME_NS],
799
+ "("],
764
800
  :trigDoc => [
765
801
  :_eps,
766
802
  :PREFIX,
767
803
  :BASE,
768
804
  "{",
805
+ :GRAPH,
769
806
  :IRIREF,
770
807
  :BLANK_NODE_LABEL,
771
808
  :ANON,
809
+ "[",
810
+ "(",
772
811
  :PNAME_LN,
773
812
  :PNAME_NS],
774
813
  :_trigDoc_1 => [
775
814
  :PREFIX,
776
815
  :BASE,
777
816
  "{",
817
+ :GRAPH,
778
818
  :IRIREF,
779
819
  :BLANK_NODE_LABEL,
780
820
  :ANON,
821
+ "[",
822
+ "(",
781
823
  :PNAME_LN,
782
824
  :PNAME_NS],
783
825
  :_trigDoc_2 => [
826
+ :PREFIX,
827
+ :BASE,
828
+ "{",
829
+ :GRAPH,
830
+ :IRIREF,
831
+ :BLANK_NODE_LABEL,
832
+ :ANON,
833
+ "[",
834
+ "(",
835
+ :PNAME_LN,
836
+ :PNAME_NS],
837
+ :_trigDoc_3 => [
784
838
  :_eps,
785
839
  :PREFIX,
786
840
  :BASE,
787
841
  "{",
842
+ :GRAPH,
788
843
  :IRIREF,
789
844
  :BLANK_NODE_LABEL,
790
845
  :ANON,
846
+ "[",
847
+ "(",
791
848
  :PNAME_LN,
792
849
  :PNAME_NS],
793
850
  :triples => [
794
851
  "[",
795
852
  :IRIREF,
853
+ :PNAME_LN,
854
+ :PNAME_NS,
796
855
  :BLANK_NODE_LABEL,
797
856
  :ANON,
798
- "(",
857
+ "("],
858
+ :triples2 => [
859
+ "[",
860
+ "("],
861
+ :_triples2_1 => [
862
+ "[",
863
+ "("],
864
+ :_triples2_2 => [
865
+ :_eps,
866
+ "a",
867
+ :IRIREF,
868
+ :PNAME_LN,
869
+ :PNAME_NS],
870
+ :_triples2_3 => [
871
+ ".",
872
+ "a",
873
+ :IRIREF,
799
874
  :PNAME_LN,
800
875
  :PNAME_NS],
801
876
  :triplesBlock => [
802
877
  "[",
803
878
  :IRIREF,
879
+ :PNAME_LN,
880
+ :PNAME_NS,
804
881
  :BLANK_NODE_LABEL,
805
882
  :ANON,
806
- "(",
807
- :PNAME_LN,
808
- :PNAME_NS],
883
+ "("],
809
884
  :_triplesBlock_1 => [
810
885
  :_eps,
811
886
  "."],
@@ -815,11 +890,11 @@ module RDF::TriG::Meta
815
890
  :_eps,
816
891
  "[",
817
892
  :IRIREF,
893
+ :PNAME_LN,
894
+ :PNAME_NS,
818
895
  :BLANK_NODE_LABEL,
819
896
  :ANON,
820
- "(",
821
- :PNAME_LN,
822
- :PNAME_NS],
897
+ "("],
823
898
  :_triplesBlock_4 => [
824
899
  ".",
825
900
  :_eps],
@@ -827,18 +902,43 @@ module RDF::TriG::Meta
827
902
  :_eps,
828
903
  "[",
829
904
  :IRIREF,
905
+ :PNAME_LN,
906
+ :PNAME_NS,
830
907
  :BLANK_NODE_LABEL,
831
908
  :ANON,
832
- "(",
909
+ "("],
910
+ :triplesOrGraph => [
911
+ :IRIREF,
912
+ :BLANK_NODE_LABEL,
913
+ :ANON,
914
+ :PNAME_LN,
915
+ :PNAME_NS],
916
+ :_triplesOrGraph_1 => [
917
+ "{",
918
+ "a",
919
+ :IRIREF,
920
+ :PNAME_LN,
921
+ :PNAME_NS],
922
+ :_triplesOrGraph_2 => [
923
+ "a",
924
+ :IRIREF,
925
+ :PNAME_LN,
926
+ :PNAME_NS],
927
+ :_triplesOrGraph_3 => [
928
+ "{",
929
+ "a",
930
+ :IRIREF,
833
931
  :PNAME_LN,
834
932
  :PNAME_NS],
933
+ :_triplesOrGraph_4 => [
934
+ "."],
835
935
  :_triples_1 => [
836
936
  :IRIREF,
937
+ :PNAME_LN,
938
+ :PNAME_NS,
837
939
  :BLANK_NODE_LABEL,
838
940
  :ANON,
839
- "(",
840
- :PNAME_LN,
841
- :PNAME_NS],
941
+ "("],
842
942
  :_triples_2 => [
843
943
  "["],
844
944
  :_triples_3 => [
@@ -863,24 +963,46 @@ module RDF::TriG::Meta
863
963
  :IRIREF,
864
964
  :PNAME_LN,
865
965
  :PNAME_NS],
866
- }.freeze
867
- FOLLOW = {
966
+ :wrappedGraph => [
967
+ "{"],
968
+ :_wrappedGraph_1 => [
969
+ :_eps,
970
+ "[",
971
+ :IRIREF,
972
+ :PNAME_LN,
973
+ :PNAME_NS,
974
+ :BLANK_NODE_LABEL,
975
+ :ANON,
976
+ "("],
977
+ :_wrappedGraph_2 => [
978
+ "}",
979
+ "[",
980
+ :IRIREF,
981
+ :PNAME_LN,
982
+ :PNAME_NS,
983
+ :BLANK_NODE_LABEL,
984
+ :ANON,
985
+ "("],
986
+ :_wrappedGraph_3 => [
987
+ "}"],
988
+ }.freeze
989
+ FOLLOW = {
868
990
  :BlankNode => [
869
991
  "{",
870
992
  "a",
871
993
  ")",
872
994
  ",",
995
+ ".",
873
996
  "]",
874
997
  :IRIREF,
875
- :BLANK_NODE_LABEL,
876
- :ANON,
877
- "(",
878
998
  "[",
879
999
  ";",
880
- ".",
881
1000
  "}",
882
1001
  :PNAME_LN,
883
1002
  :PNAME_NS,
1003
+ :BLANK_NODE_LABEL,
1004
+ :ANON,
1005
+ "(",
884
1006
  :INTEGER,
885
1007
  :DECIMAL,
886
1008
  :DOUBLE,
@@ -893,17 +1015,17 @@ module RDF::TriG::Meta
893
1015
  :BooleanLiteral => [
894
1016
  ")",
895
1017
  ",",
1018
+ ".",
896
1019
  "]",
897
1020
  :IRIREF,
898
- :BLANK_NODE_LABEL,
899
- :ANON,
900
- "(",
901
1021
  "[",
902
1022
  ";",
903
- ".",
904
1023
  "}",
905
1024
  :PNAME_LN,
906
1025
  :PNAME_NS,
1026
+ :BLANK_NODE_LABEL,
1027
+ :ANON,
1028
+ "(",
907
1029
  :INTEGER,
908
1030
  :DECIMAL,
909
1031
  :DOUBLE,
@@ -916,17 +1038,17 @@ module RDF::TriG::Meta
916
1038
  :NumericLiteral => [
917
1039
  ")",
918
1040
  ",",
1041
+ ".",
919
1042
  "]",
920
1043
  :IRIREF,
921
- :BLANK_NODE_LABEL,
922
- :ANON,
923
- "(",
924
1044
  "[",
925
1045
  ";",
926
- ".",
927
1046
  "}",
928
1047
  :PNAME_LN,
929
1048
  :PNAME_NS,
1049
+ :BLANK_NODE_LABEL,
1050
+ :ANON,
1051
+ "(",
930
1052
  :INTEGER,
931
1053
  :DECIMAL,
932
1054
  :DOUBLE,
@@ -940,22 +1062,22 @@ module RDF::TriG::Meta
940
1062
  "{",
941
1063
  "a",
942
1064
  :IRIREF,
943
- :BLANK_NODE_LABEL,
944
- :ANON,
945
- "(",
946
1065
  "[",
947
1066
  ")",
948
1067
  ",",
1068
+ ".",
949
1069
  "]",
950
1070
  :PNAME_LN,
951
1071
  :PNAME_NS,
1072
+ :BLANK_NODE_LABEL,
1073
+ :ANON,
1074
+ "(",
952
1075
  :INTEGER,
953
1076
  :DECIMAL,
954
1077
  :DOUBLE,
955
1078
  "true",
956
1079
  "false",
957
1080
  ";",
958
- ".",
959
1081
  "}",
960
1082
  :STRING_LITERAL_QUOTE,
961
1083
  :STRING_LITERAL_SINGLE_QUOTE,
@@ -964,17 +1086,17 @@ module RDF::TriG::Meta
964
1086
  :RDFLiteral => [
965
1087
  ")",
966
1088
  ",",
1089
+ ".",
967
1090
  "]",
968
1091
  :IRIREF,
969
- :BLANK_NODE_LABEL,
970
- :ANON,
971
- "(",
972
1092
  "[",
973
1093
  ";",
974
- ".",
975
1094
  "}",
976
1095
  :PNAME_LN,
977
1096
  :PNAME_NS,
1097
+ :BLANK_NODE_LABEL,
1098
+ :ANON,
1099
+ "(",
978
1100
  :INTEGER,
979
1101
  :DECIMAL,
980
1102
  :DOUBLE,
@@ -987,17 +1109,17 @@ module RDF::TriG::Meta
987
1109
  :_RDFLiteral_1 => [
988
1110
  ")",
989
1111
  ",",
1112
+ ".",
990
1113
  "]",
991
1114
  :IRIREF,
992
- :BLANK_NODE_LABEL,
993
- :ANON,
994
- "(",
995
1115
  "[",
996
1116
  ";",
997
- ".",
998
1117
  "}",
999
1118
  :PNAME_LN,
1000
1119
  :PNAME_NS,
1120
+ :BLANK_NODE_LABEL,
1121
+ :ANON,
1122
+ "(",
1001
1123
  :INTEGER,
1002
1124
  :DECIMAL,
1003
1125
  :DOUBLE,
@@ -1010,17 +1132,17 @@ module RDF::TriG::Meta
1010
1132
  :_RDFLiteral_2 => [
1011
1133
  ")",
1012
1134
  ",",
1135
+ ".",
1013
1136
  "]",
1014
1137
  :IRIREF,
1015
- :BLANK_NODE_LABEL,
1016
- :ANON,
1017
- "(",
1018
1138
  "[",
1019
1139
  ";",
1020
- ".",
1021
1140
  "}",
1022
1141
  :PNAME_LN,
1023
1142
  :PNAME_NS,
1143
+ :BLANK_NODE_LABEL,
1144
+ :ANON,
1145
+ "(",
1024
1146
  :INTEGER,
1025
1147
  :DECIMAL,
1026
1148
  :DOUBLE,
@@ -1033,17 +1155,17 @@ module RDF::TriG::Meta
1033
1155
  :_RDFLiteral_3 => [
1034
1156
  ")",
1035
1157
  ",",
1158
+ ".",
1036
1159
  "]",
1037
1160
  :IRIREF,
1038
- :BLANK_NODE_LABEL,
1039
- :ANON,
1040
- "(",
1041
1161
  "[",
1042
1162
  ";",
1043
- ".",
1044
1163
  "}",
1045
1164
  :PNAME_LN,
1046
1165
  :PNAME_NS,
1166
+ :BLANK_NODE_LABEL,
1167
+ :ANON,
1168
+ "(",
1047
1169
  :INTEGER,
1048
1170
  :DECIMAL,
1049
1171
  :DOUBLE,
@@ -1056,17 +1178,17 @@ module RDF::TriG::Meta
1056
1178
  :_RDFLiteral_4 => [
1057
1179
  ")",
1058
1180
  ",",
1181
+ ".",
1059
1182
  "]",
1060
1183
  :IRIREF,
1061
- :BLANK_NODE_LABEL,
1062
- :ANON,
1063
- "(",
1064
1184
  "[",
1065
1185
  ";",
1066
- ".",
1067
1186
  "}",
1068
1187
  :PNAME_LN,
1069
1188
  :PNAME_NS,
1189
+ :BLANK_NODE_LABEL,
1190
+ :ANON,
1191
+ "(",
1070
1192
  :INTEGER,
1071
1193
  :DECIMAL,
1072
1194
  :DOUBLE,
@@ -1081,17 +1203,17 @@ module RDF::TriG::Meta
1081
1203
  "^^",
1082
1204
  ")",
1083
1205
  ",",
1206
+ ".",
1084
1207
  "]",
1085
1208
  :IRIREF,
1086
- :BLANK_NODE_LABEL,
1087
- :ANON,
1088
- "(",
1089
1209
  "[",
1090
1210
  ";",
1091
- ".",
1092
1211
  "}",
1093
1212
  :PNAME_LN,
1094
1213
  :PNAME_NS,
1214
+ :BLANK_NODE_LABEL,
1215
+ :ANON,
1216
+ "(",
1095
1217
  :INTEGER,
1096
1218
  :DECIMAL,
1097
1219
  :DOUBLE,
@@ -1106,9 +1228,12 @@ module RDF::TriG::Meta
1106
1228
  :PREFIX,
1107
1229
  :BASE,
1108
1230
  "{",
1231
+ :GRAPH,
1109
1232
  :IRIREF,
1110
1233
  :BLANK_NODE_LABEL,
1111
1234
  :ANON,
1235
+ "[",
1236
+ "(",
1112
1237
  :PNAME_LN,
1113
1238
  :PNAME_NS],
1114
1239
  :_base_1 => [
@@ -1116,9 +1241,12 @@ module RDF::TriG::Meta
1116
1241
  :PREFIX,
1117
1242
  :BASE,
1118
1243
  "{",
1244
+ :GRAPH,
1119
1245
  :IRIREF,
1120
1246
  :BLANK_NODE_LABEL,
1121
1247
  :ANON,
1248
+ "[",
1249
+ "(",
1122
1250
  :PNAME_LN,
1123
1251
  :PNAME_NS],
1124
1252
  :_base_2 => [
@@ -1126,9 +1254,12 @@ module RDF::TriG::Meta
1126
1254
  :PREFIX,
1127
1255
  :BASE,
1128
1256
  "{",
1257
+ :GRAPH,
1129
1258
  :IRIREF,
1130
1259
  :BLANK_NODE_LABEL,
1131
1260
  :ANON,
1261
+ "[",
1262
+ "(",
1132
1263
  :PNAME_LN,
1133
1264
  :PNAME_NS],
1134
1265
  :_base_3 => [
@@ -1136,26 +1267,53 @@ module RDF::TriG::Meta
1136
1267
  :PREFIX,
1137
1268
  :BASE,
1138
1269
  "{",
1270
+ :GRAPH,
1139
1271
  :IRIREF,
1140
1272
  :BLANK_NODE_LABEL,
1141
1273
  :ANON,
1274
+ "[",
1275
+ "(",
1142
1276
  :PNAME_LN,
1143
1277
  :PNAME_NS],
1144
- :blankNodePropertyList => [
1145
- ".",
1146
- "}",
1278
+ :blank => [
1147
1279
  "a",
1148
1280
  ")",
1149
1281
  ",",
1282
+ ".",
1150
1283
  "]",
1151
1284
  :IRIREF,
1285
+ "[",
1286
+ ";",
1287
+ "}",
1288
+ :PNAME_LN,
1289
+ :PNAME_NS,
1152
1290
  :BLANK_NODE_LABEL,
1153
1291
  :ANON,
1154
1292
  "(",
1293
+ :INTEGER,
1294
+ :DECIMAL,
1295
+ :DOUBLE,
1296
+ "true",
1297
+ "false",
1298
+ :STRING_LITERAL_QUOTE,
1299
+ :STRING_LITERAL_SINGLE_QUOTE,
1300
+ :STRING_LITERAL_LONG_SINGLE_QUOTE,
1301
+ :STRING_LITERAL_LONG_QUOTE],
1302
+ :blankNodePropertyList => [
1303
+ ".",
1304
+ "}",
1305
+ "a",
1306
+ ")",
1307
+ ",",
1308
+ "]",
1309
+ :IRIREF,
1155
1310
  "[",
1156
1311
  ";",
1157
1312
  :PNAME_LN,
1158
1313
  :PNAME_NS,
1314
+ :BLANK_NODE_LABEL,
1315
+ :ANON,
1316
+ "(",
1159
1317
  :INTEGER,
1160
1318
  :DECIMAL,
1161
1319
  :DOUBLE,
@@ -1173,13 +1331,13 @@ module RDF::TriG::Meta
1173
1331
  ",",
1174
1332
  "]",
1175
1333
  :IRIREF,
1176
- :BLANK_NODE_LABEL,
1177
- :ANON,
1178
- "(",
1179
1334
  "[",
1180
1335
  ";",
1181
1336
  :PNAME_LN,
1182
1337
  :PNAME_NS,
1338
+ :BLANK_NODE_LABEL,
1339
+ :ANON,
1340
+ "(",
1183
1341
  :INTEGER,
1184
1342
  :DECIMAL,
1185
1343
  :DOUBLE,
@@ -1197,13 +1355,13 @@ module RDF::TriG::Meta
1197
1355
  ",",
1198
1356
  "]",
1199
1357
  :IRIREF,
1200
- :BLANK_NODE_LABEL,
1201
- :ANON,
1202
- "(",
1203
1358
  "[",
1204
1359
  ";",
1205
1360
  :PNAME_LN,
1206
1361
  :PNAME_NS,
1362
+ :BLANK_NODE_LABEL,
1363
+ :ANON,
1364
+ "(",
1207
1365
  :INTEGER,
1208
1366
  :DECIMAL,
1209
1367
  :DOUBLE,
@@ -1213,21 +1371,73 @@ module RDF::TriG::Meta
1213
1371
  :STRING_LITERAL_SINGLE_QUOTE,
1214
1372
  :STRING_LITERAL_LONG_SINGLE_QUOTE,
1215
1373
  :STRING_LITERAL_LONG_QUOTE],
1374
+ :block => [
1375
+ :_eof,
1376
+ :PREFIX,
1377
+ :BASE,
1378
+ "{",
1379
+ :GRAPH,
1380
+ :IRIREF,
1381
+ :BLANK_NODE_LABEL,
1382
+ :ANON,
1383
+ "[",
1384
+ "(",
1385
+ :PNAME_LN,
1386
+ :PNAME_NS],
1387
+ :_block_1 => [
1388
+ :_eof,
1389
+ :PREFIX,
1390
+ :BASE,
1391
+ "{",
1392
+ :GRAPH,
1393
+ :IRIREF,
1394
+ :BLANK_NODE_LABEL,
1395
+ :ANON,
1396
+ "[",
1397
+ "(",
1398
+ :PNAME_LN,
1399
+ :PNAME_NS],
1400
+ :_block_2 => [
1401
+ :_eof,
1402
+ :PREFIX,
1403
+ :BASE,
1404
+ "{",
1405
+ :GRAPH,
1406
+ :IRIREF,
1407
+ :BLANK_NODE_LABEL,
1408
+ :ANON,
1409
+ "[",
1410
+ "(",
1411
+ :PNAME_LN,
1412
+ :PNAME_NS],
1413
+ :_block_3 => [
1414
+ :_eof,
1415
+ :PREFIX,
1416
+ :BASE,
1417
+ "{",
1418
+ :GRAPH,
1419
+ :IRIREF,
1420
+ :BLANK_NODE_LABEL,
1421
+ :ANON,
1422
+ "[",
1423
+ "(",
1424
+ :PNAME_LN,
1425
+ :PNAME_NS],
1216
1426
  :collection => [
1427
+ ".",
1217
1428
  "a",
1218
1429
  ")",
1219
1430
  ",",
1220
1431
  "]",
1221
1432
  :IRIREF,
1222
- :BLANK_NODE_LABEL,
1223
- :ANON,
1224
- "(",
1225
1433
  "[",
1226
1434
  ";",
1227
- ".",
1228
1435
  "}",
1229
1436
  :PNAME_LN,
1230
1437
  :PNAME_NS,
1438
+ :BLANK_NODE_LABEL,
1439
+ :ANON,
1440
+ "(",
1231
1441
  :INTEGER,
1232
1442
  :DECIMAL,
1233
1443
  :DOUBLE,
@@ -1242,20 +1452,20 @@ module RDF::TriG::Meta
1242
1452
  :_collection_2 => [
1243
1453
  ")"],
1244
1454
  :_collection_3 => [
1455
+ ".",
1245
1456
  "a",
1246
1457
  ")",
1247
1458
  ",",
1248
1459
  "]",
1249
1460
  :IRIREF,
1250
- :BLANK_NODE_LABEL,
1251
- :ANON,
1252
- "(",
1253
1461
  "[",
1254
1462
  ";",
1255
- ".",
1256
1463
  "}",
1257
1464
  :PNAME_LN,
1258
1465
  :PNAME_NS,
1466
+ :BLANK_NODE_LABEL,
1467
+ :ANON,
1468
+ "(",
1259
1469
  :INTEGER,
1260
1470
  :DECIMAL,
1261
1471
  :DOUBLE,
@@ -1268,20 +1478,20 @@ module RDF::TriG::Meta
1268
1478
  :_collection_4 => [
1269
1479
  ")"],
1270
1480
  :_collection_5 => [
1481
+ ".",
1271
1482
  "a",
1272
1483
  ")",
1273
1484
  ",",
1274
1485
  "]",
1275
1486
  :IRIREF,
1276
- :BLANK_NODE_LABEL,
1277
- :ANON,
1278
- "(",
1279
1487
  "[",
1280
1488
  ";",
1281
- ".",
1282
1489
  "}",
1283
1490
  :PNAME_LN,
1284
1491
  :PNAME_NS,
1492
+ :BLANK_NODE_LABEL,
1493
+ :ANON,
1494
+ "(",
1285
1495
  :INTEGER,
1286
1496
  :DECIMAL,
1287
1497
  :DOUBLE,
@@ -1296,106 +1506,59 @@ module RDF::TriG::Meta
1296
1506
  :PREFIX,
1297
1507
  :BASE,
1298
1508
  "{",
1509
+ :GRAPH,
1299
1510
  :IRIREF,
1300
1511
  :BLANK_NODE_LABEL,
1301
1512
  :ANON,
1302
- :PNAME_LN,
1303
- :PNAME_NS],
1304
- :graph => [
1305
- :_eof,
1306
- :PREFIX,
1307
- :BASE,
1308
- "{",
1309
- :IRIREF,
1310
- :BLANK_NODE_LABEL,
1311
- :ANON,
1312
- :PNAME_LN,
1313
- :PNAME_NS],
1314
- :graphName => [
1315
- "{"],
1316
- :_graph_1 => [
1317
- "{"],
1318
- :_graph_2 => [
1319
- "}"],
1320
- :_graph_3 => [
1321
- :_eof,
1322
- :PREFIX,
1323
- :BASE,
1324
- "{",
1325
- :IRIREF,
1326
- :BLANK_NODE_LABEL,
1327
- :ANON,
1328
- :PNAME_LN,
1329
- :PNAME_NS],
1330
- :_graph_4 => [
1331
- :_eof,
1332
- :PREFIX,
1333
- :BASE,
1334
- "{",
1335
- :IRIREF,
1336
- :BLANK_NODE_LABEL,
1337
- :ANON,
1338
- :PNAME_LN,
1339
- :PNAME_NS],
1340
- :_graph_5 => [
1341
- :_eof,
1342
- :PREFIX,
1343
- :BASE,
1344
- "{",
1345
- :IRIREF,
1346
- :BLANK_NODE_LABEL,
1347
- :ANON,
1348
- :PNAME_LN,
1349
- :PNAME_NS],
1350
- :graph_statement => [
1351
- :_eof,
1352
- :PREFIX,
1353
- :BASE,
1354
- "{",
1355
- :IRIREF,
1356
- :BLANK_NODE_LABEL,
1357
- :ANON,
1513
+ "[",
1514
+ "(",
1358
1515
  :PNAME_LN,
1359
1516
  :PNAME_NS],
1360
1517
  :iri => [
1361
1518
  "{",
1362
1519
  "a",
1363
1520
  :IRIREF,
1364
- :BLANK_NODE_LABEL,
1365
- :ANON,
1366
- "(",
1367
1521
  "[",
1368
1522
  ")",
1369
1523
  ",",
1524
+ ".",
1370
1525
  "]",
1371
1526
  :PNAME_LN,
1372
1527
  :PNAME_NS,
1528
+ :BLANK_NODE_LABEL,
1529
+ :ANON,
1530
+ "(",
1373
1531
  :INTEGER,
1374
1532
  :DECIMAL,
1375
1533
  :DOUBLE,
1376
1534
  "true",
1377
1535
  "false",
1378
1536
  ";",
1379
- ".",
1380
1537
  "}",
1381
1538
  :STRING_LITERAL_QUOTE,
1382
1539
  :STRING_LITERAL_SINGLE_QUOTE,
1383
1540
  :STRING_LITERAL_LONG_SINGLE_QUOTE,
1384
1541
  :STRING_LITERAL_LONG_QUOTE],
1542
+ :labelOrSubject => [
1543
+ "{",
1544
+ "a",
1545
+ :IRIREF,
1546
+ :PNAME_LN,
1547
+ :PNAME_NS],
1385
1548
  :literal => [
1386
1549
  ")",
1387
1550
  ",",
1551
+ ".",
1388
1552
  "]",
1389
1553
  :IRIREF,
1390
- :BLANK_NODE_LABEL,
1391
- :ANON,
1392
- "(",
1393
1554
  "[",
1394
1555
  ";",
1395
- ".",
1396
1556
  "}",
1397
1557
  :PNAME_LN,
1398
1558
  :PNAME_NS,
1559
+ :BLANK_NODE_LABEL,
1560
+ :ANON,
1561
+ "(",
1399
1562
  :INTEGER,
1400
1563
  :DECIMAL,
1401
1564
  :DOUBLE,
@@ -1408,17 +1571,17 @@ module RDF::TriG::Meta
1408
1571
  :object => [
1409
1572
  ")",
1410
1573
  ",",
1574
+ ".",
1411
1575
  "]",
1412
1576
  :IRIREF,
1413
- :BLANK_NODE_LABEL,
1414
- :ANON,
1415
- "(",
1416
1577
  "[",
1417
1578
  ";",
1418
- ".",
1419
1579
  "}",
1420
1580
  :PNAME_LN,
1421
1581
  :PNAME_NS,
1582
+ :BLANK_NODE_LABEL,
1583
+ :ANON,
1584
+ "(",
1422
1585
  :INTEGER,
1423
1586
  :DECIMAL,
1424
1587
  :DOUBLE,
@@ -1429,50 +1592,50 @@ module RDF::TriG::Meta
1429
1592
  :STRING_LITERAL_LONG_SINGLE_QUOTE,
1430
1593
  :STRING_LITERAL_LONG_QUOTE],
1431
1594
  :objectList => [
1595
+ ".",
1432
1596
  "]",
1433
1597
  ";",
1434
- ".",
1435
1598
  "}"],
1436
1599
  :_objectList_1 => [
1600
+ ".",
1437
1601
  "]",
1438
1602
  ";",
1439
- ".",
1440
1603
  "}"],
1441
1604
  :_objectList_2 => [
1442
1605
  ",",
1606
+ ".",
1443
1607
  "]",
1444
1608
  ";",
1445
- ".",
1446
1609
  "}"],
1447
1610
  :_objectList_3 => [
1611
+ ".",
1448
1612
  "]",
1449
1613
  ";",
1450
- ".",
1451
1614
  "}"],
1452
1615
  :_objectList_4 => [
1616
+ ".",
1453
1617
  "]",
1454
1618
  ";",
1455
- ".",
1456
1619
  "}"],
1457
1620
  :_objectList_5 => [
1621
+ ".",
1458
1622
  "]",
1459
1623
  ";",
1460
- ".",
1461
1624
  "}"],
1462
1625
  :_objectList_6 => [
1463
1626
  ",",
1627
+ ".",
1464
1628
  "]",
1465
1629
  ";",
1466
- ".",
1467
1630
  "}"],
1468
1631
  :predicate => [
1469
1632
  :IRIREF,
1470
- :BLANK_NODE_LABEL,
1471
- :ANON,
1472
- "(",
1473
1633
  "[",
1474
1634
  :PNAME_LN,
1475
1635
  :PNAME_NS,
1636
+ :BLANK_NODE_LABEL,
1637
+ :ANON,
1638
+ "(",
1476
1639
  :INTEGER,
1477
1640
  :DECIMAL,
1478
1641
  :DOUBLE,
@@ -1480,67 +1643,70 @@ module RDF::TriG::Meta
1480
1643
  "false",
1481
1644
  ")",
1482
1645
  ",",
1646
+ ".",
1483
1647
  "]",
1484
1648
  :STRING_LITERAL_QUOTE,
1485
1649
  :STRING_LITERAL_SINGLE_QUOTE,
1486
1650
  :STRING_LITERAL_LONG_SINGLE_QUOTE,
1487
1651
  :STRING_LITERAL_LONG_QUOTE,
1488
1652
  ";",
1489
- ".",
1490
1653
  "}"],
1491
1654
  :predicateObjectList => [
1492
- "]",
1493
1655
  ".",
1656
+ "]",
1494
1657
  "}"],
1495
1658
  :_predicateObjectList_1 => [
1496
- "]",
1497
1659
  ".",
1660
+ "]",
1498
1661
  "}"],
1499
1662
  :_predicateObjectList_2 => [
1663
+ ".",
1500
1664
  ";",
1501
1665
  "]",
1502
- ".",
1503
1666
  "}"],
1504
1667
  :_predicateObjectList_3 => [
1505
- "]",
1506
1668
  ".",
1669
+ "]",
1507
1670
  "}"],
1508
1671
  :_predicateObjectList_4 => [
1672
+ ".",
1509
1673
  ";",
1510
1674
  "]",
1511
- ".",
1512
1675
  "}"],
1513
1676
  :_predicateObjectList_5 => [
1677
+ ".",
1514
1678
  ";",
1515
1679
  "]",
1516
- ".",
1517
1680
  "}"],
1518
1681
  :_predicateObjectList_6 => [
1519
- "]",
1520
1682
  ".",
1683
+ "]",
1521
1684
  "}"],
1522
1685
  :_predicateObjectList_7 => [
1523
- "]",
1524
1686
  ".",
1687
+ "]",
1525
1688
  "}"],
1526
1689
  :_predicateObjectList_8 => [
1690
+ ".",
1527
1691
  ";",
1528
1692
  "]",
1529
- ".",
1530
1693
  "}"],
1531
1694
  :_predicateObjectList_9 => [
1695
+ ".",
1532
1696
  ";",
1533
1697
  "]",
1534
- ".",
1535
1698
  "}"],
1536
1699
  :prefixID => [
1537
1700
  :_eof,
1538
1701
  :PREFIX,
1539
1702
  :BASE,
1540
1703
  "{",
1704
+ :GRAPH,
1541
1705
  :IRIREF,
1542
1706
  :BLANK_NODE_LABEL,
1543
1707
  :ANON,
1708
+ "[",
1709
+ "(",
1544
1710
  :PNAME_LN,
1545
1711
  :PNAME_NS],
1546
1712
  :_prefixID_1 => [
@@ -1548,9 +1714,12 @@ module RDF::TriG::Meta
1548
1714
  :PREFIX,
1549
1715
  :BASE,
1550
1716
  "{",
1717
+ :GRAPH,
1551
1718
  :IRIREF,
1552
1719
  :BLANK_NODE_LABEL,
1553
1720
  :ANON,
1721
+ "[",
1722
+ "(",
1554
1723
  :PNAME_LN,
1555
1724
  :PNAME_NS],
1556
1725
  :_prefixID_2 => [
@@ -1558,9 +1727,12 @@ module RDF::TriG::Meta
1558
1727
  :PREFIX,
1559
1728
  :BASE,
1560
1729
  "{",
1730
+ :GRAPH,
1561
1731
  :IRIREF,
1562
1732
  :BLANK_NODE_LABEL,
1563
1733
  :ANON,
1734
+ "[",
1735
+ "(",
1564
1736
  :PNAME_LN,
1565
1737
  :PNAME_NS],
1566
1738
  :_prefixID_3 => [
@@ -1568,9 +1740,12 @@ module RDF::TriG::Meta
1568
1740
  :PREFIX,
1569
1741
  :BASE,
1570
1742
  "{",
1743
+ :GRAPH,
1571
1744
  :IRIREF,
1572
1745
  :BLANK_NODE_LABEL,
1573
1746
  :ANON,
1747
+ "[",
1748
+ "(",
1574
1749
  :PNAME_LN,
1575
1750
  :PNAME_NS],
1576
1751
  :_prefixID_4 => [
@@ -1578,9 +1753,12 @@ module RDF::TriG::Meta
1578
1753
  :PREFIX,
1579
1754
  :BASE,
1580
1755
  "{",
1756
+ :GRAPH,
1581
1757
  :IRIREF,
1582
1758
  :BLANK_NODE_LABEL,
1583
1759
  :ANON,
1760
+ "[",
1761
+ "(",
1584
1762
  :PNAME_LN,
1585
1763
  :PNAME_NS],
1586
1764
  :subject => [
@@ -1591,12 +1769,59 @@ module RDF::TriG::Meta
1591
1769
  :trigDoc => [
1592
1770
  :_eof],
1593
1771
  :_trigDoc_1 => [
1594
- :_eof],
1772
+ :_eof,
1773
+ :PREFIX,
1774
+ :BASE,
1775
+ "{",
1776
+ :GRAPH,
1777
+ :IRIREF,
1778
+ :BLANK_NODE_LABEL,
1779
+ :ANON,
1780
+ "[",
1781
+ "(",
1782
+ :PNAME_LN,
1783
+ :PNAME_NS],
1595
1784
  :_trigDoc_2 => [
1596
1785
  :_eof],
1786
+ :_trigDoc_3 => [
1787
+ :_eof],
1597
1788
  :triples => [
1598
1789
  ".",
1599
1790
  "}"],
1791
+ :triples2 => [
1792
+ :_eof,
1793
+ :PREFIX,
1794
+ :BASE,
1795
+ "{",
1796
+ :GRAPH,
1797
+ :IRIREF,
1798
+ :BLANK_NODE_LABEL,
1799
+ :ANON,
1800
+ "[",
1801
+ "(",
1802
+ :PNAME_LN,
1803
+ :PNAME_NS],
1804
+ :_triples2_1 => [
1805
+ ".",
1806
+ "a",
1807
+ :IRIREF,
1808
+ :PNAME_LN,
1809
+ :PNAME_NS],
1810
+ :_triples2_2 => [
1811
+ "."],
1812
+ :_triples2_3 => [
1813
+ :_eof,
1814
+ :PREFIX,
1815
+ :BASE,
1816
+ "{",
1817
+ :GRAPH,
1818
+ :IRIREF,
1819
+ :BLANK_NODE_LABEL,
1820
+ :ANON,
1821
+ "[",
1822
+ "(",
1823
+ :PNAME_LN,
1824
+ :PNAME_NS],
1600
1825
  :triplesBlock => [
1601
1826
  "}"],
1602
1827
  :_triplesBlock_1 => [
@@ -1609,6 +1834,71 @@ module RDF::TriG::Meta
1609
1834
  "}"],
1610
1835
  :_triplesBlock_5 => [
1611
1836
  "}"],
1837
+ :triplesOrGraph => [
1838
+ :_eof,
1839
+ :PREFIX,
1840
+ :BASE,
1841
+ "{",
1842
+ :GRAPH,
1843
+ :IRIREF,
1844
+ :BLANK_NODE_LABEL,
1845
+ :ANON,
1846
+ "[",
1847
+ "(",
1848
+ :PNAME_LN,
1849
+ :PNAME_NS],
1850
+ :_triplesOrGraph_1 => [
1851
+ :_eof,
1852
+ :PREFIX,
1853
+ :BASE,
1854
+ "{",
1855
+ :GRAPH,
1856
+ :IRIREF,
1857
+ :BLANK_NODE_LABEL,
1858
+ :ANON,
1859
+ "[",
1860
+ "(",
1861
+ :PNAME_LN,
1862
+ :PNAME_NS],
1863
+ :_triplesOrGraph_2 => [
1864
+ :_eof,
1865
+ :PREFIX,
1866
+ :BASE,
1867
+ "{",
1868
+ :GRAPH,
1869
+ :IRIREF,
1870
+ :BLANK_NODE_LABEL,
1871
+ :ANON,
1872
+ "[",
1873
+ "(",
1874
+ :PNAME_LN,
1875
+ :PNAME_NS],
1876
+ :_triplesOrGraph_3 => [
1877
+ :_eof,
1878
+ :PREFIX,
1879
+ :BASE,
1880
+ "{",
1881
+ :GRAPH,
1882
+ :IRIREF,
1883
+ :BLANK_NODE_LABEL,
1884
+ :ANON,
1885
+ "[",
1886
+ "(",
1887
+ :PNAME_LN,
1888
+ :PNAME_NS],
1889
+ :_triplesOrGraph_4 => [
1890
+ :_eof,
1891
+ :PREFIX,
1892
+ :BASE,
1893
+ "{",
1894
+ :GRAPH,
1895
+ :IRIREF,
1896
+ :BLANK_NODE_LABEL,
1897
+ :ANON,
1898
+ "[",
1899
+ "(",
1900
+ :PNAME_LN,
1901
+ :PNAME_NS],
1612
1902
  :_triples_1 => [
1613
1903
  ".",
1614
1904
  "}"],
@@ -1626,12 +1916,12 @@ module RDF::TriG::Meta
1626
1916
  "}"],
1627
1917
  :verb => [
1628
1918
  :IRIREF,
1629
- :BLANK_NODE_LABEL,
1630
- :ANON,
1631
- "(",
1632
1919
  "[",
1633
1920
  :PNAME_LN,
1634
1921
  :PNAME_NS,
1922
+ :BLANK_NODE_LABEL,
1923
+ :ANON,
1924
+ "(",
1635
1925
  :INTEGER,
1636
1926
  :DECIMAL,
1637
1927
  :DOUBLE,
@@ -1641,6 +1931,47 @@ module RDF::TriG::Meta
1641
1931
  :STRING_LITERAL_SINGLE_QUOTE,
1642
1932
  :STRING_LITERAL_LONG_SINGLE_QUOTE,
1643
1933
  :STRING_LITERAL_LONG_QUOTE],
1934
+ :wrappedGraph => [
1935
+ :_eof,
1936
+ :PREFIX,
1937
+ :BASE,
1938
+ "{",
1939
+ :GRAPH,
1940
+ :IRIREF,
1941
+ :BLANK_NODE_LABEL,
1942
+ :ANON,
1943
+ "[",
1944
+ "(",
1945
+ :PNAME_LN,
1946
+ :PNAME_NS],
1947
+ :_wrappedGraph_1 => [
1948
+ "}"],
1949
+ :_wrappedGraph_2 => [
1950
+ :_eof,
1951
+ :PREFIX,
1952
+ :BASE,
1953
+ "{",
1954
+ :GRAPH,
1955
+ :IRIREF,
1956
+ :BLANK_NODE_LABEL,
1957
+ :ANON,
1958
+ "[",
1959
+ "(",
1960
+ :PNAME_LN,
1961
+ :PNAME_NS],
1962
+ :_wrappedGraph_3 => [
1963
+ :_eof,
1964
+ :PREFIX,
1965
+ :BASE,
1966
+ "{",
1967
+ :GRAPH,
1968
+ :IRIREF,
1969
+ :BLANK_NODE_LABEL,
1970
+ :ANON,
1971
+ "[",
1972
+ "(",
1973
+ :PNAME_LN,
1974
+ :PNAME_NS],
1644
1975
  }.freeze
1645
1976
  end
1646
1977