google-place-text-search 0.0.0
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 +7 -0
- data/lib/google_place_text_search.rb +16 -0
- metadata +44 -0
checksums.yaml
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
---
|
|
2
|
+
SHA1:
|
|
3
|
+
metadata.gz: 69e5fef7f3434bc47eaf36d1f9efb479e62083b0
|
|
4
|
+
data.tar.gz: 529089334fb8d504db2095e399f3b4625193e4b4
|
|
5
|
+
SHA512:
|
|
6
|
+
metadata.gz: 243be2df493053d60c0407e37b5fc8f920722d14be9eff7ca20adc304f6bbf5714d873e089db1459ff1cbd13bf4057637e087f5bce523201d9209f062791d24b
|
|
7
|
+
data.tar.gz: f4ef8c207b729b93c74a079345317a4b1150ef96e98ee69de826c640ad060273d2bf312a629d3104c8404207be5432050489e95e883aa660b9b74fd3e1d8323b
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
class GooglePlaceTextSearch
|
|
2
|
+
|
|
3
|
+
require 'httparty'
|
|
4
|
+
require 'json'
|
|
5
|
+
|
|
6
|
+
def get_response(api_key,radius,location,query)
|
|
7
|
+
url = "https://maps.googleapis.com/maps/api/place/textsearch/json"
|
|
8
|
+
location="#{lat},#{lng}"
|
|
9
|
+
response = HTTParty.get("#{url}", :query=>{:api_key=>api_key,:query=>query, :location=>location,:radius=>radius})
|
|
10
|
+
|
|
11
|
+
json = JSON.parse(response.body)
|
|
12
|
+
return json
|
|
13
|
+
end
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
end
|
metadata
ADDED
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
|
2
|
+
name: google-place-text-search
|
|
3
|
+
version: !ruby/object:Gem::Version
|
|
4
|
+
version: 0.0.0
|
|
5
|
+
platform: ruby
|
|
6
|
+
authors:
|
|
7
|
+
- Abhishek Sharma
|
|
8
|
+
autorequire:
|
|
9
|
+
bindir: bin
|
|
10
|
+
cert_chain: []
|
|
11
|
+
date: 2014-10-10 00:00:00.000000000 Z
|
|
12
|
+
dependencies: []
|
|
13
|
+
description: 'It get places with query string , location and radius. '
|
|
14
|
+
email: abhishek.sharma@medma.in
|
|
15
|
+
executables: []
|
|
16
|
+
extensions: []
|
|
17
|
+
extra_rdoc_files: []
|
|
18
|
+
files:
|
|
19
|
+
- lib/google_place_text_search.rb
|
|
20
|
+
homepage: http://rubygems.org/gems/google_api_customization
|
|
21
|
+
licenses:
|
|
22
|
+
- NONE
|
|
23
|
+
metadata: {}
|
|
24
|
+
post_install_message:
|
|
25
|
+
rdoc_options: []
|
|
26
|
+
require_paths:
|
|
27
|
+
- lib
|
|
28
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
|
29
|
+
requirements:
|
|
30
|
+
- - '>='
|
|
31
|
+
- !ruby/object:Gem::Version
|
|
32
|
+
version: '0'
|
|
33
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
34
|
+
requirements:
|
|
35
|
+
- - '>='
|
|
36
|
+
- !ruby/object:Gem::Version
|
|
37
|
+
version: '0'
|
|
38
|
+
requirements: []
|
|
39
|
+
rubyforge_project:
|
|
40
|
+
rubygems_version: 2.3.0
|
|
41
|
+
signing_key:
|
|
42
|
+
specification_version: 4
|
|
43
|
+
summary: Hello! This is for getting places with formatted address in bulk
|
|
44
|
+
test_files: []
|