地点类型是用于标识地点特征的类别。 一个地点可以分配有一个或多个地点类型。
地点的类型包含在“地点详情(新)”“附近搜索(新)”“文本搜索(新)”和“自动补全(新)”请求的响应中:
- 一个地点可以有一个关联的主要类型,该类型来自表 A 或表 B。例如,主要类型可能是
mexican_restaurant或steak_house。如果地点的主要类型是不受支持的类型,则可能会缺少主要类型。如果存在主要类型,则该类型始终是types字段中的类型之一。 - 一个地点可以有多个与类型表 A 或类型表 B 关联的类型值。
例如,某餐厅可能具有以下类型:
seafood_restaurant、restaurant、food、point_of_interest、establishment。 - 地点及其地址组成部分可以标记为地址类型和地址组成部分类型表中的某些类型。例如,某个地址可能被标记为
street_address,而该地址的某个组成部分可能被标记为street_number。
您还可以将地点类型指定为请求的一部分。如果在请求中指定,则该类型会充当过滤条件,以将响应限制为仅包含与指定类型匹配的地点。
关于类型表
表 A 列出了各种地点类型支持的值:
- 作为“地点详情(新)”“附近搜索(新)”和“文本搜索(新)”响应的一部分返回。然后,系统将使用表 A 中的值来填充这些字段。
- 在“附近搜索(新)”请求中用作
includedTypes、excludedTypes、includedPrimaryTypes和excludedPrimaryTypes参数的值。然后,系统将使用表 B 中的值来填充这些字段。 - 在“文本搜索(新)”请求中用作
includedType参数的值。 - 在“地点自动补全微件(新)”请求中用作
includedPrimaryTypes参数的值。 - 作为“地点自动补全微件(新)”响应的一部分返回。
表 B 列出了也可以在“地点详情(新)”“附近搜索(新)”“文本搜索(新)”和“地点自动补全 widget(新)”响应中返回的其他地点类型值。请求必须在字段掩码中指定 places.types 或 places.primaryType 字段中的至少一个。除了在“地点自动补全 widget(新)”请求中作为 includedPrimaryTypes 参数的值以外,表 B 中的值不能在请求中使用。
地址类型和地址组成部分类型 列出了可能会出现在响应正文中的地址类型数组和/或地址组成部分类型数组中的类型。地址组成部分类型可能会发生变化。
表 A
| 汽车 | ||
|---|---|---|
car_dealercar_rentalcar_repaircar_washebike_charging_station *electric_vehicle_charging_stationgas_station |
parkingparking_garage *parking_lot *rest_stoptire_shop *truck_dealer * |
|
| 企业 | ||
business_center *corporate_officecoworking_space *farmmanufacturer *ranchsupplier *television_studio * |
||
| 文化 | ||
art_galleryart_museum *art_studioauditoriumcastle *cultural_landmarkfountain *historical_placehistory_museum * |
monumentmuseumperforming_arts_theatersculpture |
|
| 教育 | ||
academic_department *educational_institution *librarypreschoolprimary_school |
research_institute *schoolsecondary_schooluniversity |
|
| 休闲娱乐场所 | ||
adventure_sports_centeramphitheatreamusement_centeramusement_parkaquariumbanquet_hallbarbecue_areabotanical_gardenbowling_alleycasinochildrens_campcity_park *comedy_clubcommunity_centerconcert_hallconvention_centercultural_centercycling_parkdance_halldog_parkevent_venueferris_wheelgardengo_karting_venue * |
hiking_areahistorical_landmarkindoor_playground *internet_cafekaraokelive_music_venue *marinaminiature_golf_course *movie_rentalmovie_theaternational_parknight_clubobservation_deckoff_roading_areaopera_housepaintball_center *parkphilharmonic_hallpicnic_groundplanetariumplazaroller_coasterskateboard_parkstate_park |
tourist_attractionvideo_arcadevineyard *visitor_centerwater_parkwedding_venuewildlife_parkwildlife_refugewinery *zoo
|
| 设施 | ||
public_bathpublic_bathroomstable
|
||
| 财经 | ||
accountingatmbank
|
||
| 餐饮 | ||
acai_shopafghani_restaurantafrican_restaurantamerican_restaurantargentinian_restaurant *asian_fusion_restaurant *asian_restaurantaustralian_restaurant *austrian_restaurant *bagel_shopbakerybangladeshi_restaurant *barbar_and_grillbarbecue_restaurantbasque_restaurant *bavarian_restaurant *beer_garden *belgian_restaurant *bistro *brazilian_restaurantbreakfast_restaurantbrewery *brewpub *british_restaurant *brunch_restaurantbuffet_restaurantburmese_restaurant *burrito_restaurant *cafecafeteriacajun_restaurant *cake_shop *californian_restaurant *cambodian_restaurant *candy_storecantonese_restaurant *caribbean_restaurant *cat_cafechicken_restaurant *chicken_wings_restaurant *chilean_restaurant *chinese_noodle_restaurant *chinese_restaurantchocolate_factorychocolate_shopcocktail_bar *coffee_roastery *coffee_shopcoffee_stand *colombian_restaurant *confectionerycroatian_restaurant *cuban_restaurant *czech_restaurant *danish_restaurant *deli |
dessert_restaurantdessert_shopdim_sum_restaurant *dinerdog_cafedonut_shopdumpling_restaurant *dutch_restaurant *eastern_european_restaurant *ethiopian_restaurant *european_restaurant *falafel_restaurant *family_restaurant *fast_food_restaurantfilipino_restaurant *fine_dining_restaurantfish_and_chips_restaurant *fondue_restaurant *food_courtfrench_restaurantfusion_restaurant *gastropub *german_restaurant *greek_restaurantgyro_restaurant *halal_restaurant* hamburger_restauranthawaiian_restaurant *hookah_bar *hot_dog_restaurant *hot_dog_stand *hot_pot_restaurant *hungarian_restaurant *ice_cream_shopindian_restaurantindonesian_restaurantirish_pub *irish_restaurant *israeli_restaurant *italian_restaurantjapanese_curry_restaurant *japanese_izakaya_restaurant *japanese_restaurantjuice_shopkebab_shop *korean_barbecue_restaurant *korean_restaurantlatin_american_restaurant *lebanese_restaurantlounge_bar *malaysian_restaurant *meal_deliverymeal_takeawaymediterranean_restaurantmexican_restaurantmiddle_eastern_restaurantmongolian_barbecue_restaurant * |
moroccan_restaurant *noodle_shop *north_indian_restaurant *oyster_bar_restaurant *pakistani_restaurant *pastry_shop *persian_restaurant *peruvian_restaurant *pizza_delivery *pizza_restaurantpolish_restaurant *portuguese_restaurant *pubramen_restaurantrestaurantromanian_restaurant *russian_restaurant *salad_shop *sandwich_shopscandinavian_restaurant *seafood_restaurantshawarma_restaurant *snack_bar *soul_food_restaurant *soup_restaurant *south_american_restaurant *south_indian_restaurant *southwestern_us_restaurant *spanish_restaurantsports_bar *sri_lankan_restaurant *steak_housesushi_restaurantswiss_restaurant *taco_restaurant *taiwanese_restaurant *tapas_restaurant *tea_housetex_mex_restaurant *thai_restauranttibetan_restaurant *tonkatsu_restaurant *turkish_restaurantukrainian_restaurant *vegan_restaurantvegetarian_restaurantvietnamese_restaurantwestern_restaurant *wine_barwinery *yakiniku_restaurant *yakitori_restaurant * |
| 地理区域 | ||
administrative_area_level_1administrative_area_level_2country
|
localitypostal_codeschool_district
|
|
| 政府 | ||
city_hallcourthouseembassyfire_stationgovernment_office
|
local_government_officeneighborhood_police_station(仅限日本)policepost_office
|
|
| 健康与保健 | ||
chiropractordental_clinicdentistdoctordrugstoregeneral_hospital *hospitalmassagemassage_spa *medical_center *medical_clinic *medical_lab
|
pharmacyphysiotherapistsaunaskin_care_clinicspatanning_studiowellness_centeryoga_studio
|
|
| 住房 | ||
apartment_buildingapartment_complexcondominium_complexhousing_complex
|
||
| 住宿 | ||
bed_and_breakfastbudget_japanese_inncampgroundcamping_cabincottageextended_stay_hotelfarmstayguest_househostelhotel |
innjapanese_innlodgingmobile_home_parkmotelprivate_guest_roomresort_hotelrv_park
|
|
| 自然景观 | ||
beachisland *lake *mountain_peak *nature_preserve *river *scenic_spot *woods * |
||
| 礼拜场所 | ||
buddhist_temple *churchhindu_templemosqueshinto_shrine *synagogue
|
||
| 服务 | ||
aircraft_rental_service *association_or_organization *astrologerbarber_shopbeauticianbeauty_salonbody_art_servicecatering_servicecemeterychauffeur_service *child_care_agencyconsultantcourier_serviceelectricianemployment_agency *floristfood_deliveryfoot_carefuneral_homehair_carehair_saloninsurance_agencylaundrylawyerlocksmith |
makeup_artistmarketing_consultant *moving_companynail_salonnon_profit_organization *painterpet_boarding_service *pet_care *plumberpsychicreal_estate_agencyroofing_contractorservice *shipping_service *storagesummer_camp_organizertailortelecommunications_service_providertour_agencytourist_information_centertravel_agencyveterinary_care
|
|
| 购物 | ||
asian_grocery_storeauto_parts_storebicycle_storebook_storebuilding_materials_store *butcher_shopcell_phone_storeclothing_storeconvenience_storecosmetics_store *department_storediscount_storediscount_supermarket *electronics_storefarmers_market *flea_market *food_storefurniture_storegarden_center *general_store *gift_shopgrocery_storehardware_storehealth_food_store *home_goods_store
|
home_improvement_storehypermarket *jewelry_storeliquor_storemarketpet_storeshoe_storeshopping_mallsporting_goods_storesportswear_store *storesupermarkettea_store *thrift_store *toy_store *warehouse_storewholesalerwomens_clothing_store * |
|
| 体育 | ||
arenaathletic_fieldfishing_charterfishing_pier *fishing_pondfitness_centergolf_coursegymice_skating_rinkindoor_golf_course * |
playgroundrace_course *ski_resortsports_activity_locationsports_clubsports_coachingsports_complexsports_school *stadiumswimming_pool *tennis_court * |
|
| 交通 | ||
airportyakitori_restaurant *airstripbike_sharing_station *bridge *bus_stationbus_stopferry_service *ferry_terminalheliportinternational_airportlight_rail_stationpark_and_ride |
subway_stationtaxi_service *taxi_standtoll_station *train_stationtrain_ticket_office *tram_stop *transit_depottransit_stationtransit_stop *transportation_service *truck_stop
|
|
表 B
表 B 中的地点类型值可能会作为“地点详情(新)”“附近搜索(新)”“文本搜索(新)”或“自动补全(新)”响应的一部分返回。includedPrimaryTypes 还支持用于自动补全(新)请求的这些类型。
| 其他地点类型值 | ||
|---|---|---|
administrative_area_level_3administrative_area_level_4administrative_area_level_5administrative_area_level_6administrative_area_level_7archipelagocolloquial_areacontinentestablishmentfinancefoodgeneral_contractorgeocodehealthintersectionlandmarknatural_featureneighborhoodplace_of_worshipplus_code
|
point_of_interestpoliticalpostal_code_prefixpostal_code_suffixpostal_townpremiseroutestreet_addresssublocalitysublocality_level_1sublocality_level_2sublocality_level_3sublocality_level_4sublocality_level_5subpremisetown_square
|
|
地址类型和地址组成部分类型
响应中的 types 数组表示地址类型。地址类型的示例包括街道地址、国家/地区或政治实体。google.maps.places.AddressComponent 类中的 types 数组表示地址每个部分的类型。示例包括门牌号码或国家/地区。
地址可能具有多种类型。这些类型可以视为“标记”。
例如,许多城市都带有 political 和 locality 类型的标记。
对于地址类型和地址组成部分类型数组,地理编码器都支持并返回以下类型:
| 地址类型 | 说明 |
|---|---|
street_address |
精确的街道地址。 |
route |
已命名的路线(例如“US 101”)。 |
intersection |
主要交叉路口,通常是两条主要道路的交叉路口。 |
political |
政治实体。通常,这种类型表示某个民政管理部门的多边形 |
country |
表示国家政治实体,通常列在地理编码器所返回结果的最前面。 |
administrative_area_level_1 |
表示国家/地区级别以下的一级行政实体。在美国,这类行政级别是指州。并不是所有国家都设有这类行政级别。在大多数情况下,administrative_area_level_1 简称可高度匹配 ISO 3166-2 行政区划以及其他广为传播的列表;不过,我们无法对此做出保证,因为我们的地理编码结果基于各种信号和位置数据。 |
administrative_area_level_2 |
表示国家/地区级别以下的二级行政实体。在美国,这类行政级别是指县。并不是所有国家都设有这类行政级别。 |
administrative_area_level_3 |
表示国家/地区级别以下的三级行政实体。此类型表示较小的行政区划单位。并不是所有国家都设有这类行政级别。 |
administrative_area_level_4 |
表示国家/地区级别以下的四级行政实体。此类型表示较小的行政区划单位。并不是所有国家都设有这类行政级别。 |
administrative_area_level_5 |
表示国家/地区级别以下的五级行政实体。此类型表示较小的行政区划单位。并不是所有国家都设有这类行政级别。 |
administrative_area_level_6 |
表示国家/地区级别以下的六级行政实体。此类型表示较小的行政区划单位。并不是所有国家都设有这类行政级别。 |
administrative_area_level_7 |
表示国家/地区级别以下的七级行政实体。此类型表示较小的行政区划单位。并不是所有国家都设有这类行政级别。 |
colloquial_area |
实体的常用替代名称。 |
locality |
表示有建制的城市或城镇政治实体。 |
sublocality |
表示市行政区以下的一级行政实体。对于某些位置,可能会收到以下任一类型:从 sublocality_level_1 到 sublocality_level_5。每个子级市行政区级别都是一个行政实体。数字越大,表示的地理区域越小 |
neighborhood |
表示已命名的街区。 |
premise |
已命名的位置,通常是具有常见名称的建筑或建筑群。 |
subpremise |
营业场所级别以下的地址实体,例如公寓、单元或套房。 |
plus_code |
经过编码的位置引用,衍生自纬度和经度。在没有街道地址的地点(例如建筑物未编号,或者街道未命名),Plus Code 可替代街道地址使用。如需了解详情,请参阅 https://plus.codes。 |
postal_code |
表示国家/地区内邮寄地址所用的邮政编码。 |
natural_feature |
某个明显的自然地貌。 |
airport |
机场。 |
park |
表示已命名的公园。 |
point_of_interest |
已命名的地图注点。通常情况下,这些“地图注点”是当地的著名实体,无法轻易归入其他类别,例如“帝国大厦”或“埃菲尔铁塔”。 |
空的类型列表表示特定地址组成部分没有对应的已知类型(例如法国的地点 [Lieu-dit])。
除了上述类型之外,地址组成部分还可能包括下列类型。
| 地址组成部分类型 | 说明 |
|---|---|
floor |
建筑物地址的楼层。 |
establishment |
通常表示某个尚未归类的地点。 |
landmark |
可用作辅助导航的参考的附近地点。 |
point_of_interest |
已命名的地图注点。 |
parking |
停车场或停车楼。 |
post_box |
特定邮箱。 |
postal_town |
地理区域分组(例如 locality 和 sublocality),在某些国家/地区用于邮寄地址。 |
room |
建筑物地址的房间。 |
street_number |
精确的门牌号。 |
bus_station、train_station和transit_station |
公交车站、火车站或公共交通站的位置。 |