aucklandia 0.2.0 → 0.4.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA256:
3
- metadata.gz: 37fc92772d65047ed6b36dbfef375d30c1ef4f91e419dc1c03c6a7bc67fa33fb
4
- data.tar.gz: 784d8d6839a632b1481c02c7ebe3a7a4ffb6da2c421b7b9254ffcdd64c1be7d2
2
+ SHA1:
3
+ metadata.gz: b27dfd48680826ba8eb65ada26a623726a8abf61
4
+ data.tar.gz: bb2352ac60e378c2e63f52ce7ad55248453a71f9
5
5
  SHA512:
6
- metadata.gz: c35d82ea59bbbae8062dd6e0820e350aade128e1d1a28d9cc596fd3d5680f7ecf7685255fd4294cf7b6cb3abf4c45653125c8376757664d2c2e86a5ec7f7993b
7
- data.tar.gz: baf405e5637b9fa5660e18f1b2dbcbcf1238da1a38e02cb5102f1e072c67c164195a75144add9e039491d7149f2c5003a33c1500ce977c4e9f699fa77264ab4e
6
+ metadata.gz: a3834ffa6e38b741cb7c091437e9ea077dc32b9caf4491e7934722c060c6d6575382ea842da679bfdc960691a0163ec11f3658cebc90b25b8dd03b2613faa95a
7
+ data.tar.gz: d759b3f0ee6774d6e211624edcf6723fe39729e72156d4109afea77247823686212a792841cb6f23ab8c74321a665ecdc1e99bf38403ffa209175be7105b018c
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- aucklandia (0.2.0)
4
+ aucklandia (0.4.0)
5
5
  rest-client
6
6
 
7
7
  GEM
@@ -70,4 +70,4 @@ DEPENDENCIES
70
70
  webmock
71
71
 
72
72
  BUNDLED WITH
73
- 1.16.4
73
+ 1.17.1
@@ -17,5 +17,13 @@ module Aucklandia
17
17
 
18
18
  JSON.parse(response)['response']
19
19
  end
20
+
21
+ def get_route_by_id(route_id)
22
+ url = build_url(BASE_URL, ROUTE_ENDPOINT, '/routeId/', route_id)
23
+
24
+ response = get(url)
25
+
26
+ JSON.parse(response)['response'].first
27
+ end
20
28
  end
21
29
  end
@@ -2,6 +2,14 @@ module Aucklandia
2
2
  module Stops
3
3
  STOPS_ENDPOINT = '/gtfs/stops'
4
4
 
5
+ def get_stops
6
+ url = build_url(BASE_URL, STOPS_ENDPOINT)
7
+
8
+ response = get(url)
9
+
10
+ JSON.parse(response)['response']
11
+ end
12
+
5
13
  def get_stops_by_trip_id(trip_id)
6
14
  url = build_url(BASE_URL, STOPS_ENDPOINT, '/tripId/', trip_id)
7
15
 
@@ -1,3 +1,3 @@
1
1
  module Aucklandia
2
- VERSION = "0.2.0"
2
+ VERSION = "0.4.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aucklandia
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Theo Markkus Paul
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-10-03 00:00:00.000000000 Z
11
+ date: 2018-11-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rest-client
@@ -179,7 +179,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
179
179
  version: '0'
180
180
  requirements: []
181
181
  rubyforge_project:
182
- rubygems_version: 2.7.7
182
+ rubygems_version: 2.4.5.1
183
183
  signing_key:
184
184
  specification_version: 4
185
185
  summary: Auckland Transport API wrapper gem. Provides a suite of easy-to-use methods