API tương tác
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.
Việc di chuyển dần ứng dụng của bạn sang Compose có nghĩa là Compose và Khung hiển thị sẽ cùng tồn tại trong ứng dụng đó.
Các trang sau đây mô tả những API cụ thể mà bạn cần sử dụng để tích hợp Compose trong ứng dụng hiện có dựa trên Khung hiển thị:
Đề xuất cho bạn
Nội dung và mã mẫu trên trang này phải tuân thủ các giấy phép như mô tả trong phần Giấy phép nội dung. Java và OpenJDK là nhãn hiệu hoặc nhãn hiệu đã đăng ký của Oracle và/hoặc đơn vị liên kết của Oracle.
Cập nhật lần gần đây nhất: 2025-08-27 UTC.
[[["Dễ hiểu","easyToUnderstand","thumb-up"],["Giúp tôi giải quyết được vấn đề","solvedMyProblem","thumb-up"],["Khác","otherUp","thumb-up"]],[["Thiếu thông tin tôi cần","missingTheInformationINeed","thumb-down"],["Quá phức tạp/quá nhiều bước","tooComplicatedTooManySteps","thumb-down"],["Đã lỗi thời","outOfDate","thumb-down"],["Vấn đề về bản dịch","translationIssue","thumb-down"],["Vấn đề về mẫu/mã","samplesCodeIssue","thumb-down"],["Khác","otherDown","thumb-down"]],["Cập nhật lần gần đây nhất: 2025-08-27 UTC."],[],[],null,["Incrementally migrating your app to Compose means that Compose and Views will\nco-exist in your app.\n\nThe following pages describe the specific APIs you need to use to integrate\nCompose within your existing View-based app:\n\n- [Using Compose in Views](/develop/ui/compose/migrate/interoperability-apis/compose-in-views): Learn about `ComposeView`---the API to use to add Compose in Views.\n- [Using Views in Compose](/develop/ui/compose/migrate/interoperability-apis/views-in-compose): Learn about `AndroidView` and `AndroidViewBinding`---APIs for using Views in Compose.\n\nRecommended for you\n\n- Note: link text is displayed when JavaScript is off\n- [Display emoji](/develop/ui/compose/text/emoji)\n- [Using Views in Compose](/develop/ui/compose/migrate/interoperability-apis/views-in-compose)\n- [Migrate `CoordinatorLayout` to Compose](/develop/ui/compose/migrate/migration-scenarios/coordinator-layout)"]]