MapUp Tlemcen - Google Maps API

Preview:

Citation preview

Google Confidential and Proprietary

Maps API

GDG Tlemcen

Google Confidential and Proprietary

Introduction

La cartographie dynamique. Permettre à l’internaute de naviguer dans

des cartes Démocratiser cette nouvelle technologie. Web mapping.

Google Confidential and Proprietary

Introduction

Version 3, plus de 350 000 sites web l’utilisent pour afficher des cartes dynamiques.

L’API a été proposée aux développeurs en juin 2005.

Google Confidential and Proprietary

What is Google Maps API?

Une interface de programmation. Il s’agit d’un ensemble de fonctions et classes

JavaScript qui permettent de manipuler une carte dynamiquement au sein d’un site web.

Google Confidential and Proprietary

Web Android

Get Started!!

Google Confidential and Proprietary

Obtaining an API Key

To create your API key:

1. APIs Console at https://code.google.com/apis/console.

2. Click the Services link from the left-hand menu.

3. Activate the Google Maps API v3 service.4. Click the API Access link from the left-hand

menu.Web

Google Confidential and Proprietary

Your API key is available from the API Access page, in the Simple API Access section.

Web

Google Confidential and Proprietary

Simple Map, example

Web

Google Confidential and Proprietary

Result

Web

Google Confidential and Proprietary

Web Android

Google Confidential and Proprietary

Overview

Android

Install the Android SDK. Download and configure the

Google Play services SDK. Obtain an API key. Add the required settings in your application's

manifest. Add a map to your application. Publish your application.

Google Confidential and Proprietary

Install the Android SDK

Android

http://developer.android.com/sdk/

Google Confidential and Proprietary

Google Play services SDK

Android

Install the Google Play services SDK.

Add Google Play services as an Android library project.

Reference the Google Play services in your app's project.

Google Confidential and Proprietary

Obtain an API key

Android

http://console.developers.google.com

In the Services page, verify that the "Google Maps Android API v2" is enabled.

In the left navigation bar, click API Access. In the resulting page, click Create New Android

Key. Enter the SHA-1 fingerprint, then a semicolon,

then your application's package name.

Google Confidential and Proprietary

Obtain an API key

Android

Google Confidential and Proprietary

Android Manifest

Android

Add the Google Play

services version.

Specify API key.

Specify requirement for

OpenGL ES 2

Specify permissions.

Google Confidential and Proprietary

Android

Add the Google Play services version

Google Confidential and Proprietary

Android

Specify API key

Google Confidential and Proprietary

Android

Specify requirement for OpenGL ES 2

Google Confidential and Proprietary

Android

Specify permissions

Google Confidential and Proprietary

Add a map

Android

In the app's layout XML

file.

Extend MapFragment.

Basic setup.

Google Confidential and Proprietary

Android

1. Add the following fragment in the app's layout XML file

Google Confidential and Proprietary

Android

2. Add the following code in ActivityMain.java

Google Confidential and Proprietary

Simple Map, example

Android

Google Confidential and Proprietary

Result

Android

Google Confidential and Proprietary

Thanks! Questions?

meriemb.tlm@gmail.com

Meryem Bendella

Meryem BENDELLA‘GDG Tlemcen Technical Manager ’

Recommended