Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit aba3e5a3 authored by Chris Manton's avatar Chris Manton
Browse files

Re-group and label interfaces main/shim/acl::

Towards readable code

Bug: 163134718
Tag: #refactor
Test: gd/cert/run --host

Change-Id: Ifd2d40b5104153171cf00de20000e4e64ae4e542
parent 9ddd7286
Loading
Loading
Loading
Loading
+13 −11
Original line number Diff line number Diff line
@@ -37,24 +37,26 @@ class Acl : public hci::acl_manager::ConnectionCallbacks,
  Acl(os::Handler* handler, const acl_interface_t& acl_interface);
  ~Acl();

  void CreateClassicConnection(const bluetooth::hci::Address& address);
  void CreateLeConnection(
      const bluetooth::hci::AddressWithType& address_with_type);
  void CancelLeConnection(
      const bluetooth::hci::AddressWithType& address_with_type);
  void DisconnectClassic(uint16_t handle, tHCI_STATUS reason);
  void DisconnectLe(uint16_t handle, tHCI_STATUS reason);
  // hci::acl_manager::ConnectionCallbacks
  void OnConnectSuccess(
      std::unique_ptr<hci::acl_manager::ClassicAclConnection>) override;
  void OnConnectFail(hci::Address, hci::ErrorCode reason) override;
  void OnClassicLinkDisconnected(uint16_t handle, hci::ErrorCode reason);

  // hci::acl_manager::LeConnectionCallbacks
  void OnLeConnectSuccess(
      hci::AddressWithType,
      std::unique_ptr<hci::acl_manager::LeAclConnection>) override;
  void OnLeConnectFail(hci::AddressWithType, hci::ErrorCode reason) override;
  void OnLeLinkDisconnected(uint16_t handle, hci::ErrorCode reason);

  void OnConnectSuccess(
      std::unique_ptr<hci::acl_manager::ClassicAclConnection>) override;
  void OnConnectFail(hci::Address, hci::ErrorCode reason) override;
  void OnClassicLinkDisconnected(uint16_t handle, hci::ErrorCode reason);
  void CreateClassicConnection(const bluetooth::hci::Address& address);
  void CreateLeConnection(
      const bluetooth::hci::AddressWithType& address_with_type);
  void CancelLeConnection(
      const bluetooth::hci::AddressWithType& address_with_type);
  void DisconnectClassic(uint16_t handle, tHCI_STATUS reason);
  void DisconnectLe(uint16_t handle, tHCI_STATUS reason);

  void WriteData(uint16_t hci_handle,
                 std::unique_ptr<bluetooth::packet::RawBuilder> packet);