georuby-ext 0.0.1 → 0.0.2
Sign up to get free protection for your applications and to get access to all the features.
- data/.jrubyrc +1 -0
- data/.travis.yml +23 -0
- data/Gemfile +6 -0
- data/Guardfile +12 -2
- data/MIT-LICENSE +20 -0
- data/README.rdoc +2 -28
- data/georuby-ext.gemspec +14 -11
- data/lib/georuby-ext.rb +17 -2
- data/lib/georuby-ext/core_ext.rb +11 -0
- data/lib/georuby-ext/geokit.rb +10 -3
- data/lib/georuby-ext/georuby/envelope.rb +36 -1
- data/lib/georuby-ext/georuby/ewkb_parser.rb +11 -0
- data/lib/georuby-ext/georuby/ewkt_parser.rb +11 -0
- data/lib/georuby-ext/georuby/geometry.rb +46 -2
- data/lib/georuby-ext/georuby/line_string.rb +19 -7
- data/lib/georuby-ext/georuby/linear_ring.rb +15 -0
- data/lib/georuby-ext/georuby/locators.rb +30 -17
- data/lib/georuby-ext/georuby/multi_polygon.rb +15 -1
- data/lib/georuby-ext/georuby/point.rb +148 -24
- data/lib/georuby-ext/georuby/polygon.rb +38 -27
- data/lib/georuby-ext/georuby/rtree.rb +133 -0
- data/lib/georuby-ext/georuby/srid.rb +17 -0
- data/lib/georuby-ext/proj4.rb +15 -2
- data/lib/georuby-ext/rgeo/cartesian/feature_methods.rb +58 -0
- data/lib/georuby-ext/rgeo/feature/geometry.rb +11 -0
- data/lib/georuby-ext/rgeo/feature/geometry_collection.rb +11 -0
- data/lib/georuby-ext/rgeo/feature/rgeo.rb +157 -0
- data/lib/georuby-ext/rgeo/geos/ffi_feature_methods.rb +265 -0
- data/lib/georuby-ext/rspec_helper.rb +47 -8
- data/spec/lib/geokit_spec.rb +44 -0
- data/spec/lib/georuby/envelope_spec.rb +46 -0
- data/spec/lib/georuby/geometry_spec.rb +81 -0
- data/spec/{georuby → lib/georuby}/line_string_spec.rb +29 -14
- data/spec/lib/georuby/linear_ring_spec.rb +52 -0
- data/spec/lib/georuby/locators_spec.rb +123 -0
- data/spec/lib/georuby/multi_polygon_spec.rb +69 -0
- data/spec/lib/georuby/point_spec.rb +248 -0
- data/spec/lib/georuby/polygon_spec.rb +175 -0
- data/spec/lib/georuby/rtree_spec.rb +132 -0
- data/spec/lib/proj4_spec.rb +24 -0
- data/spec/lib/rgeo/cartesian/feature_methods_spec.rb +110 -0
- data/spec/lib/rgeo/geos/ffi_feature_methods_spec.rb +234 -0
- data/spec/spec_helper.rb +12 -8
- metadata +224 -189
- data/lib/georuby-ext/rgeo.rb +0 -23
- data/spec/georuby/linear_ring_spec.rb +0 -33
- data/spec/georuby/locators_spec.rb +0 -120
- data/spec/georuby/multi_polygon_spec.rb +0 -29
- data/spec/georuby/point_spec.rb +0 -44
- data/spec/georuby/polygon_spec.rb +0 -134
- data/spec/rgeo_spec.rb +0 -81
data/spec/spec_helper.rb
CHANGED
@@ -1,23 +1,27 @@
|
|
1
|
-
|
2
|
-
require 'rspec'
|
3
|
-
rescue LoadError
|
4
|
-
require 'rubygems' unless ENV['NO_RUBYGEMS']
|
5
|
-
require 'rspec'
|
6
|
-
end
|
1
|
+
ENV["RAILS_ENV"] ||= 'test'
|
7
2
|
|
8
|
-
|
3
|
+
require 'rspec'
|
9
4
|
|
5
|
+
$:.unshift(File.dirname(__FILE__) + '/../lib')
|
10
6
|
require 'georuby-ext'
|
11
7
|
require 'georuby-ext/rspec_helper'
|
12
8
|
|
9
|
+
RSpec.configure do |c|
|
10
|
+
|
11
|
+
c.mock_with :rspec
|
12
|
+
|
13
|
+
end
|
14
|
+
|
13
15
|
RSpec::Matchers.define :have_same do |*attributes|
|
14
16
|
chain :than do |other|
|
15
17
|
@other = other
|
16
18
|
end
|
17
|
-
|
19
|
+
|
18
20
|
match do |model|
|
19
21
|
attributes.all? do |attribute|
|
20
22
|
model.send(attribute) == @other.send(attribute)
|
21
23
|
end
|
22
24
|
end
|
23
25
|
end
|
26
|
+
|
27
|
+
|
metadata
CHANGED
@@ -1,155 +1,178 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: georuby-ext
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash: 29
|
5
4
|
prerelease:
|
6
|
-
|
7
|
-
- 0
|
8
|
-
- 0
|
9
|
-
- 1
|
10
|
-
version: 0.0.1
|
5
|
+
version: 0.0.2
|
11
6
|
platform: ruby
|
12
7
|
authors:
|
13
|
-
- Marc Florisson
|
14
|
-
- Luc Donnet
|
15
|
-
- Alban Peignier
|
8
|
+
- Marc Florisson
|
9
|
+
- Luc Donnet
|
10
|
+
- Alban Peignier
|
16
11
|
autorequire:
|
17
12
|
bindir: bin
|
18
13
|
cert_chain: []
|
19
14
|
|
20
|
-
date:
|
15
|
+
date: 2013-02-25 00:00:00 Z
|
21
16
|
dependencies:
|
22
|
-
- !ruby/object:Gem::Dependency
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
- !ruby/object:Gem::
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
17
|
+
- !ruby/object:Gem::Dependency
|
18
|
+
name: rspec
|
19
|
+
version_requirements: &id001 !ruby/object:Gem::Requirement
|
20
|
+
none: false
|
21
|
+
requirements:
|
22
|
+
- - ">="
|
23
|
+
- !ruby/object:Gem::Version
|
24
|
+
version: "0"
|
25
|
+
requirement: *id001
|
26
|
+
prerelease: false
|
27
|
+
type: :development
|
28
|
+
- !ruby/object:Gem::Dependency
|
29
|
+
name: rake
|
30
|
+
version_requirements: &id002 !ruby/object:Gem::Requirement
|
31
|
+
none: false
|
32
|
+
requirements:
|
33
|
+
- - ">="
|
34
|
+
- !ruby/object:Gem::Version
|
35
|
+
version: "0"
|
36
|
+
requirement: *id002
|
37
|
+
prerelease: false
|
38
|
+
type: :development
|
39
|
+
- !ruby/object:Gem::Dependency
|
40
|
+
name: guard
|
41
|
+
version_requirements: &id003 !ruby/object:Gem::Requirement
|
42
|
+
none: false
|
43
|
+
requirements:
|
44
|
+
- - ">="
|
45
|
+
- !ruby/object:Gem::Version
|
46
|
+
version: 1.3.3
|
47
|
+
requirement: *id003
|
48
|
+
prerelease: false
|
49
|
+
type: :development
|
50
|
+
- !ruby/object:Gem::Dependency
|
51
|
+
name: guard-rspec
|
52
|
+
version_requirements: &id004 !ruby/object:Gem::Requirement
|
53
|
+
none: false
|
54
|
+
requirements:
|
55
|
+
- - ">="
|
56
|
+
- !ruby/object:Gem::Version
|
57
|
+
version: "0"
|
58
|
+
requirement: *id004
|
59
|
+
prerelease: false
|
60
|
+
type: :development
|
61
|
+
- !ruby/object:Gem::Dependency
|
62
|
+
name: guard-bundler
|
63
|
+
version_requirements: &id005 !ruby/object:Gem::Requirement
|
64
|
+
none: false
|
65
|
+
requirements:
|
66
|
+
- - ">="
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: "0"
|
69
|
+
requirement: *id005
|
70
|
+
prerelease: false
|
71
|
+
type: :development
|
72
|
+
- !ruby/object:Gem::Dependency
|
73
|
+
name: georuby
|
74
|
+
version_requirements: &id006 !ruby/object:Gem::Requirement
|
75
|
+
none: false
|
76
|
+
requirements:
|
77
|
+
- - "="
|
78
|
+
- !ruby/object:Gem::Version
|
79
|
+
version: 1.9.8
|
80
|
+
requirement: *id006
|
81
|
+
prerelease: false
|
82
|
+
type: :runtime
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: dbf
|
85
|
+
version_requirements: &id007 !ruby/object:Gem::Requirement
|
86
|
+
none: false
|
87
|
+
requirements:
|
88
|
+
- - ">="
|
89
|
+
- !ruby/object:Gem::Version
|
90
|
+
version: "0"
|
91
|
+
requirement: *id007
|
92
|
+
prerelease: false
|
93
|
+
type: :runtime
|
94
|
+
- !ruby/object:Gem::Dependency
|
95
|
+
name: nokogiri
|
96
|
+
version_requirements: &id008 !ruby/object:Gem::Requirement
|
97
|
+
none: false
|
98
|
+
requirements:
|
99
|
+
- - ">="
|
100
|
+
- !ruby/object:Gem::Version
|
101
|
+
version: "0"
|
102
|
+
requirement: *id008
|
103
|
+
prerelease: false
|
104
|
+
type: :runtime
|
105
|
+
- !ruby/object:Gem::Dependency
|
106
|
+
name: geokit
|
107
|
+
version_requirements: &id009 !ruby/object:Gem::Requirement
|
108
|
+
none: false
|
109
|
+
requirements:
|
110
|
+
- - ">="
|
111
|
+
- !ruby/object:Gem::Version
|
112
|
+
version: "0"
|
113
|
+
requirement: *id009
|
114
|
+
prerelease: false
|
115
|
+
type: :runtime
|
116
|
+
- !ruby/object:Gem::Dependency
|
117
|
+
name: rgeo
|
118
|
+
version_requirements: &id010 !ruby/object:Gem::Requirement
|
119
|
+
none: false
|
120
|
+
requirements:
|
121
|
+
- - "="
|
122
|
+
- !ruby/object:Gem::Version
|
123
|
+
version: 0.3.20
|
124
|
+
requirement: *id010
|
125
|
+
prerelease: false
|
126
|
+
type: :runtime
|
127
|
+
- !ruby/object:Gem::Dependency
|
128
|
+
name: json_pure
|
129
|
+
version_requirements: &id011 !ruby/object:Gem::Requirement
|
130
|
+
none: false
|
131
|
+
requirements:
|
132
|
+
- - ">="
|
133
|
+
- !ruby/object:Gem::Version
|
134
|
+
version: "0"
|
135
|
+
requirement: *id011
|
136
|
+
prerelease: false
|
137
|
+
type: :runtime
|
138
|
+
- !ruby/object:Gem::Dependency
|
139
|
+
name: ffi-geos
|
140
|
+
version_requirements: &id012 !ruby/object:Gem::Requirement
|
141
|
+
none: false
|
142
|
+
requirements:
|
143
|
+
- - "="
|
144
|
+
- !ruby/object:Gem::Version
|
145
|
+
version: 0.1.1
|
146
|
+
requirement: *id012
|
147
|
+
prerelease: false
|
148
|
+
type: :runtime
|
149
|
+
- !ruby/object:Gem::Dependency
|
150
|
+
name: dr-ffi-proj4
|
151
|
+
version_requirements: &id013 !ruby/object:Gem::Requirement
|
152
|
+
none: false
|
153
|
+
requirements:
|
154
|
+
- - "="
|
155
|
+
- !ruby/object:Gem::Version
|
156
|
+
version: 0.0.1
|
157
|
+
requirement: *id013
|
158
|
+
prerelease: false
|
159
|
+
type: :runtime
|
160
|
+
- !ruby/object:Gem::Dependency
|
161
|
+
name: activesupport
|
162
|
+
version_requirements: &id014 !ruby/object:Gem::Requirement
|
163
|
+
none: false
|
164
|
+
requirements:
|
165
|
+
- - ">="
|
166
|
+
- !ruby/object:Gem::Version
|
167
|
+
version: "0"
|
168
|
+
requirement: *id014
|
169
|
+
prerelease: false
|
170
|
+
type: :runtime
|
148
171
|
description: Use together GeoRuby, rgeo, geokit, proj4j (and others)
|
149
172
|
email:
|
150
|
-
-
|
151
|
-
-
|
152
|
-
- alban@
|
173
|
+
- mflorisson@cityway.fr
|
174
|
+
- ldonnet@cityway.fr
|
175
|
+
- alban@tryphon.eu
|
153
176
|
executables: []
|
154
177
|
|
155
178
|
extensions: []
|
@@ -157,32 +180,51 @@ extensions: []
|
|
157
180
|
extra_rdoc_files: []
|
158
181
|
|
159
182
|
files:
|
160
|
-
- .gitignore
|
161
|
-
-
|
162
|
-
-
|
163
|
-
-
|
164
|
-
-
|
165
|
-
-
|
166
|
-
-
|
167
|
-
-
|
168
|
-
-
|
169
|
-
- lib/georuby-ext
|
170
|
-
- lib/georuby-ext/
|
171
|
-
- lib/georuby-ext/
|
172
|
-
- lib/georuby-ext/georuby/
|
173
|
-
- lib/georuby-ext/georuby/
|
174
|
-
- lib/georuby-ext/georuby/
|
175
|
-
- lib/georuby-ext/
|
176
|
-
- lib/georuby-ext/
|
177
|
-
- lib/georuby-ext/
|
178
|
-
-
|
179
|
-
-
|
180
|
-
-
|
181
|
-
-
|
182
|
-
-
|
183
|
-
-
|
184
|
-
-
|
185
|
-
-
|
183
|
+
- .gitignore
|
184
|
+
- .jrubyrc
|
185
|
+
- .travis.yml
|
186
|
+
- Gemfile
|
187
|
+
- Guardfile
|
188
|
+
- MIT-LICENSE
|
189
|
+
- README.rdoc
|
190
|
+
- Rakefile
|
191
|
+
- georuby-ext.gemspec
|
192
|
+
- lib/georuby-ext.rb
|
193
|
+
- lib/georuby-ext/core_ext.rb
|
194
|
+
- lib/georuby-ext/geokit.rb
|
195
|
+
- lib/georuby-ext/georuby/envelope.rb
|
196
|
+
- lib/georuby-ext/georuby/ewkb_parser.rb
|
197
|
+
- lib/georuby-ext/georuby/ewkt_parser.rb
|
198
|
+
- lib/georuby-ext/georuby/geometry.rb
|
199
|
+
- lib/georuby-ext/georuby/line_string.rb
|
200
|
+
- lib/georuby-ext/georuby/linear_ring.rb
|
201
|
+
- lib/georuby-ext/georuby/locators.rb
|
202
|
+
- lib/georuby-ext/georuby/multi_polygon.rb
|
203
|
+
- lib/georuby-ext/georuby/point.rb
|
204
|
+
- lib/georuby-ext/georuby/polygon.rb
|
205
|
+
- lib/georuby-ext/georuby/rtree.rb
|
206
|
+
- lib/georuby-ext/georuby/srid.rb
|
207
|
+
- lib/georuby-ext/proj4.rb
|
208
|
+
- lib/georuby-ext/rgeo/cartesian/feature_methods.rb
|
209
|
+
- lib/georuby-ext/rgeo/feature/geometry.rb
|
210
|
+
- lib/georuby-ext/rgeo/feature/geometry_collection.rb
|
211
|
+
- lib/georuby-ext/rgeo/feature/rgeo.rb
|
212
|
+
- lib/georuby-ext/rgeo/geos/ffi_feature_methods.rb
|
213
|
+
- lib/georuby-ext/rspec_helper.rb
|
214
|
+
- spec/lib/geokit_spec.rb
|
215
|
+
- spec/lib/georuby/envelope_spec.rb
|
216
|
+
- spec/lib/georuby/geometry_spec.rb
|
217
|
+
- spec/lib/georuby/line_string_spec.rb
|
218
|
+
- spec/lib/georuby/linear_ring_spec.rb
|
219
|
+
- spec/lib/georuby/locators_spec.rb
|
220
|
+
- spec/lib/georuby/multi_polygon_spec.rb
|
221
|
+
- spec/lib/georuby/point_spec.rb
|
222
|
+
- spec/lib/georuby/polygon_spec.rb
|
223
|
+
- spec/lib/georuby/rtree_spec.rb
|
224
|
+
- spec/lib/proj4_spec.rb
|
225
|
+
- spec/lib/rgeo/cartesian/feature_methods_spec.rb
|
226
|
+
- spec/lib/rgeo/geos/ffi_feature_methods_spec.rb
|
227
|
+
- spec/spec_helper.rb
|
186
228
|
homepage: http://github.com/dryade/georuby-ext
|
187
229
|
licenses: []
|
188
230
|
|
@@ -190,38 +232,31 @@ post_install_message:
|
|
190
232
|
rdoc_options: []
|
191
233
|
|
192
234
|
require_paths:
|
193
|
-
- lib
|
235
|
+
- lib
|
194
236
|
required_ruby_version: !ruby/object:Gem::Requirement
|
195
237
|
none: false
|
196
238
|
requirements:
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
|
239
|
+
- - ">="
|
240
|
+
- !ruby/object:Gem::Version
|
241
|
+
hash: 2
|
242
|
+
segments:
|
243
|
+
- 0
|
244
|
+
version: "0"
|
203
245
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
204
246
|
none: false
|
205
247
|
requirements:
|
206
|
-
|
207
|
-
|
208
|
-
|
209
|
-
|
210
|
-
|
211
|
-
|
248
|
+
- - ">="
|
249
|
+
- !ruby/object:Gem::Version
|
250
|
+
hash: 2
|
251
|
+
segments:
|
252
|
+
- 0
|
253
|
+
version: "0"
|
212
254
|
requirements: []
|
213
255
|
|
214
|
-
rubyforge_project:
|
215
|
-
rubygems_version: 1.
|
256
|
+
rubyforge_project:
|
257
|
+
rubygems_version: 1.8.24
|
216
258
|
signing_key:
|
217
259
|
specification_version: 3
|
218
260
|
summary: Extension to Ruby geometry libraries
|
219
|
-
test_files:
|
220
|
-
|
221
|
-
- spec/georuby/linear_ring_spec.rb
|
222
|
-
- spec/georuby/locators_spec.rb
|
223
|
-
- spec/georuby/multi_polygon_spec.rb
|
224
|
-
- spec/georuby/point_spec.rb
|
225
|
-
- spec/georuby/polygon_spec.rb
|
226
|
-
- spec/rgeo_spec.rb
|
227
|
-
- spec/spec_helper.rb
|
261
|
+
test_files: []
|
262
|
+
|