usesuper::APIConnector;useparking_lot::RwLock;usestd::sync::Arc;usetypemap_rev::TypeMap;/// The context object is an utility object that gets passed to all event
/// handlers, it provides access to the API client and to any custom data you
/// have set in the data object.
#[derive(Clone)]pubstructContext{/// The API client, implementing the [`API`] trait
////// [`API`]: ../api/trait.API.html
pubapi:Arc<Box<APIConnector>>,
/// A clone of [`Client::data`], see its documentation for more detail
////// [`Client::data`]: struct.Client.html#structfield.data
pubdata:Arc<RwLock<TypeMap>>,
}implContext{pubfnnew(api:Arc<Box<APIConnector>>, data:Arc<RwLock<TypeMap>>)->Self{Self{
api,
data,}}}