rdf-raptor 1.0.1 → 1.1.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: c7eb116ef79e2762de1eff47783c45c9cd8444f6
4
+ data.tar.gz: 9775d37d0507e5b81381c49a483772977a972ca2
5
+ SHA512:
6
+ metadata.gz: e904e98d8fc13740688926e44c934bf03f25ae4f3b7da8e711c354883a0290cd86d0cb81450c23d3268ecb73a38ab0551bf7c1e5fc19da19c20ed789f70fc673
7
+ data.tar.gz: 282db34adcbdaa040667d11d074bde0aad41e2786da98db2b2cce432e0db80cc60b0a7b8b1f63be8d648589b32799a51af5a3a85d8b910121370009d82035924
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.0.1
1
+ 1.1.0
@@ -179,6 +179,7 @@ module RDF::Raptor
179
179
  # @return [void]
180
180
  # @see RDF::Writer#write_epilogue
181
181
  def write_epilogue
182
+ @serializer.prefix(self.prefixes)
182
183
  @serializer.finish
183
184
  super
184
185
  end
@@ -49,7 +49,7 @@ module RDF::Raptor::FFI::V1
49
49
  ##
50
50
  # Sets the subject term from an `RDF::Resource`.
51
51
  #
52
- # @param [RDF::Resource] value
52
+ # @param [RDF::Resource] resource
53
53
  # @return [void]
54
54
  def subject=(resource)
55
55
  @subject = nil
@@ -87,7 +87,7 @@ module RDF::Raptor::FFI::V1
87
87
  ##
88
88
  # Sets the predicate term from an `RDF::URI`.
89
89
  #
90
- # @param [RDF::URI] value
90
+ # @param [RDF::URI] uri
91
91
  # @return [void]
92
92
  def predicate=(uri)
93
93
  @predicate = nil
@@ -123,6 +123,7 @@ module RDF::Raptor::FFI
123
123
  attach_function :raptor_serializer_start_to_filename, [:raptor_serializer, :string], :int
124
124
  attach_function :raptor_serializer_serialize_statement, [:raptor_serializer, :raptor_statement], :int
125
125
  attach_function :raptor_serializer_serialize_end, [:raptor_serializer], :int
126
+ attach_function :raptor_serializer_set_namespace, [:raptor_serializer, :raptor_uri, :string], :int
126
127
  #attach_function :raptor_serializer_set_error_handler, [:raptor_serializer, :pointer, :raptor_message_handler], :void
127
128
  #attach_function :raptor_serializer_set_warning_handler, [:raptor_serializer, :pointer, :raptor_message_handler], :void
128
129
 
@@ -98,6 +98,17 @@ module RDF::Raptor::FFI::V2
98
98
  end
99
99
  end
100
100
 
101
+ ##
102
+ # @param [Hash{namespace => uri}] prefixes
103
+ # @return [void]
104
+ def prefix(prefixes)
105
+ prefixes.each do |name, uri|
106
+ if V2.raptor_serializer_set_namespace(self, V2::URI.new(uri.to_s), name.to_s).nonzero?
107
+ raise RDF::WriterError, "raptor_serializer_set_namespace() failed"
108
+ end
109
+ end
110
+ end
111
+
101
112
  ##
102
113
  # @return [void]
103
114
  def finish
@@ -41,7 +41,7 @@ module RDF::Raptor::FFI::V2
41
41
  ##
42
42
  # Sets the subject term from an `RDF::Resource`.
43
43
  #
44
- # @param [RDF::Resource] value
44
+ # @param [RDF::Resource] resource
45
45
  # @return [void]
46
46
  def subject=(resource)
47
47
  @subject = nil
@@ -65,7 +65,7 @@ module RDF::Raptor::FFI::V2
65
65
  ##
66
66
  # Sets the predicate term from an `RDF::URI`.
67
67
  #
68
- # @param [RDF::URI] value
68
+ # @param [RDF::URI] uri
69
69
  # @return [void]
70
70
  def predicate=(uri)
71
71
  @predicate = nil
metadata CHANGED
@@ -1,8 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rdf-raptor
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
5
- prerelease:
4
+ version: 1.1.0
6
5
  platform: ruby
7
6
  authors:
8
7
  - Arto Bendiken
@@ -10,86 +9,90 @@ authors:
10
9
  autorequire:
11
10
  bindir: bin
12
11
  cert_chain: []
13
- date: 2013-04-23 00:00:00.000000000 Z
12
+ date: 2013-11-30 00:00:00.000000000 Z
14
13
  dependencies:
15
14
  - !ruby/object:Gem::Dependency
16
15
  name: ffi
17
16
  requirement: !ruby/object:Gem::Requirement
18
- none: false
19
17
  requirements:
20
- - - ! '>='
18
+ - - '>='
21
19
  - !ruby/object:Gem::Version
22
- version: '1.0'
20
+ version: 1.9.3
23
21
  type: :runtime
