Browse Source

LoopbackInterface → Loopback.

whitequark 7 years ago
parent
commit
9a4efcd656
2 changed files with 6 additions and 6 deletions
  1. 5 5
      src/phy/loopback.rs
  2. 1 1
      src/phy/mod.rs

+ 5 - 5
src/phy/loopback.rs

@@ -16,19 +16,19 @@ use super::Device;
 
 /// A loopback interface.
 #[derive(Debug)]
-pub struct LoopbackInterface(Rc<RefCell<VecDeque<Vec<u8>>>>);
+pub struct Loopback(Rc<RefCell<VecDeque<Vec<u8>>>>);
 
-impl LoopbackInterface {
+impl Loopback {
     /// Creates a loopback interface.
     ///
     /// Every packet transmitted through this interface will be received through it
     /// in FIFO order.
-    pub fn new() -> LoopbackInterface {
-        LoopbackInterface(Rc::new(RefCell::new(VecDeque::new())))
+    pub fn new() -> Loopback {
+        Loopback(Rc::new(RefCell::new(VecDeque::new())))
     }
 }
 
-impl Device for LoopbackInterface {
+impl Device for Loopback {
     type RxBuffer = Vec<u8>;
     type TxBuffer = TxBuffer;
 

+ 1 - 1
src/phy/mod.rs

@@ -118,7 +118,7 @@ mod tap_interface;
 pub use self::tracer::Tracer;
 pub use self::fault_injector::FaultInjector;
 #[cfg(any(feature = "std", feature = "collections"))]
-pub use self::loopback::LoopbackInterface;
+pub use self::loopback::Loopback;
 #[cfg(any(feature = "raw_socket"))]
 pub use self::raw_socket::RawSocket;
 #[cfg(all(feature = "tap_interface", target_os = "linux"))]