error: add docstrings
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
This commit is contained in:
parent
bcc2f7d85e
commit
d94d472b9d
1 changed files with 7 additions and 0 deletions
|
@ -21,12 +21,19 @@ use xmpp_parsers::{Error as ParserError, FullJid, Jid};
|
||||||
|
|
||||||
#[derive(Debug)]
|
#[derive(Debug)]
|
||||||
pub enum Error {
|
pub enum Error {
|
||||||
|
/// Raised when editing an occupant with a non-matching session JID.
|
||||||
MismatchJids(Jid, Jid),
|
MismatchJids(Jid, Jid),
|
||||||
|
/// Raised when a new occupant tries to use a nickname already assigned in the room.
|
||||||
NickAlreadyAssigned(String),
|
NickAlreadyAssigned(String),
|
||||||
|
/// Raised when editing or fetching an occupant with a session that isn't associated with the
|
||||||
|
/// occupant.
|
||||||
NonexistantSession(FullJid),
|
NonexistantSession(FullJid),
|
||||||
SessionAlreadyExists(FullJid),
|
SessionAlreadyExists(FullJid),
|
||||||
|
/// Raised when fetching an occupant with a nickname that isn't assigned in the room.
|
||||||
ParticipantNotFound(String),
|
ParticipantNotFound(String),
|
||||||
|
/// TokioXMPP errors
|
||||||
Xmpp(Box<TokioXMPPError>),
|
Xmpp(Box<TokioXMPPError>),
|
||||||
|
/// Parser errors
|
||||||
Parser(Box<ParserError>),
|
Parser(Box<ParserError>),
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue