SDK điều hướng cho mã mẫu Android
Sử dụng bộ sưu tập để sắp xếp ngăn nắp các trang
Lưu và phân loại nội dung dựa trên lựa chọn ưu tiên của bạn.
Kho lưu trữ mẫu của Navigation SDK cho Android trên GitHub có các ứng dụng mẫu minh hoạ cách sử dụng SDK này. Bạn có thể nhập và tạo các ứng dụng, thêm khoá API, xem bản minh hoạ và sử dụng mã mẫu được cung cấp làm điểm bắt đầu cho ứng dụng của mình. Kho lưu trữ này chứa 2 ứng dụng mẫu:
- Map-sample, một bản trình diễn về giao diện người dùng MapView và NavView:
android-navigation-samples/map-sample/
- Navigation-sample, Trải nghiệm điều hướng cơ bản:
android-navigation-samples /navigation-sample/
Để biết thêm thông tin về cách chạy các ứng dụng mẫu, hãy xem phần Dùng thử bản minh hoạ.
Lớp học lập trình về Navigation SDK cho Android
Để tìm hiểu cách sử dụng Navigation SDK bằng cách tạo một ứng dụng Android đơn giản, hãy xem Lớp học lập trình Navigation SDK cho Android.
Lớp học lập trình này cung cấp hướng dẫn từng bước để triển khai SDK bằng Kotlin.
Trừ phi có lưu ý khác, nội dung của trang này được cấp phép theo Giấy phép ghi nhận tác giả 4.0 của Creative Commons và các mẫu mã lập trình được cấp phép theo Giấy phép Apache 2.0. Để biết thông tin chi tiết, vui lòng tham khảo Chính sách trang web của Google Developers. Java là nhãn hiệu đã đăng ký của Oracle và/hoặc các đơn vị liên kết với Oracle.
Cập nhật lần gần đây nhất: 2025-08-31 UTC.
[null,null,["Cập nhật lần gần đây nhất: 2025-08-31 UTC."],[[["\u003cp\u003eThe Navigation SDK for Android provides sample apps on GitHub that demonstrate the use of the SDK, allowing developers to import, build, and explore the code.\u003c/p\u003e\n"],["\u003cp\u003eThe repository features two key samples: "Map-sample" focusing on MapView and NavView UI, and "Navigation-sample" showcasing the core navigation experience.\u003c/p\u003e\n"],["\u003cp\u003eA dedicated Codelab offers a step-by-step guide to build a simple Android app using the Navigation SDK with Kotlin, aiding developers in practical implementation.\u003c/p\u003e\n"]]],[],null,["# Navigation SDK for Android code samples\n\nThe Navigation SDK for Android [samples repository on\nGitHub](https://github.com/googlemaps-samples/android-navigation-samples)\nincludes sample apps that demonstrate the use of the SDK. You can import and\nbuild the apps, add your API key, view the demo, and use the sample code\nsupplied as a starting point for your app. The repository contains two sample\napps:\n\n- **Map-sample** , a showcase of the MapView and NavView UI: `android-navigation-samples/map-sample/`\n- **Navigation-sample** , The fundamental navigation experience: `android-navigation-samples /navigation-sample/`\n\nFor more information about running the sample apps, see [Try the\ndemo](/maps/documentation/navigation/android-sdk/try-demo).\n\nNavigation SDK for Android Codelab\n----------------------------------\n\nTo learn how to use the Navigation SDK by building a simple Android app, see the\n[Navigation SDK for Android\nCodelab](https://codelabs.developers.google.com/codelabs/maps-platform/navigation-sdk-101-android).\nThe Codelab provides a step-by-step guide for implementing the SDK using Kotlin."]]