如何在Google地图上创建地图。 [英] How to create a map on Google map.

查看:101
本文介绍了如何在Google地图上创建地图。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

亲爱的所有人,

我不了解基于地理位置的技术,公司想要创建基于地理位置的桌面应用程序,并且我是这个应用程序的一部分,我对此一无所知。



职责:获取建筑物/家庭的经度和经度,并在用户身份的谷歌地图上显示。



如果有人有任何想法,请指导我。



先谢谢。

Daulat Singh。



我尝试过的事情:



由于缺乏准则,我没有尝试任何事情。

Dear All,
Am not Aware in Geo Based Technology,Company want to create Geo based desktop application and am a part of this application i don't have any idea about that.

Responsibilities : Take latitude and longitude of a building/Home and show this on Google map with a user identity.

If some one have any idea please guide me.

Thanks in Advance.
Daulat Singh.

What I have tried:

Am not trying to anything because of lack of guideline.

推荐答案

您需要执行此操作的所有信息都在Googles服务器上。利用他们的API密钥,您就可以在应用程序中找到它。但要实现这一点,您需要拥有Google开发人员API,凭据。



地理编码请求和响应(纬度/经度查询)



All the info you need to do this is on Googles servers. Make use of their API keys and you are where you want to be with your application. For this to work however, you need to have a google developer API, credentials.

Geocoding request and response (latitude/longitude lookup)

{
   "results" : [
      {
         "address_components" : [
            {
               "long_name" : "1600",
               "short_name" : "1600",
               "types" : [ "street_number" ]
            },
            {
               "long_name" : "Amphitheatre Pkwy",
               "short_name" : "Amphitheatre Pkwy",
               "types" : [ "route" ]
            },
            {
               "long_name" : "Mountain View",
               "short_name" : "Mountain View",
               "types" : [ "locality", "political" ]
            },
            {
               "long_name" : "Santa Clara County",
               "short_name" : "Santa Clara County",
               "types" : [ "administrative_area_level_2", "political" ]
            },
            {
               "long_name" : "California",
               "short_name" : "CA",
               "types" : [ "administrative_area_level_1", "political" ]
            },
            {
               "long_name" : "United States",
               "short_name" : "US",
               "types" : [ "country", "political" ]
            },
            {
               "long_name" : "94043",
               "short_name" : "94043",
               "types" : [ "postal_code" ]
            }
         ],
         "formatted_address" : "1600 Amphitheatre Parkway, Mountain View, CA 94043, USA",
         "geometry" : {
            "location" : {
               "lat" : 37.4224764,
               "lng" : -122.0842499
            },
            "location_type" : "ROOFTOP",
            "viewport" : {
               "northeast" : {
                  "lat" : 37.4238253802915,
                  "lng" : -122.0829009197085
               },
               "southwest" : {
                  "lat" : 37.4211274197085,
                  "lng" : -122.0855988802915
               }
            }
         },
         "place_id" : "ChIJ2eUgeAK6j4ARbn5u_wAGqWA",
         "types" : [ "street_address" ]
      }
   ],
   "status" : "OK"
}





反向地理编码请求和响应(地址查询)

< br $>



Reverse geocoding request and response (address lookup)

{
   "results" : [
      {
         "address_components" : [
            {
               "long_name" : "277",
               "short_name" : "277",
               "types" : [ "street_number" ]
            },
            {
               "long_name" : "Bedford Avenue",
               "short_name" : "Bedford Ave",
               "types" : [ "route" ]
            },
            {
               "long_name" : "Williamsburg",
               "short_name" : "Williamsburg",
               "types" : [ "neighborhood", "political" ]
            },
            {
               "long_name" : "Brooklyn",
               "short_name" : "Brooklyn",
               "types" : [ "sublocality", "political" ]
            },
            {
               "long_name" : "Kings",
               "short_name" : "Kings",
               "types" : [ "administrative_area_level_2", "political" ]
            },
            {
               "long_name" : "New York",
               "short_name" : "NY",
               "types" : [ "administrative_area_level_1", "political" ]
            },
            {
               "long_name" : "United States",
               "short_name" : "US",
               "types" : [ "country", "political" ]
            },
            {
               "long_name" : "11211",
               "short_name" : "11211",
               "types" : [ "postal_code" ]
            }
         ],
         "formatted_address" : "277 Bedford Avenue, Brooklyn, NY 11211, USA",
         "geometry" : {
            "location" : {
               "lat" : 40.714232,
               "lng" : -73.9612889
            },
            "location_type" : "ROOFTOP",
            "viewport" : {
               "northeast" : {
                  "lat" : 40.7155809802915,
                  "lng" : -73.9599399197085
               },
               "southwest" : {
                  "lat" : 40.7128830197085,
                  "lng" : -73.96263788029151
               }
            }
         },
         "place_id" : "ChIJd8BlQ2BZwokRAFUEcm_qrcA",
         "types" : [ "street_address" ]
      },

   ... Additional results truncated in this example[] ...

   ],
   "status" : "OK"
}





这些只是从Google获取的样本映射服务器。您需要对Json有基本的了解才能完成您已经完成的任务...您可以在此处阅读更多相关信息: Google Maps API  ; |&NBSP; Google Developers [ ^ ]



在开始深入研究之前,您还需要创建一个Google Developer API / Credentials。您可以在此处执行此操作:

登录 - Google帐户 [ ^ ]



或尝试使用此直接链接 直接链接 [ ^ ]用于您的API凭证。



These are only samples taken from google maps servers. You will need a basic understanding of Json to complete the task you have been given... You can read more about it here: Google Maps APIs  |  Google Developers[^]

You will also need to create a Google Developer API/Credentials before you start delving into this. You can do that here:
Sign in - Google Accounts[^]

Or try this direct link direct link[^] for your API credentials.


这篇关于如何在Google地图上创建地图。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