Struct ngrok::config::TcpTunnelBuilder
source · pub struct TcpTunnelBuilder { /* private fields */ }
Expand description
A builder for a tunnel backing a TCP endpoint.
Implementations§
source§impl TcpTunnelBuilder
impl TcpTunnelBuilder
The options for a TCP edge.
sourcepub fn allow_cidr(self, cidr: impl Into<String>) -> Self
pub fn allow_cidr(self, cidr: impl Into<String>) -> Self
Add the provided CIDR to the allowlist.
sourcepub fn proxy_proto(self, proxy_proto: ProxyProto) -> Self
pub fn proxy_proto(self, proxy_proto: ProxyProto) -> Self
Sets the PROXY protocol version for connections over this tunnel.
sourcepub fn metadata(self, metadata: impl Into<String>) -> Self
pub fn metadata(self, metadata: impl Into<String>) -> Self
Sets the opaque metadata string for this tunnel.
sourcepub fn forwards_to(self, forwards_to: impl Into<String>) -> Self
pub fn forwards_to(self, forwards_to: impl Into<String>) -> Self
Sets the ForwardsTo string for this tunnel. This can be viewed via the API or dashboard.
sourcepub fn remote_addr(self, remote_addr: impl Into<String>) -> Self
pub fn remote_addr(self, remote_addr: impl Into<String>) -> Self
Sets the TCP address to request for this edge.
Trait Implementations§
source§impl Clone for TcpTunnelBuilder
impl Clone for TcpTunnelBuilder
source§fn clone(&self) -> TcpTunnelBuilder
fn clone(&self) -> TcpTunnelBuilder
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl From<Session> for TcpTunnelBuilder
impl From<Session> for TcpTunnelBuilder
source§impl TunnelBuilder for TcpTunnelBuilder
impl TunnelBuilder for TcpTunnelBuilder
Auto Trait Implementations§
impl !RefUnwindSafe for TcpTunnelBuilder
impl Send for TcpTunnelBuilder
impl Sync for TcpTunnelBuilder
impl Unpin for TcpTunnelBuilder
impl !UnwindSafe for TcpTunnelBuilder
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more