mirror of
https://gitlab.com/xmpp-rs/xmpp-rs.git
synced 2024-07-12 22:21:53 +00:00
Move to edition 2018.
This commit is contained in:
parent
7ba1b5604f
commit
24b2ff1851
10 changed files with 26 additions and 25 deletions
|
@ -9,6 +9,7 @@ repository = "https://github.com/astro/tokio-xmpp"
|
|||
documentation = "https://docs.rs/tokio-xmpp"
|
||||
categories = ["asynchronous", "network-programming"]
|
||||
keywords = ["xmpp", "tokio"]
|
||||
edition = "2018"
|
||||
|
||||
[dependencies]
|
||||
futures = "0.1"
|
||||
|
|
|
@ -10,10 +10,10 @@ use minidom::Element;
|
|||
use xmpp_parsers::sasl::{Auth, Challenge, Response, Success, Failure, Mechanism as XMPPMechanism};
|
||||
use try_from::TryFrom;
|
||||
|
||||
use xmpp_codec::Packet;
|
||||
use xmpp_stream::XMPPStream;
|
||||
use stream_start::StreamStart;
|
||||
use {Error, AuthError, ProtocolError};
|
||||
use crate::xmpp_codec::Packet;
|
||||
use crate::xmpp_stream::XMPPStream;
|
||||
use crate::stream_start::StreamStart;
|
||||
use crate::{Error, AuthError, ProtocolError};
|
||||
|
||||
const NS_XMPP_SASL: &str = "urn:ietf:params:xml:ns:xmpp-sasl";
|
||||
|
||||
|
|
|
@ -5,9 +5,9 @@ use xmpp_parsers::iq::{Iq, IqType};
|
|||
use xmpp_parsers::bind::Bind;
|
||||
use try_from::TryFrom;
|
||||
|
||||
use xmpp_codec::Packet;
|
||||
use xmpp_stream::XMPPStream;
|
||||
use {Error, ProtocolError};
|
||||
use crate::xmpp_codec::Packet;
|
||||
use crate::xmpp_stream::XMPPStream;
|
||||
use crate::{Error, ProtocolError};
|
||||
|
||||
const NS_XMPP_BIND: &str = "urn:ietf:params:xml:ns:xmpp-bind";
|
||||
const BIND_REQ_ID: &str = "resource-bind";
|
||||
|
|
|
@ -3,9 +3,9 @@ use futures::{Future, Poll, Async, sink, Stream};
|
|||
use tokio_io::{AsyncRead, AsyncWrite};
|
||||
use xmpp_parsers::component::Handshake;
|
||||
|
||||
use xmpp_codec::Packet;
|
||||
use xmpp_stream::XMPPStream;
|
||||
use {Error, AuthError};
|
||||
use crate::xmpp_codec::Packet;
|
||||
use crate::xmpp_stream::XMPPStream;
|
||||
use crate::{Error, AuthError};
|
||||
|
||||
const NS_JABBER_COMPONENT_ACCEPT: &str = "jabber:component:accept";
|
||||
|
||||
|
|
|
@ -12,7 +12,7 @@ use trust_dns_resolver::lookup::SrvLookupFuture;
|
|||
use trust_dns_resolver::lookup_ip::LookupIpFuture;
|
||||
use trust_dns_resolver::system_conf;
|
||||
use trust_dns_resolver::config::LookupIpStrategy;
|
||||
use {Error, ConnecterError};
|
||||
use crate::{Error, ConnecterError};
|
||||
|
||||
enum State {
|
||||
AwaitResolver(Box<Future<Item = ResolverFuture, Error = ResolveError> + Send>),
|
||||
|
|
10
src/lib.rs
10
src/lib.rs
|
@ -26,13 +26,13 @@ pub mod xmpp_codec;
|
|||
pub mod xmpp_stream;
|
||||
mod stream_start;
|
||||
mod starttls;
|
||||
pub use starttls::StartTlsClient;
|
||||
pub use crate::starttls::StartTlsClient;
|
||||
mod happy_eyeballs;
|
||||
mod event;
|
||||
pub use event::Event;
|
||||
pub use crate::event::Event;
|
||||
mod client;
|
||||
pub use client::Client;
|
||||
pub use crate::client::Client;
|
||||
mod component;
|
||||
pub use component::Component;
|
||||
pub use crate::component::Component;
|
||||
mod error;
|
||||
pub use error::{Error, ProtocolError, AuthError, ConnecterError, ParseError, ParserError};
|
||||
pub use crate::error::{Error, ProtocolError, AuthError, ConnecterError, ParseError, ParserError};
|
||||
|
|
|
@ -8,9 +8,9 @@ use native_tls::TlsConnector as NativeTlsConnector;
|
|||
use minidom::Element;
|
||||
use jid::Jid;
|
||||
|
||||
use xmpp_codec::Packet;
|
||||
use xmpp_stream::XMPPStream;
|
||||
use Error;
|
||||
use crate::xmpp_codec::Packet;
|
||||
use crate::xmpp_stream::XMPPStream;
|
||||
use crate::Error;
|
||||
|
||||
/// XMPP TLS XML namespace
|
||||
pub const NS_XMPP_TLS: &str = "urn:ietf:params:xml:ns:xmpp-tls";
|
||||
|
|
|
@ -5,9 +5,9 @@ use tokio_codec::Framed;
|
|||
use jid::Jid;
|
||||
use minidom::Element;
|
||||
|
||||
use xmpp_codec::{XMPPCodec, Packet};
|
||||
use xmpp_stream::XMPPStream;
|
||||
use {Error, ProtocolError};
|
||||
use crate::xmpp_codec::{XMPPCodec, Packet};
|
||||
use crate::xmpp_stream::XMPPStream;
|
||||
use crate::{Error, ProtocolError};
|
||||
|
||||
const NS_XMPP_STREAM: &str = "http://etherx.jabber.org/streams";
|
||||
|
||||
|
|
|
@ -16,7 +16,7 @@ use xml5ever::tokenizer::{XmlTokenizer, TokenSink, Token, Tag, TagKind};
|
|||
use xml5ever::interface::Attribute;
|
||||
use bytes::{BytesMut, BufMut};
|
||||
use quick_xml::Writer as EventWriter;
|
||||
use {ParserError, ParseError};
|
||||
use crate::{ParserError, ParseError};
|
||||
|
||||
/// Anything that can be sent or received on an XMPP/XML stream
|
||||
#[derive(Debug)]
|
||||
|
|
|
@ -7,8 +7,8 @@ use tokio_codec::Framed;
|
|||
use minidom::Element;
|
||||
use jid::Jid;
|
||||
|
||||
use xmpp_codec::{XMPPCodec, Packet};
|
||||
use stream_start::StreamStart;
|
||||
use crate::xmpp_codec::{XMPPCodec, Packet};
|
||||
use crate::stream_start::StreamStart;
|
||||
|
||||
/// <stream:stream> namespace
|
||||
pub const NS_XMPP_STREAM: &str = "http://etherx.jabber.org/streams";
|
||||
|
|
Loading…
Reference in a new issue