feat(ble): AndroidBleBridge::channel_open — let next_send tell closed from timeout

This commit is contained in:
Arjen
2026-07-14 13:53:57 +02:00
parent 1611282047
commit 9e59659073
+6
View File
@@ -280,6 +280,12 @@ impl AndroidBleBridge {
drop(state);
}
}
/// Whether `ch_id` is still registered. The JNI `next_send` export uses this
/// to tell a timeout (loop again) from a closed channel (stop the writer).
pub fn channel_open(&self, ch_id: i64) -> bool {
self.lock_channels().contains_key(&ch_id)
}
}
// ============================================================================