use std::borrow::Cow; #[derive(Clone, Debug)] pub struct Tag(pub String); #[derive(Debug)] #[non_exhaustive] pub enum Response<'a> { Done(ResponseDone<'a>), } #[derive(Debug)] pub struct ResponseDone<'a> { pub tag: Tag, pub status: Status, pub code: Option>, pub info: Option>, } #[derive(Debug)] pub struct Condition<'a> { pub status: Status, pub code: Option>, pub text: String, } #[derive(Debug)] pub enum Status { Ok, No, Bad, PreAuth, Bye, } #[derive(Debug)] #[non_exhaustive] pub enum ResponseCode<'a> { Alert, Capabilities(Vec>), } #[derive(Debug)] pub enum Capability<'a> { Imap4rev1, Auth(Cow<'a, [u8]>), Atom(Cow<'a, [u8]>), }