Trait ContainerPortExt

Source
pub trait ContainerPortExt: Sized {
    // Required methods
    fn new(port: i32, protocol: impl ToString) -> Self;
    fn name(self, name: impl ToString) -> Self;
    fn host_ip(self, ip: impl ToString) -> Self;
    fn host_port(self, port: i32) -> Self;

    // Provided methods
    fn tcp(port: i32) -> Self { ... }
    fn udp(port: i32) -> Self { ... }
    fn sctp(port: i32) -> Self { ... }
}

Required Methods§

Source

fn new(port: i32, protocol: impl ToString) -> Self

Source

fn name(self, name: impl ToString) -> Self

Source

fn host_ip(self, ip: impl ToString) -> Self

Source

fn host_port(self, port: i32) -> Self

Provided Methods§

Source

fn tcp(port: i32) -> Self

Source

fn udp(port: i32) -> Self

Source

fn sctp(port: i32) -> Self

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§