概要
コレクションでコンテンツを整理
必要に応じて、コンテンツの保存と分類を行います。
境界線用データドリブン スタイル設定は、行政区域境界線を示す Google のポリゴンに、スタイル設定を適用し、地図上に表示できる機能です。
境界線用データドリブン スタイル設定では、プレイス ID に基づいてターゲット地域を指定し、地図上の境界線ポリゴンにカスタム スタイル設定を適用できます。各対象物タイプは地域の種類を表します。有効にする対象物タイプは、地図のスタイルを設定するときに選択します。国ごとの境界線情報の提供範囲は、Google の境界線の範囲でご確認いただけます。
対象物の種類
データドリブン スタイル設定を使うと、行政区域を表す対象物の種類に応じた境界線を使用できるようになります。行政区域は、国、都道府県、地域、郵便番号などの機能単位ごとに分類されています。対象物の種類は行政区分の階層に基づいて並べられていて、この構造は国によって異なります。
たとえば:
GMSFeatureTypeCountry
- 国の政治的区域(通常は最上位)
GMSFeatureTypeAdministrativeAreaLevel1
- 国の 1 段階下の行政区域。米国の場合、州がこの行政区画レベルに相当しますが、
GMSFeatureTypeAdministrativeAreaLevel2
- は国の 2 段階下の行政区域。米国の場合、郡がこの行政区画レベルに相当しますが、
GMSFeatureTypeLocality
— 行政区域である都市または町
GMSFeatureTypePostalCode
- 対象の国内で郵便物の宛先として使用される郵便番号。
GMSFeatureTypeSchoolDistrict
- 学区(一貫校、小学校、中学校を含む)。
行政区域は対象物レイヤとして地図上に表示されます。対象物の種類ごとに独自のレイヤがあります。地図のレイヤは、地図のスタイルごとに有効化されます。どの地図のレイヤを有効にするかは、Google Cloud コンソールで地図のスタイルを設定する際に選択できます。
境界線ポリゴンのスタイルを設定する
境界線ポリゴンに塗りつぶし(色、不透明度)とストローク(色、不透明度、ストロークの太さ)のスタイルを適用できます。スタイルを使用して次のことができます。
- 1 つの境界線ポリゴンのスタイルを設定したり、同じ種類の対象物のすべての境界線を表示したりすることができます。
- 階級区分図を作成します。
Google の境界線の範囲では、国ごとに利用できる対象物の種類を確認できます。
特に記載のない限り、このページのコンテンツはクリエイティブ・コモンズの表示 4.0 ライセンスにより使用許諾されます。コードサンプルは Apache 2.0 ライセンスにより使用許諾されます。詳しくは、Google Developers サイトのポリシーをご覧ください。Java は Oracle および関連会社の登録商標です。
最終更新日 2025-08-31 UTC。
[null,null,["最終更新日 2025-08-31 UTC。"],[[["\u003cp\u003eData-driven styling enables applying custom styles to Google's administrative boundary polygons on your maps, targeting regions by place ID.\u003c/p\u003e\n"],["\u003cp\u003eYou can select specific feature types like countries, states, localities, and postal codes to display on your map.\u003c/p\u003e\n"],["\u003cp\u003eBoundary polygons can be styled with fill and stroke properties to create visual effects or choropleth maps.\u003c/p\u003e\n"],["\u003cp\u003eGoogle provides boundary data for various countries, and coverage details are available in the documentation.\u003c/p\u003e\n"],["\u003cp\u003eData-driven styling is available across Android, iOS, and JavaScript platforms.\u003c/p\u003e\n"]]],["Data-driven styling allows accessing and styling Google's administrative boundary polygons on maps. Users can target regions by place ID and apply custom styling to the polygons. Feature types, categorized by administrative level (e.g., country, state, locality, postal code, school district), are accessed via layers within map styles. Styling options include fill color and opacity, as well as stroke color, opacity, and weight, enabling the creation of choropleth maps or individual boundary styles. Availability of these feature types varies by country.\n"],null,["Select platform: [Android](/maps/documentation/android-sdk/dds-boundaries/overview \"View this page for the Android platform docs.\") [iOS](/maps/documentation/ios-sdk/dds-boundaries/overview \"View this page for the iOS platform docs.\") [JavaScript](/maps/documentation/javascript/dds-boundaries/overview \"View this page for the JavaScript platform docs.\")\n\n\u003cbr /\u003e\n\nData-driven styling for boundaries lets you access Google's polygons for\nadministrative boundaries, apply styling to boundary polygons, display them on\nyour maps.\n\nData-driven styling for boundaries lets you target regions by place ID, and apply\ncustom styling to boundary polygons on the map. Each feature type represents a\ntype of region; you select which feature types to enable when configuring a map\nstyle. Consult [Google boundaries coverage](/maps/documentation/ios-sdk/dds-boundaries/coverage) to see per-country\nboundary coverage.\n\nFeature types\n\nData-driven styling provides access to Google boundaries for feature types that\nrepresent administrative areas. Administrative areas are categorized by\nfunction, for example country, state, locality, and postal code. Feature types\nare arranged by administrative level, the structure of which varies by country.\nThese include:\n\n- `GMSFeatureTypeCountry` --- The national political entity, typically the highest order type.\n- `GMSFeatureTypeAdministrativeAreaLevel1` - A first-order civil entity below the country level. Within the United States, these administrative levels are states.\n- `GMSFeatureTypeAdministrativeAreaLevel2` --- A second-order civil entity below the country level. Within the United States, these administrative levels are counties.\n- `GMSFeatureTypeLocality` --- An incorporated city or town political entity.\n- `GMSFeatureTypePostalCode` --- A postal code, as used to address postal mail within the country.\n- `GMSFeatureTypeSchoolDistrict` --- A school district; includes unified, elementary, and secondary.\n\nAdministrative areas are represented on the map as feature layers; each type has\nits own layer. Feature layers are enabled per map style. You can choose which\nfeature layers to enable when setting up your map style in the\nGoogle Cloud console.\n\nStyle boundary polygons\n\nYou can apply styles to boundary polygons for fill (color, opacity), and stroke\n(color, opacity, stroke weight). Use styling to:\n\n- Style a boundary polygon or show all the boundaries for a feature type.\n- Create a choropleth map.\n\n[Google boundaries coverage](/maps/documentation/ios-sdk/dds-boundaries/coverage) shows per-country availability of feature\ntypes."]]