Od 27 marca 2025 r. zalecamy używanie android-latest-release
zamiast aosp-main
do kompilowania i wspołtworzenia AOSP. Więcej informacji znajdziesz w artykule o zmianach w AOSP.
Zadbaj o dobrą organizację dzięki kolekcji
Zapisuj i kategoryzuj treści zgodnie ze swoimi preferencjami.
Struktura btsdp_interface_t
#include <
bt_sdp.h
>
Definicja w wierszu
120
pliku
bt_sdp.h
.
Użyj funkcji listen w interfejsie socketa, aby utworzyć kanały rfcomm lub l2cap PSM (bez UUID i service_name oraz z flagą BTSOCK_FLAG_NO_SDP w flagach). Następnie użyj funkcji createSdpRecord, aby utworzyć rekord SDP powiązany z kanałami rfcomm/l2cap.
Zwraca uchwyt do rekordu SDP, który można przeanalizować w celu usunięcia rekordu SDP.
record (w) – rekord SDP do utworzenia; record_handle (w) – odpowiedni identyfikator rekordu zostanie zapisany w tym wskaźniku.
Definicja w wierszu
143
pliku
bt_sdp.h
.
Wyrejestruj SDP BT
Definicja w wierszu
128
pliku
bt_sdp.h
.
Rejestrowanie wywołań zwrotnych wyszukiwania BT SDP
Definicja w wierszu
125
pliku
bt_sdp.h
.
Usuwanie rekordu SDP utworzonego przez createSdpRecord
Definicja w wierszu
146
pliku
bt_sdp.h
.
bt_status_t
(* sdp_search)(bt_bdaddr_t *bd_addr, const uint8_t *uuid)
|
Wyszukiwanie rekordów SDP z określonym identyfikatorem UUID na urządzeniu zdalnym
Definicja w wierszu
131
pliku
bt_sdp.h
.
Ustaw rozmiar tej struktury.
Definicja w wierszu
122
pliku
bt_sdp.h
.
Dokumentacja tego typu danych została wygenerowana z tego pliku:
-
hardware/libhardware/include/hardware/
bt_sdp.h
Treść strony i umieszczone na niej fragmenty kodu podlegają licencjom opisanym w Licencji na treści. Java i OpenJDK są znakami towarowymi lub zastrzeżonymi znakami towarowymi należącymi do firmy Oracle lub jej podmiotów stowarzyszonych.
Ostatnia aktualizacja: 2025-07-27 UTC.
[[["Łatwo zrozumieć","easyToUnderstand","thumb-up"],["Rozwiązało to mój problem","solvedMyProblem","thumb-up"],["Inne","otherUp","thumb-up"]],[["Brak potrzebnych mi informacji","missingTheInformationINeed","thumb-down"],["Zbyt skomplikowane / zbyt wiele czynności do wykonania","tooComplicatedTooManySteps","thumb-down"],["Nieaktualne treści","outOfDate","thumb-down"],["Problem z tłumaczeniem","translationIssue","thumb-down"],["Problem z przykładami/kodem","samplesCodeIssue","thumb-down"],["Inne","otherDown","thumb-down"]],["Ostatnia aktualizacja: 2025-07-27 UTC."],[],[],null,["# Android Hardware Abstraction Layer: btsdp_interface_t Struct Reference\n\nbtsdp_interface_t Struct Reference\n==================================\n\n[Data Fields](#pub-attribs) \nbtsdp_interface_t Struct Reference \n\n`\n#include \u003c\n`[bt_sdp.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sdp.h)`\n\u003e\n`\n\n|-------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| Data Fields ----------- ||\n| size_t | [size](/reference/hal/structbtsdp__interface__t#a854352f53b148adc24983a58a1866d66) |\n| ||\n| [bt_status_t](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bluetooth.h) (\\* | [init](/reference/hal/structbtsdp__interface__t#a1fc7441984c7bf89fc8bb4719b943db4) )( [btsdp_callbacks_t](/reference/hal/structbtsdp__callbacks__t) \\*callbacks) |\n| ||\n| [bt_status_t](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bluetooth.h) (\\* | [deinit](/reference/hal/structbtsdp__interface__t#a6d26449b7562197ad32b98495759085e) )() |\n| ||\n| [bt_status_t](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bluetooth.h) (\\* | [sdp_search](/reference/hal/structbtsdp__interface__t#a58527da515be3086e14b10e1c5f13f7b) )(bt_bdaddr_t \\*bd_addr, const uint8_t \\*uuid) |\n| ||\n| [bt_status_t](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bluetooth.h) (\\* | [create_sdp_record](/reference/hal/structbtsdp__interface__t#a73db7398c35a3aa6fed7a67284f496d0) )( [bluetooth_sdp_record](/reference/hal/unionbluetooth__sdp__record) \\*record, int \\*record_handle) |\n| ||\n| [bt_status_t](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bluetooth.h) (\\* | [remove_sdp_record](/reference/hal/structbtsdp__interface__t#a5edc4376964673ce7817eb7143bc9d0f) )(int sdp_handle) |\n| ||\n\n\nDetailed Description\n--------------------\n\n\nDefinition at line\n[120](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sdp.h)\nof file\n[bt_sdp.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sdp.h)\n.\n\nField Documentation\n-------------------\n\n\n|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [bt_status_t](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bluetooth.h) (\\* create_sdp_record)( [bluetooth_sdp_record](/reference/hal/unionbluetooth__sdp__record) \\*record, int \\*record_handle) |\n\n\nUse listen in the socket interface to create rfcomm and/or l2cap PSM channels, (without UUID and service_name and set the BTSOCK_FLAG_NO_SDP flag in flags). Then use createSdpRecord to create the SDP record associated with the rfcomm/l2cap channels.\n\n\nReturns a handle to the SDP record, which can be parsed to remove_sdp_record.\n\n\nrecord (in) The SDP record to create record_handle (out)The corresponding record handle will be written to this pointer.\n\n\nDefinition at line\n[143](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sdp.h)\nof file\n[bt_sdp.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sdp.h)\n.\n\n|-----------------------------------------------------------------------------------------------------------------------------------|\n| [bt_status_t](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bluetooth.h) (\\* deinit)() |\n\n\nUnregister BT SDP\n\n\nDefinition at line\n[128](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sdp.h)\nof file\n[bt_sdp.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sdp.h)\n.\n\n|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [bt_status_t](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bluetooth.h) (\\* init)( [btsdp_callbacks_t](/reference/hal/structbtsdp__callbacks__t) \\*callbacks) |\n\n\nRegister BT SDP search callbacks\n\n\nDefinition at line\n[125](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sdp.h)\nof file\n[bt_sdp.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sdp.h)\n.\n\n|------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [bt_status_t](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bluetooth.h) (\\* remove_sdp_record)(int sdp_handle) |\n\n\nRemove a SDP record created by createSdpRecord\n\n\nDefinition at line\n[146](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sdp.h)\nof file\n[bt_sdp.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sdp.h)\n.\n\n|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [bt_status_t](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bluetooth.h) (\\* sdp_search)(bt_bdaddr_t \\*bd_addr, const uint8_t \\*uuid) |\n\n\nSearch for SDP records with specific uuid on remote device\n\n\nDefinition at line\n[131](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sdp.h)\nof file\n[bt_sdp.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sdp.h)\n.\n\n|-------------|\n| size_t size |\n\n\nSet to size of this struct\n\n\nDefinition at line\n[122](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sdp.h)\nof file\n[bt_sdp.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sdp.h)\n.\n\n*** ** * ** ***\n\nThe documentation for this struct was generated from the following file:\n\n- hardware/libhardware/include/hardware/ [bt_sdp.h](https://android.googlesource.com/platform/hardware/libhardware/+/master/include/hardware/bt_sdp.h)"]]