diff --git a/Cargo.toml b/Cargo.toml index e43d5d28c380ea9d4163a3b6b2fa7875834d44a7..c397ed40be7620798b5c561757d37cd9dce2bf37 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -18,15 +18,12 @@ tokio-io = "0.1" tokio-codec = "0.1" bytes = "0.4" xml5ever = "0.12" -minidom = "0.9" native-tls = "0.2" tokio-tls = "0.2" sasl = "0.4" -jid = { version = "0.5", features = ["minidom"] } trust-dns-resolver = "0.9.1" trust-dns-proto = "0.4.0" -xmpp-parsers = "0.11" +xmpp-parsers = "0.12.2" idna = "0.1" -try_from = "0.2" -quick-xml = "0.12" +quick-xml = "0.13" derive-error = "0.0.4" diff --git a/examples/echo_bot.rs b/examples/echo_bot.rs index 80ffc97fcc142e4e035d3488abb05379a1c53008..24b101079d76d0800a4d46f73262d50eea99a594 100644 --- a/examples/echo_bot.rs +++ b/examples/echo_bot.rs @@ -1,11 +1,9 @@ use futures::{future, Sink, Stream}; -use jid::Jid; -use minidom::Element; use std::env::args; use std::process::exit; use tokio::runtime::current_thread::Runtime; use tokio_xmpp::Client; -use try_from::TryFrom; +use xmpp_parsers::{Jid, Element, TryFrom}; use xmpp_parsers::message::{Body, Message, MessageType}; use xmpp_parsers::presence::{Presence, Show as PresenceShow, Type as PresenceType}; diff --git a/examples/echo_component.rs b/examples/echo_component.rs index 348b06a4d2d812303943b996e514a966b945f610..618032e324a422621c168df9e9a986f5f6fa282e 100644 --- a/examples/echo_component.rs +++ b/examples/echo_component.rs @@ -1,12 +1,10 @@ use futures::{future, Sink, Stream}; -use jid::Jid; -use minidom::Element; use std::env::args; use std::process::exit; use std::str::FromStr; use tokio::runtime::current_thread::Runtime; use tokio_xmpp::Component; -use try_from::TryFrom; +use xmpp_parsers::{Jid, Element, TryFrom}; use xmpp_parsers::message::{Body, Message, MessageType}; use xmpp_parsers::presence::{Presence, Show as PresenceShow, Type as PresenceType}; diff --git a/src/client/auth.rs b/src/client/auth.rs index 588b1a73e14c757c356244f8884a6efe1680bc3c..d961f7a0988b1b26ef11b99038e8bebab312d499 100644 --- a/src/client/auth.rs +++ b/src/client/auth.rs @@ -6,7 +6,7 @@ use sasl::client::Mechanism; use sasl::common::scram::{Sha1, Sha256}; use sasl::common::Credentials; use tokio_io::{AsyncRead, AsyncWrite}; -use try_from::TryFrom; +use xmpp_parsers::TryFrom; use xmpp_parsers::sasl::{Auth, Challenge, Failure, Mechanism as XMPPMechanism, Response, Success}; use crate::xmpp_codec::Packet; diff --git a/src/client/bind.rs b/src/client/bind.rs index 3758a563708083650694d4419f14bd186ba3d15d..083650b9b94196fac4a797534f0083dc51222129 100644 --- a/src/client/bind.rs +++ b/src/client/bind.rs @@ -1,7 +1,7 @@ use futures::{sink, Async, Future, Poll, Stream}; use std::mem::replace; use tokio_io::{AsyncRead, AsyncWrite}; -use try_from::TryFrom; +use xmpp_parsers::TryFrom; use xmpp_parsers::bind::Bind; use xmpp_parsers::iq::{Iq, IqType}; diff --git a/src/client/mod.rs b/src/client/mod.rs index 146d51a40fdd57a23775dcf8b4775f2334605eab..acc60441223ba248a620b696cb8a9a8c98acb326 100644 --- a/src/client/mod.rs +++ b/src/client/mod.rs @@ -1,7 +1,6 @@ use futures::{done, Async, AsyncSink, Future, Poll, Sink, StartSend, Stream}; use idna; -use jid::{Jid, JidParseError}; -use minidom::Element; +use xmpp_parsers::{Jid, JidParseError, Element}; use sasl::common::{ChannelBinding, Credentials}; use std::mem::replace; use std::str::FromStr; diff --git a/src/component/mod.rs b/src/component/mod.rs index aac66ab4e5e64e40eac3a5233b9cf7cc4831bf0e..cfc1ee5e2452504a6a39daa06fa26b3e0a61db5f 100644 --- a/src/component/mod.rs +++ b/src/component/mod.rs @@ -2,8 +2,7 @@ //! XMPP server under a JID consisting of just a domain name. They are //! allowed to use any user and resource identifiers in their stanzas. use futures::{done, Async, AsyncSink, Future, Poll, Sink, StartSend, Stream}; -use jid::{Jid, JidParseError}; -use minidom::Element; +use xmpp_parsers::{Jid, JidParseError, Element}; use std::mem::replace; use std::str::FromStr; use tokio::net::TcpStream; diff --git a/src/error.rs b/src/error.rs index e7fad549fbda79e50f73884b7c7b2cee3ca4b397..9697f2681b860b1416cc16da6e60cd29e436a5f3 100644 --- a/src/error.rs +++ b/src/error.rs @@ -7,7 +7,7 @@ use std::str::Utf8Error; use trust_dns_proto::error::ProtoError; use trust_dns_resolver::error::ResolveError; -use xmpp_parsers::error::Error as ParsersError; +use xmpp_parsers::Error as ParsersError; use xmpp_parsers::sasl::DefinedCondition as SaslDefinedCondition; /// Top-level error type diff --git a/src/event.rs b/src/event.rs index 7a225ba352d9f3015aaa9d78b8b7b1d3b0beff31..94dd36c2b7f298642a6e33671d1fbf2f138dd7f2 100644 --- a/src/event.rs +++ b/src/event.rs @@ -1,4 +1,4 @@ -use minidom::Element; +use xmpp_parsers::Element; /// High-level event on the Stream implemented by Client and Component #[derive(Debug)] diff --git a/src/starttls.rs b/src/starttls.rs index e48d1824a1220f98b70b015098cc9c93ec9a9b0a..00966ac1d491ba3d87d0b1b3bf0011d086e6a2ec 100644 --- a/src/starttls.rs +++ b/src/starttls.rs @@ -1,8 +1,7 @@ use futures::sink; use futures::stream::Stream; use futures::{Async, Future, Poll, Sink}; -use jid::Jid; -use minidom::Element; +use xmpp_parsers::{Jid, Element}; use native_tls::TlsConnector as NativeTlsConnector; use std::mem::replace; use tokio_io::{AsyncRead, AsyncWrite}; diff --git a/src/stream_start.rs b/src/stream_start.rs index 0a5945b7bda5e6d8dae908f23d20c59b3b5bb4e6..bf2d39e8b8968dc49474288be94a8c900f51beed 100644 --- a/src/stream_start.rs +++ b/src/stream_start.rs @@ -1,6 +1,5 @@ use futures::{sink, Async, Future, Poll, Sink, Stream}; -use jid::Jid; -use minidom::Element; +use xmpp_parsers::{Jid, Element}; use std::mem::replace; use tokio_codec::Framed; use tokio_io::{AsyncRead, AsyncWrite}; diff --git a/src/xmpp_codec.rs b/src/xmpp_codec.rs index 69ab5fc23c82b43370d0408a0bb86ce2c0632f11..54ddcb51a5908b8716c339e7b18c78d11bfe2747 100644 --- a/src/xmpp_codec.rs +++ b/src/xmpp_codec.rs @@ -2,7 +2,7 @@ use crate::{ParseError, ParserError}; use bytes::{BufMut, BytesMut}; -use minidom::Element; +use xmpp_parsers::Element; use quick_xml::Writer as EventWriter; use std; use std::cell::RefCell; diff --git a/src/xmpp_stream.rs b/src/xmpp_stream.rs index c67cc1efdd6ea8b53e84c784b2e88b4829fb6772..129dd1d4fe8825b06409cf52fac2f145f6678969 100644 --- a/src/xmpp_stream.rs +++ b/src/xmpp_stream.rs @@ -2,8 +2,7 @@ use futures::sink::Send; use futures::{Poll, Sink, StartSend, Stream}; -use jid::Jid; -use minidom::Element; +use xmpp_parsers::{Jid, Element}; use tokio_codec::Framed; use tokio_io::{AsyncRead, AsyncWrite};