city_grid 0.0.2 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- data/city_grid.gemspec +1 -0
- data/lib/city_grid/api.rb +1 -1
- data/lib/city_grid/detail.rb +7 -0
- data/lib/city_grid/request.rb +5 -1
- data/lib/city_grid/result.rb +4 -0
- data/lib/city_grid/version.rb +1 -1
- data/lib/city_grid.rb +3 -0
- metadata +21 -8
data/city_grid.gemspec
CHANGED
data/lib/city_grid/api.rb
CHANGED
data/lib/city_grid/request.rb
CHANGED
@@ -13,6 +13,10 @@ module CityGrid
|
|
13
13
|
end
|
14
14
|
|
15
15
|
private
|
16
|
+
def request_class
|
17
|
+
request_opts[:request_class] || Curl
|
18
|
+
end
|
19
|
+
|
16
20
|
def default_opts
|
17
21
|
{
|
18
22
|
format: 'json',
|
@@ -25,7 +29,7 @@ module CityGrid
|
|
25
29
|
end
|
26
30
|
|
27
31
|
def make_request
|
28
|
-
|
32
|
+
request_class.get(@uri, @request_opts)
|
29
33
|
end
|
30
34
|
end
|
31
35
|
end
|
data/lib/city_grid/version.rb
CHANGED
data/lib/city_grid.rb
CHANGED
@@ -1,3 +1,4 @@
|
|
1
|
+
require 'hashie'
|
1
2
|
require 'city_grid/version'
|
2
3
|
require 'city_grid/config'
|
3
4
|
require 'city_grid/request'
|
@@ -5,6 +6,8 @@ require 'city_grid/api'
|
|
5
6
|
require 'city_grid/reviews'
|
6
7
|
require 'city_grid/places'
|
7
8
|
require 'city_grid/offers'
|
9
|
+
require 'city_grid/detail'
|
10
|
+
require 'city_grid/result'
|
8
11
|
|
9
12
|
module CityGrid
|
10
13
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: city_grid
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.3
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,11 +9,11 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2012-09-
|
12
|
+
date: 2012-09-18 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: curb
|
16
|
-
requirement: &
|
16
|
+
requirement: &6945960 !ruby/object:Gem::Requirement
|
17
17
|
none: false
|
18
18
|
requirements:
|
19
19
|
- - ! '>='
|
@@ -21,10 +21,10 @@ dependencies:
|
|
21
21
|
version: '0'
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
|
-
version_requirements: *
|
24
|
+
version_requirements: *6945960
|
25
25
|
- !ruby/object:Gem::Dependency
|
26
26
|
name: json
|
27
|
-
requirement: &
|
27
|
+
requirement: &6945180 !ruby/object:Gem::Requirement
|
28
28
|
none: false
|
29
29
|
requirements:
|
30
30
|
- - ! '>='
|
@@ -32,10 +32,21 @@ dependencies:
|
|
32
32
|
version: '0'
|
33
33
|
type: :runtime
|
34
34
|
prerelease: false
|
35
|
-
version_requirements: *
|
35
|
+
version_requirements: *6945180
|
36
|
+
- !ruby/object:Gem::Dependency
|
37
|
+
name: hashie
|
38
|
+
requirement: &6961320 !ruby/object:Gem::Requirement
|
39
|
+
none: false
|
40
|
+
requirements:
|
41
|
+
- - ! '>='
|
42
|
+
- !ruby/object:Gem::Version
|
43
|
+
version: '0'
|
44
|
+
type: :runtime
|
45
|
+
prerelease: false
|
46
|
+
version_requirements: *6961320
|
36
47
|
- !ruby/object:Gem::Dependency
|
37
48
|
name: pry
|
38
|
-
requirement: &
|
49
|
+
requirement: &6960740 !ruby/object:Gem::Requirement
|
39
50
|
none: false
|
40
51
|
requirements:
|
41
52
|
- - ! '>='
|
@@ -43,7 +54,7 @@ dependencies:
|
|
43
54
|
version: '0'
|
44
55
|
type: :development
|
45
56
|
prerelease: false
|
46
|
-
version_requirements: *
|
57
|
+
version_requirements: *6960740
|
47
58
|
description: Ruby wrapper for CityGrid API
|
48
59
|
email:
|
49
60
|
- nicholas.fine@gmail.com
|
@@ -60,9 +71,11 @@ files:
|
|
60
71
|
- lib/city_grid.rb
|
61
72
|
- lib/city_grid/api.rb
|
62
73
|
- lib/city_grid/config.rb
|
74
|
+
- lib/city_grid/detail.rb
|
63
75
|
- lib/city_grid/offers.rb
|
64
76
|
- lib/city_grid/places.rb
|
65
77
|
- lib/city_grid/request.rb
|
78
|
+
- lib/city_grid/result.rb
|
66
79
|
- lib/city_grid/reviews.rb
|
67
80
|
- lib/city_grid/version.rb
|
68
81
|
homepage: ''
|