aboutsummaryrefslogtreecommitdiffstats
path: root/components/net_traits
diff options
context:
space:
mode:
Diffstat (limited to 'components/net_traits')
-rw-r--r--components/net_traits/bluetooth_thread.rs12
1 files changed, 11 insertions, 1 deletions
diff --git a/components/net_traits/bluetooth_thread.rs b/components/net_traits/bluetooth_thread.rs
index caeadabd6d4..48f64ff7474 100644
--- a/components/net_traits/bluetooth_thread.rs
+++ b/components/net_traits/bluetooth_thread.rs
@@ -1,10 +1,20 @@
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
+
use bluetooth_scanfilter::RequestDeviceoptions;
use ipc_channel::ipc::IpcSender;
#[derive(Deserialize, Serialize)]
+pub enum BluetoothError {
+ Type(String),
+ Network,
+ NotFound,
+ NotSupported,
+ Security,
+}
+
+#[derive(Deserialize, Serialize)]
pub struct BluetoothDeviceMsg {
// Bluetooth Device properties
pub id: String,
@@ -51,7 +61,7 @@ pub type BluetoothCharacteristicsMsg = Vec<BluetoothCharacteristicMsg>;
pub type BluetoothDescriptorsMsg = Vec<BluetoothDescriptorMsg>;
-pub type BluetoothResult<T> = Result<T, String>;
+pub type BluetoothResult<T> = Result<T, BluetoothError>;
#[derive(Deserialize, Serialize)]
pub enum BluetoothMethodMsg {