MCPcopy Create free account
hub / github.com/bjoernQ/bleps / AttData

Interface AttData

bleps/src/attribute.rs:8–28  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

6};
7
8pub trait AttData {
9 fn readable(&self) -> bool {
10 false
11 }
12
13 fn read(&mut self, _offset: usize, _data: &mut [u8]) -> Result<usize, AttErrorCode> {
14 Ok(0)
15 }
16
17 fn writable(&self) -> bool {
18 false
19 }
20
21 fn write(&mut self, _offset: usize, _data: &[u8]) -> Result<(), AttErrorCode> {
22 Ok(())
23 }
24
25 fn enable_notification(&mut self, _enabled: bool) -> Result<(), AttErrorCode> {
26 Ok(())
27 }
28}
29
30impl<'a, const N: usize> AttData for &'a [u8; N] {
31 fn readable(&self) -> bool {

Callers

nothing calls this directly

Implementers 1

attribute.rsbleps/src/attribute.rs

Calls

no outgoing calls

Tested by

no test coverage detected