Mulai 27 Maret 2025, sebaiknya gunakan android-latest-release
, bukan aosp-main
, untuk mem-build dan berkontribusi pada AOSP. Untuk mengetahui informasi selengkapnya, lihat Perubahan pada AOSP.
Tetap teratur dengan koleksi
Simpan dan kategorikan konten berdasarkan preferensi Anda.
Referensi Struct btgatt_interface_t
#include <
bt_gatt.h
>
Merepresentasikan antarmuka GATT Bluetooth standar.
Definisi di baris
40
file
bt_gatt.h
.
Menutup antarmuka
Definisi di baris
50
dari file
bt_gatt.h
.
Pointer ke metode antarmuka klien GATT.
Definisi di baris
53
dari file
bt_gatt.h
.
Melakukan inisialisasi antarmuka dan menyediakan rutinitas callback
Definisi di baris
47
dari file
bt_gatt.h
.
Pointer ke metode antarmuka server GATT.
Definisi di baris
56
dari file
bt_gatt.h
.
Tetapkan ke sizeof(btgatt_interface_t)
Definisi di baris
42
dari file
bt_gatt.h
.
Dokumentasi untuk struct ini dibuat dari file berikut:
-
hardware/libhardware/include/hardware/
bt_gatt.h
Konten dan contoh kode di halaman ini tunduk kepada lisensi yang dijelaskan dalam Lisensi Konten. Java dan OpenJDK adalah merek dagang atau merek dagang terdaftar dari Oracle dan/atau afiliasinya.
Terakhir diperbarui pada 2025-07-27 UTC.
[[["Mudah dipahami","easyToUnderstand","thumb-up"],["Memecahkan masalah saya","solvedMyProblem","thumb-up"],["Lainnya","otherUp","thumb-up"]],[["Informasi yang saya butuhkan tidak ada","missingTheInformationINeed","thumb-down"],["Terlalu rumit/langkahnya terlalu banyak","tooComplicatedTooManySteps","thumb-down"],["Sudah usang","outOfDate","thumb-down"],["Masalah terjemahan","translationIssue","thumb-down"],["Masalah kode / contoh","samplesCodeIssue","thumb-down"],["Lainnya","otherDown","thumb-down"]],["Terakhir diperbarui pada 2025-07-27 UTC."],[],[],null,["# Android Hardware Abstraction Layer: btgatt_interface_t Struct Reference\n\nbtgatt_interface_t Struct Reference\n===================================\n\n[Data Fields](#pub-attribs) \nbtgatt_interface_t Struct Reference \n\n`\n#include \u003c\n`[bt_gatt.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_gatt.h)`\n\u003e\n`\n\n|-------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| Data Fields ----------- ||\n| size_t | [size](/reference/hal/structbtgatt__interface__t#a854352f53b148adc24983a58a1866d66) |\n| ||\n| [bt_status_t](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bluetooth.h) (\\* | [init](/reference/hal/structbtgatt__interface__t#a15fca7a0f2a74810223a31f3e1b234b2) )(const [btgatt_callbacks_t](/reference/hal/structbtgatt__callbacks__t) \\*callbacks) |\n| ||\n| void(\\* | [cleanup](/reference/hal/structbtgatt__interface__t#a8e1ba7348775abcd3cd56ec6f718bea0) )(void) |\n| ||\n| const [btgatt_client_interface_t](/reference/hal/structbtgatt__client__interface__t) \\* | [client](/reference/hal/structbtgatt__interface__t#ad376dedbfa9df97ca8eaad22cb074cd7) |\n| ||\n| const [btgatt_server_interface_t](/reference/hal/structbtgatt__server__interface__t) \\* | [server](/reference/hal/structbtgatt__interface__t#a782f6b6e9804f4f5a802a9d74094a782) |\n| ||\n\n\nDetailed Description\n--------------------\n\n\nRepresents the standard Bluetooth GATT interface.\n\n\nDefinition at line\n[40](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_gatt.h)\nof file\n[bt_gatt.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_gatt.h)\n.\n\nField Documentation\n-------------------\n\n\n|------------------------|\n| void(\\* cleanup)(void) |\n\n\nCloses the interface\n\n\nDefinition at line\n[50](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_gatt.h)\nof file\n[bt_gatt.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_gatt.h)\n.\n\n|------------------------------------------------------------------------------------------------|\n| const [btgatt_client_interface_t](/reference/hal/structbtgatt__client__interface__t) \\* client |\n\n\nPointer to the GATT client interface methods.\n\n\nDefinition at line\n[53](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_gatt.h)\nof file\n[bt_gatt.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_gatt.h)\n.\n\n|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [bt_status_t](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bluetooth.h) (\\* init)(const [btgatt_callbacks_t](/reference/hal/structbtgatt__callbacks__t) \\*callbacks) |\n\n\nInitializes the interface and provides callback routines\n\n\nDefinition at line\n[47](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_gatt.h)\nof file\n[bt_gatt.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_gatt.h)\n.\n\n|------------------------------------------------------------------------------------------------|\n| const [btgatt_server_interface_t](/reference/hal/structbtgatt__server__interface__t) \\* server |\n\n\nPointer to the GATT server interface methods.\n\n\nDefinition at line\n[56](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_gatt.h)\nof file\n[bt_gatt.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_gatt.h)\n.\n\n|-------------|\n| size_t size |\n\n\nSet to sizeof(btgatt_interface_t)\n\n\nDefinition at line\n[42](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_gatt.h)\nof file\n[bt_gatt.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_gatt.h)\n.\n\n*** ** * ** ***\n\nThe documentation for this struct was generated from the following file:\n\n- hardware/libhardware/include/hardware/ [bt_gatt.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_gatt.h)"]]