mirror of
https://github.com/tokio-rs/tokio.git
synced 2026-08-07 00:00:09 +02:00
Remove unused UdpSocketNew
This commit is contained in:
+1
-1
@@ -8,4 +8,4 @@ mod udp;
|
||||
|
||||
pub use self::tcp::{TcpStream, TcpStreamNew};
|
||||
pub use self::tcp::{TcpListener, Incoming};
|
||||
pub use self::udp::{UdpSocket, UdpSocketNew};
|
||||
pub use self::udp::UdpSocket;
|
||||
|
||||
+1
-16
@@ -2,10 +2,9 @@ use std::io;
|
||||
use std::net::{self, SocketAddr, Ipv4Addr, Ipv6Addr};
|
||||
use std::fmt;
|
||||
|
||||
use futures::{Future, Poll, Async};
|
||||
use futures::Async;
|
||||
use mio;
|
||||
|
||||
use io::IoFuture;
|
||||
use reactor::{Handle, PollEvented};
|
||||
|
||||
/// An I/O object representing a UDP socket.
|
||||
@@ -13,11 +12,6 @@ pub struct UdpSocket {
|
||||
io: PollEvented<mio::udp::UdpSocket>,
|
||||
}
|
||||
|
||||
/// Future returned from `UdpSocket::bind` which will resolve to a `UdpSocket`.
|
||||
pub struct UdpSocketNew {
|
||||
inner: IoFuture<UdpSocket>,
|
||||
}
|
||||
|
||||
impl UdpSocket {
|
||||
/// Create a new UDP socket bound to the specified address.
|
||||
///
|
||||
@@ -257,15 +251,6 @@ impl fmt::Debug for UdpSocket {
|
||||
}
|
||||
}
|
||||
|
||||
impl Future for UdpSocketNew {
|
||||
type Item = UdpSocket;
|
||||
type Error = io::Error;
|
||||
|
||||
fn poll(&mut self) -> Poll<UdpSocket, io::Error> {
|
||||
self.inner.poll()
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(unix)]
|
||||
mod sys {
|
||||
use std::os::unix::prelude::*;
|
||||
|
||||
Reference in New Issue
Block a user