pub struct AmiConnection { /* private fields */ }Implementations§
Source§impl AmiConnection
impl AmiConnection
Sourcepub async fn connect<A: ToSocketAddrs + Debug>(
server: A,
) -> Result<AmiConnection, Error>
pub async fn connect<A: ToSocketAddrs + Debug>( server: A, ) -> Result<AmiConnection, Error>
Establishes a connection to an asterisk server
§Arguments
server- address of the asterisk server’s AMI interface, e.g127.0.0.1:5038
pub fn events(&self) -> Receiver<Option<Packet>>
Auto Trait Implementations§
impl Freeze for AmiConnection
impl !RefUnwindSafe for AmiConnection
impl Send for AmiConnection
impl Sync for AmiConnection
impl Unpin for AmiConnection
impl !UnwindSafe for AmiConnection
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more