[−][src]Struct wishbone_bridge::EthernetBridge
A builder to create a connection to a target via Ethernet, either using
TCP or UDP. The EthernetBridge
struct also describes
connections to proxy servers that relay Wishbone packets
over Ethernet, such as remote USB-to-Ethernet bridges.
use wishbone_bridge::EthernetBridge; let bridge = EthernetBridge::new("192.168.50.100:1234").unwrap().create().unwrap();
Implementations
impl EthernetBridge
[src]
Describes all configuration parameters required to connect to a
Wishbone bridge via Ethernet. The protocol defaults to UDP
, which
is what most embedded hardware uses. Set the protocol to TCP by using .protocol()
.
pub fn new<A: ToSocketAddrs>(addr: A) -> Result<EthernetBridge, BridgeError>
[src]
pub fn port(&mut self, new_port: u16) -> &mut EthernetBridge
[src]
Set the remote port for the target device.
pub fn protocol(&mut self, prot: EthernetBridgeProtocol) -> &mut EthernetBridge
[src]
Set the protocol to be used to connect to the remote device.
pub fn create(&self) -> Result<Bridge, BridgeError>
[src]
Create a new Bridge
based on the current configuration.
Trait Implementations
impl Clone for EthernetBridge
[src]
fn clone(&self) -> EthernetBridge
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Auto Trait Implementations
impl RefUnwindSafe for EthernetBridge
impl Send for EthernetBridge
impl Sync for EthernetBridge
impl Unpin for EthernetBridge
impl UnwindSafe for EthernetBridge
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,