simple-aprs 0.3.2

APRS Library to interact with APRS-IS servers
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
use tokio::task::JoinHandle;

pub(crate) struct AbortOnDrop<T> {
    handle: JoinHandle<T>,
}

impl<T> AbortOnDrop<T> {
    pub fn new(handle: JoinHandle<T>) -> Self {
        Self { handle }
    }
}

impl<T> Drop for AbortOnDrop<T> {
    fn drop(&mut self) {
        self.handle.abort();
    }
}