9 Commits
Author SHA1 Message Date
Francis Tsui dacbd03aa1 Replace ByteArray with std::string.
PiperOrigin-RevId: 900893850
2026-04-16 13:52:02 -07:00
Francis Tsui ee1a46c3da Fix code style.
PiperOrigin-RevId: 831606257
2025-11-12 17:37:55 -08:00
Janusz Sobczak 8ccb9fcfec Replace std::function with AnyInvocable
PiperOrigin-RevId: 556090653
2023-08-11 14:27:08 -07:00
Suet-Fei Li 084f7ebd88 Remove location namespace in third_party/nearby.
PiperOrigin-RevId: 500023196
2023-01-06 02:53:57 -08:00
hai007 e4a0f280e2 BWU Hotspot Responder(client) need to disconnect Hotspot when the session is done
PiperOrigin-RevId: 460577462
2022-07-12 16:23:48 -07:00
nohle 98a5b9d0ee [Nearby Connections][C++] Track bandwidth upgrade mediums for each endpoint (4/4 unit tests)
Add unit tests for BaseBwuHandler and BwuManager (BWU initiation only). Add fake classes and helper methods needed for testing. Refine comments and logs.

PiperOrigin-RevId: 442021842
2022-04-15 08:33:21 -07:00
nohle e5fb3a8f11 [Nearby Connections][C++] Track bandwidth upgrade mediums for each endpoint (3/4)
* Fix bandwidth upgrade service ID usage. For instance, no longer use the inaccurate service ID from ClientProxy.
* Add more fine-grained upgraded endpoint tracking using both service IDs and endpoint IDs
* Only "revert" bandwidth-upgrade mediums--for example, stop accepting connections on a server socket--for a service when the last endpoint for that service is finished.

These changes are necessary to support multiple services (e.g., Nearby Share and Phone Hub) and multiple mediums (e.g., WebRTC and WLAN).

PiperOrigin-RevId: 442021257
2022-04-15 08:29:41 -07:00
nohle dee3e9cfb4 [Nearby Connections][C++] Track bandwidth upgrade mediums for each endpoint (2/4)
Consolidate BWU service ID bookkeeping into the BaseBwuHandler class. This eliminates duplicated code in per-medium BWU handlers and allows us to easily augment the bookkeeping with endpoint IDs in a subsequent CL.

Also, localize all service ID wrapping to the BaseBwuHandler class. A postfix is appended to the service ID during bandwidth upgrade, e.g., "NearbyShare_INITIATOR_BWU"; this is done to distinguish a medium's use for advertising/discovery vs. its use for device-to-device connections.

This CL should theoretically be a no-op, but per-medium BWU handlers were inconsistent in their implementations.

PiperOrigin-RevId: 442019603
2022-04-15 08:19:19 -07:00
hais f5fcd35ced nearby sdk refactor
PiperOrigin-RevId: 425434260
2022-02-02 11:56:39 -08:00