pub struct FipsEndpointBuilder { /* private fields */ }Expand description
Builder for an embedded FIPS endpoint.
Implementations§
Source§impl FipsEndpointBuilder
impl FipsEndpointBuilder
Sourcepub fn identity_nsec(self, nsec: impl Into<String>) -> Self
pub fn identity_nsec(self, nsec: impl Into<String>) -> Self
Use an nsec or hex secret for the endpoint identity.
Sourcepub fn discovery_scope(self, scope: impl Into<String>) -> Self
pub fn discovery_scope(self, scope: impl Into<String>) -> Self
Set an application-level discovery scope.
When the builder owns the default empty connectivity config, this also enables scoped Nostr discovery, open same-scope peer discovery, local LAN candidates, and a UDP NAT advert. If an explicit transport or Nostr config was supplied, the explicit config is left in control and the scope is retained as endpoint metadata.
Sourcepub fn without_system_tun(self) -> Self
pub fn without_system_tun(self) -> Self
Disable FIPS-owned TUN and DNS system integration.
Sourcepub fn packet_channel_capacity(self, capacity: usize) -> Self
pub fn packet_channel_capacity(self, capacity: usize) -> Self
Set the app packet/data channel capacity.
Sourcepub async fn bind(self) -> Result<FipsEndpoint, FipsEndpointError>
pub async fn bind(self) -> Result<FipsEndpoint, FipsEndpointError>
Bind and start the embedded endpoint.
Trait Implementations§
Source§impl Clone for FipsEndpointBuilder
impl Clone for FipsEndpointBuilder
Source§fn clone(&self) -> FipsEndpointBuilder
fn clone(&self) -> FipsEndpointBuilder
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FipsEndpointBuilder
impl Debug for FipsEndpointBuilder
Auto Trait Implementations§
impl Freeze for FipsEndpointBuilder
impl RefUnwindSafe for FipsEndpointBuilder
impl Send for FipsEndpointBuilder
impl Sync for FipsEndpointBuilder
impl Unpin for FipsEndpointBuilder
impl UnsafeUnpin for FipsEndpointBuilder
impl UnwindSafe for FipsEndpointBuilder
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more