24
22
  prerelease: false
25
23
  version_requirements: !ruby/object:Gem::Requirement
26
- none: false
27
24
  requirements:
28
- - - ! '>='
25
+ - - '>='
29
26
  - !ruby/object:Gem::Version
30
- version: '1.0'
27
+ version: 1.9.3
31
28
  - !ruby/object:Gem::Dependency
32
29
  name: rdf
33
30
  requirement: !ruby/object:Gem::Requirement
34
- none: false
35
31
  requirements:
36
- - - ! '>='
32
+ - - '>='
37
33
  - !ruby/object:Gem::Version
38
- version: 1.0.0
34
+ version: 1.1.0
39
35
  type: :runtime
40
36
  prerelease: false
41
37
  version_requirements: !ruby/object:Gem::Requirement
42
- none: false
43
38
  requirements:
44
- - - ! '>='
39
+ - - '>='
45
40
  - !ruby/object:Gem::Version
46
- version: 1.0.0
41
+ version: 1.1.0
47
42
  - !ruby/object:Gem::Dependency
48
43
  name: yard
49
44
  requirement: !ruby/object:Gem::Requirement
50
- none: false
51
45
  requirements:
52
- - - ! '>='
46
+ - - '>='
53
47
  - !ruby/object:Gem::Version
54
48
  version: 0.8.6
55
49
  type: :development
56
50
  prerelease: false
57
51
  version_requirements: !ruby/object:Gem::Requirement
58
- none: false
59
52
  requirements:
60
- - - ! '>='
53
+ - - '>='
61
54
  - !ruby/object:Gem::Version
62
55
  version: 0.8.6
63
56
  - !ruby/object:Gem::Dependency
64
57
  name: rspec
65
58
  requirement: !ruby/object:Gem::Requirement
66
- none: false
67
59
  requirements:
68
- - - ! '>='
60
+ - - '>='
69
61
  - !ruby/object:Gem::Version
70
- version: 2.13.0
62
+ version: 2.14.0
71
63
  type: :development
72
64
  prerelease: false
73
65
  version_requirements: !ruby/object:Gem::Requirement
74
- none: false
75
66
  requirements:
76
- - - ! '>='
67
+ - - '>='
77
68
  - !ruby/object:Gem::Version
78
- version: 2.13.0
69
+ version: 2.14.0
70
+ - !ruby/object:Gem::Dependency
71
+ name: rdf-spec
72
+ requirement: !ruby/object:Gem::Requirement
73
+ requirements:
74
+ - - '>='
75
+ - !ruby/object:Gem::Version
76
+ version: 1.1.0
77
+ type: :development
78
+ prerelease: false
79
+ version_requirements: !ruby/object:Gem::Requirement
80
+ requirements:
81
+ - - '>='
82
+ - !ruby/object:Gem::Version
83
+ version: 1.1.0
79
84
  - !ruby/object:Gem::Dependency
80
85
  name: rake
81
86
  requirement: !ruby/object:Gem::Requirement
82
- none: false
83
87
  requirements:
84
- - - ! '>='
88
+ - - '>='
85
89
  - !ruby/object:Gem::Version
86
90
  version: '0'
87
91
  type: :development
88
92
  prerelease: false
89
93
  version_requirements: !ruby/object:Gem::Requirement
90
- none: false
91
94
  requirements:
92
- - - ! '>='
95
+ - - '>='
93
96
  - !ruby/object:Gem::Version
94
97
  version: '0'
95
98
  description: RDF.rb plugin for parsing/serializing NTriples, RDF/XML, Turtle and RDFa
@@ -134,31 +137,27 @@ files:
134
137
  homepage: http://ruby-rdf.github.com/rdf-raptor
135
138
  licenses:
136
139
  - Public Domain
140
+ metadata: {}
137
141
  post_install_message:
138
142
  rdoc_options: []
139
143
  require_paths:
140
144
  - lib
141
145
  required_ruby_version: !ruby/object:Gem::Requirement
142
- none: false
143
146
  requirements:
144
- - - ! '>='
147
+ - - '>='
145
148
  - !ruby/object:Gem::Version
146
- version: 1.8.1
149
+ version: 1.9.2
147
150
  required_rubygems_version: !ruby/object:Gem::Requirement
148
- none: false
149
151
  requirements:
150
- - - ! '>='
152
+ - - '>='
151
153
  - !ruby/object:Gem::Version
152
154
  version: '0'
153
- segments:
154
- - 0
155
- hash: 2507009861349013909
156
155
  requirements:
157
156
  - libraptor (>= 2.0)
158
157
  rubyforge_project: rdf
159
- rubygems_version: 1.8.24
158
+ rubygems_version: 2.1.11
160
159
  signing_key:
161
- specification_version: 3
160
+ specification_version: 4
162
161
  summary: Raptor RDF Parser plugin for RDF.rb.
163
162
  test_files: []
164
163
  has_rdoc: false