tokio_xmpp/xmlstream/
xmpp.rs1use xso::{AsXml, FromXml};
8
9use xmpp_parsers::{component, sasl, sm, starttls, stream_error::ReceivedStreamError};
10
11use crate::Stanza;
12
13#[derive(FromXml, AsXml, Debug)]
15#[xml()]
16pub enum XmppStreamElement {
17 #[xml(transparent)]
19 Stanza(Stanza),
20
21 #[xml(transparent)]
23 Sasl(sasl::Nonza),
24
25 #[xml(transparent)]
27 Starttls(starttls::Nonza),
28
29 #[xml(transparent)]
31 ComponentHandshake(component::Handshake),
32
33 #[xml(transparent)]
35 StreamError(ReceivedStreamError),
36
37 #[xml(transparent)]
39 SM(sm::Nonza),
40}