fieldview 0.0.2 → 0.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 42ce3fc3ca592d38465e8625ab4ce76a19204ef3
4
- data.tar.gz: 73bcdb8be3ae5e3f188f14e37233f9012536608a
3
+ metadata.gz: e0b4d597a39d0a0c0833ea45cd5d5abf2374743a
4
+ data.tar.gz: d85bc687c56ac861d75633080582841f59b2364d
5
5
  SHA512:
6
- metadata.gz: 79d8559523948541f50ea3e826d163875013e30b3447285f1c948eefcf32a4371ff8e77689bf1137e45fe97e62f232af9913b1b24cc972cf2071268b3b2a7f05
7
- data.tar.gz: 90b3f2a25cfdcaed05e9cb28a53737a24e2dab9b2f93eb9db159497472bf594d6783bcc21a87a84ce18f2b9f4adaa5fd6fdb1dfbc4c1e85f3fed9ceb69bca123
6
+ metadata.gz: 61dce5f68747baa88c0272247ddbc2be85467178292f3358a6b7f613be78777e1eddaae0897d53167eb9c358ca9a86c9208cc9da7c5019a5d94c4f31fe445654
7
+ data.tar.gz: fc4a4fad66da59753792453d4307950a30f3c51309d176184d9a3270fd227468e58bd3ea09f9f41f1b27e8067c65ef2ccb1b26bec4b137bad494fc794f1a90d7
@@ -3,9 +3,9 @@ module FieldView
3
3
  attr_accessor :id, :units, :area, :centroid, :geometry
4
4
  def initialize(json_object)
5
5
  self.id = json_object[:id]
6
- self.area = json_object[:area][:q]
7
- self.units = json_object[:area][:u]
8
- self.centroid = Feature.new(json_object[:centroid])
6
+ self.area = json_object[:properties][:area][:q]
7
+ self.units = json_object[:properties][:area][:u]
8
+ self.centroid = Feature.new(json_object[:properties][:centroid])
9
9
  self.geometry = Feature.new(json_object[:geometry])
10
10
  end
11
11
  end
@@ -1,3 +1,3 @@
1
1
  module FieldView
2
- VERSION = '0.0.2'
2
+ VERSION = '0.0.3'
3
3
  end
data/spec/fixtures.json CHANGED
@@ -1,16 +1,18 @@
1
1
  {
2
2
  "boundary_one": {
3
3
  "id": "e694b43e-86eb-4773-86d0-3c4f546178dc",
4
- "area": {
5
- "q": 58.923473472390256,
6
- "u": "ac"
7
- },
8
- "centroid": {
9
- "type": "Point",
10
- "coordinates": [
11
- -105.223479062131,
12
- 40.0579906147381
13
- ]
4
+ "properties": {
5
+ "area": {
6
+ "q": 58.923473472390256,
7
+ "u": "ac"
8
+ },
9
+ "centroid": {
10
+ "type": "Point",
11
+ "coordinates": [
12
+ -105.223479062131,
13
+ 40.0579906147381
14
+ ]
15
+ }
14
16
  },
15
17
  "geometry": {
16
18
  "type": "MultiPolygon",
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fieldview
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Paul Susmarski