From 91d570ac4fe5df510805eb7d4315bfbfdb166d33 Mon Sep 17 00:00:00 2001 From: dignifiedquire Date: Wed, 11 Dec 2024 15:03:08 +0000 Subject: [PATCH] deploy: cb20f0a53e7b6e769fd3134ae9e4b56a3c86fad1 --- .../discovery/dns/struct.DnsDiscovery.html | 2 +- pr/3024/docs/iroh/discovery/index.html | 2 +- .../pkarr/constant.DEFAULT_PKARR_TTL.html | 2 +- .../constant.DEFAULT_REPUBLISH_INTERVAL.html | 2 +- .../constant.N0_DNS_PKARR_RELAY_PROD.html | 2 +- .../constant.N0_DNS_PKARR_RELAY_STAGING.html | 2 +- .../pkarr/dht/struct.DhtDiscovery.html | 2 +- pr/3024/docs/iroh/discovery/pkarr/index.html | 2 +- .../pkarr/struct.PkarrPublisher.html | 14 +++--- .../pkarr/struct.PkarrRelayClient.html | 10 ++-- .../discovery/pkarr/struct.PkarrResolver.html | 10 ++-- .../struct.StaticProvider.html | 2 +- .../discovery/struct.ConcurrentDiscovery.html | 14 +++--- .../iroh/discovery/struct.DiscoveryItem.html | 4 +- .../docs/iroh/discovery/trait.Discovery.html | 10 ++-- .../constant.ENV_FORCE_STAGING_RELAYS.html | 2 +- .../iroh/endpoint/enum.DirectAddrType.html | 12 ++--- .../docs/iroh/endpoint/enum.RelayMode.html | 8 +-- .../iroh/endpoint/fn.default_relay_mode.html | 2 +- .../iroh/endpoint/fn.force_staging_infra.html | 2 +- .../iroh/endpoint/fn.get_remote_node_id.html | 2 +- .../iroh/endpoint/fn.make_server_config.html | 2 +- pr/3024/docs/iroh/endpoint/index.html | 4 +- pr/3024/docs/iroh/endpoint/struct.Accept.html | 32 ++++++------ .../docs/iroh/endpoint/struct.AcceptBi.html | 28 +++++------ .../docs/iroh/endpoint/struct.AcceptUni.html | 28 +++++------ .../docs/iroh/endpoint/struct.Builder.html | 42 ++++++++-------- pr/3024/docs/iroh/endpoint/struct.Bytes.html | 20 ++++---- .../docs/iroh/endpoint/struct.Connecting.html | 44 ++++++++-------- .../endpoint/struct.ConnectionTypeStream.html | 46 ++++++++--------- .../docs/iroh/endpoint/struct.DirectAddr.html | 12 ++--- .../endpoint/struct.DirectAddrsStream.html | 50 +++++++++---------- .../docs/iroh/endpoint/struct.Endpoint.html | 46 ++++++++--------- .../docs/iroh/endpoint/struct.Incoming.html | 20 ++++---- .../iroh/endpoint/struct.IncomingFuture.html | 34 ++++++------- pr/3024/docs/iroh/endpoint/struct.OpenBi.html | 28 +++++------ .../docs/iroh/endpoint/struct.OpenUni.html | 28 +++++------ .../iroh/endpoint/struct.ReadDatagram.html | 28 +++++------ .../docs/iroh/endpoint/struct.SendStream.html | 2 +- .../iroh/endpoint/struct.ServerConfig.html | 4 +- .../iroh/endpoint/struct.ZeroRttAccepted.html | 26 +++++----- pr/3024/docs/iroh/hash/index.html | 2 +- pr/3024/docs/iroh/hash/struct.Hash.html | 8 +-- .../docs/iroh/hash/struct.HashAndFormat.html | 18 +++---- pr/3024/docs/iroh/index.html | 4 +- pr/3024/docs/iroh/key/index.html | 2 +- pr/3024/docs/iroh/key/struct.Signature.html | 4 +- pr/3024/docs/iroh/metrics/index.html | 2 +- .../iroh/metrics/struct.MagicsockMetrics.html | 4 +- .../iroh/metrics/struct.NetReportMetrics.html | 4 +- .../iroh/metrics/struct.PortmapMetrics.html | 4 +- .../iroh/metrics/struct.RelayMetrics.html | 4 +- pr/3024/docs/iroh/struct.RelayUrl.html | 6 +-- .../test_utils/fn.create_dns_resolver.html | 2 +- .../iroh/test_utils/fn.run_relay_server.html | 2 +- .../test_utils/fn.run_relay_server_with.html | 2 +- .../fn.run_relay_server_with_stun.html | 2 +- pr/3024/docs/iroh/test_utils/index.html | 2 +- .../test_utils/struct.CleanupDropGuard.html | 2 +- .../test_utils/struct.DnsPkarrServer.html | 2 +- pr/3024/docs/iroh/ticket/enum.Error.html | 4 +- pr/3024/docs/iroh/ticket/index.html | 2 +- .../docs/iroh/ticket/struct.BlobTicket.html | 2 +- .../docs/iroh/ticket/struct.NodeTicket.html | 2 +- pr/3024/docs/iroh/ticket/trait.Ticket.html | 12 ++--- .../iroh_base/base32/struct.DecodeError.html | 2 +- pr/3024/docs/iroh_base/hash/index.html | 2 +- pr/3024/docs/iroh_base/hash/struct.Hash.html | 8 +-- .../iroh_base/hash/struct.HashAndFormat.html | 18 +++---- pr/3024/docs/iroh_base/index.html | 2 +- .../docs/iroh_base/key/struct.Signature.html | 4 +- pr/3024/docs/iroh_base/node_addr/index.html | 2 +- .../iroh_base/node_addr/struct.RelayUrl.html | 8 +-- pr/3024/docs/iroh_base/relay_map/index.html | 2 +- .../iroh_base/relay_map/struct.RelayUrl.html | 8 +-- pr/3024/docs/iroh_base/ticket/enum.Error.html | 4 +- pr/3024/docs/iroh_base/ticket/index.html | 2 +- .../iroh_base/ticket/struct.BlobTicket.html | 2 +- .../iroh_base/ticket/struct.NodeTicket.html | 2 +- .../docs/iroh_base/ticket/trait.Ticket.html | 12 ++--- .../docs/iroh_net_report/struct.Client.html | 4 +- .../struct.RelayLatencies.html | 2 +- .../docs/iroh_net_report/struct.Report.html | 4 +- pr/3024/docs/iroh_relay/client/index.html | 2 +- .../docs/iroh_relay/client/struct.Client.html | 22 ++++---- .../client/struct.ClientBuilder.html | 26 +++++----- .../client/struct.ClientReceiver.html | 2 +- .../constant.DEFAULT_RELAY_QUIC_PORT.html | 2 +- .../defaults/constant.DEFAULT_STUN_PORT.html | 2 +- pr/3024/docs/iroh_relay/defaults/index.html | 2 +- .../docs/iroh_relay/enum.ReceivedMessage.html | 8 +-- .../iroh_relay/http/constant.RELAY_PATH.html | 2 +- .../http/constant.RELAY_PROBE_PATH.html | 2 +- .../docs/iroh_relay/http/enum.Protocol.html | 10 ++-- pr/3024/docs/iroh_relay/http/index.html | 2 +- pr/3024/docs/iroh_relay/index.html | 2 +- .../docs/iroh_relay/protos/relay/index.html | 2 +- .../protos/stun/struct.TransactionId.html | 10 ++-- pr/3024/docs/iroh_relay/quic/index.html | 2 +- .../iroh_relay/quic/struct.QuicClient.html | 8 +-- .../iroh_relay/server/enum.CertConfig.html | 4 +- pr/3024/docs/iroh_relay/server/index.html | 2 +- .../server/struct.ClientConnRateLimit.html | 4 +- .../docs/iroh_relay/server/struct.Limits.html | 4 +- .../iroh_relay/server/struct.Metrics.html | 4 +- .../iroh_relay/server/struct.QuicConfig.html | 4 +- .../iroh_relay/server/struct.RelayConfig.html | 6 +-- .../docs/iroh_relay/server/struct.Server.html | 24 ++++----- .../server/struct.ServerConfig.html | 6 +-- .../iroh_relay/server/struct.StunConfig.html | 4 +- .../iroh_relay/server/struct.StunMetrics.html | 4 +- .../iroh_relay/server/struct.TlsConfig.html | 6 +-- pr/3024/docs/iroh_relay/struct.RelayConn.html | 2 +- pr/3024/docs/iroh_relay/struct.RelayUrl.html | 26 +++++----- pr/3024/docs/src/iroh/discovery.rs.html | 2 - pr/3024/docs/src/iroh/discovery/pkarr.rs.html | 2 - pr/3024/docs/src/iroh/endpoint.rs.html | 10 ---- pr/3024/docs/src/iroh/lib.rs.html | 4 +- pr/3024/docs/src/iroh/magicsock.rs.html | 44 +++++++++++++--- pr/3024/docs/src/iroh/metrics.rs.html | 2 - pr/3024/docs/src/iroh_base/hash.rs.html | 2 - pr/3024/docs/src/iroh_base/lib.rs.html | 14 +----- pr/3024/docs/src/iroh_base/ticket.rs.html | 6 --- pr/3024/docs/src/iroh_relay/client.rs.html | 6 --- pr/3024/docs/src/iroh_relay/defaults.rs.html | 2 - pr/3024/docs/src/iroh_relay/http.rs.html | 4 -- pr/3024/docs/src/iroh_relay/lib.rs.html | 4 +- .../docs/src/iroh_relay/protos/relay.rs.html | 10 ---- pr/3024/docs/src/iroh_relay/quic.rs.html | 2 - pr/3024/docs/src/iroh_relay/server.rs.html | 8 --- 130 files changed, 551 insertions(+), 595 deletions(-) diff --git a/pr/3024/docs/iroh/discovery/dns/struct.DnsDiscovery.html b/pr/3024/docs/iroh/discovery/dns/struct.DnsDiscovery.html index 32974634e5..b09de975a5 100644 --- a/pr/3024/docs/iroh/discovery/dns/struct.DnsDiscovery.html +++ b/pr/3024/docs/iroh/discovery/dns/struct.DnsDiscovery.html @@ -26,7 +26,7 @@ service for testing purposes.

&self, ep: Endpoint, node_id: NodeId -) -> Option<BoxStream<Result<DiscoveryItem>>>
Resolves the DiscoveryItem for the given NodeId. Read more
source§

fn publish(&self, _url: Option<&RelayUrl>, _addrs: &BTreeSet<SocketAddr>)

Publishes the given RelayUrl and direct addreesses to the discovery mechanism. Read more
source§

fn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>

Subscribe to all addresses that get passively discovered. Read more

Auto Trait Implementations§

§

impl Freeze for DnsDiscovery

§

impl RefUnwindSafe for DnsDiscovery

§

impl Send for DnsDiscovery

§

impl Sync for DnsDiscovery

§

impl Unpin for DnsDiscovery

§

impl UnwindSafe for DnsDiscovery

Blanket Implementations§

source§

impl<T> Any for T
where +) -> Option<BoxStream<Result<DiscoveryItem>>>

Resolves the DiscoveryItem for the given NodeId. Read more
source§

fn publish(&self, _url: Option<&RelayUrl>, _addrs: &BTreeSet<SocketAddr>)

Publishes the given RelayUrl and direct addreesses to the discovery mechanism. Read more
source§

fn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>

Subscribe to all addresses that get passively discovered. Read more

Auto Trait Implementations§

§

impl Freeze for DnsDiscovery

§

impl RefUnwindSafe for DnsDiscovery

§

impl Send for DnsDiscovery

§

impl Sync for DnsDiscovery

§

impl Unpin for DnsDiscovery

§

impl UnwindSafe for DnsDiscovery

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<'a, T, E> AsTaggedExplicit<'a, E> for T
where T: 'a,

§

fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

§

impl<'a, T, E> AsTaggedImplicit<'a, E> for T
where T: 'a,

§

fn implicit( diff --git a/pr/3024/docs/iroh/discovery/index.html b/pr/3024/docs/iroh/discovery/index.html index 87e940e3e5..e391c3bfc8 100644 --- a/pr/3024/docs/iroh/discovery/index.html +++ b/pr/3024/docs/iroh/discovery/index.html @@ -1,4 +1,4 @@ -iroh::discovery - Rust

Module iroh::discovery

source ·
Expand description

Node address discovery.

+iroh::discovery - Rust

Module iroh::discovery

source ·
Expand description

Node address discovery.

To connect to an iroh node a NodeAddr is needed, which may contain a RelayUrl or one or more direct addresses in addition to the NodeId.

Since there is a conversion from NodeId to NodeAddr, you can also use diff --git a/pr/3024/docs/iroh/discovery/pkarr/constant.DEFAULT_PKARR_TTL.html b/pr/3024/docs/iroh/discovery/pkarr/constant.DEFAULT_PKARR_TTL.html index 0552b4cf88..3c6fb854fc 100644 --- a/pr/3024/docs/iroh/discovery/pkarr/constant.DEFAULT_PKARR_TTL.html +++ b/pr/3024/docs/iroh/discovery/pkarr/constant.DEFAULT_PKARR_TTL.html @@ -1,4 +1,4 @@ -DEFAULT_PKARR_TTL in iroh::discovery::pkarr - Rust

Constant iroh::discovery::pkarr::DEFAULT_PKARR_TTL

source ·
pub const DEFAULT_PKARR_TTL: u32 = 30;
Expand description

Default TTL for the records in the pkarr signed packet.

+DEFAULT_PKARR_TTL in iroh::discovery::pkarr - Rust

Constant iroh::discovery::pkarr::DEFAULT_PKARR_TTL

source ·
pub const DEFAULT_PKARR_TTL: u32 = 30;
Expand description

Default TTL for the records in the pkarr signed packet.

The Time To Live (TTL) tells DNS caches how long to store a record. It is ignored by the iroh-dns-server, e.g. as running on N0_DNS_PKARR_RELAY_PROD, as the home server keeps the records for the domain. When using the pkarr relay no DNS is involved and the diff --git a/pr/3024/docs/iroh/discovery/pkarr/constant.DEFAULT_REPUBLISH_INTERVAL.html b/pr/3024/docs/iroh/discovery/pkarr/constant.DEFAULT_REPUBLISH_INTERVAL.html index f26e2bc1f9..5a8507169b 100644 --- a/pr/3024/docs/iroh/discovery/pkarr/constant.DEFAULT_REPUBLISH_INTERVAL.html +++ b/pr/3024/docs/iroh/discovery/pkarr/constant.DEFAULT_REPUBLISH_INTERVAL.html @@ -1,2 +1,2 @@ -DEFAULT_REPUBLISH_INTERVAL in iroh::discovery::pkarr - Rust

Constant iroh::discovery::pkarr::DEFAULT_REPUBLISH_INTERVAL

source ·
pub const DEFAULT_REPUBLISH_INTERVAL: Duration;
Expand description

Interval in which to republish the node info even if unchanged: 5 minutes.

+DEFAULT_REPUBLISH_INTERVAL in iroh::discovery::pkarr - Rust

Constant iroh::discovery::pkarr::DEFAULT_REPUBLISH_INTERVAL

source ·
pub const DEFAULT_REPUBLISH_INTERVAL: Duration;
Expand description

Interval in which to republish the node info even if unchanged: 5 minutes.

\ No newline at end of file diff --git a/pr/3024/docs/iroh/discovery/pkarr/constant.N0_DNS_PKARR_RELAY_PROD.html b/pr/3024/docs/iroh/discovery/pkarr/constant.N0_DNS_PKARR_RELAY_PROD.html index 4385cbc822..3d81b5bf80 100644 --- a/pr/3024/docs/iroh/discovery/pkarr/constant.N0_DNS_PKARR_RELAY_PROD.html +++ b/pr/3024/docs/iroh/discovery/pkarr/constant.N0_DNS_PKARR_RELAY_PROD.html @@ -1,4 +1,4 @@ -N0_DNS_PKARR_RELAY_PROD in iroh::discovery::pkarr - Rust

Constant iroh::discovery::pkarr::N0_DNS_PKARR_RELAY_PROD

source ·
pub const N0_DNS_PKARR_RELAY_PROD: &str = "https://dns.iroh.link/pkarr";
Expand description

The production pkarr relay run by number 0.

+N0_DNS_PKARR_RELAY_PROD in iroh::discovery::pkarr - Rust

Constant iroh::discovery::pkarr::N0_DNS_PKARR_RELAY_PROD

source ·
pub const N0_DNS_PKARR_RELAY_PROD: &str = "https://dns.iroh.link/pkarr";
Expand description

The production pkarr relay run by number 0.

This server is both a pkarr relay server as well as a DNS resolver, see the module documentation. However it does not interact with the Mainline DHT, so is a more central service. It is a reliable service to use for node discovery.

diff --git a/pr/3024/docs/iroh/discovery/pkarr/constant.N0_DNS_PKARR_RELAY_STAGING.html b/pr/3024/docs/iroh/discovery/pkarr/constant.N0_DNS_PKARR_RELAY_STAGING.html index 39f7eb0bd5..dd8ddee460 100644 --- a/pr/3024/docs/iroh/discovery/pkarr/constant.N0_DNS_PKARR_RELAY_STAGING.html +++ b/pr/3024/docs/iroh/discovery/pkarr/constant.N0_DNS_PKARR_RELAY_STAGING.html @@ -1,4 +1,4 @@ -N0_DNS_PKARR_RELAY_STAGING in iroh::discovery::pkarr - Rust

Constant iroh::discovery::pkarr::N0_DNS_PKARR_RELAY_STAGING

source ·
pub const N0_DNS_PKARR_RELAY_STAGING: &str = "https://staging-dns.iroh.link/pkarr";
Expand description

The testing pkarr relay run by number 0.

+N0_DNS_PKARR_RELAY_STAGING in iroh::discovery::pkarr - Rust

Constant iroh::discovery::pkarr::N0_DNS_PKARR_RELAY_STAGING

source ·
pub const N0_DNS_PKARR_RELAY_STAGING: &str = "https://staging-dns.iroh.link/pkarr";
Expand description

The testing pkarr relay run by number 0.

This server operates similarly to N0_DNS_PKARR_RELAY_PROD but is not as reliable. It is meant for more experimental use and testing purposes.

\ No newline at end of file diff --git a/pr/3024/docs/iroh/discovery/pkarr/dht/struct.DhtDiscovery.html b/pr/3024/docs/iroh/discovery/pkarr/dht/struct.DhtDiscovery.html index b7627460ed..3513959639 100644 --- a/pr/3024/docs/iroh/discovery/pkarr/dht/struct.DhtDiscovery.html +++ b/pr/3024/docs/iroh/discovery/pkarr/dht/struct.DhtDiscovery.html @@ -9,7 +9,7 @@ a background task that periodically publishes the node address.

&self, _endpoint: Endpoint, node_id: NodeId -) -> Option<Boxed<Result<DiscoveryItem>>>

Resolves the DiscoveryItem for the given NodeId. Read more
source§

fn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>

Subscribe to all addresses that get passively discovered. Read more

Auto Trait Implementations§

§

impl Freeze for DhtDiscovery

§

impl !RefUnwindSafe for DhtDiscovery

§

impl Send for DhtDiscovery

§

impl Sync for DhtDiscovery

§

impl Unpin for DhtDiscovery

§

impl !UnwindSafe for DhtDiscovery

Blanket Implementations§

source§

impl<T> Any for T
where +) -> Option<Boxed<Result<DiscoveryItem>>>

Resolves the DiscoveryItem for the given NodeId. Read more
source§

fn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>

Subscribe to all addresses that get passively discovered. Read more

Auto Trait Implementations§

§

impl Freeze for DhtDiscovery

§

impl !RefUnwindSafe for DhtDiscovery

§

impl Send for DhtDiscovery

§

impl Sync for DhtDiscovery

§

impl Unpin for DhtDiscovery

§

impl !UnwindSafe for DhtDiscovery

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<'a, T, E> AsTaggedExplicit<'a, E> for T
where T: 'a,

§

fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

§

impl<'a, T, E> AsTaggedImplicit<'a, E> for T
where T: 'a,

§

fn implicit( diff --git a/pr/3024/docs/iroh/discovery/pkarr/index.html b/pr/3024/docs/iroh/discovery/pkarr/index.html index 1f3bada019..89cbc86f8d 100644 --- a/pr/3024/docs/iroh/discovery/pkarr/index.html +++ b/pr/3024/docs/iroh/discovery/pkarr/index.html @@ -1,4 +1,4 @@ -iroh::discovery::pkarr - Rust

Module iroh::discovery::pkarr

source ·
Expand description

A discovery service which publishes and resolves node information using a pkarr relay.

+iroh::discovery::pkarr - Rust

Module iroh::discovery::pkarr

source ·
Expand description

A discovery service which publishes and resolves node information using a pkarr relay.

Public-Key Addressable Resource Records, pkarr, is a system which allows publishing DNS Resource Records owned by a particular SecretKey under a name derived from its corresponding PublicKey, also known as the NodeId. Additionally this pkarr diff --git a/pr/3024/docs/iroh/discovery/pkarr/struct.PkarrPublisher.html b/pr/3024/docs/iroh/discovery/pkarr/struct.PkarrPublisher.html index b8f6516fdb..91a67ce03b 100644 --- a/pr/3024/docs/iroh/discovery/pkarr/struct.PkarrPublisher.html +++ b/pr/3024/docs/iroh/discovery/pkarr/struct.PkarrPublisher.html @@ -1,16 +1,16 @@ -PkarrPublisher in iroh::discovery::pkarr - Rust

Struct iroh::discovery::pkarr::PkarrPublisher

source ·
pub struct PkarrPublisher { /* private fields */ }
Expand description

Publisher of node discovery information to a pkarr relay.

+PkarrPublisher in iroh::discovery::pkarr - Rust

Struct iroh::discovery::pkarr::PkarrPublisher

source ·
pub struct PkarrPublisher { /* private fields */ }
Expand description

Publisher of node discovery information to a pkarr relay.

This publisher uses HTTP to publish node discovery information to a pkarr relay server, see the module docs for details.

This implements the Discovery trait to be used as a node discovery service. Note that it only publishes node discovery information, for the corresponding resolver use the PkarrResolver together with ConcurrentDiscovery.

This publisher will only publish the RelayUrl if it is set, otherwise the direct addresses are published instead.

-

Implementations§

source§

impl PkarrPublisher

source

pub fn new(secret_key: SecretKey, pkarr_relay: Url) -> Self

Creates a new publisher for the SecretKey.

+

Implementations§

source§

impl PkarrPublisher

source

pub fn new(secret_key: SecretKey, pkarr_relay: Url) -> Self

Creates a new publisher for the SecretKey.

This publisher will be able to publish pkarr records for SecretKey. It will use DEFAULT_PKARR_TTL as the time-to-live value for the published packets. Will republish discovery information every DEFAULT_REPUBLISH_INTERVAL, even if the information is unchanged.

-
source

pub fn with_options( +

source

pub fn with_options( secret_key: SecretKey, pkarr_relay: Url, ttl: u32, @@ -18,23 +18,23 @@ information is unchanged.

) -> Self

Creates a new PkarrPublisher with a custom TTL and republish intervals.

This allows creating the publisher with custom time-to-live values of the [pkarr::SignedPacket]s and well as a custom republish interval.

-
source

pub fn n0_dns(secret_key: SecretKey) -> Self

Creates a pkarr publisher which uses the number 0 pkarr relay server.

+
source

pub fn n0_dns(secret_key: SecretKey) -> Self

Creates a pkarr publisher which uses the number 0 pkarr relay server.

This uses the pkarr relay server operated by number 0, at N0_DNS_PKARR_RELAY_PROD.

When running with the environment variable IROH_FORCE_STAGING_RELAYS set to any non empty value N0_DNS_PKARR_RELAY_STAGING server is used instead.

-
source

pub fn update_addr_info( +

source

pub fn update_addr_info( &self, url: Option<&RelayUrl>, addrs: &BTreeSet<SocketAddr> )

Publishes the addressing information about this node to a pkarr relay.

This is a nonblocking function, the actual update is performed in the background.

-

Trait Implementations§

source§

impl Clone for PkarrPublisher

source§

fn clone(&self) -> PkarrPublisher

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for PkarrPublisher

source§

fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Discovery for PkarrPublisher

source§

fn publish(&self, url: Option<&RelayUrl>, addrs: &BTreeSet<SocketAddr>)

Publishes the given RelayUrl and direct addreesses to the discovery mechanism. Read more
source§

fn resolve( +

Trait Implementations§

source§

impl Clone for PkarrPublisher

source§

fn clone(&self) -> PkarrPublisher

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for PkarrPublisher

source§

fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Discovery for PkarrPublisher

source§

fn publish(&self, url: Option<&RelayUrl>, addrs: &BTreeSet<SocketAddr>)

Publishes the given RelayUrl and direct addreesses to the discovery mechanism. Read more
source§

fn resolve( &self, _endpoint: Endpoint, _node_id: NodeId -) -> Option<BoxStream<Result<DiscoveryItem>>>

Resolves the DiscoveryItem for the given NodeId. Read more
source§

fn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>

Subscribe to all addresses that get passively discovered. Read more
source§

impl Drop for PkarrPublisher

source§

fn drop(&mut self)

Executes the destructor for this type. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where +) -> Option<BoxStream<Result<DiscoveryItem>>>

Resolves the DiscoveryItem for the given NodeId. Read more
source§

fn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>

Subscribe to all addresses that get passively discovered. Read more
source§

impl Drop for PkarrPublisher

source§

fn drop(&mut self)

Executes the destructor for this type. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<'a, T, E> AsTaggedExplicit<'a, E> for T
where T: 'a,

§

fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

§

impl<'a, T, E> AsTaggedImplicit<'a, E> for T
where T: 'a,

§

fn implicit( diff --git a/pr/3024/docs/iroh/discovery/pkarr/struct.PkarrRelayClient.html b/pr/3024/docs/iroh/discovery/pkarr/struct.PkarrRelayClient.html index e394489cf5..7488d2b6da 100644 --- a/pr/3024/docs/iroh/discovery/pkarr/struct.PkarrRelayClient.html +++ b/pr/3024/docs/iroh/discovery/pkarr/struct.PkarrRelayClient.html @@ -1,8 +1,8 @@ -PkarrRelayClient in iroh::discovery::pkarr - Rust

Struct iroh::discovery::pkarr::PkarrRelayClient

source ·
pub struct PkarrRelayClient { /* private fields */ }
Expand description

A pkarr client to publish [pkarr::SignedPacket]s to a pkarr relay.

-

Implementations§

source§

impl PkarrRelayClient

source

pub fn new(pkarr_relay_url: Url) -> Self

Creates a new client.

-
source

pub async fn resolve(&self, node_id: NodeId) -> Result<SignedPacket>

Resolves a [SignedPacket] for the given NodeId.

-
source

pub async fn publish(&self, signed_packet: &SignedPacket) -> Result<()>

Publishes a [SignedPacket].

-

Trait Implementations§

source§

impl Clone for PkarrRelayClient

source§

fn clone(&self) -> PkarrRelayClient

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for PkarrRelayClient

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where +PkarrRelayClient in iroh::discovery::pkarr - Rust

Struct iroh::discovery::pkarr::PkarrRelayClient

source ·
pub struct PkarrRelayClient { /* private fields */ }
Expand description

A pkarr client to publish [pkarr::SignedPacket]s to a pkarr relay.

+

Implementations§

source§

impl PkarrRelayClient

source

pub fn new(pkarr_relay_url: Url) -> Self

Creates a new client.

+
source

pub async fn resolve(&self, node_id: NodeId) -> Result<SignedPacket>

Resolves a [SignedPacket] for the given NodeId.

+
source

pub async fn publish(&self, signed_packet: &SignedPacket) -> Result<()>

Publishes a [SignedPacket].

+

Trait Implementations§

source§

impl Clone for PkarrRelayClient

source§

fn clone(&self) -> PkarrRelayClient

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for PkarrRelayClient

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<'a, T, E> AsTaggedExplicit<'a, E> for T
where T: 'a,

§

fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

§

impl<'a, T, E> AsTaggedImplicit<'a, E> for T
where T: 'a,

§

fn implicit( diff --git a/pr/3024/docs/iroh/discovery/pkarr/struct.PkarrResolver.html b/pr/3024/docs/iroh/discovery/pkarr/struct.PkarrResolver.html index 63a3316da1..3bdc880b12 100644 --- a/pr/3024/docs/iroh/discovery/pkarr/struct.PkarrResolver.html +++ b/pr/3024/docs/iroh/discovery/pkarr/struct.PkarrResolver.html @@ -1,21 +1,21 @@ -PkarrResolver in iroh::discovery::pkarr - Rust

Struct iroh::discovery::pkarr::PkarrResolver

source ·
pub struct PkarrResolver { /* private fields */ }
Expand description

Resolver of node discovery information from a pkarr relay.

+PkarrResolver in iroh::discovery::pkarr - Rust

Struct iroh::discovery::pkarr::PkarrResolver

source ·
pub struct PkarrResolver { /* private fields */ }
Expand description

Resolver of node discovery information from a pkarr relay.

The resolver uses HTTP to query node discovery information from a pkarr relay server, see the module docs for details.

This implements the Discovery trait to be used as a node discovery service. Note that it only resolves node discovery information, for the corresponding publisher use the PkarrPublisher together with ConcurrentDiscovery.

-

Implementations§

source§

impl PkarrResolver

source

pub fn new(pkarr_relay: Url) -> Self

Creates a new publisher using the pkarr relay server at the URL.

-
source

pub fn n0_dns() -> Self

Creates a pkarr resolver which uses the number 0 pkarr relay server.

+

Implementations§

source§

impl PkarrResolver

source

pub fn new(pkarr_relay: Url) -> Self

Creates a new publisher using the pkarr relay server at the URL.

+
source

pub fn n0_dns() -> Self

Creates a pkarr resolver which uses the number 0 pkarr relay server.

This uses the pkarr relay server operated by number 0 at N0_DNS_PKARR_RELAY_PROD.

When running with the environment variable IROH_FORCE_STAGING_RELAYS set to any non empty value N0_DNS_PKARR_RELAY_STAGING server is used instead.

-

Trait Implementations§

source§

impl Clone for PkarrResolver

source§

fn clone(&self) -> PkarrResolver

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for PkarrResolver

source§

fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Discovery for PkarrResolver

Trait Implementations§

source§

impl Clone for PkarrResolver

source§

fn clone(&self) -> PkarrResolver

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for PkarrResolver

source§

fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Discovery for PkarrResolver

source§

fn resolve( &self, _ep: Endpoint, node_id: NodeId -) -> Option<BoxStream<'static, Result<DiscoveryItem>>>

Resolves the DiscoveryItem for the given NodeId. Read more
source§

fn publish(&self, _url: Option<&RelayUrl>, _addrs: &BTreeSet<SocketAddr>)

Publishes the given RelayUrl and direct addreesses to the discovery mechanism. Read more
source§

fn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>

Subscribe to all addresses that get passively discovered. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where +) -> Option<BoxStream<'static, Result<DiscoveryItem>>>

Resolves the DiscoveryItem for the given NodeId. Read more
source§

fn publish(&self, _url: Option<&RelayUrl>, _addrs: &BTreeSet<SocketAddr>)

Publishes the given RelayUrl and direct addreesses to the discovery mechanism. Read more
source§

fn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>

Subscribe to all addresses that get passively discovered. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<'a, T, E> AsTaggedExplicit<'a, E> for T
where T: 'a,

§

fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

§

impl<'a, T, E> AsTaggedImplicit<'a, E> for T
where T: 'a,

§

fn implicit( diff --git a/pr/3024/docs/iroh/discovery/static_provider/struct.StaticProvider.html b/pr/3024/docs/iroh/discovery/static_provider/struct.StaticProvider.html index ab21846ced..767dbae095 100644 --- a/pr/3024/docs/iroh/discovery/static_provider/struct.StaticProvider.html +++ b/pr/3024/docs/iroh/discovery/static_provider/struct.StaticProvider.html @@ -29,7 +29,7 @@ &self, _endpoint: Endpoint, node_id: NodeId -) -> Option<Boxed<Result<DiscoveryItem>>>

Resolves the DiscoveryItem for the given NodeId. Read more
source§

fn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>

Subscribe to all addresses that get passively discovered. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where +) -> Option<Boxed<Result<DiscoveryItem>>>

Resolves the DiscoveryItem for the given NodeId. Read more
source§

fn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>

Subscribe to all addresses that get passively discovered. Read more

Auto Trait Implementations§

§

impl Freeze for StaticProvider

§

impl RefUnwindSafe for StaticProvider

§

impl Send for StaticProvider

§

impl Sync for StaticProvider

§

impl Unpin for StaticProvider

§

impl UnwindSafe for StaticProvider

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<'a, T, E> AsTaggedExplicit<'a, E> for T
where T: 'a,

§

fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

§

impl<'a, T, E> AsTaggedImplicit<'a, E> for T
where T: 'a,

§

fn implicit( diff --git a/pr/3024/docs/iroh/discovery/struct.ConcurrentDiscovery.html b/pr/3024/docs/iroh/discovery/struct.ConcurrentDiscovery.html index 451aa06037..ac7d8860e3 100644 --- a/pr/3024/docs/iroh/discovery/struct.ConcurrentDiscovery.html +++ b/pr/3024/docs/iroh/discovery/struct.ConcurrentDiscovery.html @@ -1,14 +1,14 @@ -ConcurrentDiscovery in iroh::discovery - Rust

Struct iroh::discovery::ConcurrentDiscovery

source ·
pub struct ConcurrentDiscovery { /* private fields */ }
Expand description

A discovery service that combines multiple discovery sources.

+ConcurrentDiscovery in iroh::discovery - Rust

Struct iroh::discovery::ConcurrentDiscovery

source ·
pub struct ConcurrentDiscovery { /* private fields */ }
Expand description

A discovery service that combines multiple discovery sources.

The discovery services will resolve concurrently.

-

Implementations§

source§

impl ConcurrentDiscovery

source

pub fn empty() -> Self

Creates an empty ConcurrentDiscovery.

-
source

pub fn from_services(services: Vec<Box<dyn Discovery>>) -> Self

Creates a new ConcurrentDiscovery.

-
source

pub fn add(&mut self, service: impl Discovery + 'static)

Adds a Discovery service.

-

Trait Implementations§

source§

impl Debug for ConcurrentDiscovery

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for ConcurrentDiscovery

source§

fn default() -> ConcurrentDiscovery

Returns the “default value” for a type. Read more
source§

impl Discovery for ConcurrentDiscovery

source§

fn publish(&self, url: Option<&RelayUrl>, addrs: &BTreeSet<SocketAddr>)

Publishes the given RelayUrl and direct addreesses to the discovery mechanism. Read more
source§

fn resolve( +

Implementations§

source§

impl ConcurrentDiscovery

source

pub fn empty() -> Self

Creates an empty ConcurrentDiscovery.

+
source

pub fn from_services(services: Vec<Box<dyn Discovery>>) -> Self

Creates a new ConcurrentDiscovery.

+
source

pub fn add(&mut self, service: impl Discovery + 'static)

Adds a Discovery service.

+

Trait Implementations§

source§

impl Debug for ConcurrentDiscovery

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for ConcurrentDiscovery

source§

fn default() -> ConcurrentDiscovery

Returns the “default value” for a type. Read more
source§

impl Discovery for ConcurrentDiscovery

source§

fn publish(&self, url: Option<&RelayUrl>, addrs: &BTreeSet<SocketAddr>)

Publishes the given RelayUrl and direct addreesses to the discovery mechanism. Read more
source§

fn resolve( &self, endpoint: Endpoint, node_id: NodeId -) -> Option<BoxStream<Result<DiscoveryItem>>>

Resolves the DiscoveryItem for the given NodeId. Read more
source§

fn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>

Subscribe to all addresses that get passively discovered. Read more
source§

impl<T> From<T> for ConcurrentDiscovery
where - T: IntoIterator<Item = Box<dyn Discovery>>,

source§

fn from(iter: T) -> Self

Converts to this type from the input type.

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where +) -> Option<BoxStream<Result<DiscoveryItem>>>

Resolves the DiscoveryItem for the given NodeId. Read more
source§

fn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>

Subscribe to all addresses that get passively discovered. Read more
source§

impl<T> From<T> for ConcurrentDiscovery
where + T: IntoIterator<Item = Box<dyn Discovery>>,

source§

fn from(iter: T) -> Self

Converts to this type from the input type.

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<'a, T, E> AsTaggedExplicit<'a, E> for T
where T: 'a,

§

fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

§

impl<'a, T, E> AsTaggedImplicit<'a, E> for T
where T: 'a,

§

fn implicit( diff --git a/pr/3024/docs/iroh/discovery/struct.DiscoveryItem.html b/pr/3024/docs/iroh/discovery/struct.DiscoveryItem.html index eaf89d19ba..8079aea57d 100644 --- a/pr/3024/docs/iroh/discovery/struct.DiscoveryItem.html +++ b/pr/3024/docs/iroh/discovery/struct.DiscoveryItem.html @@ -1,4 +1,4 @@ -DiscoveryItem in iroh::discovery - Rust

Struct iroh::discovery::DiscoveryItem

source ·
pub struct DiscoveryItem {
+DiscoveryItem in iroh::discovery - Rust

Struct iroh::discovery::DiscoveryItem

source ·
pub struct DiscoveryItem {
     pub node_addr: NodeAddr,
     pub provenance: &'static str,
     pub last_updated: Option<u64>,
@@ -8,7 +8,7 @@
 

Should be uniform per discovery service.

§last_updated: Option<u64>

Optional timestamp when this node address info was last updated.

Must be microseconds since the unix epoch.

-

Trait Implementations§

source§

impl Clone for DiscoveryItem

source§

fn clone(&self) -> DiscoveryItem

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for DiscoveryItem

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where +

Trait Implementations§

source§

impl Clone for DiscoveryItem

source§

fn clone(&self) -> DiscoveryItem

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for DiscoveryItem

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<'a, T, E> AsTaggedExplicit<'a, E> for T
where T: 'a,

§

fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

§

impl<'a, T, E> AsTaggedImplicit<'a, E> for T
where T: 'a,

§

fn implicit( diff --git a/pr/3024/docs/iroh/discovery/trait.Discovery.html b/pr/3024/docs/iroh/discovery/trait.Discovery.html index acd0c719d1..312c19b579 100644 --- a/pr/3024/docs/iroh/discovery/trait.Discovery.html +++ b/pr/3024/docs/iroh/discovery/trait.Discovery.html @@ -1,4 +1,4 @@ -Discovery in iroh::discovery - Rust

Trait iroh::discovery::Discovery

source ·
pub trait Discovery: Debug + Send + Sync {
+Discovery in iroh::discovery - Rust

Trait iroh::discovery::Discovery

source ·
pub trait Discovery: Debug + Send + Sync {
     // Provided methods
     fn publish(&self, _url: Option<&RelayUrl>, _addrs: &BTreeSet<SocketAddr>) { ... }
     fn resolve(
@@ -18,19 +18,19 @@ addresses.

To allow for discovery, the super::Endpoint will call publish whenever discovery information changes. If a discovery mechanism requires a periodic refresh, it should start its own task.

-

Provided Methods§

source

fn publish(&self, _url: Option<&RelayUrl>, _addrs: &BTreeSet<SocketAddr>)

Publishes the given RelayUrl and direct addreesses to the discovery mechanism.

+

Provided Methods§

source

fn publish(&self, _url: Option<&RelayUrl>, _addrs: &BTreeSet<SocketAddr>)

Publishes the given RelayUrl and direct addreesses to the discovery mechanism.

This is fire and forget, since the Endpoint can not wait for successful publishing. If publishing is async, the implementation should start it’s own task.

This will be called from a tokio task, so it is safe to spawn new tasks. These tasks will be run on the runtime of the super::Endpoint.

-
source

fn resolve( +

source

fn resolve( &self, _endpoint: Endpoint, _node_id: NodeId ) -> Option<BoxStream<Result<DiscoveryItem>>>

Resolves the DiscoveryItem for the given NodeId.

Once the returned [BoxStream] is dropped, the service should stop any pending work.

-
source

fn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>

Subscribe to all addresses that get passively discovered.

+
source

fn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>

Subscribe to all addresses that get passively discovered.

An implementation may choose to defer emitting passively discovered nodes until the stream is actually polled. To avoid missing discovered nodes, poll the stream as soon as possible.

@@ -47,4 +47,4 @@ should be sent on all streams.

The crate::endpoint::Endpoint will subscribe to the discovery system and add the discovered addresses to the internal address book as they arrive on this stream.

-

Implementors§

source§

impl Discovery for DnsDiscovery

source§

impl Discovery for LocalSwarmDiscovery

Available on crate feature discovery-local-network only.
source§

impl Discovery for DhtDiscovery

Available on crate feature discovery-pkarr-dht only.
source§

impl Discovery for PkarrPublisher

source§

impl Discovery for PkarrResolver

source§

impl Discovery for StaticProvider

source§

impl Discovery for ConcurrentDiscovery

\ No newline at end of file +

Implementors§

source§

impl Discovery for DnsDiscovery

source§

impl Discovery for LocalSwarmDiscovery

Available on crate feature discovery-local-network only.
source§

impl Discovery for DhtDiscovery

Available on crate feature discovery-pkarr-dht only.
source§

impl Discovery for PkarrPublisher

source§

impl Discovery for PkarrResolver

source§

impl Discovery for StaticProvider

source§

impl Discovery for ConcurrentDiscovery

\ No newline at end of file diff --git a/pr/3024/docs/iroh/endpoint/constant.ENV_FORCE_STAGING_RELAYS.html b/pr/3024/docs/iroh/endpoint/constant.ENV_FORCE_STAGING_RELAYS.html index 03f6ef3935..c2656a9c09 100644 --- a/pr/3024/docs/iroh/endpoint/constant.ENV_FORCE_STAGING_RELAYS.html +++ b/pr/3024/docs/iroh/endpoint/constant.ENV_FORCE_STAGING_RELAYS.html @@ -1,2 +1,2 @@ -ENV_FORCE_STAGING_RELAYS in iroh::endpoint - Rust

Constant iroh::endpoint::ENV_FORCE_STAGING_RELAYS

source ·
pub const ENV_FORCE_STAGING_RELAYS: &str = "IROH_FORCE_STAGING_RELAYS";
Available on non-test only.
Expand description

Environment variable to force the use of staging relays.

+ENV_FORCE_STAGING_RELAYS in iroh::endpoint - Rust

Constant iroh::endpoint::ENV_FORCE_STAGING_RELAYS

source ·
pub const ENV_FORCE_STAGING_RELAYS: &str = "IROH_FORCE_STAGING_RELAYS";
Expand description

Environment variable to force the use of staging relays.

\ No newline at end of file diff --git a/pr/3024/docs/iroh/endpoint/enum.DirectAddrType.html b/pr/3024/docs/iroh/endpoint/enum.DirectAddrType.html index b5c83a3fd8..176fa71b6a 100644 --- a/pr/3024/docs/iroh/endpoint/enum.DirectAddrType.html +++ b/pr/3024/docs/iroh/endpoint/enum.DirectAddrType.html @@ -1,4 +1,4 @@ -DirectAddrType in iroh::endpoint - Rust

Enum iroh::endpoint::DirectAddrType

source ·
pub enum DirectAddrType {
+DirectAddrType in iroh::endpoint - Rust

Enum iroh::endpoint::DirectAddrType

source ·
pub enum DirectAddrType {
     Unknown,
     Local,
     Stun,
@@ -20,16 +20,16 @@ get a publicly routable direct address.

It is possible to configure iroh to bound to a specific port and independently configure the router to forward this port to the iroh node. This indicates a situation like this, which still uses STUN to discover the public address.

-

Trait Implementations§

source§

impl Clone for DirectAddrType

source§

fn clone(&self) -> DirectAddrType

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for DirectAddrType

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Display for DirectAddrType

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Hash for DirectAddrType

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where +

Trait Implementations§

source§

impl Clone for DirectAddrType

source§

fn clone(&self) -> DirectAddrType

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for DirectAddrType

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Display for DirectAddrType

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Hash for DirectAddrType

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, - Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl Ord for DirectAddrType

source§

fn cmp(&self, other: &DirectAddrType) -> Ordering

This method returns an Ordering between self and other. Read more
1.21.0 · source§

fn max(self, other: Self) -> Self
where + Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl Ord for DirectAddrType

source§

fn cmp(&self, other: &DirectAddrType) -> Ordering

This method returns an Ordering between self and other. Read more
1.21.0 · source§

fn max(self, other: Self) -> Self
where Self: Sized,

Compares and returns the maximum of two values. Read more
1.21.0 · source§

fn min(self, other: Self) -> Self
where Self: Sized,

Compares and returns the minimum of two values. Read more
1.50.0 · source§

fn clamp(self, min: Self, max: Self) -> Self
where - Self: Sized + PartialOrd,

Restrict a value to a certain interval. Read more
source§

impl PartialEq for DirectAddrType

source§

fn eq(&self, other: &DirectAddrType) -> bool

This method tests for self and other values to be equal, and is used + Self: Sized + PartialOrd,
Restrict a value to a certain interval. Read more
source§

impl PartialEq for DirectAddrType

source§

fn eq(&self, other: &DirectAddrType) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always -sufficient, and should not be overridden without very good reason.
source§

impl PartialOrd for DirectAddrType

source§

fn partial_cmp(&self, other: &DirectAddrType) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= +sufficient, and should not be overridden without very good reason.
source§

impl PartialOrd for DirectAddrType

source§

fn partial_cmp(&self, other: &DirectAddrType) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= -operator. Read more
source§

impl Copy for DirectAddrType

source§

impl Eq for DirectAddrType

source§

impl StructuralPartialEq for DirectAddrType

Auto Trait Implementations§

§

impl Freeze for DirectAddrType

§

impl RefUnwindSafe for DirectAddrType

§

impl Send for DirectAddrType

§

impl Sync for DirectAddrType

§

impl Unpin for DirectAddrType

§

impl UnwindSafe for DirectAddrType

Blanket Implementations§

source§

impl<T> Any for T
where +operator. Read more

source§

impl Copy for DirectAddrType

source§

impl Eq for DirectAddrType

source§

impl StructuralPartialEq for DirectAddrType

Auto Trait Implementations§

§

impl Freeze for DirectAddrType

§

impl RefUnwindSafe for DirectAddrType

§

impl Send for DirectAddrType

§

impl Sync for DirectAddrType

§

impl Unpin for DirectAddrType

§

impl UnwindSafe for DirectAddrType

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<'a, T, E> AsTaggedExplicit<'a, E> for T
where T: 'a,

§

fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

§

impl<'a, T, E> AsTaggedImplicit<'a, E> for T
where T: 'a,

§

fn implicit( diff --git a/pr/3024/docs/iroh/endpoint/enum.RelayMode.html b/pr/3024/docs/iroh/endpoint/enum.RelayMode.html index 2ebade4b18..5b0e8eb434 100644 --- a/pr/3024/docs/iroh/endpoint/enum.RelayMode.html +++ b/pr/3024/docs/iroh/endpoint/enum.RelayMode.html @@ -1,4 +1,4 @@ -RelayMode in iroh::endpoint - Rust

Enum iroh::endpoint::RelayMode

source ·
pub enum RelayMode {
+RelayMode in iroh::endpoint - Rust

Enum iroh::endpoint::RelayMode

source ·
pub enum RelayMode {
     Disabled,
     Default,
     Staging,
@@ -9,10 +9,10 @@
 

See crate::defaults::prod for the severs used.

§

Staging

Use the staging relay servers from n0.

§

Custom(RelayMap)

Use a custom relay map.

-

Implementations§

source§

impl RelayMode

source

pub fn relay_map(&self) -> RelayMap

Returns the relay map for this mode.

-

Trait Implementations§

source§

impl Clone for RelayMode

source§

fn clone(&self) -> RelayMode

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for RelayMode

source§

fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl PartialEq for RelayMode

source§

fn eq(&self, other: &RelayMode) -> bool

This method tests for self and other values to be equal, and is used +

Implementations§

source§

impl RelayMode

source

pub fn relay_map(&self) -> RelayMap

Returns the relay map for this mode.

+

Trait Implementations§

source§

impl Clone for RelayMode

source§

fn clone(&self) -> RelayMode

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for RelayMode

source§

fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl PartialEq for RelayMode

source§

fn eq(&self, other: &RelayMode) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always -sufficient, and should not be overridden without very good reason.
source§

impl Eq for RelayMode

source§

impl StructuralPartialEq for RelayMode

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where +sufficient, and should not be overridden without very good reason.

source§

impl Eq for RelayMode

source§

impl StructuralPartialEq for RelayMode

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<'a, T, E> AsTaggedExplicit<'a, E> for T
where T: 'a,

§

fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

§

impl<'a, T, E> AsTaggedImplicit<'a, E> for T
where T: 'a,

§

fn implicit( diff --git a/pr/3024/docs/iroh/endpoint/fn.default_relay_mode.html b/pr/3024/docs/iroh/endpoint/fn.default_relay_mode.html index 634bb6b6b7..0c24d7a505 100644 --- a/pr/3024/docs/iroh/endpoint/fn.default_relay_mode.html +++ b/pr/3024/docs/iroh/endpoint/fn.default_relay_mode.html @@ -1,4 +1,4 @@ -default_relay_mode in iroh::endpoint - Rust

Function iroh::endpoint::default_relay_mode

source ·
pub fn default_relay_mode() -> RelayMode
Expand description

Returns the default relay mode.

+default_relay_mode in iroh::endpoint - Rust

Function iroh::endpoint::default_relay_mode

source ·
pub fn default_relay_mode() -> RelayMode
Expand description

Returns the default relay mode.

If the IROH_FORCE_STAGING_RELAYS environment variable is non empty, it will return RelayMode::Staging. Otherwise, it will return RelayMode::Default.

\ No newline at end of file diff --git a/pr/3024/docs/iroh/endpoint/fn.force_staging_infra.html b/pr/3024/docs/iroh/endpoint/fn.force_staging_infra.html index 9f3e7f1fcb..3b49969567 100644 --- a/pr/3024/docs/iroh/endpoint/fn.force_staging_infra.html +++ b/pr/3024/docs/iroh/endpoint/fn.force_staging_infra.html @@ -1,2 +1,2 @@ -force_staging_infra in iroh::endpoint - Rust

Function iroh::endpoint::force_staging_infra

source ·
pub fn force_staging_infra() -> bool
Expand description

Returns true if the use of staging relays is forced.

+force_staging_infra in iroh::endpoint - Rust

Function iroh::endpoint::force_staging_infra

source ·
pub fn force_staging_infra() -> bool
Expand description

Returns true if the use of staging relays is forced.

\ No newline at end of file diff --git a/pr/3024/docs/iroh/endpoint/fn.get_remote_node_id.html b/pr/3024/docs/iroh/endpoint/fn.get_remote_node_id.html index cb16eb1d59..64437b1ba5 100644 --- a/pr/3024/docs/iroh/endpoint/fn.get_remote_node_id.html +++ b/pr/3024/docs/iroh/endpoint/fn.get_remote_node_id.html @@ -1,2 +1,2 @@ -get_remote_node_id in iroh::endpoint - Rust

Function iroh::endpoint::get_remote_node_id

source ·
pub fn get_remote_node_id(connection: &Connection) -> Result<PublicKey>
Expand description

Extract the PublicKey from the peer’s TLS certificate.

+get_remote_node_id in iroh::endpoint - Rust

Function iroh::endpoint::get_remote_node_id

source ·
pub fn get_remote_node_id(connection: &Connection) -> Result<PublicKey>
Expand description

Extract the PublicKey from the peer’s TLS certificate.

\ No newline at end of file diff --git a/pr/3024/docs/iroh/endpoint/fn.make_server_config.html b/pr/3024/docs/iroh/endpoint/fn.make_server_config.html index 886b316b34..9ffd756749 100644 --- a/pr/3024/docs/iroh/endpoint/fn.make_server_config.html +++ b/pr/3024/docs/iroh/endpoint/fn.make_server_config.html @@ -1,4 +1,4 @@ -make_server_config in iroh::endpoint - Rust

Function iroh::endpoint::make_server_config

source ·
pub fn make_server_config(
+make_server_config in iroh::endpoint - Rust

Function iroh::endpoint::make_server_config

source ·
pub fn make_server_config(
     secret_key: &SecretKey,
     alpn_protocols: Vec<Vec<u8>>,
     transport_config: Arc<TransportConfig>,
diff --git a/pr/3024/docs/iroh/endpoint/index.html b/pr/3024/docs/iroh/endpoint/index.html
index ddd9cdee22..4a9b76ab9d 100644
--- a/pr/3024/docs/iroh/endpoint/index.html
+++ b/pr/3024/docs/iroh/endpoint/index.html
@@ -1,4 +1,4 @@
-iroh::endpoint - Rust

Module iroh::endpoint

source ·
Expand description

The Endpoint allows establishing connections to other iroh nodes.

+iroh::endpoint - Rust

Module iroh::endpoint

source ·
Expand description

The Endpoint allows establishing connections to other iroh nodes.

The Endpoint is the main API interface to manage a local iroh node. It allows connecting to and accepting connections from other nodes. See the module docs for more details on how iroh connections work.

@@ -10,4 +10,4 @@ more details on how iroh connections work.

Structs§

Enums§

Constants§

Traits§

Functions§

\ No newline at end of file +was discovered.
  • Errors that arise while monitoring for a send stream stop from the peer
  • Errors that arise from writing to a stream
  • Constants§

    Traits§

    Functions§

    \ No newline at end of file diff --git a/pr/3024/docs/iroh/endpoint/struct.Accept.html b/pr/3024/docs/iroh/endpoint/struct.Accept.html index 579b556429..5c233c09dc 100644 --- a/pr/3024/docs/iroh/endpoint/struct.Accept.html +++ b/pr/3024/docs/iroh/endpoint/struct.Accept.html @@ -1,6 +1,6 @@ -Accept in iroh::endpoint - Rust

    Struct iroh::endpoint::Accept

    source ·
    pub struct Accept<'a> { /* private fields */ }
    Expand description

    Future produced by Endpoint::accept.

    -

    Trait Implementations§

    source§

    impl<'a> Debug for Accept<'a>

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Future for Accept<'_>

    §

    type Output = Option<Incoming>

    The type of value produced on completion.
    source§

    fn poll(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Self::Output>

    Attempt to resolve the future to a final value, registering -the current task for wakeup if the value is not yet available. Read more
    source§

    impl<'pin, 'a> Unpin for Accept<'a>
    where +Accept in iroh::endpoint - Rust

    Struct iroh::endpoint::Accept

    source ·
    pub struct Accept<'a> { /* private fields */ }
    Expand description

    Future produced by Endpoint::accept.

    +

    Trait Implementations§

    source§

    impl<'a> Debug for Accept<'a>

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Future for Accept<'_>

    §

    type Output = Option<Incoming>

    The type of value produced on completion.
    source§

    fn poll(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Self::Output>

    Attempt to resolve the future to a final value, registering +the current task for wakeup if the value is not yet available. Read more
    source§

    impl<'pin, 'a> Unpin for Accept<'a>
    where PinnedFieldsOf<__Accept<'pin, 'a>>: Unpin,

    Auto Trait Implementations§

    §

    impl<'a> !Freeze for Accept<'a>

    §

    impl<'a> !RefUnwindSafe for Accept<'a>

    §

    impl<'a> Send for Accept<'a>

    §

    impl<'a> Sync for Accept<'a>

    §

    impl<'a> !UnwindSafe for Accept<'a>

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where @@ -18,19 +18,19 @@ the current task for wakeup if the value is not yet available. Sized, F: Future<Output = Self::Output>,

    Returns the result of self or other future, preferring self if both are ready. Read more
    §

    fn race<F>(self, other: F) -> Race<Self, F>
    where Self: Sized, - F: Future<Output = Self::Output>,

    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Boxes the future and changes its type to dyn Future + 'a. Read more

    §

    impl<F> FutureExt for F
    where + F: Future<Output = Self::Output>,

    Available on crate features std and race only.
    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F> FutureExt for F
    where F: Future + ?Sized,

    §

    fn poll(&mut self, cx: &mut Context<'_>) -> Poll<Self::Output>
    where Self: Unpin,

    A convenience for calling Future::poll() on !Unpin types.
    §

    fn or<F>(self, other: F) -> Or<Self, F>
    where Self: Sized, F: Future<Output = Self::Output>,

    Returns the result of self or other future, preferring self if both are ready. Read more
    §

    fn race<F>(self, other: F) -> Race<Self, F>
    where Self: Sized, - F: Future<Output = Self::Output>,

    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F1> FutureExt for F1
    where + F: Future<Output = Self::Output>,

    Available on crate feature std only.
    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F1> FutureExt for F1
    where F1: Future,

    §

    fn join<F2>(self, other: F2) -> Join2<F1, <F2 as IntoFuture>::IntoFuture>
    where F1: Future, F2: IntoFuture,

    Wait for both futures to complete.
    §

    fn race<T, S2>(self, other: S2) -> Race2<T, F1, <S2 as IntoFuture>::IntoFuture>
    where @@ -70,14 +70,14 @@ completed. This method can be used to turn any Future into a FusedFuture. Read more

    §

    fn inspect<F>(self, f: F) -> Inspect<Self, F>
    where F: FnOnce(&Self::Output), Self: Sized,

    Do something with the output of a future before passing it on. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches unwinding panics while polling the future. Read more
    §

    fn shared(self) -> Shared<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches unwinding panics while polling the future. Read more
    §

    fn shared(self) -> Shared<Self>
    where Self: Sized, - Self::Output: Clone,

    Create a cloneable handle to this future where all handles will resolve + Self::Output: Clone,

    Available on crate feature std only.
    Create a cloneable handle to this future where all handles will resolve to the same result. Read more
    §

    fn remote_handle(self) -> (Remote<Self>, RemoteHandle<Self::Output>)
    where - Self: Sized,

    Turn this future into a future that yields () on completion and sends + Self: Sized,

    Available on crate features channel and std only.
    Turn this future into a future that yields () on completion and sends its output to another future on a separate task. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Wrap the future in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Wrap the future in a Box, pinning it. Read more
    §

    fn unit_error(self) -> UnitError<Self>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Wrap the future in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Wrap the future in a Box, pinning it. Read more
    §

    fn unit_error(self) -> UnitError<Self>
    where Self: Sized,

    §

    fn never_error(self) -> NeverError<Self>
    where Self: Sized,

    Turns a Future<Output = T> into a diff --git a/pr/3024/docs/iroh/endpoint/struct.AcceptBi.html b/pr/3024/docs/iroh/endpoint/struct.AcceptBi.html index 964d0f026f..2a7e387d40 100644 --- a/pr/3024/docs/iroh/endpoint/struct.AcceptBi.html +++ b/pr/3024/docs/iroh/endpoint/struct.AcceptBi.html @@ -21,19 +21,19 @@ the current task for wakeup if the value is not yet available. Sized, F: Future<Output = Self::Output>,
    Returns the result of self or other future, preferring self if both are ready. Read more
    §

    fn race<F>(self, other: F) -> Race<Self, F>
    where Self: Sized, - F: Future<Output = Self::Output>,

    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F> FutureExt for F
    where + F: Future<Output = Self::Output>,

    Available on crate features std and race only.
    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F> FutureExt for F
    where F: Future + ?Sized,

    §

    fn poll(&mut self, cx: &mut Context<'_>) -> Poll<Self::Output>
    where Self: Unpin,

    A convenience for calling Future::poll() on !Unpin types.
    §

    fn or<F>(self, other: F) -> Or<Self, F>
    where Self: Sized, F: Future<Output = Self::Output>,

    Returns the result of self or other future, preferring self if both are ready. Read more
    §

    fn race<F>(self, other: F) -> Race<Self, F>
    where Self: Sized, - F: Future<Output = Self::Output>,

    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F1> FutureExt for F1
    where + F: Future<Output = Self::Output>,

    Available on crate feature std only.
    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F1> FutureExt for F1
    where F1: Future,

    §

    fn join<F2>(self, other: F2) -> Join2<F1, <F2 as IntoFuture>::IntoFuture>
    where F1: Future, F2: IntoFuture,

    Wait for both futures to complete.
    §

    fn race<T, S2>(self, other: S2) -> Race2<T, F1, <S2 as IntoFuture>::IntoFuture>
    where @@ -73,14 +73,14 @@ completed. This method can be used to turn any Future into a FusedFuture. Read more

    §

    fn inspect<F>(self, f: F) -> Inspect<Self, F>
    where F: FnOnce(&Self::Output), Self: Sized,

    Do something with the output of a future before passing it on. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches unwinding panics while polling the future. Read more
    §

    fn shared(self) -> Shared<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches unwinding panics while polling the future. Read more
    §

    fn shared(self) -> Shared<Self>
    where Self: Sized, - Self::Output: Clone,

    Create a cloneable handle to this future where all handles will resolve + Self::Output: Clone,
    Available on crate feature std only.
    Create a cloneable handle to this future where all handles will resolve to the same result. Read more
    §

    fn remote_handle(self) -> (Remote<Self>, RemoteHandle<Self::Output>)
    where - Self: Sized,

    Turn this future into a future that yields () on completion and sends + Self: Sized,
    Available on crate features channel and std only.
    Turn this future into a future that yields () on completion and sends its output to another future on a separate task. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Wrap the future in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Wrap the future in a Box, pinning it. Read more
    §

    fn unit_error(self) -> UnitError<Self>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Wrap the future in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Wrap the future in a Box, pinning it. Read more
    §

    fn unit_error(self) -> UnitError<Self>
    where Self: Sized,

    §

    fn never_error(self) -> NeverError<Self>
    where Self: Sized,

    Turns a Future<Output = T> into a @@ -103,7 +103,7 @@ the future is ready after the first call to Future::poll. Read m F: Future<Output = Result<T, E>> + ?Sized,
    §

    type Ok = T

    §

    type Err = E

    §

    impl<Fut> TryFutureExt for Fut
    where Fut: TryFuture + ?Sized,

    §

    fn flatten_sink<Item>(self) -> FlattenSink<Self, Self::Ok>
    where Self::Ok: Sink<Item, Error = Self::Error>, - Self: Sized,

    Flattens the execution of this future when the successful result of this + Self: Sized,
    Available on crate feature sink only.
    Flattens the execution of this future when the successful result of this future is a [Sink]. Read more
    §

    fn map_ok<T, F>(self, f: F) -> MapOk<Self, F>
    where F: FnOnce(Self::Ok) -> T, Self: Sized,

    Maps this future’s success value to a different value. Read more
    §

    fn map_ok_or_else<T, E, F>(self, e: E, f: F) -> MapOkOrElse<Self, F, E>
    where diff --git a/pr/3024/docs/iroh/endpoint/struct.AcceptUni.html b/pr/3024/docs/iroh/endpoint/struct.AcceptUni.html index 059251bc7f..953ccf7e7c 100644 --- a/pr/3024/docs/iroh/endpoint/struct.AcceptUni.html +++ b/pr/3024/docs/iroh/endpoint/struct.AcceptUni.html @@ -21,19 +21,19 @@ the current task for wakeup if the value is not yet available. Sized, F: Future<Output = Self::Output>,

    Returns the result of self or other future, preferring self if both are ready. Read more
    §

    fn race<F>(self, other: F) -> Race<Self, F>
    where Self: Sized, - F: Future<Output = Self::Output>,

    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F> FutureExt for F
    where + F: Future<Output = Self::Output>,

    Available on crate features std and race only.
    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F> FutureExt for F
    where F: Future + ?Sized,

    §

    fn poll(&mut self, cx: &mut Context<'_>) -> Poll<Self::Output>
    where Self: Unpin,

    A convenience for calling Future::poll() on !Unpin types.
    §

    fn or<F>(self, other: F) -> Or<Self, F>
    where Self: Sized, F: Future<Output = Self::Output>,

    Returns the result of self or other future, preferring self if both are ready. Read more
    §

    fn race<F>(self, other: F) -> Race<Self, F>
    where Self: Sized, - F: Future<Output = Self::Output>,

    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F1> FutureExt for F1
    where + F: Future<Output = Self::Output>,

    Available on crate feature std only.
    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F1> FutureExt for F1
    where F1: Future,

    §

    fn join<F2>(self, other: F2) -> Join2<F1, <F2 as IntoFuture>::IntoFuture>
    where F1: Future, F2: IntoFuture,

    Wait for both futures to complete.
    §

    fn race<T, S2>(self, other: S2) -> Race2<T, F1, <S2 as IntoFuture>::IntoFuture>
    where @@ -73,14 +73,14 @@ completed. This method can be used to turn any Future into a FusedFuture. Read more

    §

    fn inspect<F>(self, f: F) -> Inspect<Self, F>
    where F: FnOnce(&Self::Output), Self: Sized,

    Do something with the output of a future before passing it on. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches unwinding panics while polling the future. Read more
    §

    fn shared(self) -> Shared<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches unwinding panics while polling the future. Read more
    §

    fn shared(self) -> Shared<Self>
    where Self: Sized, - Self::Output: Clone,

    Create a cloneable handle to this future where all handles will resolve + Self::Output: Clone,
    Available on crate feature std only.
    Create a cloneable handle to this future where all handles will resolve to the same result. Read more
    §

    fn remote_handle(self) -> (Remote<Self>, RemoteHandle<Self::Output>)
    where - Self: Sized,

    Turn this future into a future that yields () on completion and sends + Self: Sized,
    Available on crate features channel and std only.
    Turn this future into a future that yields () on completion and sends its output to another future on a separate task. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Wrap the future in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Wrap the future in a Box, pinning it. Read more
    §

    fn unit_error(self) -> UnitError<Self>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Wrap the future in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Wrap the future in a Box, pinning it. Read more
    §

    fn unit_error(self) -> UnitError<Self>
    where Self: Sized,

    §

    fn never_error(self) -> NeverError<Self>
    where Self: Sized,

    Turns a Future<Output = T> into a @@ -103,7 +103,7 @@ the future is ready after the first call to Future::poll. Read m F: Future<Output = Result<T, E>> + ?Sized,
    §

    type Ok = T

    §

    type Err = E

    §

    impl<Fut> TryFutureExt for Fut
    where Fut: TryFuture + ?Sized,

    §

    fn flatten_sink<Item>(self) -> FlattenSink<Self, Self::Ok>
    where Self::Ok: Sink<Item, Error = Self::Error>, - Self: Sized,

    Flattens the execution of this future when the successful result of this + Self: Sized,
    Available on crate feature sink only.
    Flattens the execution of this future when the successful result of this future is a [Sink]. Read more
    §

    fn map_ok<T, F>(self, f: F) -> MapOk<Self, F>
    where F: FnOnce(Self::Ok) -> T, Self: Sized,

    Maps this future’s success value to a different value. Read more
    §

    fn map_ok_or_else<T, E, F>(self, e: E, f: F) -> MapOkOrElse<Self, F, E>
    where diff --git a/pr/3024/docs/iroh/endpoint/struct.Builder.html b/pr/3024/docs/iroh/endpoint/struct.Builder.html index c3b14bb0b4..4615abdc8d 100644 --- a/pr/3024/docs/iroh/endpoint/struct.Builder.html +++ b/pr/3024/docs/iroh/endpoint/struct.Builder.html @@ -1,24 +1,24 @@ -Builder in iroh::endpoint - Rust

    Struct iroh::endpoint::Builder

    source ·
    pub struct Builder { /* private fields */ }
    Expand description

    Builder for Endpoint.

    +Builder in iroh::endpoint - Rust

    Struct iroh::endpoint::Builder

    source ·
    pub struct Builder { /* private fields */ }
    Expand description

    Builder for Endpoint.

    By default the endpoint will generate a new random SecretKey, which will result in a new NodeId.

    To create the Endpoint call Builder::bind.

    -

    Implementations§

    source§

    impl Builder

    source

    pub async fn bind(self) -> Result<Endpoint>

    Binds the magic endpoint.

    -
    source

    pub fn bind_addr_v4(self, addr: SocketAddrV4) -> Self

    Sets the IPv4 bind address.

    +

    Implementations§

    source§

    impl Builder

    source

    pub async fn bind(self) -> Result<Endpoint>

    Binds the magic endpoint.

    +
    source

    pub fn bind_addr_v4(self, addr: SocketAddrV4) -> Self

    Sets the IPv4 bind address.

    Setting the port to 0 will use a random port. If the port specified is already in use, it will fallback to choosing a random port.

    By default will use 0.0.0.0:0 to bind to.

    -
    source

    pub fn bind_addr_v6(self, addr: SocketAddrV6) -> Self

    Sets the IPv6 bind address.

    +
    source

    pub fn bind_addr_v6(self, addr: SocketAddrV6) -> Self

    Sets the IPv6 bind address.

    Setting the port to 0 will use a random port. If the port specified is already in use, it will fallback to choosing a random port.

    By default will use [::]:0 to bind to.

    -
    source

    pub fn secret_key(self, secret_key: SecretKey) -> Self

    Sets a secret key to authenticate with other peers.

    +
    source

    pub fn secret_key(self, secret_key: SecretKey) -> Self

    Sets a secret key to authenticate with other peers.

    This secret key’s public key will be the PublicKey of this endpoint and thus also its NodeId

    If not set, a new secret key will be generated.

    -
    source

    pub fn alpns(self, alpn_protocols: Vec<Vec<u8>>) -> Self

    Sets the ALPN protocols that this endpoint will accept on incoming connections.

    +
    source

    pub fn alpns(self, alpn_protocols: Vec<Vec<u8>>) -> Self

    Sets the ALPN protocols that this endpoint will accept on incoming connections.

    Not setting this will still allow creating connections, but to accept incoming connections the ALPN must be set.

    -
    source

    pub fn relay_mode(self, relay_mode: RelayMode) -> Self

    Sets the relay servers to assist in establishing connectivity.

    +
    source

    pub fn relay_mode(self, relay_mode: RelayMode) -> Self

    Sets the relay servers to assist in establishing connectivity.

    Relay servers are used to establish initial connection with another iroh node. They also perform various functions related to hole punching, see the crate docs for more details.

    @@ -26,15 +26,15 @@ for more details.

    When using RelayMode::Custom, the provided relay_map must contain at least one configured relay node. If an invalid RelayMap is provided bind will result in an error.

    -
    source

    pub fn clear_discovery(self) -> Self

    Removes all discovery services from the builder.

    -
    source

    pub fn discovery(self, discovery: Box<dyn Discovery>) -> Self

    Optionally sets a discovery mechanism for this endpoint.

    +
    source

    pub fn clear_discovery(self) -> Self

    Removes all discovery services from the builder.

    +
    source

    pub fn discovery(self, discovery: Box<dyn Discovery>) -> Self

    Optionally sets a discovery mechanism for this endpoint.

    If you want to combine multiple discovery services, you can use Builder::add_discovery instead. This will internally create a crate::discovery::ConcurrentDiscovery.

    If no discovery service is set, connecting to a node without providing its direct addresses or relay URLs will fail.

    See the documentation of the Discovery trait for details.

    -
    source

    pub fn add_discovery<F, D>(self, discovery: F) -> Self
    where +

    source

    pub fn add_discovery<F, D>(self, discovery: F) -> Self
    where F: FnOnce(&SecretKey) -> Option<D> + Send + Sync + 'static, D: Discovery + 'static,

    Adds a discovery mechanism for this endpoint.

    The function discovery @@ -47,7 +47,7 @@ to use this secret key to sign the information.

    direct addresses or relay URLs will fail.

    To clear all discovery services, use Builder::clear_discovery.

    See the documentation of the Discovery trait for details.

    -
    source

    pub fn discovery_n0(self) -> Self

    Configures the endpoint to use the default n0 DNS discovery service.

    +
    source

    pub fn discovery_n0(self) -> Self

    Configures the endpoint to use the default n0 DNS discovery service.

    The default discovery service publishes to and resolves from the n0.computer dns server iroh.link.

    This is equivalent to adding both a crate::discovery::pkarr::PkarrPublisher @@ -56,45 +56,45 @@ n0.computer dns server.

    This will by default use N0_DNS_PKARR_RELAY_PROD. When in tests, or when the test-utils feature is enabled, this will use the N0_DNS_PKARR_RELAY_STAGING.

    -
    source

    pub fn discovery_dht(self) -> Self

    Available on crate feature discovery-pkarr-dht only.

    Configures the endpoint to also use the mainline DHT with default settings.

    +
    source

    pub fn discovery_dht(self) -> Self

    Available on crate feature discovery-pkarr-dht only.

    Configures the endpoint to also use the mainline DHT with default settings.

    This is equivalent to adding a crate::discovery::pkarr::dht::DhtDiscovery with default settings. Note that DhtDiscovery has various more advanced configuration options. If you need any of those, you should manually create a DhtDiscovery and add it with Builder::add_discovery.

    -
    source

    pub fn discovery_local_network(self) -> Self

    Available on crate feature discovery-local-network only.

    Configures the endpoint to also use local network discovery.

    +
    source

    pub fn discovery_local_network(self) -> Self

    Available on crate feature discovery-local-network only.

    Configures the endpoint to also use local network discovery.

    This is equivalent to adding a crate::discovery::local_swarm_discovery::LocalSwarmDiscovery with default settings. Note that LocalSwarmDiscovery has various more advanced configuration options. If you need any of those, you should manually create a LocalSwarmDiscovery and add it with Builder::add_discovery.

    -
    source

    pub fn known_nodes(self, nodes: Vec<NodeAddr>) -> Self

    Optionally set a list of known nodes.

    -
    source

    pub fn transport_config(self, transport_config: TransportConfig) -> Self

    Sets a custom quinn::TransportConfig for this endpoint.

    +
    source

    pub fn known_nodes(self, nodes: Vec<NodeAddr>) -> Self

    Optionally set a list of known nodes.

    +
    source

    pub fn transport_config(self, transport_config: TransportConfig) -> Self

    Sets a custom quinn::TransportConfig for this endpoint.

    The transport config contains parameters governing the QUIC state machine.

    If unset, the default config is used. Default values should be suitable for most internet applications. Applications protocols which forbid remotely-initiated streams should set max_concurrent_bidi_streams and max_concurrent_uni_streams to zero.

    -
    source

    pub fn dns_resolver(self, dns_resolver: DnsResolver) -> Self

    Optionally sets a custom DNS resolver to use for this endpoint.

    +
    source

    pub fn dns_resolver(self, dns_resolver: DnsResolver) -> Self

    Optionally sets a custom DNS resolver to use for this endpoint.

    The DNS resolver is used to resolve relay hostnames, and node addresses if crate::discovery::dns::DnsDiscovery is configured.

    By default, all endpoints share a DNS resolver, which is configured to use the host system’s DNS configuration. You can pass a custom instance of DnsResolver here to use a differently configured DNS resolver for this endpoint.

    -
    source

    pub fn proxy_url(self, url: Url) -> Self

    Sets an explicit proxy url to proxy all HTTP(S) traffic through.

    -
    source

    pub fn proxy_from_env(self) -> Self

    Sets the proxy url from the environment, in this order:

    +
    source

    pub fn proxy_url(self, url: Url) -> Self

    Sets an explicit proxy url to proxy all HTTP(S) traffic through.

    +
    source

    pub fn proxy_from_env(self) -> Self

    Sets the proxy url from the environment, in this order:

    • HTTP_PROXY
    • http_proxy
    • HTTPS_PROXY
    • https_proxy
    -
    source

    pub fn keylog(self, keylog: bool) -> Self

    Enables saving the TLS pre-master key for connections.

    +
    source

    pub fn keylog(self, keylog: bool) -> Self

    Enables saving the TLS pre-master key for connections.

    This key should normally remain secret but can be useful to debug networking issues by decrypting captured traffic.

    If keylog is true then setting the SSLKEYLOGFILE environment variable to a filename will result in this file being used to log the TLS pre-master keys.

    -
    source

    pub fn insecure_skip_relay_cert_verify(self, skip_verify: bool) -> Self

    Available on test or crate feature test-utils only.

    Skip verification of SSL certificates from relay servers

    +
    source

    pub fn insecure_skip_relay_cert_verify(self, skip_verify: bool) -> Self

    Available on crate feature test-utils only.

    Skip verification of SSL certificates from relay servers

    May only be used in tests.

    -

    Trait Implementations§

    source§

    impl Debug for Builder

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Default for Builder

    source§

    fn default() -> Self

    Returns the “default value” for a type. Read more

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where +

    Trait Implementations§

    source§

    impl Debug for Builder

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Default for Builder

    source§

    fn default() -> Self

    Returns the “default value” for a type. Read more

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/iroh/endpoint/struct.Bytes.html b/pr/3024/docs/iroh/endpoint/struct.Bytes.html index fbc549e858..532232f90a 100644 --- a/pr/3024/docs/iroh/endpoint/struct.Bytes.html +++ b/pr/3024/docs/iroh/endpoint/struct.Bytes.html @@ -63,14 +63,14 @@ v v v v ┌─────┬─────┬───────────┬───────────────┬─────┐ │ Arc │ │ │ │ │ └─────┴─────┴───────────┴───────────────┴─────┘ -

    Implementations§

    §

    impl Bytes

    pub const fn new() -> Bytes

    Creates a new empty Bytes.

    +

    Implementations§

    §

    impl Bytes

    pub const fn new() -> Bytes

    Available on non-loom only.

    Creates a new empty Bytes.

    This will not allocate and the returned Bytes handle will be empty.

    §Examples
    use bytes::Bytes;
     
     let b = Bytes::new();
     assert_eq!(&b[..], b"");
    -

    pub const fn from_static(bytes: &'static [u8]) -> Bytes

    Creates a new Bytes from a static slice.

    +

    pub const fn from_static(bytes: &'static [u8]) -> Bytes

    Available on non-loom only.

    Creates a new Bytes from a static slice.

    The returned Bytes will point directly to the static slice. There is no allocating or copying.

    §Examples
    @@ -1257,25 +1257,25 @@ code in the form of a C-string literal (c"...").

    let expected = stringify!(c"\xFErris the 🦀\u{7}"); assert_eq!(lit, expected); }
    -
    1.23.0 · source

    pub fn to_ascii_uppercase(&self) -> Vec<u8> ⓘ

    Returns a vector containing a copy of this slice where each byte +

    1.23.0 · source

    pub fn to_ascii_uppercase(&self) -> Vec<u8> ⓘ

    Available on non-no_global_oom_handling only.

    Returns a vector containing a copy of this slice where each byte is mapped to its ASCII upper case equivalent.

    ASCII letters ‘a’ to ‘z’ are mapped to ‘A’ to ‘Z’, but non-ASCII letters are unchanged.

    To uppercase the value in-place, use make_ascii_uppercase.

    -
    1.23.0 · source

    pub fn to_ascii_lowercase(&self) -> Vec<u8> ⓘ

    Returns a vector containing a copy of this slice where each byte +

    1.23.0 · source

    pub fn to_ascii_lowercase(&self) -> Vec<u8> ⓘ

    Available on non-no_global_oom_handling only.

    Returns a vector containing a copy of this slice where each byte is mapped to its ASCII lower case equivalent.

    ASCII letters ‘A’ to ‘Z’ are mapped to ‘a’ to ‘z’, but non-ASCII letters are unchanged.

    To lowercase the value in-place, use make_ascii_lowercase.

    1.0.0 · source

    pub fn to_vec(&self) -> Vec<T>
    where - T: Clone,

    Copies self into a new Vec.

    + T: Clone,

    Available on non-no_global_oom_handling only.

    Copies self into a new Vec.

    §Examples
    let s = [10, 40, 30];
     let x = s.to_vec();
     // Here, `s` and `x` can be modified independently.
    source

    pub fn to_vec_in<A>(&self, alloc: A) -> Vec<T, A>
    where A: Allocator, - T: Clone,

    🔬This is a nightly-only experimental API. (allocator_api)

    Copies self into a new Vec with an allocator.

    + T: Clone,
    🔬This is a nightly-only experimental API. (allocator_api)
    Available on non-no_global_oom_handling only.

    Copies self into a new Vec with an allocator.

    §Examples
    #![feature(allocator_api)]
     
    @@ -1285,7 +1285,7 @@ but non-ASCII letters are unchanged.

    let x = s.to_vec_in(System); // Here, `s` and `x` can be modified independently.
    1.40.0 · source

    pub fn repeat(&self, n: usize) -> Vec<T>
    where - T: Copy,

    Creates a vector by copying a slice n times.

    + T: Copy,
    Available on non-no_global_oom_handling only.

    Creates a vector by copying a slice n times.

    §Panics

    This function will panic if the capacity would overflow.

    §Examples
    @@ -1325,7 +1325,7 @@ given separator between each.

    the buffer. Read more
    §

    fn chunk(&self) -> &[u8] ⓘ

    Returns a slice starting at the current position and of length between 0 and Buf::remaining(). Note that this can return a shorter slice (this allows non-continuous internal representation). Read more
    §

    fn advance(&mut self, cnt: usize)

    Advance the internal cursor of the Buf Read more
    §

    fn copy_to_bytes(&mut self, len: usize) -> Bytes

    Consumes len bytes inside self and returns new instance of Bytes -with this data. Read more
    §

    fn chunks_vectored<'a>(&'a self, dst: &mut [IoSlice<'a>]) -> usize

    Fills dst with potentially multiple slices starting at self’s +with this data. Read more
    §

    fn chunks_vectored<'a>(&'a self, dst: &mut [IoSlice<'a>]) -> usize

    Available on crate feature std only.
    Fills dst with potentially multiple slices starting at self’s current position. Read more
    §

    fn has_remaining(&self) -> bool

    Returns true if there are any more bytes to consume Read more
    §

    fn copy_to_slice(&mut self, dst: &mut [u8])

    Copies bytes from self into dst. Read more
    §

    fn get_u8(&mut self) -> u8

    Gets an unsigned 8 bit integer from self. Read more
    §

    fn get_i8(&mut self) -> i8

    Gets a signed 8 bit integer from self. Read more
    §

    fn get_u16(&mut self) -> u16

    Gets an unsigned 16 bit integer from self in big-endian byte order. Read more
    §

    fn get_u16_le(&mut self) -> u16

    Gets an unsigned 16 bit integer from self in little-endian byte order. Read more
    §

    fn get_u16_ne(&mut self) -> u16

    Gets an unsigned 16 bit integer from self in native-endian byte order. Read more
    §

    fn get_i16(&mut self) -> i16

    Gets a signed 16 bit integer from self in big-endian byte order. Read more
    §

    fn get_i16_le(&mut self) -> i16

    Gets a signed 16 bit integer from self in little-endian byte order. Read more
    §

    fn get_i16_ne(&mut self) -> i16

    Gets a signed 16 bit integer from self in native-endian byte order. Read more
    §

    fn get_u32(&mut self) -> u32

    Gets an unsigned 32 bit integer from self in the big-endian byte order. Read more
    §

    fn get_u32_le(&mut self) -> u32

    Gets an unsigned 32 bit integer from self in the little-endian byte order. Read more
    §

    fn get_u32_ne(&mut self) -> u32

    Gets an unsigned 32 bit integer from self in native-endian byte order. Read more
    §

    fn get_i32(&mut self) -> i32

    Gets a signed 32 bit integer from self in big-endian byte order. Read more
    §

    fn get_i32_le(&mut self) -> i32

    Gets a signed 32 bit integer from self in little-endian byte order. Read more
    §

    fn get_i32_ne(&mut self) -> i32

    Gets a signed 32 bit integer from self in native-endian byte order. Read more
    §

    fn get_u64(&mut self) -> u64

    Gets an unsigned 64 bit integer from self in big-endian byte order. Read more
    §

    fn get_u64_le(&mut self) -> u64

    Gets an unsigned 64 bit integer from self in little-endian byte order. Read more
    §

    fn get_u64_ne(&mut self) -> u64

    Gets an unsigned 64 bit integer from self in native-endian byte order. Read more
    §

    fn get_i64(&mut self) -> i64

    Gets a signed 64 bit integer from self in big-endian byte order. Read more
    §

    fn get_i64_le(&mut self) -> i64

    Gets a signed 64 bit integer from self in little-endian byte order. Read more
    §

    fn get_i64_ne(&mut self) -> i64

    Gets a signed 64 bit integer from self in native-endian byte order. Read more
    §

    fn get_u128(&mut self) -> u128

    Gets an unsigned 128 bit integer from self in big-endian byte order. Read more
    §

    fn get_u128_le(&mut self) -> u128

    Gets an unsigned 128 bit integer from self in little-endian byte order. Read more
    §

    fn get_u128_ne(&mut self) -> u128

    Gets an unsigned 128 bit integer from self in native-endian byte order. Read more
    §

    fn get_i128(&mut self) -> i128

    Gets a signed 128 bit integer from self in big-endian byte order. Read more
    §

    fn get_i128_le(&mut self) -> i128

    Gets a signed 128 bit integer from self in little-endian byte order. Read more
    §

    fn get_i128_ne(&mut self) -> i128

    Gets a signed 128 bit integer from self in native-endian byte order. Read more
    §

    fn get_uint(&mut self, nbytes: usize) -> u64

    Gets an unsigned n-byte integer from self in big-endian byte order. Read more
    §

    fn get_uint_le(&mut self, nbytes: usize) -> u64

    Gets an unsigned n-byte integer from self in little-endian byte order. Read more
    §

    fn get_uint_ne(&mut self, nbytes: usize) -> u64

    Gets an unsigned n-byte integer from self in native-endian byte order. Read more
    §

    fn get_int(&mut self, nbytes: usize) -> i64

    Gets a signed n-byte integer from self in big-endian byte order. Read more
    §

    fn get_int_le(&mut self, nbytes: usize) -> i64

    Gets a signed n-byte integer from self in little-endian byte order. Read more
    §

    fn get_int_ne(&mut self, nbytes: usize) -> i64

    Gets a signed n-byte integer from self in native-endian byte order. Read more
    §

    fn get_f32(&mut self) -> f32

    Gets an IEEE754 single-precision (4 bytes) floating point number from self in big-endian byte order. Read more
    §

    fn get_f32_le(&mut self) -> f32

    Gets an IEEE754 single-precision (4 bytes) floating point number from self in little-endian byte order. Read more
    §

    fn get_f32_ne(&mut self) -> f32

    Gets an IEEE754 single-precision (4 bytes) floating point number from @@ -1336,7 +1336,7 @@ current position. Read more
    Sized,
    Creates an adaptor which will read at most limit bytes from self. Read more
    §

    fn chain<U>(self, next: U) -> Chain<Self, U>
    where U: Buf, Self: Sized,

    Creates an adaptor which will chain this buffer with another. Read more
    §

    fn reader(self) -> Reader<Self>
    where - Self: Sized,

    Creates an adaptor which implements the Read trait for self. Read more
    §

    impl Clone for Bytes

    §

    fn clone(&self) -> Bytes

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    §

    impl Debug for Bytes

    §

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    §

    impl Default for Bytes

    §

    fn default() -> Bytes

    Returns the “default value” for a type. Read more
    §

    impl Deref for Bytes

    §

    type Target = [u8]

    The resulting type after dereferencing.
    §

    fn deref(&self) -> &[u8] ⓘ

    Dereferences the value.
    §

    impl Drop for Bytes

    §

    fn drop(&mut self)

    Executes the destructor for this type. Read more
    §

    impl From<&'static [u8]> for Bytes

    §

    fn from(slice: &'static [u8]) -> Bytes

    Converts to this type from the input type.
    §

    impl From<&'static str> for Bytes

    §

    fn from(slice: &'static str) -> Bytes

    Converts to this type from the input type.
    §

    impl From<Box<[u8]>> for Bytes

    §

    fn from(slice: Box<[u8]>) -> Bytes

    Converts to this type from the input type.
    §

    impl From<ByteStr> for Bytes

    §

    fn from(src: ByteStr) -> Bytes

    Converts to this type from the input type.
    source§

    impl From<ByteStr> for Bytes

    source§

    fn from(src: ByteStr) -> Bytes

    Converts to this type from the input type.
    §

    impl From<Bytes> for Vec<u8>

    §

    fn from(bytes: Bytes) -> Vec<u8> ⓘ

    Converts to this type from the input type.
    §

    impl From<BytesMut> for Bytes

    §

    fn from(src: BytesMut) -> Bytes

    Converts to this type from the input type.
    §

    impl From<Custom> for Bytes

    §

    fn from(_: Custom) -> Bytes

    Converts to this type from the input type.
    source§

    impl From<Custom> for Bytes

    source§

    fn from(_: Custom) -> Bytes

    Converts to this type from the input type.
    §

    impl From<ReasonPhrase> for Bytes

    §

    fn from(reason: ReasonPhrase) -> Bytes

    Converts to this type from the input type.
    §

    impl From<String> for Bytes

    §

    fn from(s: String) -> Bytes

    Converts to this type from the input type.
    §

    impl From<Vec<u8>> for Bytes

    §

    fn from(vec: Vec<u8>) -> Bytes

    Converts to this type from the input type.
    §

    impl FromIterator<u8> for Bytes

    §

    fn from_iter<T>(into_iter: T) -> Bytes
    where + Self: Sized,

    Available on crate feature std only.
    Creates an adaptor which implements the Read trait for self. Read more
    §

    impl Clone for Bytes

    §

    fn clone(&self) -> Bytes

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    §

    impl Debug for Bytes

    §

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    §

    impl Default for Bytes

    §

    fn default() -> Bytes

    Returns the “default value” for a type. Read more
    §

    impl Deref for Bytes

    §

    type Target = [u8]

    The resulting type after dereferencing.
    §

    fn deref(&self) -> &[u8] ⓘ

    Dereferences the value.
    §

    impl Drop for Bytes

    §

    fn drop(&mut self)

    Executes the destructor for this type. Read more
    §

    impl From<&'static [u8]> for Bytes

    §

    fn from(slice: &'static [u8]) -> Bytes

    Converts to this type from the input type.
    §

    impl From<&'static str> for Bytes

    §

    fn from(slice: &'static str) -> Bytes

    Converts to this type from the input type.
    §

    impl From<Box<[u8]>> for Bytes

    §

    fn from(slice: Box<[u8]>) -> Bytes

    Converts to this type from the input type.
    §

    impl From<ByteStr> for Bytes

    §

    fn from(src: ByteStr) -> Bytes

    Converts to this type from the input type.
    source§

    impl From<ByteStr> for Bytes

    source§

    fn from(src: ByteStr) -> Bytes

    Converts to this type from the input type.
    §

    impl From<Bytes> for Vec<u8>

    §

    fn from(bytes: Bytes) -> Vec<u8> ⓘ

    Converts to this type from the input type.
    §

    impl From<BytesMut> for Bytes

    §

    fn from(src: BytesMut) -> Bytes

    Converts to this type from the input type.
    §

    impl From<Custom> for Bytes

    §

    fn from(_: Custom) -> Bytes

    Converts to this type from the input type.
    source§

    impl From<Custom> for Bytes

    source§

    fn from(_: Custom) -> Bytes

    Converts to this type from the input type.
    §

    impl From<ReasonPhrase> for Bytes

    §

    fn from(reason: ReasonPhrase) -> Bytes

    Converts to this type from the input type.
    §

    impl From<String> for Bytes

    §

    fn from(s: String) -> Bytes

    Converts to this type from the input type.
    §

    impl From<Vec<u8>> for Bytes

    §

    fn from(vec: Vec<u8>) -> Bytes

    Converts to this type from the input type.
    §

    impl FromIterator<u8> for Bytes

    §

    fn from_iter<T>(into_iter: T) -> Bytes
    where T: IntoIterator<Item = u8>,

    Creates a value from an iterator. Read more
    §

    impl<S> FromRequest<S> for Bytes
    where S: Send + Sync,

    §

    type Rejection = BytesRejection

    If the extractor fails it’ll use this “rejection” type. A rejection is a kind of error that can be converted into a response.
    §

    fn from_request<'life0, 'async_trait>( @@ -1429,7 +1429,7 @@ operator.
    §

    fn with_state(self, state: S) -> HandlerService<Self, T, S>

    Convert the handler into a [Service] by providing the state

    §

    impl<H, T> HandlerWithoutStateExt<T> for H
    where H: Handler<T, ()>,

    §

    fn into_service(self) -> HandlerService<H, T, ()>

    Convert the handler into a [Service] and no state.
    §

    fn into_make_service(self) -> IntoMakeService<HandlerService<H, T, ()>>

    Convert the handler into a MakeService and no state. Read more
    §

    fn into_make_service_with_connect_info<C>( self -) -> IntoMakeServiceWithConnectInfo<HandlerService<H, T, ()>, C>

    Convert the handler into a MakeService which stores information +) -> IntoMakeServiceWithConnectInfo<HandlerService<H, T, ()>, C>
    Available on crate feature tokio only.
    Convert the handler into a MakeService which stores information about the incoming connection and has no state. Read more
    §

    impl<T> Instrument for T

    §

    fn instrument(self, span: Span) -> Instrumented<Self>

    Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
    §

    fn in_current_span(self) -> Instrumented<Self>

    Instruments this type with the current Span, returning an Instrumented wrapper. Read more
    source§

    impl<T, U> Into<U> for T
    where diff --git a/pr/3024/docs/iroh/endpoint/struct.Connecting.html b/pr/3024/docs/iroh/endpoint/struct.Connecting.html index 5bca5699a4..1180cf1183 100644 --- a/pr/3024/docs/iroh/endpoint/struct.Connecting.html +++ b/pr/3024/docs/iroh/endpoint/struct.Connecting.html @@ -1,11 +1,11 @@ -Connecting in iroh::endpoint - Rust

    Struct iroh::endpoint::Connecting

    source ·
    pub struct Connecting { /* private fields */ }
    Expand description

    In-progress connection attempt future

    -

    Implementations§

    source§

    impl Connecting

    source

    pub fn into_0rtt(self) -> Result<(Connection, ZeroRttAccepted), Self>

    Convert into a 0-RTT or 0.5-RTT connection at the cost of weakened security.

    -
    source

    pub async fn handshake_data(&mut self) -> Result<Box<dyn Any>, ConnectionError>

    Parameters negotiated during the handshake

    -
    source

    pub fn local_ip(&self) -> Option<IpAddr>

    The local IP address which was used when the peer established the connection.

    -
    source

    pub fn remote_address(&self) -> SocketAddr

    The peer’s UDP address.

    -
    source

    pub async fn alpn(&mut self) -> Result<Vec<u8>>

    Extracts the ALPN protocol from the peer’s handshake data.

    -

    Trait Implementations§

    source§

    impl Debug for Connecting

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Future for Connecting

    §

    type Output = Result<Connection, ConnectionError>

    The type of value produced on completion.
    source§

    fn poll(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Self::Output>

    Attempt to resolve the future to a final value, registering -the current task for wakeup if the value is not yet available. Read more
    source§

    impl<'pin> Unpin for Connecting
    where +Connecting in iroh::endpoint - Rust

    Struct iroh::endpoint::Connecting

    source ·
    pub struct Connecting { /* private fields */ }
    Expand description

    In-progress connection attempt future

    +

    Implementations§

    source§

    impl Connecting

    source

    pub fn into_0rtt(self) -> Result<(Connection, ZeroRttAccepted), Self>

    Convert into a 0-RTT or 0.5-RTT connection at the cost of weakened security.

    +
    source

    pub async fn handshake_data(&mut self) -> Result<Box<dyn Any>, ConnectionError>

    Parameters negotiated during the handshake

    +
    source

    pub fn local_ip(&self) -> Option<IpAddr>

    The local IP address which was used when the peer established the connection.

    +
    source

    pub fn remote_address(&self) -> SocketAddr

    The peer’s UDP address.

    +
    source

    pub async fn alpn(&mut self) -> Result<Vec<u8>>

    Extracts the ALPN protocol from the peer’s handshake data.

    +

    Trait Implementations§

    source§

    impl Debug for Connecting

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Future for Connecting

    §

    type Output = Result<Connection, ConnectionError>

    The type of value produced on completion.
    source§

    fn poll(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Self::Output>

    Attempt to resolve the future to a final value, registering +the current task for wakeup if the value is not yet available. Read more
    source§

    impl<'pin> Unpin for Connecting
    where PinnedFieldsOf<__Connecting<'pin>>: Unpin,

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where @@ -23,19 +23,19 @@ the current task for wakeup if the value is not yet available. Sized, F: Future<Output = Self::Output>,

    Returns the result of self or other future, preferring self if both are ready. Read more
    §

    fn race<F>(self, other: F) -> Race<Self, F>
    where Self: Sized, - F: Future<Output = Self::Output>,

    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Boxes the future and changes its type to dyn Future + 'a. Read more

    §

    impl<F> FutureExt for F
    where + F: Future<Output = Self::Output>,

    Available on crate features std and race only.
    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F> FutureExt for F
    where F: Future + ?Sized,

    §

    fn poll(&mut self, cx: &mut Context<'_>) -> Poll<Self::Output>
    where Self: Unpin,

    A convenience for calling Future::poll() on !Unpin types.
    §

    fn or<F>(self, other: F) -> Or<Self, F>
    where Self: Sized, F: Future<Output = Self::Output>,

    Returns the result of self or other future, preferring self if both are ready. Read more
    §

    fn race<F>(self, other: F) -> Race<Self, F>
    where Self: Sized, - F: Future<Output = Self::Output>,

    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F1> FutureExt for F1
    where + F: Future<Output = Self::Output>,

    Available on crate feature std only.
    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F1> FutureExt for F1
    where F1: Future,

    §

    fn join<F2>(self, other: F2) -> Join2<F1, <F2 as IntoFuture>::IntoFuture>
    where F1: Future, F2: IntoFuture,

    Wait for both futures to complete.
    §

    fn race<T, S2>(self, other: S2) -> Race2<T, F1, <S2 as IntoFuture>::IntoFuture>
    where @@ -75,14 +75,14 @@ completed. This method can be used to turn any Future into a FusedFuture. Read more

    §

    fn inspect<F>(self, f: F) -> Inspect<Self, F>
    where F: FnOnce(&Self::Output), Self: Sized,

    Do something with the output of a future before passing it on. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches unwinding panics while polling the future. Read more
    §

    fn shared(self) -> Shared<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches unwinding panics while polling the future. Read more
    §

    fn shared(self) -> Shared<Self>
    where Self: Sized, - Self::Output: Clone,

    Create a cloneable handle to this future where all handles will resolve + Self::Output: Clone,
    Available on crate feature std only.
    Create a cloneable handle to this future where all handles will resolve to the same result. Read more
    §

    fn remote_handle(self) -> (Remote<Self>, RemoteHandle<Self::Output>)
    where - Self: Sized,

    Turn this future into a future that yields () on completion and sends + Self: Sized,
    Available on crate features channel and std only.
    Turn this future into a future that yields () on completion and sends its output to another future on a separate task. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Wrap the future in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Wrap the future in a Box, pinning it. Read more
    §

    fn unit_error(self) -> UnitError<Self>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Wrap the future in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Wrap the future in a Box, pinning it. Read more
    §

    fn unit_error(self) -> UnitError<Self>
    where Self: Sized,

    §

    fn never_error(self) -> NeverError<Self>
    where Self: Sized,

    Turns a Future<Output = T> into a @@ -105,7 +105,7 @@ the future is ready after the first call to Future::poll. Read m F: Future<Output = Result<T, E>> + ?Sized,
    §

    type Ok = T

    §

    type Err = E

    §

    impl<Fut> TryFutureExt for Fut
    where Fut: TryFuture + ?Sized,

    §

    fn flatten_sink<Item>(self) -> FlattenSink<Self, Self::Ok>
    where Self::Ok: Sink<Item, Error = Self::Error>, - Self: Sized,

    Flattens the execution of this future when the successful result of this + Self: Sized,
    Available on crate feature sink only.
    Flattens the execution of this future when the successful result of this future is a [Sink]. Read more
    §

    fn map_ok<T, F>(self, f: F) -> MapOk<Self, F>
    where F: FnOnce(Self::Ok) -> T, Self: Sized,

    Maps this future’s success value to a different value. Read more
    §

    fn map_ok_or_else<T, E, F>(self, e: E, f: F) -> MapOkOrElse<Self, F, E>
    where diff --git a/pr/3024/docs/iroh/endpoint/struct.ConnectionTypeStream.html b/pr/3024/docs/iroh/endpoint/struct.ConnectionTypeStream.html index 2be4cab0ce..e16ad67bbb 100644 --- a/pr/3024/docs/iroh/endpoint/struct.ConnectionTypeStream.html +++ b/pr/3024/docs/iroh/endpoint/struct.ConnectionTypeStream.html @@ -116,9 +116,9 @@ available. Read more

    Sized, S: Stream<Item = Self::Item>,
    Merges with other stream, preferring items from self whenever both streams are ready. Read more
    §

    fn race<S>(self, other: S) -> Race<Self, S>
    where Self: Sized, - S: Stream<Item = Self::Item>,

    Merges with other stream, with no preference for either stream when both are ready. Read more
    §

    fn drain(&mut self) -> Drain<'_, Self>

    Yields all immediately available values from a stream. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the stream and changes its type to dyn Stream + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + 'a>>
    where - Self: Sized + 'a,

    Boxes the stream and changes its type to dyn Stream + 'a. Read more
    §

    impl<S> StreamExt for S
    where + S: Stream<Item = Self::Item>,

    Available on crate features std and race only.
    Merges with other stream, with no preference for either stream when both are ready. Read more
    §

    fn drain(&mut self) -> Drain<'_, Self>

    Yields all immediately available values from a stream. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the stream and changes its type to dyn Stream + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the stream and changes its type to dyn Stream + 'a. Read more
    §

    impl<S> StreamExt for S
    where S: Stream + ?Sized,

    §

    fn poll_next(&mut self, cx: &mut Context<'_>) -> Poll<Option<Self::Item>>
    where Self: Unpin,

    A convenience for calling [Stream::poll_next()] on !Unpin types.
    §

    fn next(&mut self) -> NextFuture<'_, Self>
    where Self: Unpin,

    Retrieves the next item in the stream. Read more
    §

    fn try_next<T, E>(&mut self) -> TryNextFuture<'_, Self>
    where @@ -198,9 +198,9 @@ available. Read more

    Sized, S: Stream<Item = Self::Item>,
    Merges with other stream, preferring items from self whenever both streams are ready. Read more
    §

    fn race<S>(self, other: S) -> Race<Self, S>
    where Self: Sized, - S: Stream<Item = Self::Item>,

    Merges with other stream, with no preference for either stream when both are ready. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the stream and changes its type to dyn Stream + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + 'a>>
    where - Self: Sized + 'a,

    Boxes the stream and changes its type to dyn Stream + 'a. Read more
    §

    impl<S1> StreamExt for S1
    where + S: Stream<Item = Self::Item>,

    Available on crate feature std only.
    Merges with other stream, with no preference for either stream when both are ready. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the stream and changes its type to dyn Stream + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the stream and changes its type to dyn Stream + 'a. Read more
    §

    impl<S1> StreamExt for S1
    where S1: Stream,

    §

    fn merge<T, S2>( self, other: S2 @@ -211,7 +211,7 @@ available. Read more

    §

    fn zip<T, S2>(self, other: S2) -> Zip2<S1, <S2 as IntoStream>::IntoStream>
    where S1: Stream<Item = T>, S2: IntoStream<Item = T>,

    ‘Zips up’ multiple streams into a single stream of pairs.
    §

    fn co(self) -> FromStream<Self>
    where - Self: Sized,

    Convert into a concurrent stream.
    §

    fn wait_until<D>( + Self: Sized,

    Available on crate feature alloc only.
    Convert into a concurrent stream.
    §

    fn wait_until<D>( self, deadline: D ) -> WaitUntil<Self, <D as IntoFuture>::IntoFuture>
    where @@ -264,14 +264,14 @@ first stream then all values from the second stream. Read more
    Read more

    §

    fn collect<T>(self) -> Collect<Self, T>
    where T: FromStream<Self::Item>, Self: Sized,

    Drain stream pushing all emitted values into a collection. Read more
    §

    fn timeout(self, duration: Duration) -> Timeout<Self>
    where - Self: Sized,

    Applies a per-item timeout to the passed stream. Read more
    §

    fn timeout_repeating(self, interval: Interval) -> TimeoutRepeating<Self>
    where - Self: Sized,

    Applies a per-item timeout to the passed stream. Read more
    §

    fn throttle(self, duration: Duration) -> Throttle<Self>
    where - Self: Sized,

    Slows down a stream by enforcing a delay between items. Read more
    §

    fn chunks_timeout( + Self: Sized,

    Available on crate feature time only.
    Applies a per-item timeout to the passed stream. Read more
    §

    fn timeout_repeating(self, interval: Interval) -> TimeoutRepeating<Self>
    where + Self: Sized,

    Available on crate feature time only.
    Applies a per-item timeout to the passed stream. Read more
    §

    fn throttle(self, duration: Duration) -> Throttle<Self>
    where + Self: Sized,

    Available on crate feature time only.
    Slows down a stream by enforcing a delay between items. Read more
    §

    fn chunks_timeout( self, max_size: usize, duration: Duration ) -> ChunksTimeout<Self>
    where - Self: Sized,

    Batches the items in the given stream using a maximum duration and size for each batch. Read more
    §

    fn peekable(self) -> Peekable<Self>
    where + Self: Sized,

    Available on crate feature time only.
    Batches the items in the given stream using a maximum duration and size for each batch. Read more
    §

    fn peekable(self) -> Peekable<Self>
    where Self: Sized,

    Turns the stream into a peekable stream, whose next element can be peeked at without being consumed. Read more
    §

    impl<T> StreamExt for T
    where T: Stream + ?Sized,

    §

    fn next(&mut self) -> Next<'_, Self>
    where @@ -323,7 +323,7 @@ collecting all the values into one final result. Read more

    Into<Option<usize>> ) -> FlattenUnorderedWithFlowController<Self, ()>
    where Self::Item: Stream + Unpin, - Self: Sized,
    Flattens a stream of streams into just one continuous stream. Polls + Self: Sized,
    Available on crate feature alloc only.
    Flattens a stream of streams into just one continuous stream. Polls inner streams produced by the base stream concurrently. Read more
    §

    fn flat_map<U, F>(self, f: F) -> FlatMap<Self, U, F>
    where F: FnMut(Self::Item) -> U, U: Stream, @@ -334,7 +334,7 @@ inner streams produced by the base stream concurrently. Read more
    where U: Stream + Unpin, F: FnMut(Self::Item) -> U, - Self: Sized,

    Maps a stream like [StreamExt::map] but flattens nested Streams + Self: Sized,
    Available on crate feature alloc only.
    Maps a stream like [StreamExt::map] but flattens nested Streams and polls them concurrently, yielding items in any order, as they made available. Read more
    §

    fn scan<S, B, Fut, F>(self, initial_state: S, f: F) -> Scan<Self, S, Fut, F>
    where F: FnMut(&mut S, Self::Item) -> Fut, @@ -361,7 +361,7 @@ closure for each element on the stream. Read more

    where F: FnMut(Self::Item) -> Fut, Fut: Future<Output = ()>, - Self: Sized,
    Runs this stream to completion, executing the provided asynchronous + Self: Sized,
    Available on crate feature alloc only.
    Runs this stream to completion, executing the provided asynchronous closure for each element on the stream concurrently as elements become available. Read more
    §

    fn take(self, n: usize) -> Take<Self>
    where Self: Sized,

    Creates a new stream of at most n items of the underlying stream. Read more
    §

    fn skip(self, n: usize) -> Skip<Self>
    where @@ -369,24 +369,24 @@ available. Read more

    Sized,
    Fuse a stream such that poll_next will never again be called once it has finished. This method can be used to turn any Stream into a FusedStream. Read more
    §

    fn by_ref(&mut self) -> &mut Self

    Borrows a stream, rather than consuming it. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches unwinding panics while polling the stream. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Wrap the stream in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + 'a>>
    where - Self: Sized + 'a,

    Wrap the stream in a Box, pinning it. Read more
    §

    fn buffered(self, n: usize) -> Buffered<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches unwinding panics while polling the stream. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Wrap the stream in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Wrap the stream in a Box, pinning it. Read more
    §

    fn buffered(self, n: usize) -> Buffered<Self>
    where Self::Item: Future, - Self: Sized,

    An adaptor for creating a buffered list of pending futures. Read more
    §

    fn buffer_unordered(self, n: usize) -> BufferUnordered<Self>
    where + Self: Sized,

    Available on crate feature alloc only.
    An adaptor for creating a buffered list of pending futures. Read more
    §

    fn buffer_unordered(self, n: usize) -> BufferUnordered<Self>
    where Self::Item: Future, - Self: Sized,

    An adaptor for creating a buffered list of pending futures (unordered). Read more
    §

    fn zip<St>(self, other: St) -> Zip<Self, St>
    where + Self: Sized,

    Available on crate feature alloc only.
    An adaptor for creating a buffered list of pending futures (unordered). Read more
    §

    fn zip<St>(self, other: St) -> Zip<Self, St>
    where St: Stream, Self: Sized,

    An adapter for zipping two streams together. Read more
    §

    fn chain<St>(self, other: St) -> Chain<Self, St>
    where St: Stream<Item = Self::Item>, Self: Sized,

    Adapter for chaining two streams. Read more
    §

    fn peekable(self) -> Peekable<Self>
    where Self: Sized,

    Creates a new stream which exposes a peek method. Read more
    §

    fn chunks(self, capacity: usize) -> Chunks<Self>
    where - Self: Sized,

    An adaptor for chunking up items of the stream inside a vector. Read more
    §

    fn ready_chunks(self, capacity: usize) -> ReadyChunks<Self>
    where - Self: Sized,

    An adaptor for chunking up ready items of the stream inside a vector. Read more
    §

    fn forward<S>(self, sink: S) -> Forward<Self, S>
    where + Self: Sized,

    Available on crate feature alloc only.
    An adaptor for chunking up items of the stream inside a vector. Read more
    §

    fn ready_chunks(self, capacity: usize) -> ReadyChunks<Self>
    where + Self: Sized,

    Available on crate feature alloc only.
    An adaptor for chunking up ready items of the stream inside a vector. Read more
    §

    fn forward<S>(self, sink: S) -> Forward<Self, S>
    where S: Sink<Self::Ok, Error = Self::Error>, - Self: Sized + TryStream,

    A future that completes after the given stream has been fully processed + Self: Sized + TryStream,
    Available on crate feature sink only.
    A future that completes after the given stream has been fully processed into the sink and the sink has been flushed and closed. Read more
    §

    fn split<Item>(self) -> (SplitSink<Self, Item>, SplitStream<Self>)
    where - Self: Sized + Sink<Item>,

    Splits this Stream + Sink object into separate Sink and Stream + Self: Sized + Sink<Item>,
    Available on crate features sink and alloc only.
    Splits this Stream + Sink object into separate Sink and Stream objects. Read more
    §

    fn inspect<F>(self, f: F) -> Inspect<Self, F>
    where F: FnMut(&Self::Item), Self: Sized,

    Do something with each item of this stream, afterwards passing it on. Read more
    §

    fn left_stream<B>(self) -> Either<Self, B>
    where diff --git a/pr/3024/docs/iroh/endpoint/struct.DirectAddr.html b/pr/3024/docs/iroh/endpoint/struct.DirectAddr.html index 6e69b24dc6..112874fbd1 100644 --- a/pr/3024/docs/iroh/endpoint/struct.DirectAddr.html +++ b/pr/3024/docs/iroh/endpoint/struct.DirectAddr.html @@ -1,4 +1,4 @@ -DirectAddr in iroh::endpoint - Rust

    Struct iroh::endpoint::DirectAddr

    source ·
    pub struct DirectAddr {
    +DirectAddr in iroh::endpoint - Rust

    Struct iroh::endpoint::DirectAddr

    source ·
    pub struct DirectAddr {
         pub addr: SocketAddr,
         pub typ: DirectAddrType,
     }
    Expand description

    A direct address on which an iroh-node might be contactable.

    @@ -7,16 +7,16 @@ contacted. These can come from various sources depending on the network topolog iroh node, see DirectAddrType for the several kinds of sources.

    Fields§

    §addr: SocketAddr

    The address.

    §typ: DirectAddrType

    The origin of this direct address.

    -

    Trait Implementations§

    source§

    impl Clone for DirectAddr

    source§

    fn clone(&self) -> DirectAddr

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for DirectAddr

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Hash for DirectAddr

    source§

    fn hash<__H: Hasher>(&self, state: &mut __H)

    Feeds this value into the given Hasher. Read more
    1.3.0 · source§

    fn hash_slice<H>(data: &[Self], state: &mut H)
    where +

    Trait Implementations§

    source§

    impl Clone for DirectAddr

    source§

    fn clone(&self) -> DirectAddr

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for DirectAddr

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Hash for DirectAddr

    source§

    fn hash<__H: Hasher>(&self, state: &mut __H)

    Feeds this value into the given Hasher. Read more
    1.3.0 · source§

    fn hash_slice<H>(data: &[Self], state: &mut H)
    where H: Hasher, - Self: Sized,

    Feeds a slice of this type into the given Hasher. Read more
    source§

    impl Ord for DirectAddr

    source§

    fn cmp(&self, other: &DirectAddr) -> Ordering

    This method returns an Ordering between self and other. Read more
    1.21.0 · source§

    fn max(self, other: Self) -> Self
    where + Self: Sized,

    Feeds a slice of this type into the given Hasher. Read more
    source§

    impl Ord for DirectAddr

    source§

    fn cmp(&self, other: &DirectAddr) -> Ordering

    This method returns an Ordering between self and other. Read more
    1.21.0 · source§

    fn max(self, other: Self) -> Self
    where Self: Sized,

    Compares and returns the maximum of two values. Read more
    1.21.0 · source§

    fn min(self, other: Self) -> Self
    where Self: Sized,

    Compares and returns the minimum of two values. Read more
    1.50.0 · source§

    fn clamp(self, min: Self, max: Self) -> Self
    where - Self: Sized + PartialOrd,

    Restrict a value to a certain interval. Read more
    source§

    impl PartialEq for DirectAddr

    source§

    fn eq(&self, other: &DirectAddr) -> bool

    This method tests for self and other values to be equal, and is used + Self: Sized + PartialOrd,

    Restrict a value to a certain interval. Read more
    source§

    impl PartialEq for DirectAddr

    source§

    fn eq(&self, other: &DirectAddr) -> bool

    This method tests for self and other values to be equal, and is used by ==.
    1.0.0 · source§

    fn ne(&self, other: &Rhs) -> bool

    This method tests for !=. The default implementation is almost always -sufficient, and should not be overridden without very good reason.
    source§

    impl PartialOrd for DirectAddr

    source§

    fn partial_cmp(&self, other: &DirectAddr) -> Option<Ordering>

    This method returns an ordering between self and other values if one exists. Read more
    1.0.0 · source§

    fn lt(&self, other: &Rhs) -> bool

    This method tests less than (for self and other) and is used by the < operator. Read more
    1.0.0 · source§

    fn le(&self, other: &Rhs) -> bool

    This method tests less than or equal to (for self and other) and is used by the <= +sufficient, and should not be overridden without very good reason.
    source§

    impl PartialOrd for DirectAddr

    source§

    fn partial_cmp(&self, other: &DirectAddr) -> Option<Ordering>

    This method returns an ordering between self and other values if one exists. Read more
    1.0.0 · source§

    fn lt(&self, other: &Rhs) -> bool

    This method tests less than (for self and other) and is used by the < operator. Read more
    1.0.0 · source§

    fn le(&self, other: &Rhs) -> bool

    This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
    1.0.0 · source§

    fn gt(&self, other: &Rhs) -> bool

    This method tests greater than (for self and other) and is used by the > operator. Read more
    1.0.0 · source§

    fn ge(&self, other: &Rhs) -> bool

    This method tests greater than or equal to (for self and other) and is used by the >= -operator. Read more
    source§

    impl Eq for DirectAddr

    source§

    impl StructuralPartialEq for DirectAddr

    Auto Trait Implementations§

    §

    impl Freeze for DirectAddr

    §

    impl RefUnwindSafe for DirectAddr

    §

    impl Send for DirectAddr

    §

    impl Sync for DirectAddr

    §

    impl Unpin for DirectAddr

    §

    impl UnwindSafe for DirectAddr

    Blanket Implementations§

    source§

    impl<T> Any for T
    where +operator. Read more

    source§

    impl Eq for DirectAddr

    source§

    impl StructuralPartialEq for DirectAddr

    Auto Trait Implementations§

    §

    impl Freeze for DirectAddr

    §

    impl RefUnwindSafe for DirectAddr

    §

    impl Send for DirectAddr

    §

    impl Sync for DirectAddr

    §

    impl Unpin for DirectAddr

    §

    impl UnwindSafe for DirectAddr

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/iroh/endpoint/struct.DirectAddrsStream.html b/pr/3024/docs/iroh/endpoint/struct.DirectAddrsStream.html index 887cb774fe..ad8591668a 100644 --- a/pr/3024/docs/iroh/endpoint/struct.DirectAddrsStream.html +++ b/pr/3024/docs/iroh/endpoint/struct.DirectAddrsStream.html @@ -1,5 +1,5 @@ -DirectAddrsStream in iroh::endpoint - Rust

    Struct iroh::endpoint::DirectAddrsStream

    source ·
    pub struct DirectAddrsStream { /* private fields */ }
    Expand description

    Stream returning local endpoints as they change.

    -

    Trait Implementations§

    source§

    impl Debug for DirectAddrsStream

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Stream for DirectAddrsStream

    §

    type Item = BTreeSet<DirectAddr>

    Values yielded by the stream.
    source§

    fn poll_next( +DirectAddrsStream in iroh::endpoint - Rust

    Struct iroh::endpoint::DirectAddrsStream

    source ·
    pub struct DirectAddrsStream { /* private fields */ }
    Expand description

    Stream returning local endpoints as they change.

    +

    Trait Implementations§

    source§

    impl Debug for DirectAddrsStream

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Stream for DirectAddrsStream

    §

    type Item = BTreeSet<DirectAddr>

    Values yielded by the stream.
    source§

    fn poll_next( self: Pin<&mut Self>, cx: &mut Context<'_> ) -> Poll<Option<Self::Item>>

    Attempt to pull out the next value of this stream, registering the @@ -116,9 +116,9 @@ available. Read more
    Sized, S: Stream<Item = Self::Item>,

    Merges with other stream, preferring items from self whenever both streams are ready. Read more
    §

    fn race<S>(self, other: S) -> Race<Self, S>
    where Self: Sized, - S: Stream<Item = Self::Item>,

    Merges with other stream, with no preference for either stream when both are ready. Read more
    §

    fn drain(&mut self) -> Drain<'_, Self>

    Yields all immediately available values from a stream. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the stream and changes its type to dyn Stream + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + 'a>>
    where - Self: Sized + 'a,

    Boxes the stream and changes its type to dyn Stream + 'a. Read more
    §

    impl<S> StreamExt for S
    where + S: Stream<Item = Self::Item>,

    Available on crate features std and race only.
    Merges with other stream, with no preference for either stream when both are ready. Read more
    §

    fn drain(&mut self) -> Drain<'_, Self>

    Yields all immediately available values from a stream. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the stream and changes its type to dyn Stream + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the stream and changes its type to dyn Stream + 'a. Read more

    §

    impl<S> StreamExt for S
    where S: Stream + ?Sized,

    §

    fn poll_next(&mut self, cx: &mut Context<'_>) -> Poll<Option<Self::Item>>
    where Self: Unpin,

    A convenience for calling [Stream::poll_next()] on !Unpin types.
    §

    fn next(&mut self) -> NextFuture<'_, Self>
    where Self: Unpin,

    Retrieves the next item in the stream. Read more
    §

    fn try_next<T, E>(&mut self) -> TryNextFuture<'_, Self>
    where @@ -198,9 +198,9 @@ available. Read more

    Sized, S: Stream<Item = Self::Item>,
    Merges with other stream, preferring items from self whenever both streams are ready. Read more
    §

    fn race<S>(self, other: S) -> Race<Self, S>
    where Self: Sized, - S: Stream<Item = Self::Item>,

    Merges with other stream, with no preference for either stream when both are ready. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the stream and changes its type to dyn Stream + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + 'a>>
    where - Self: Sized + 'a,

    Boxes the stream and changes its type to dyn Stream + 'a. Read more
    §

    impl<S1> StreamExt for S1
    where + S: Stream<Item = Self::Item>,

    Available on crate feature std only.
    Merges with other stream, with no preference for either stream when both are ready. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the stream and changes its type to dyn Stream + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the stream and changes its type to dyn Stream + 'a. Read more
    §

    impl<S1> StreamExt for S1
    where S1: Stream,

    §

    fn merge<T, S2>( self, other: S2 @@ -211,7 +211,7 @@ available. Read more

    §

    fn zip<T, S2>(self, other: S2) -> Zip2<S1, <S2 as IntoStream>::IntoStream>
    where S1: Stream<Item = T>, S2: IntoStream<Item = T>,

    ‘Zips up’ multiple streams into a single stream of pairs.
    §

    fn co(self) -> FromStream<Self>
    where - Self: Sized,

    Convert into a concurrent stream.
    §

    fn wait_until<D>( + Self: Sized,

    Available on crate feature alloc only.
    Convert into a concurrent stream.
    §

    fn wait_until<D>( self, deadline: D ) -> WaitUntil<Self, <D as IntoFuture>::IntoFuture>
    where @@ -264,14 +264,14 @@ first stream then all values from the second stream. Read more
    Read more

    §

    fn collect<T>(self) -> Collect<Self, T>
    where T: FromStream<Self::Item>, Self: Sized,

    Drain stream pushing all emitted values into a collection. Read more
    §

    fn timeout(self, duration: Duration) -> Timeout<Self>
    where - Self: Sized,

    Applies a per-item timeout to the passed stream. Read more
    §

    fn timeout_repeating(self, interval: Interval) -> TimeoutRepeating<Self>
    where - Self: Sized,

    Applies a per-item timeout to the passed stream. Read more
    §

    fn throttle(self, duration: Duration) -> Throttle<Self>
    where - Self: Sized,

    Slows down a stream by enforcing a delay between items. Read more
    §

    fn chunks_timeout( + Self: Sized,

    Available on crate feature time only.
    Applies a per-item timeout to the passed stream. Read more
    §

    fn timeout_repeating(self, interval: Interval) -> TimeoutRepeating<Self>
    where + Self: Sized,

    Available on crate feature time only.
    Applies a per-item timeout to the passed stream. Read more
    §

    fn throttle(self, duration: Duration) -> Throttle<Self>
    where + Self: Sized,

    Available on crate feature time only.
    Slows down a stream by enforcing a delay between items. Read more
    §

    fn chunks_timeout( self, max_size: usize, duration: Duration ) -> ChunksTimeout<Self>
    where - Self: Sized,

    Batches the items in the given stream using a maximum duration and size for each batch. Read more
    §

    fn peekable(self) -> Peekable<Self>
    where + Self: Sized,

    Available on crate feature time only.
    Batches the items in the given stream using a maximum duration and size for each batch. Read more
    §

    fn peekable(self) -> Peekable<Self>
    where Self: Sized,

    Turns the stream into a peekable stream, whose next element can be peeked at without being consumed. Read more
    §

    impl<T> StreamExt for T
    where T: Stream + ?Sized,

    §

    fn next(&mut self) -> Next<'_, Self>
    where @@ -323,7 +323,7 @@ collecting all the values into one final result. Read more

    Into<Option<usize>> ) -> FlattenUnorderedWithFlowController<Self, ()>
    where Self::Item: Stream + Unpin, - Self: Sized,
    Flattens a stream of streams into just one continuous stream. Polls + Self: Sized,
    Available on crate feature alloc only.
    Flattens a stream of streams into just one continuous stream. Polls inner streams produced by the base stream concurrently. Read more
    §

    fn flat_map<U, F>(self, f: F) -> FlatMap<Self, U, F>
    where F: FnMut(Self::Item) -> U, U: Stream, @@ -334,7 +334,7 @@ inner streams produced by the base stream concurrently. Read more
    where U: Stream + Unpin, F: FnMut(Self::Item) -> U, - Self: Sized,

    Maps a stream like [StreamExt::map] but flattens nested Streams + Self: Sized,
    Available on crate feature alloc only.
    Maps a stream like [StreamExt::map] but flattens nested Streams and polls them concurrently, yielding items in any order, as they made available. Read more
    §

    fn scan<S, B, Fut, F>(self, initial_state: S, f: F) -> Scan<Self, S, Fut, F>
    where F: FnMut(&mut S, Self::Item) -> Fut, @@ -361,7 +361,7 @@ closure for each element on the stream. Read more

    where F: FnMut(Self::Item) -> Fut, Fut: Future<Output = ()>, - Self: Sized,
    Runs this stream to completion, executing the provided asynchronous + Self: Sized,
    Available on crate feature alloc only.
    Runs this stream to completion, executing the provided asynchronous closure for each element on the stream concurrently as elements become available. Read more
    §

    fn take(self, n: usize) -> Take<Self>
    where Self: Sized,

    Creates a new stream of at most n items of the underlying stream. Read more
    §

    fn skip(self, n: usize) -> Skip<Self>
    where @@ -369,24 +369,24 @@ available. Read more

    Sized,
    Fuse a stream such that poll_next will never again be called once it has finished. This method can be used to turn any Stream into a FusedStream. Read more
    §

    fn by_ref(&mut self) -> &mut Self

    Borrows a stream, rather than consuming it. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches unwinding panics while polling the stream. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Wrap the stream in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + 'a>>
    where - Self: Sized + 'a,

    Wrap the stream in a Box, pinning it. Read more
    §

    fn buffered(self, n: usize) -> Buffered<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches unwinding panics while polling the stream. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Wrap the stream in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Stream<Item = Self::Item> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Wrap the stream in a Box, pinning it. Read more
    §

    fn buffered(self, n: usize) -> Buffered<Self>
    where Self::Item: Future, - Self: Sized,

    An adaptor for creating a buffered list of pending futures. Read more
    §

    fn buffer_unordered(self, n: usize) -> BufferUnordered<Self>
    where + Self: Sized,

    Available on crate feature alloc only.
    An adaptor for creating a buffered list of pending futures. Read more
    §

    fn buffer_unordered(self, n: usize) -> BufferUnordered<Self>
    where Self::Item: Future, - Self: Sized,

    An adaptor for creating a buffered list of pending futures (unordered). Read more
    §

    fn zip<St>(self, other: St) -> Zip<Self, St>
    where + Self: Sized,

    Available on crate feature alloc only.
    An adaptor for creating a buffered list of pending futures (unordered). Read more
    §

    fn zip<St>(self, other: St) -> Zip<Self, St>
    where St: Stream, Self: Sized,

    An adapter for zipping two streams together. Read more
    §

    fn chain<St>(self, other: St) -> Chain<Self, St>
    where St: Stream<Item = Self::Item>, Self: Sized,

    Adapter for chaining two streams. Read more
    §

    fn peekable(self) -> Peekable<Self>
    where Self: Sized,

    Creates a new stream which exposes a peek method. Read more
    §

    fn chunks(self, capacity: usize) -> Chunks<Self>
    where - Self: Sized,

    An adaptor for chunking up items of the stream inside a vector. Read more
    §

    fn ready_chunks(self, capacity: usize) -> ReadyChunks<Self>
    where - Self: Sized,

    An adaptor for chunking up ready items of the stream inside a vector. Read more
    §

    fn forward<S>(self, sink: S) -> Forward<Self, S>
    where + Self: Sized,

    Available on crate feature alloc only.
    An adaptor for chunking up items of the stream inside a vector. Read more
    §

    fn ready_chunks(self, capacity: usize) -> ReadyChunks<Self>
    where + Self: Sized,

    Available on crate feature alloc only.
    An adaptor for chunking up ready items of the stream inside a vector. Read more
    §

    fn forward<S>(self, sink: S) -> Forward<Self, S>
    where S: Sink<Self::Ok, Error = Self::Error>, - Self: Sized + TryStream,

    A future that completes after the given stream has been fully processed + Self: Sized + TryStream,
    Available on crate feature sink only.
    A future that completes after the given stream has been fully processed into the sink and the sink has been flushed and closed. Read more
    §

    fn split<Item>(self) -> (SplitSink<Self, Item>, SplitStream<Self>)
    where - Self: Sized + Sink<Item>,

    Splits this Stream + Sink object into separate Sink and Stream + Self: Sized + Sink<Item>,
    Available on crate features sink and alloc only.
    Splits this Stream + Sink object into separate Sink and Stream objects. Read more
    §

    fn inspect<F>(self, f: F) -> Inspect<Self, F>
    where F: FnMut(&Self::Item), Self: Sized,

    Do something with each item of this stream, afterwards passing it on. Read more
    §

    fn left_stream<B>(self) -> Either<Self, B>
    where diff --git a/pr/3024/docs/iroh/endpoint/struct.Endpoint.html b/pr/3024/docs/iroh/endpoint/struct.Endpoint.html index 17cb6b53f7..09686cf955 100644 --- a/pr/3024/docs/iroh/endpoint/struct.Endpoint.html +++ b/pr/3024/docs/iroh/endpoint/struct.Endpoint.html @@ -1,4 +1,4 @@ -Endpoint in iroh::endpoint - Rust

    Struct iroh::endpoint::Endpoint

    source ·
    pub struct Endpoint { /* private fields */ }
    Expand description

    Controls an iroh node, establishing connections with other nodes.

    +Endpoint in iroh::endpoint - Rust

    Struct iroh::endpoint::Endpoint

    source ·
    pub struct Endpoint { /* private fields */ }
    Expand description

    Controls an iroh node, establishing connections with other nodes.

    This is the main API interface to create connections to, and accept connections from other iroh nodes. The connections are peer-to-peer and encrypted, a Relay server is used to make the connections reliable. See the [crate docs] for a more detailed @@ -14,11 +14,11 @@ behaviour.

    Connection::open_bi functions.

    Note that due to the light-weight properties of streams a stream will only be accepted once the initiating peer has sent some data on it.

    -

    Implementations§

    source§

    impl Endpoint

    source

    pub fn builder() -> Builder

    Returns the builder for an Endpoint, with a production configuration.

    -
    source

    pub fn set_alpns(&self, alpns: Vec<Vec<u8>>) -> Result<()>

    Sets the list of accepted ALPN protocols.

    +

    Implementations§

    source§

    impl Endpoint

    source

    pub fn builder() -> Builder

    Returns the builder for an Endpoint, with a production configuration.

    +
    source

    pub fn set_alpns(&self, alpns: Vec<Vec<u8>>) -> Result<()>

    Sets the list of accepted ALPN protocols.

    This will only affect new incoming connections. Note that this overrides the current list of ALPNs.

    -
    source

    pub async fn connect( +

    source

    pub async fn connect( &self, node_addr: impl Into<NodeAddr>, alpn: &[u8] @@ -39,13 +39,13 @@ connection attempt will fail with an error.

    The alpn, or application-level protocol identifier, is also required. The remote endpoint must support this alpn, otherwise the connection attempt will fail with an error.

    -

    source

    pub fn accept(&self) -> Accept<'_> ⓘ

    Accepts an incoming connection on the endpoint.

    +
    source

    pub fn accept(&self) -> Accept<'_> ⓘ

    Accepts an incoming connection on the endpoint.

    Only connections with the ALPNs configured in Builder::alpns will be accepted. If multiple ALPNs have been configured the ALPN can be inspected before accepting the connection using Connecting::alpn.

    The returned future will yield None if the endpoint is closed by calling Endpoint::close.

    -
    source

    pub fn add_node_addr(&self, node_addr: NodeAddr) -> Result<()>

    Informs this Endpoint about addresses of the iroh node.

    +
    source

    pub fn add_node_addr(&self, node_addr: NodeAddr) -> Result<()>

    Informs this Endpoint about addresses of the iroh node.

    This updates the local state for the remote node. If the provided NodeAddr contains a RelayUrl this will be used as the new relay server for this node. If it contains any new IP endpoints they will also be stored and tried when next @@ -55,7 +55,7 @@ silently ignored.

    §Errors

    Will return an error if we attempt to add our own PublicKey to the node map or if the direct addresses are a subset of ours.

    -
    source

    pub fn add_node_addr_with_source( +

    source

    pub fn add_node_addr_with_source( &self, node_addr: NodeAddr, source: &'static str @@ -68,15 +68,15 @@ used for logging exclusively and will not be stored.

    §Errors

    Will return an error if we attempt to add our own PublicKey to the node map or if the direct addresses are a subset of ours.

    -

    source

    pub fn secret_key(&self) -> &SecretKey

    Returns the secret_key of this endpoint.

    -
    source

    pub fn node_id(&self) -> NodeId

    Returns the node id of this endpoint.

    +
    source

    pub fn secret_key(&self) -> &SecretKey

    Returns the secret_key of this endpoint.

    +
    source

    pub fn node_id(&self) -> NodeId

    Returns the node id of this endpoint.

    This ID is the unique addressing information of this node and other peers must know it to be able to connect to this node.

    -
    source

    pub async fn node_addr(&self) -> Result<NodeAddr>

    Returns the current NodeAddr for this endpoint.

    +
    source

    pub async fn node_addr(&self) -> Result<NodeAddr>

    Returns the current NodeAddr for this endpoint.

    The returned NodeAddr will have the current RelayUrl and local IP endpoints as they would be returned by Endpoint::home_relay and Endpoint::direct_addresses.

    -
    source

    pub fn home_relay(&self) -> Option<RelayUrl>

    Returns the RelayUrl of the Relay server used as home relay.

    +
    source

    pub fn home_relay(&self) -> Option<RelayUrl>

    Returns the RelayUrl of the Relay server used as home relay.

    Every endpoint has a home Relay server which it chooses as the server with the lowest latency out of the configured servers provided by Builder::relay_mode. This is the server other iroh nodes can use to reliably establish a connection @@ -85,14 +85,14 @@ to this node.

    Note that this will be None right after the Endpoint is created since it takes some time to connect to find and connect to the home relay server. Use Endpoint::watch_home_relay to wait until the home relay server is available.

    -
    source

    pub fn watch_home_relay(&self) -> impl Stream<Item = RelayUrl>

    Watches for changes to the home relay.

    +
    source

    pub fn watch_home_relay(&self) -> impl Stream<Item = RelayUrl>

    Watches for changes to the home relay.

    If there is currently a home relay it will be yielded immediately as the first item in the stream. This makes it possible to use this function to wait for the initial home relay to be known.

    Note that it is not guaranteed that a home relay will ever become available. If no servers are configured with Builder::relay_mode this stream will never yield an item.

    -
    source

    pub fn direct_addresses(&self) -> DirectAddrsStream

    Returns the direct addresses of this Endpoint.

    +
    source

    pub fn direct_addresses(&self) -> DirectAddrsStream

    Returns the direct addresses of this Endpoint.

    The direct addresses of the Endpoint are those that could be used by other iroh nodes to establish direct connectivity, depending on the network situation. The yielded lists of direct addresses contain both the locally-bound @@ -115,10 +115,10 @@ most recently discovered IP endpoints.

    let mep = Endpoint::builder().bind().await.unwrap(); let _addrs = mep.direct_addresses().next().await;
    -
    source

    pub fn bound_sockets(&self) -> (SocketAddr, Option<SocketAddr>)

    Returns the local socket addresses on which the underlying sockets are bound.

    +
    source

    pub fn bound_sockets(&self) -> (SocketAddr, Option<SocketAddr>)

    Returns the local socket addresses on which the underlying sockets are bound.

    The Endpoint always binds on an IPv4 address and also tries to bind on an IPv6 address if available.

    -
    source

    pub fn remote_info(&self, node_id: NodeId) -> Option<RemoteInfo>

    Returns information about the remote node identified by a NodeId.

    +
    source

    pub fn remote_info(&self, node_id: NodeId) -> Option<RemoteInfo>

    Returns information about the remote node identified by a NodeId.

    The Endpoint keeps some information about remote iroh nodes, which it uses to find the best path to a node. Having information on a remote node, however, does not mean we have ever connected to it to or even whether a connection is even possible. The information about a @@ -127,14 +127,14 @@ calls may return different information. Furthermore, node information may even b completely evicted as it becomes stale.

    See also Endpoint::remote_info_iter which returns information on all nodes known by this Endpoint.

    -
    source

    pub fn remote_info_iter(&self) -> impl Iterator<Item = RemoteInfo>

    Returns information about all the remote nodes this Endpoint knows about.

    +
    source

    pub fn remote_info_iter(&self) -> impl Iterator<Item = RemoteInfo>

    Returns information about all the remote nodes this Endpoint knows about.

    This returns the same information as Endpoint::remote_info for each node known to this Endpoint.

    The Endpoint keeps some information about remote iroh nodes, which it uses to find the best path to a node. This returns all the nodes it knows about, regardless of whether a connection was ever made or is even possible.

    See also Endpoint::remote_info to only retrieve information about a single node.

    -
    source

    pub fn conn_type_stream(&self, node_id: NodeId) -> Result<ConnectionTypeStream>

    Returns a stream that reports connection type changes for the remote node.

    +
    source

    pub fn conn_type_stream(&self, node_id: NodeId) -> Result<ConnectionTypeStream>

    Returns a stream that reports connection type changes for the remote node.

    This returns a stream of ConnectionType items, each time the underlying connection to a remote node changes it yields an item. These connection changes are when the connection switches between using the Relay server and a direct connection.

    @@ -147,11 +147,11 @@ connection when the switch from a relayed to a direct connection can be so fast the relayed state is never exposed.

    §Errors

    Will error if we do not have any address information for the given node_id.

    -
    source

    pub fn dns_resolver(&self) -> &DnsResolver

    Returns the DNS resolver used in this Endpoint.

    +
    source

    pub fn dns_resolver(&self) -> &DnsResolver

    Returns the DNS resolver used in this Endpoint.

    See Builder::discovery.

    -
    source

    pub fn discovery(&self) -> Option<&dyn Discovery>

    Returns the discovery mechanism, if configured.

    +
    source

    pub fn discovery(&self) -> Option<&dyn Discovery>

    Returns the discovery mechanism, if configured.

    See Builder::dns_resolver.

    -
    source

    pub async fn network_change(&self)

    Notifies the system of potential network changes.

    +
    source

    pub async fn network_change(&self)

    Notifies the system of potential network changes.

    On many systems iroh is able to detect network changes by itself, however some systems like android do not expose this functionality to native code. Android does however provide this functionality to Java code. This @@ -159,7 +159,7 @@ function allows for notifying iroh of any potential network changes like this.

    Even when the network did not change, or iroh was already able to detect the network change itself, there is no harm in calling this function.

    -
    source

    pub async fn close(&self) -> Result<()>

    Closes the QUIC endpoint and the magic socket.

    +
    source

    pub async fn close(&self) -> Result<()>

    Closes the QUIC endpoint and the magic socket.

    This will close any remaining open Connections with an error code of 0 and an empty reason. Though it is best practice to close those explicitly before with a custom error code and reason.

    @@ -172,8 +172,8 @@ on

    Returns an error if closing the magic socket failed. TODO: Document error cases.

    -
    source

    pub fn is_closed(&self) -> bool

    Check if this endpoint is still alive, or already closed.

    -

    Trait Implementations§

    source§

    impl Clone for Endpoint

    source§

    fn clone(&self) -> Endpoint

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for Endpoint

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more

    Auto Trait Implementations§

    §

    impl Freeze for Endpoint

    §

    impl !RefUnwindSafe for Endpoint

    §

    impl Send for Endpoint

    §

    impl Sync for Endpoint

    §

    impl Unpin for Endpoint

    §

    impl !UnwindSafe for Endpoint

    Blanket Implementations§

    source§

    impl<T> Any for T
    where +

    source

    pub fn is_closed(&self) -> bool

    Check if this endpoint is still alive, or already closed.

    +

    Trait Implementations§

    source§

    impl Clone for Endpoint

    source§

    fn clone(&self) -> Endpoint

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for Endpoint

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more

    Auto Trait Implementations§

    §

    impl Freeze for Endpoint

    §

    impl !RefUnwindSafe for Endpoint

    §

    impl Send for Endpoint

    §

    impl Sync for Endpoint

    §

    impl Unpin for Endpoint

    §

    impl !UnwindSafe for Endpoint

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/iroh/endpoint/struct.Incoming.html b/pr/3024/docs/iroh/endpoint/struct.Incoming.html index b89115d2f6..85ece5089d 100644 --- a/pr/3024/docs/iroh/endpoint/struct.Incoming.html +++ b/pr/3024/docs/iroh/endpoint/struct.Incoming.html @@ -1,29 +1,29 @@ -Incoming in iroh::endpoint - Rust

    Struct iroh::endpoint::Incoming

    source ·
    pub struct Incoming { /* private fields */ }
    Expand description

    An incoming connection for which the server has not yet begun its parts of the +Incoming in iroh::endpoint - Rust

    Struct iroh::endpoint::Incoming

    source ·
    pub struct Incoming { /* private fields */ }
    Expand description

    An incoming connection for which the server has not yet begun its parts of the handshake.

    -

    Implementations§

    source§

    impl Incoming

    source

    pub fn accept(self) -> Result<Connecting, ConnectionError>

    Attempts to accept this incoming connection (an error may still occur).

    +

    Implementations§

    source§

    impl Incoming

    source

    pub fn accept(self) -> Result<Connecting, ConnectionError>

    Attempts to accept this incoming connection (an error may still occur).

    Errors occurring here are likely not caused by the application or remote. The QUIC connection listens on a normal UDP socket and any reachable network endpoint can send datagrams to it, solicited or not. Even if the first few bytes look like a QUIC packet, it might not even be a QUIC packet that is being received.

    Thus it is common to simply log the errors here and accept them as something which can happen.

    -
    source

    pub fn accept_with( +

    source

    pub fn accept_with( self, server_config: Arc<ServerConfig> ) -> Result<Connecting, ConnectionError>

    Accepts this incoming connection using a custom configuration.

    See accept() for more details.

    -
    source

    pub fn refuse(self)

    Rejects this incoming connection attempt.

    -
    source

    pub fn retry(self) -> Result<(), RetryError>

    Responds with a retry packet.

    +
    source

    pub fn refuse(self)

    Rejects this incoming connection attempt.

    +
    source

    pub fn retry(self) -> Result<(), RetryError>

    Responds with a retry packet.

    This requires the client to retry with address validation.

    Errors if remote_address_validated() is true.

    -
    source

    pub fn ignore(self)

    Ignores this incoming connection attempt, not sending any packet in response.

    -
    source

    pub fn local_ip(&self) -> Option<IpAddr>

    Returns the local IP address which was used when the peer established the +

    source

    pub fn ignore(self)

    Ignores this incoming connection attempt, not sending any packet in response.

    +
    source

    pub fn local_ip(&self) -> Option<IpAddr>

    Returns the local IP address which was used when the peer established the connection.

    -
    source

    pub fn remote_address(&self) -> SocketAddr

    Returns the peer’s UDP address.

    -
    source

    pub fn remote_address_validated(&self) -> bool

    Whether the socket address that is initiating this connection has been validated.

    +
    source

    pub fn remote_address(&self) -> SocketAddr

    Returns the peer’s UDP address.

    +
    source

    pub fn remote_address_validated(&self) -> bool

    Whether the socket address that is initiating this connection has been validated.

    This means that the sender of the initial packet has proved that they can receive traffic sent to self.remote_address().

    -

    Trait Implementations§

    source§

    impl Debug for Incoming

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl IntoFuture for Incoming

    §

    type Output = Result<Connection, ConnectionError>

    The output that the future will produce on completion.
    §

    type IntoFuture = IncomingFuture

    Which kind of future are we turning this into?
    source§

    fn into_future(self) -> Self::IntoFuture

    Creates a future from a value. Read more

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where +

    Trait Implementations§

    source§

    impl Debug for Incoming

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl IntoFuture for Incoming

    §

    type Output = Result<Connection, ConnectionError>

    The output that the future will produce on completion.
    §

    type IntoFuture = IncomingFuture

    Which kind of future are we turning this into?
    source§

    fn into_future(self) -> Self::IntoFuture

    Creates a future from a value. Read more

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/iroh/endpoint/struct.IncomingFuture.html b/pr/3024/docs/iroh/endpoint/struct.IncomingFuture.html index 16564992c2..2c71093196 100644 --- a/pr/3024/docs/iroh/endpoint/struct.IncomingFuture.html +++ b/pr/3024/docs/iroh/endpoint/struct.IncomingFuture.html @@ -1,6 +1,6 @@ -IncomingFuture in iroh::endpoint - Rust

    Struct iroh::endpoint::IncomingFuture

    source ·
    pub struct IncomingFuture { /* private fields */ }
    Expand description

    Adaptor to let Incoming be awaited like a Connecting.

    -

    Trait Implementations§

    source§

    impl Debug for IncomingFuture

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Future for IncomingFuture

    §

    type Output = Result<Connection, ConnectionError>

    The type of value produced on completion.
    source§

    fn poll(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Self::Output>

    Attempt to resolve the future to a final value, registering -the current task for wakeup if the value is not yet available. Read more
    source§

    impl<'pin> Unpin for IncomingFuture
    where +IncomingFuture in iroh::endpoint - Rust

    Struct iroh::endpoint::IncomingFuture

    source ·
    pub struct IncomingFuture { /* private fields */ }
    Expand description

    Adaptor to let Incoming be awaited like a Connecting.

    +

    Trait Implementations§

    source§

    impl Debug for IncomingFuture

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Future for IncomingFuture

    §

    type Output = Result<Connection, ConnectionError>

    The type of value produced on completion.
    source§

    fn poll(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Self::Output>

    Attempt to resolve the future to a final value, registering +the current task for wakeup if the value is not yet available. Read more
    source§

    impl<'pin> Unpin for IncomingFuture
    where PinnedFieldsOf<__IncomingFuture<'pin>>: Unpin,

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where @@ -18,19 +18,19 @@ the current task for wakeup if the value is not yet available. Sized, F: Future<Output = Self::Output>,

    Returns the result of self or other future, preferring self if both are ready. Read more
    §

    fn race<F>(self, other: F) -> Race<Self, F>
    where Self: Sized, - F: Future<Output = Self::Output>,

    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Boxes the future and changes its type to dyn Future + 'a. Read more

    §

    impl<F> FutureExt for F
    where + F: Future<Output = Self::Output>,

    Available on crate features std and race only.
    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + 'a. Read more

    §

    impl<F> FutureExt for F
    where F: Future + ?Sized,

    §

    fn poll(&mut self, cx: &mut Context<'_>) -> Poll<Self::Output>
    where Self: Unpin,

    A convenience for calling Future::poll() on !Unpin types.
    §

    fn or<F>(self, other: F) -> Or<Self, F>
    where Self: Sized, F: Future<Output = Self::Output>,

    Returns the result of self or other future, preferring self if both are ready. Read more
    §

    fn race<F>(self, other: F) -> Race<Self, F>
    where Self: Sized, - F: Future<Output = Self::Output>,

    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F1> FutureExt for F1
    where + F: Future<Output = Self::Output>,

    Available on crate feature std only.
    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F1> FutureExt for F1
    where F1: Future,

    §

    fn join<F2>(self, other: F2) -> Join2<F1, <F2 as IntoFuture>::IntoFuture>
    where F1: Future, F2: IntoFuture,

    Wait for both futures to complete.
    §

    fn race<T, S2>(self, other: S2) -> Race2<T, F1, <S2 as IntoFuture>::IntoFuture>
    where @@ -70,14 +70,14 @@ completed. This method can be used to turn any Future into a FusedFuture. Read more

    §

    fn inspect<F>(self, f: F) -> Inspect<Self, F>
    where F: FnOnce(&Self::Output), Self: Sized,

    Do something with the output of a future before passing it on. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches unwinding panics while polling the future. Read more
    §

    fn shared(self) -> Shared<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches unwinding panics while polling the future. Read more
    §

    fn shared(self) -> Shared<Self>
    where Self: Sized, - Self::Output: Clone,

    Create a cloneable handle to this future where all handles will resolve + Self::Output: Clone,
    Available on crate feature std only.
    Create a cloneable handle to this future where all handles will resolve to the same result. Read more
    §

    fn remote_handle(self) -> (Remote<Self>, RemoteHandle<Self::Output>)
    where - Self: Sized,

    Turn this future into a future that yields () on completion and sends + Self: Sized,
    Available on crate features channel and std only.
    Turn this future into a future that yields () on completion and sends its output to another future on a separate task. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Wrap the future in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Wrap the future in a Box, pinning it. Read more
    §

    fn unit_error(self) -> UnitError<Self>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Wrap the future in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Wrap the future in a Box, pinning it. Read more
    §

    fn unit_error(self) -> UnitError<Self>
    where Self: Sized,

    §

    fn never_error(self) -> NeverError<Self>
    where Self: Sized,

    Turns a Future<Output = T> into a @@ -100,7 +100,7 @@ the future is ready after the first call to Future::poll. Read m F: Future<Output = Result<T, E>> + ?Sized,
    §

    type Ok = T

    §

    type Err = E

    §

    impl<Fut> TryFutureExt for Fut
    where Fut: TryFuture + ?Sized,

    §

    fn flatten_sink<Item>(self) -> FlattenSink<Self, Self::Ok>
    where Self::Ok: Sink<Item, Error = Self::Error>, - Self: Sized,

    Flattens the execution of this future when the successful result of this + Self: Sized,
    Available on crate feature sink only.
    Flattens the execution of this future when the successful result of this future is a [Sink]. Read more
    §

    fn map_ok<T, F>(self, f: F) -> MapOk<Self, F>
    where F: FnOnce(Self::Ok) -> T, Self: Sized,

    Maps this future’s success value to a different value. Read more
    §

    fn map_ok_or_else<T, E, F>(self, e: E, f: F) -> MapOkOrElse<Self, F, E>
    where diff --git a/pr/3024/docs/iroh/endpoint/struct.OpenBi.html b/pr/3024/docs/iroh/endpoint/struct.OpenBi.html index 59d813f09a..c2b279c4bb 100644 --- a/pr/3024/docs/iroh/endpoint/struct.OpenBi.html +++ b/pr/3024/docs/iroh/endpoint/struct.OpenBi.html @@ -21,19 +21,19 @@ the current task for wakeup if the value is not yet available. Sized, F: Future<Output = Self::Output>,

    Returns the result of self or other future, preferring self if both are ready. Read more
    §

    fn race<F>(self, other: F) -> Race<Self, F>
    where Self: Sized, - F: Future<Output = Self::Output>,

    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F> FutureExt for F
    where + F: Future<Output = Self::Output>,

    Available on crate features std and race only.
    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F> FutureExt for F
    where F: Future + ?Sized,

    §

    fn poll(&mut self, cx: &mut Context<'_>) -> Poll<Self::Output>
    where Self: Unpin,

    A convenience for calling Future::poll() on !Unpin types.
    §

    fn or<F>(self, other: F) -> Or<Self, F>
    where Self: Sized, F: Future<Output = Self::Output>,

    Returns the result of self or other future, preferring self if both are ready. Read more
    §

    fn race<F>(self, other: F) -> Race<Self, F>
    where Self: Sized, - F: Future<Output = Self::Output>,

    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F1> FutureExt for F1
    where + F: Future<Output = Self::Output>,

    Available on crate feature std only.
    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F1> FutureExt for F1
    where F1: Future,

    §

    fn join<F2>(self, other: F2) -> Join2<F1, <F2 as IntoFuture>::IntoFuture>
    where F1: Future, F2: IntoFuture,

    Wait for both futures to complete.
    §

    fn race<T, S2>(self, other: S2) -> Race2<T, F1, <S2 as IntoFuture>::IntoFuture>
    where @@ -73,14 +73,14 @@ completed. This method can be used to turn any Future into a FusedFuture. Read more

    §

    fn inspect<F>(self, f: F) -> Inspect<Self, F>
    where F: FnOnce(&Self::Output), Self: Sized,

    Do something with the output of a future before passing it on. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches unwinding panics while polling the future. Read more
    §

    fn shared(self) -> Shared<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches unwinding panics while polling the future. Read more
    §

    fn shared(self) -> Shared<Self>
    where Self: Sized, - Self::Output: Clone,

    Create a cloneable handle to this future where all handles will resolve + Self::Output: Clone,
    Available on crate feature std only.
    Create a cloneable handle to this future where all handles will resolve to the same result. Read more
    §

    fn remote_handle(self) -> (Remote<Self>, RemoteHandle<Self::Output>)
    where - Self: Sized,

    Turn this future into a future that yields () on completion and sends + Self: Sized,
    Available on crate features channel and std only.
    Turn this future into a future that yields () on completion and sends its output to another future on a separate task. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Wrap the future in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Wrap the future in a Box, pinning it. Read more
    §

    fn unit_error(self) -> UnitError<Self>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Wrap the future in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Wrap the future in a Box, pinning it. Read more
    §

    fn unit_error(self) -> UnitError<Self>
    where Self: Sized,

    §

    fn never_error(self) -> NeverError<Self>
    where Self: Sized,

    Turns a Future<Output = T> into a @@ -103,7 +103,7 @@ the future is ready after the first call to Future::poll. Read m F: Future<Output = Result<T, E>> + ?Sized,
    §

    type Ok = T

    §

    type Err = E

    §

    impl<Fut> TryFutureExt for Fut
    where Fut: TryFuture + ?Sized,

    §

    fn flatten_sink<Item>(self) -> FlattenSink<Self, Self::Ok>
    where Self::Ok: Sink<Item, Error = Self::Error>, - Self: Sized,

    Flattens the execution of this future when the successful result of this + Self: Sized,
    Available on crate feature sink only.
    Flattens the execution of this future when the successful result of this future is a [Sink]. Read more
    §

    fn map_ok<T, F>(self, f: F) -> MapOk<Self, F>
    where F: FnOnce(Self::Ok) -> T, Self: Sized,

    Maps this future’s success value to a different value. Read more
    §

    fn map_ok_or_else<T, E, F>(self, e: E, f: F) -> MapOkOrElse<Self, F, E>
    where diff --git a/pr/3024/docs/iroh/endpoint/struct.OpenUni.html b/pr/3024/docs/iroh/endpoint/struct.OpenUni.html index f9ca21bac1..2dfd57ddd8 100644 --- a/pr/3024/docs/iroh/endpoint/struct.OpenUni.html +++ b/pr/3024/docs/iroh/endpoint/struct.OpenUni.html @@ -21,19 +21,19 @@ the current task for wakeup if the value is not yet available. Sized, F: Future<Output = Self::Output>,

    Returns the result of self or other future, preferring self if both are ready. Read more
    §

    fn race<F>(self, other: F) -> Race<Self, F>
    where Self: Sized, - F: Future<Output = Self::Output>,

    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F> FutureExt for F
    where + F: Future<Output = Self::Output>,

    Available on crate features std and race only.
    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F> FutureExt for F
    where F: Future + ?Sized,

    §

    fn poll(&mut self, cx: &mut Context<'_>) -> Poll<Self::Output>
    where Self: Unpin,

    A convenience for calling Future::poll() on !Unpin types.
    §

    fn or<F>(self, other: F) -> Or<Self, F>
    where Self: Sized, F: Future<Output = Self::Output>,

    Returns the result of self or other future, preferring self if both are ready. Read more
    §

    fn race<F>(self, other: F) -> Race<Self, F>
    where Self: Sized, - F: Future<Output = Self::Output>,

    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F1> FutureExt for F1
    where + F: Future<Output = Self::Output>,

    Available on crate feature std only.
    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F1> FutureExt for F1
    where F1: Future,

    §

    fn join<F2>(self, other: F2) -> Join2<F1, <F2 as IntoFuture>::IntoFuture>
    where F1: Future, F2: IntoFuture,

    Wait for both futures to complete.
    §

    fn race<T, S2>(self, other: S2) -> Race2<T, F1, <S2 as IntoFuture>::IntoFuture>
    where @@ -73,14 +73,14 @@ completed. This method can be used to turn any Future into a FusedFuture. Read more

    §

    fn inspect<F>(self, f: F) -> Inspect<Self, F>
    where F: FnOnce(&Self::Output), Self: Sized,

    Do something with the output of a future before passing it on. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches unwinding panics while polling the future. Read more
    §

    fn shared(self) -> Shared<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches unwinding panics while polling the future. Read more
    §

    fn shared(self) -> Shared<Self>
    where Self: Sized, - Self::Output: Clone,

    Create a cloneable handle to this future where all handles will resolve + Self::Output: Clone,
    Available on crate feature std only.
    Create a cloneable handle to this future where all handles will resolve to the same result. Read more
    §

    fn remote_handle(self) -> (Remote<Self>, RemoteHandle<Self::Output>)
    where - Self: Sized,

    Turn this future into a future that yields () on completion and sends + Self: Sized,
    Available on crate features channel and std only.
    Turn this future into a future that yields () on completion and sends its output to another future on a separate task. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Wrap the future in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Wrap the future in a Box, pinning it. Read more
    §

    fn unit_error(self) -> UnitError<Self>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Wrap the future in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Wrap the future in a Box, pinning it. Read more
    §

    fn unit_error(self) -> UnitError<Self>
    where Self: Sized,

    §

    fn never_error(self) -> NeverError<Self>
    where Self: Sized,

    Turns a Future<Output = T> into a @@ -103,7 +103,7 @@ the future is ready after the first call to Future::poll. Read m F: Future<Output = Result<T, E>> + ?Sized,
    §

    type Ok = T

    §

    type Err = E

    §

    impl<Fut> TryFutureExt for Fut
    where Fut: TryFuture + ?Sized,

    §

    fn flatten_sink<Item>(self) -> FlattenSink<Self, Self::Ok>
    where Self::Ok: Sink<Item, Error = Self::Error>, - Self: Sized,

    Flattens the execution of this future when the successful result of this + Self: Sized,
    Available on crate feature sink only.
    Flattens the execution of this future when the successful result of this future is a [Sink]. Read more
    §

    fn map_ok<T, F>(self, f: F) -> MapOk<Self, F>
    where F: FnOnce(Self::Ok) -> T, Self: Sized,

    Maps this future’s success value to a different value. Read more
    §

    fn map_ok_or_else<T, E, F>(self, e: E, f: F) -> MapOkOrElse<Self, F, E>
    where diff --git a/pr/3024/docs/iroh/endpoint/struct.ReadDatagram.html b/pr/3024/docs/iroh/endpoint/struct.ReadDatagram.html index 27d2ffc692..cc99458537 100644 --- a/pr/3024/docs/iroh/endpoint/struct.ReadDatagram.html +++ b/pr/3024/docs/iroh/endpoint/struct.ReadDatagram.html @@ -21,19 +21,19 @@ the current task for wakeup if the value is not yet available. Sized, F: Future<Output = Self::Output>,

    Returns the result of self or other future, preferring self if both are ready. Read more
    §

    fn race<F>(self, other: F) -> Race<Self, F>
    where Self: Sized, - F: Future<Output = Self::Output>,

    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F> FutureExt for F
    where + F: Future<Output = Self::Output>,

    Available on crate features std and race only.
    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F> FutureExt for F
    where F: Future + ?Sized,

    §

    fn poll(&mut self, cx: &mut Context<'_>) -> Poll<Self::Output>
    where Self: Unpin,

    A convenience for calling Future::poll() on !Unpin types.
    §

    fn or<F>(self, other: F) -> Or<Self, F>
    where Self: Sized, F: Future<Output = Self::Output>,

    Returns the result of self or other future, preferring self if both are ready. Read more
    §

    fn race<F>(self, other: F) -> Race<Self, F>
    where Self: Sized, - F: Future<Output = Self::Output>,

    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F1> FutureExt for F1
    where + F: Future<Output = Self::Output>,

    Available on crate feature std only.
    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F1> FutureExt for F1
    where F1: Future,

    §

    fn join<F2>(self, other: F2) -> Join2<F1, <F2 as IntoFuture>::IntoFuture>
    where F1: Future, F2: IntoFuture,

    Wait for both futures to complete.
    §

    fn race<T, S2>(self, other: S2) -> Race2<T, F1, <S2 as IntoFuture>::IntoFuture>
    where @@ -73,14 +73,14 @@ completed. This method can be used to turn any Future into a FusedFuture. Read more

    §

    fn inspect<F>(self, f: F) -> Inspect<Self, F>
    where F: FnOnce(&Self::Output), Self: Sized,

    Do something with the output of a future before passing it on. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches unwinding panics while polling the future. Read more
    §

    fn shared(self) -> Shared<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches unwinding panics while polling the future. Read more
    §

    fn shared(self) -> Shared<Self>
    where Self: Sized, - Self::Output: Clone,

    Create a cloneable handle to this future where all handles will resolve + Self::Output: Clone,
    Available on crate feature std only.
    Create a cloneable handle to this future where all handles will resolve to the same result. Read more
    §

    fn remote_handle(self) -> (Remote<Self>, RemoteHandle<Self::Output>)
    where - Self: Sized,

    Turn this future into a future that yields () on completion and sends + Self: Sized,
    Available on crate features channel and std only.
    Turn this future into a future that yields () on completion and sends its output to another future on a separate task. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Wrap the future in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Wrap the future in a Box, pinning it. Read more
    §

    fn unit_error(self) -> UnitError<Self>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Wrap the future in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Wrap the future in a Box, pinning it. Read more
    §

    fn unit_error(self) -> UnitError<Self>
    where Self: Sized,

    §

    fn never_error(self) -> NeverError<Self>
    where Self: Sized,

    Turns a Future<Output = T> into a @@ -103,7 +103,7 @@ the future is ready after the first call to Future::poll. Read m F: Future<Output = Result<T, E>> + ?Sized,
    §

    type Ok = T

    §

    type Err = E

    §

    impl<Fut> TryFutureExt for Fut
    where Fut: TryFuture + ?Sized,

    §

    fn flatten_sink<Item>(self) -> FlattenSink<Self, Self::Ok>
    where Self::Ok: Sink<Item, Error = Self::Error>, - Self: Sized,

    Flattens the execution of this future when the successful result of this + Self: Sized,
    Available on crate feature sink only.
    Flattens the execution of this future when the successful result of this future is a [Sink]. Read more
    §

    fn map_ok<T, F>(self, f: F) -> MapOk<Self, F>
    where F: FnOnce(Self::Ok) -> T, Self: Sized,

    Maps this future’s success value to a different value. Read more
    §

    fn map_ok_or_else<T, E, F>(self, e: E, f: F) -> MapOkOrElse<Self, F, E>
    where diff --git a/pr/3024/docs/iroh/endpoint/struct.SendStream.html b/pr/3024/docs/iroh/endpoint/struct.SendStream.html index ee3a4d5a7e..617d9f6a28 100644 --- a/pr/3024/docs/iroh/endpoint/struct.SendStream.html +++ b/pr/3024/docs/iroh/endpoint/struct.SendStream.html @@ -69,7 +69,7 @@ may introduce more latency than using an application-level response of some sort

    If the stream is not ready for writing, the method returns Poll::Pending and arranges for the current task (via cx.waker().wake_by_ref()) to receive a notification when the stream becomes writable or is closed.

    -

    Trait Implementations§

    §

    impl AsyncWrite for SendStream

    Trait Implementations§

    §

    impl AsyncWrite for SendStream

    Available on crate feature runtime-tokio only.
    §

    fn poll_write( self: Pin<&mut SendStream>, cx: &mut Context<'_>, buf: &[u8] diff --git a/pr/3024/docs/iroh/endpoint/struct.ServerConfig.html b/pr/3024/docs/iroh/endpoint/struct.ServerConfig.html index 9d14fbc83c..0b0aa3cd47 100644 --- a/pr/3024/docs/iroh/endpoint/struct.ServerConfig.html +++ b/pr/3024/docs/iroh/endpoint/struct.ServerConfig.html @@ -69,9 +69,9 @@ exhaustion in most contexts.

    §

    impl ServerConfig

    pub fn with_single_cert( cert_chain: Vec<CertificateDer<'static>>, key: PrivateKeyDer<'static> -) -> Result<ServerConfig, Error>

    Create a server config with the given certificate chain to be presented to clients

    +) -> Result<ServerConfig, Error>
    Available on crate feature rustls only.

    Create a server config with the given certificate chain to be presented to clients

    Uses a randomized handshake token key.

    -
    §

    impl ServerConfig

    pub fn with_crypto(crypto: Arc<dyn ServerConfig>) -> ServerConfig

    Create a server config with the given crypto::ServerConfig

    +
    §

    impl ServerConfig

    pub fn with_crypto(crypto: Arc<dyn ServerConfig>) -> ServerConfig

    Available on crate feature ring only.

    Create a server config with the given crypto::ServerConfig

    Uses a randomized handshake token key.

    Trait Implementations§

    §

    impl Clone for ServerConfig

    §

    fn clone(&self) -> ServerConfig

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    §

    impl Debug for ServerConfig

    §

    fn fmt(&self, fmt: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more

    Auto Trait Implementations§

    §

    impl Freeze for ServerConfig

    §

    impl !RefUnwindSafe for ServerConfig

    §

    impl Send for ServerConfig

    §

    impl Sync for ServerConfig

    §

    impl Unpin for ServerConfig

    §

    impl !UnwindSafe for ServerConfig

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where diff --git a/pr/3024/docs/iroh/endpoint/struct.ZeroRttAccepted.html b/pr/3024/docs/iroh/endpoint/struct.ZeroRttAccepted.html index da84359ad5..b8933fcc33 100644 --- a/pr/3024/docs/iroh/endpoint/struct.ZeroRttAccepted.html +++ b/pr/3024/docs/iroh/endpoint/struct.ZeroRttAccepted.html @@ -22,19 +22,19 @@ the current task for wakeup if the value is not yet available. Sized, F: Future<Output = Self::Output>,

    Returns the result of self or other future, preferring self if both are ready. Read more
    §

    fn race<F>(self, other: F) -> Race<Self, F>
    where Self: Sized, - F: Future<Output = Self::Output>,

    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F> FutureExt for F
    where + F: Future<Output = Self::Output>,

    Available on crate features std and race only.
    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F> FutureExt for F
    where F: Future + ?Sized,

    §

    fn poll(&mut self, cx: &mut Context<'_>) -> Poll<Self::Output>
    where Self: Unpin,

    A convenience for calling Future::poll() on !Unpin types.
    §

    fn or<F>(self, other: F) -> Or<Self, F>
    where Self: Sized, F: Future<Output = Self::Output>,

    Returns the result of self or other future, preferring self if both are ready. Read more
    §

    fn race<F>(self, other: F) -> Race<Self, F>
    where Self: Sized, - F: Future<Output = Self::Output>,

    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F1> FutureExt for F1
    where + F: Future<Output = Self::Output>,

    Available on crate feature std only.
    Returns the result of self or other future, with no preference if both are ready. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches panics while polling the future. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + Send + 'a. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Boxes the future and changes its type to dyn Future + 'a. Read more
    §

    impl<F1> FutureExt for F1
    where F1: Future,

    §

    fn join<F2>(self, other: F2) -> Join2<F1, <F2 as IntoFuture>::IntoFuture>
    where F1: Future, F2: IntoFuture,

    Wait for both futures to complete.
    §

    fn race<T, S2>(self, other: S2) -> Race2<T, F1, <S2 as IntoFuture>::IntoFuture>
    where @@ -74,14 +74,14 @@ completed. This method can be used to turn any Future into a FusedFuture. Read more

    §

    fn inspect<F>(self, f: F) -> Inspect<Self, F>
    where F: FnOnce(&Self::Output), Self: Sized,

    Do something with the output of a future before passing it on. Read more
    §

    fn catch_unwind(self) -> CatchUnwind<Self>
    where - Self: Sized + UnwindSafe,

    Catches unwinding panics while polling the future. Read more
    §

    fn shared(self) -> Shared<Self>
    where + Self: Sized + UnwindSafe,

    Available on crate feature std only.
    Catches unwinding panics while polling the future. Read more
    §

    fn shared(self) -> Shared<Self>
    where Self: Sized, - Self::Output: Clone,

    Create a cloneable handle to this future where all handles will resolve + Self::Output: Clone,
    Available on crate feature std only.
    Create a cloneable handle to this future where all handles will resolve to the same result. Read more
    §

    fn remote_handle(self) -> (Remote<Self>, RemoteHandle<Self::Output>)
    where - Self: Sized,

    Turn this future into a future that yields () on completion and sends + Self: Sized,
    Available on crate features channel and std only.
    Turn this future into a future that yields () on completion and sends its output to another future on a separate task. Read more
    §

    fn boxed<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + Send + 'a>>
    where - Self: Sized + Send + 'a,

    Wrap the future in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where - Self: Sized + 'a,

    Wrap the future in a Box, pinning it. Read more
    §

    fn unit_error(self) -> UnitError<Self>
    where + Self: Sized + Send + 'a,

    Available on crate feature alloc only.
    Wrap the future in a Box, pinning it. Read more
    §

    fn boxed_local<'a>(self) -> Pin<Box<dyn Future<Output = Self::Output> + 'a>>
    where + Self: Sized + 'a,

    Available on crate feature alloc only.
    Wrap the future in a Box, pinning it. Read more
    §

    fn unit_error(self) -> UnitError<Self>
    where Self: Sized,

    §

    fn never_error(self) -> NeverError<Self>
    where Self: Sized,

    Turns a Future<Output = T> into a diff --git a/pr/3024/docs/iroh/hash/index.html b/pr/3024/docs/iroh/hash/index.html index 45a816dc9a..94216845d3 100644 --- a/pr/3024/docs/iroh/hash/index.html +++ b/pr/3024/docs/iroh/hash/index.html @@ -1,2 +1,2 @@ -iroh::hash - Rust

    Module iroh::hash

    source ·
    Expand description

    The blake3 hash used in Iroh.

    +iroh::hash - Rust

    Module iroh::hash

    source ·
    Expand description

    The blake3 hash used in Iroh.

    Structs§

    Enums§

    \ No newline at end of file diff --git a/pr/3024/docs/iroh/hash/struct.Hash.html b/pr/3024/docs/iroh/hash/struct.Hash.html index 831bcf7be2..1b3dfc8056 100644 --- a/pr/3024/docs/iroh/hash/struct.Hash.html +++ b/pr/3024/docs/iroh/hash/struct.Hash.html @@ -12,7 +12,7 @@ representation of the hash.

    D: Deserializer<'de>,
    Deserialize this value from the given Serde deserializer. Read more
    source§

    impl Display for Hash

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    source§

    impl From<&[u8; 32]> for Hash

    source§

    fn from(value: &[u8; 32]) -> Hash

    Converts to this type from the input type.
    source§

    impl From<[u8; 32]> for Hash

    source§

    fn from(value: [u8; 32]) -> Hash

    Converts to this type from the input type.
    source§

    impl From<Hash> for [u8; 32]

    source§

    fn from(value: Hash) -> [u8; 32]

    Converts to this type from the input type.
    source§

    impl From<Hash> for Hash

    source§

    fn from(value: Hash) -> Hash

    Converts to this type from the input type.
    source§

    impl FromStr for Hash

    §

    type Err = HexOrBase32ParseError

    The associated error which can be returned from parsing.
    source§

    fn from_str(s: &str) -> Result<Hash, <Hash as FromStr>::Err>

    Parses a string s to return a value of this type. Read more
    source§

    impl Hash for Hash

    source§

    fn hash<__H>(&self, state: &mut __H)
    where __H: Hasher,

    Feeds this value into the given Hasher. Read more
    1.3.0 · source§

    fn hash_slice<H>(data: &[Self], state: &mut H)
    where H: Hasher, - Self: Sized,

    Feeds a slice of this type into the given Hasher. Read more
    source§

    impl Key for Hash

    source§

    fn compare(data1: &[u8], data2: &[u8]) -> Ordering

    Compare data1 with data2
    source§

    impl MaxSize for Hash

    source§

    const POSTCARD_MAX_SIZE: usize = 32usize

    The maximum possible size that the serialization of this + Self: Sized,
    Feeds a slice of this type into the given Hasher. Read more
    source§

    impl Key for Hash

    source§

    fn compare(data1: &[u8], data2: &[u8]) -> Ordering

    Compare data1 with data2
    source§

    impl MaxSize for Hash

    source§

    const POSTCARD_MAX_SIZE: usize = 32usize

    The maximum possible size that the serialization of this type can have, in bytes.
    source§

    impl Ord for Hash

    source§

    fn cmp(&self, other: &Hash) -> Ordering

    This method returns an Ordering between self and other. Read more
    1.21.0 · source§

    fn max(self, other: Self) -> Self
    where Self: Sized,

    Compares and returns the maximum of two values. Read more
    1.21.0 · source§

    fn min(self, other: Self) -> Self
    where Self: Sized,

    Compares and returns the minimum of two values. Read more
    1.50.0 · source§

    fn clamp(self, min: Self, max: Self) -> Self
    where @@ -24,13 +24,13 @@ operator. Result<<S as Serializer>::Ok, <S as Serializer>::Error>
    where - S: Serializer,

    Serialize this value into the given Serde serializer. Read more
    source§

    impl Value for Hash

    §

    type SelfType<'a> = Hash

    SelfType<’a> must be the same type as Self with all lifetimes replaced with ’a
    §

    type AsBytes<'a> = &'a [u8; 32]

    source§

    fn fixed_width() -> Option<usize>

    Width of a fixed type, or None for variable width
    source§

    fn from_bytes<'a>(data: &'a [u8]) -> <Hash as Value>::SelfType<'a>
    where + S: Serializer,

    Serialize this value into the given Serde serializer. Read more
    source§

    impl Value for Hash

    §

    type SelfType<'a> = Hash

    SelfType<’a> must be the same type as Self with all lifetimes replaced with ’a
    §

    type AsBytes<'a> = &'a [u8; 32]

    source§

    fn fixed_width() -> Option<usize>

    Width of a fixed type, or None for variable width
    source§

    fn from_bytes<'a>(data: &'a [u8]) -> <Hash as Value>::SelfType<'a>
    where Hash: 'a,

    Deserializes data -Implementations may return a view over data, or an owned type
    source§

    fn as_bytes<'a, 'b>( +Implementations may return a view over data, or an owned type

    source§

    fn as_bytes<'a, 'b>( value: &'a <Hash as Value>::SelfType<'b> ) -> <Hash as Value>::AsBytes<'a>
    where 'b: 'a, - Hash: 'a + 'b,

    Serialize the value to a slice
    source§

    fn type_name() -> TypeName

    Globally unique identifier for this type
    source§

    impl Copy for Hash

    source§

    impl Eq for Hash

    source§

    impl StructuralPartialEq for Hash

    Auto Trait Implementations§

    §

    impl Freeze for Hash

    §

    impl RefUnwindSafe for Hash

    §

    impl Send for Hash

    §

    impl Sync for Hash

    §

    impl Unpin for Hash

    §

    impl UnwindSafe for Hash

    Blanket Implementations§

    source§

    impl<T> Any for T
    where + Hash: 'a + 'b,

    Serialize the value to a slice
    source§

    fn type_name() -> TypeName

    Globally unique identifier for this type
    source§

    impl Copy for Hash

    source§

    impl Eq for Hash

    source§

    impl StructuralPartialEq for Hash

    Auto Trait Implementations§

    §

    impl Freeze for Hash

    §

    impl RefUnwindSafe for Hash

    §

    impl Send for Hash

    §

    impl Sync for Hash

    §

    impl Unpin for Hash

    §

    impl UnwindSafe for Hash

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/iroh/hash/struct.HashAndFormat.html b/pr/3024/docs/iroh/hash/struct.HashAndFormat.html index 55d219540e..789aa41fc7 100644 --- a/pr/3024/docs/iroh/hash/struct.HashAndFormat.html +++ b/pr/3024/docs/iroh/hash/struct.HashAndFormat.html @@ -4,13 +4,13 @@ }
    Expand description

    A hash and format pair

    Fields§

    §hash: Hash

    The hash

    §format: BlobFormat

    The format

    -

    Implementations§

    source§

    impl HashAndFormat

    source

    pub fn new(hash: Hash, format: BlobFormat) -> HashAndFormat

    Create a new hash and format pair.

    -
    source

    pub fn raw(hash: Hash) -> HashAndFormat

    Create a new hash and format pair, using the default (raw) format.

    -
    source

    pub fn hash_seq(hash: Hash) -> HashAndFormat

    Create a new hash and format pair, using the collection format.

    -

    Trait Implementations§

    source§

    impl Clone for HashAndFormat

    source§

    fn clone(&self) -> HashAndFormat

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for HashAndFormat

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    source§

    impl<'de> Deserialize<'de> for HashAndFormat

    Implementations§

    source§

    impl HashAndFormat

    source

    pub fn new(hash: Hash, format: BlobFormat) -> HashAndFormat

    Create a new hash and format pair.

    +
    source

    pub fn raw(hash: Hash) -> HashAndFormat

    Create a new hash and format pair, using the default (raw) format.

    +
    source

    pub fn hash_seq(hash: Hash) -> HashAndFormat

    Create a new hash and format pair, using the collection format.

    +

    Trait Implementations§

    source§

    impl Clone for HashAndFormat

    source§

    fn clone(&self) -> HashAndFormat

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for HashAndFormat

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    source§

    impl<'de> Deserialize<'de> for HashAndFormat

    source§

    fn deserialize<D>( deserializer: D ) -> Result<HashAndFormat, <D as Deserializer<'de>>::Error>
    where - D: Deserializer<'de>,

    Deserialize this value from the given Serde deserializer. Read more
    source§

    impl Display for HashAndFormat

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    source§

    impl FromStr for HashAndFormat

    §

    type Err = Error

    The associated error which can be returned from parsing.
    source§

    fn from_str(s: &str) -> Result<HashAndFormat, <HashAndFormat as FromStr>::Err>

    Parses a string s to return a value of this type. Read more
    source§

    impl Hash for HashAndFormat

    source§

    fn hash<__H>(&self, state: &mut __H)
    where + D: Deserializer<'de>,

    Deserialize this value from the given Serde deserializer. Read more
    source§

    impl Display for HashAndFormat

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    source§

    impl FromStr for HashAndFormat

    §

    type Err = Error

    The associated error which can be returned from parsing.
    source§

    fn from_str(s: &str) -> Result<HashAndFormat, <HashAndFormat as FromStr>::Err>

    Parses a string s to return a value of this type. Read more
    source§

    impl Hash for HashAndFormat

    source§

    fn hash<__H>(&self, state: &mut __H)
    where __H: Hasher,

    Feeds this value into the given Hasher. Read more
    1.3.0 · source§

    fn hash_slice<H>(data: &[Self], state: &mut H)
    where H: Hasher, Self: Sized,

    Feeds a slice of this type into the given Hasher. Read more
    source§

    impl MaxSize for HashAndFormat

    source§

    const POSTCARD_MAX_SIZE: usize = 33usize

    The maximum possible size that the serialization of this @@ -21,17 +21,17 @@ type can have, in bytes.
    1.0.0 · source§

    fn ne(&self, other: &Rhs) -> bool

    This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
    source§

    impl PartialOrd for HashAndFormat

    source§

    fn partial_cmp(&self, other: &HashAndFormat) -> Option<Ordering>

    This method returns an ordering between self and other values if one exists. Read more
    1.0.0 · source§

    fn lt(&self, other: &Rhs) -> bool

    This method tests less than (for self and other) and is used by the < operator. Read more
    1.0.0 · source§

    fn le(&self, other: &Rhs) -> bool

    This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
    1.0.0 · source§

    fn gt(&self, other: &Rhs) -> bool

    This method tests greater than (for self and other) and is used by the > operator. Read more
    1.0.0 · source§

    fn ge(&self, other: &Rhs) -> bool

    This method tests greater than or equal to (for self and other) and is used by the >= -operator. Read more
    source§

    impl Serialize for HashAndFormat

    source§

    fn serialize<S>( +operator. Read more

    source§

    impl Serialize for HashAndFormat

    source§

    fn serialize<S>( &self, serializer: S ) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>
    where - S: Serializer,

    Serialize this value into the given Serde serializer. Read more
    source§

    impl Value for HashAndFormat

    §

    type SelfType<'a> = HashAndFormat

    SelfType<’a> must be the same type as Self with all lifetimes replaced with ’a
    §

    type AsBytes<'a> = [u8; 33]

    source§

    fn fixed_width() -> Option<usize>

    Width of a fixed type, or None for variable width
    source§

    fn from_bytes<'a>(data: &'a [u8]) -> <HashAndFormat as Value>::SelfType<'a>
    where + S: Serializer,

    Serialize this value into the given Serde serializer. Read more
    source§

    impl Value for HashAndFormat

    §

    type SelfType<'a> = HashAndFormat

    SelfType<’a> must be the same type as Self with all lifetimes replaced with ’a
    §

    type AsBytes<'a> = [u8; 33]

    source§

    fn fixed_width() -> Option<usize>

    Width of a fixed type, or None for variable width
    source§

    fn from_bytes<'a>(data: &'a [u8]) -> <HashAndFormat as Value>::SelfType<'a>
    where HashAndFormat: 'a,

    Deserializes data -Implementations may return a view over data, or an owned type
    source§

    fn as_bytes<'a, 'b>( +Implementations may return a view over data, or an owned type

    source§

    fn as_bytes<'a, 'b>( value: &'a <HashAndFormat as Value>::SelfType<'b> ) -> <HashAndFormat as Value>::AsBytes<'a>
    where 'b: 'a, - HashAndFormat: 'a + 'b,

    Serialize the value to a slice
    source§

    fn type_name() -> TypeName

    Globally unique identifier for this type
    source§

    impl Copy for HashAndFormat

    source§

    impl Eq for HashAndFormat

    source§

    impl StructuralPartialEq for HashAndFormat

    Auto Trait Implementations§

    §

    impl Freeze for HashAndFormat

    §

    impl RefUnwindSafe for HashAndFormat

    §

    impl Send for HashAndFormat

    §

    impl Sync for HashAndFormat

    §

    impl Unpin for HashAndFormat

    §

    impl UnwindSafe for HashAndFormat

    Blanket Implementations§

    source§

    impl<T> Any for T
    where + HashAndFormat: 'a + 'b,

    Serialize the value to a slice
    source§

    fn type_name() -> TypeName

    Globally unique identifier for this type
    source§

    impl Copy for HashAndFormat

    source§

    impl Eq for HashAndFormat

    source§

    impl StructuralPartialEq for HashAndFormat

    Auto Trait Implementations§

    §

    impl Freeze for HashAndFormat

    §

    impl RefUnwindSafe for HashAndFormat

    §

    impl Send for HashAndFormat

    §

    impl Sync for HashAndFormat

    §

    impl Unpin for HashAndFormat

    §

    impl UnwindSafe for HashAndFormat

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/iroh/index.html b/pr/3024/docs/iroh/index.html index 9c5235f8c7..04dc7f19ad 100644 --- a/pr/3024/docs/iroh/index.html +++ b/pr/3024/docs/iroh/index.html @@ -1,4 +1,4 @@ -iroh - Rust

    Crate iroh

    source ·
    Expand description

    Peer-to-peer QUIC connections.

    +iroh - Rust

    Crate iroh

    source ·
    Expand description

    Peer-to-peer QUIC connections.

    iroh is a library to establish direct connectivity between peers. It exposes an interface to QUIC connections and streams to the user, while implementing direct connectivity using hole punching complemented by relay servers under the hood.

    @@ -163,4 +163,4 @@ connecting using only the < }

    Please see the examples directory for more nuanced examples.

    Re-exports§

    Modules§

    • Default values used in iroh
    • Node address discovery.
    • This module exports a DNS resolver, which is also the default resolver used in the -crate::Endpoint if no custom resolver is configured.
    • The Endpoint allows establishing connections to other iroh nodes.
    • The blake3 hash used in Iroh.
    • Cryptographic key handling for iroh.
    • Co-locating all of the iroh metrics structs
    • Tools for spawning an accept loop that routes incoming requests to the right protocol.
    • test_utilstest or test-utils
      Internal utilities to support testing.

    Structs§

    • Network-level addressing information for an iroh node.
    • Configuration of all the relay servers that can be used.
    • Information on a specific relay server.
    • A URL identifying a relay server.

    Enums§

    Type Aliases§

    • The identifier for a node in the (iroh) network.
    \ No newline at end of file +crate::Endpoint if no custom resolver is configured.

  • The Endpoint allows establishing connections to other iroh nodes.
  • The blake3 hash used in Iroh.
  • Cryptographic key handling for iroh.
  • Co-locating all of the iroh metrics structs
  • Tools for spawning an accept loop that routes incoming requests to the right protocol.
  • test_utilstest-utils
    Internal utilities to support testing.
  • Structs§

    • Network-level addressing information for an iroh node.
    • Configuration of all the relay servers that can be used.
    • Information on a specific relay server.
    • A URL identifying a relay server.

    Enums§

    Type Aliases§

    • The identifier for a node in the (iroh) network.
    \ No newline at end of file diff --git a/pr/3024/docs/iroh/key/index.html b/pr/3024/docs/iroh/key/index.html index 92f9899f5a..92bc09ec53 100644 --- a/pr/3024/docs/iroh/key/index.html +++ b/pr/3024/docs/iroh/key/index.html @@ -1,2 +1,2 @@ -iroh::key - Rust

    Module iroh::key

    source ·
    Expand description

    Cryptographic key handling for iroh.

    +iroh::key - Rust

    Module iroh::key

    source ·
    Expand description

    Cryptographic key handling for iroh.

    Structs§

    Enums§

    Constants§

    Type Aliases§

    • The identifier for a node in the (iroh) network.
    \ No newline at end of file diff --git a/pr/3024/docs/iroh/key/struct.Signature.html b/pr/3024/docs/iroh/key/struct.Signature.html index 286912257b..ad978995bc 100644 --- a/pr/3024/docs/iroh/key/struct.Signature.html +++ b/pr/3024/docs/iroh/key/struct.Signature.html @@ -16,7 +16,7 @@ elements at the time a signature is verified.

    pub fn r_bytes(&self) -> &[u8; 32]

    Bytes for the R component of a signature.

    pub fn s_bytes(&self) -> &[u8; 32]

    Bytes for the s component of a signature.

    pub fn to_bytes(&self) -> [u8; 64]

    Return the inner byte array.

    -

    pub fn to_vec(&self) -> Vec<u8> ⓘ

    Convert this signature into a byte vector.

    +

    pub fn to_vec(&self) -> Vec<u8> ⓘ

    Available on crate feature alloc only.

    Convert this signature into a byte vector.

    Trait Implementations§

    §

    impl Clone for Signature

    §

    fn clone(&self) -> Signature

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    §

    impl Debug for Signature

    §

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    §

    impl<'de> Deserialize<'de> for Signature

    §

    fn deserialize<D>( deserializer: D ) -> Result<Signature, <D as Deserializer<'de>>::Error>
    where @@ -29,7 +29,7 @@ sufficient, and should not be overridden without very good reason.
    Result<<S as Serializer>::Ok, <S as Serializer>::Error>
    where - S: Serializer,

    Serialize this value into the given Serde serializer. Read more
    §

    impl SignatureEncoding for Signature

    §

    type Repr = [u8; 64]

    Byte representation of a signature.
    §

    fn to_bytes(&self) -> [u8; 64]

    Encode signature as its byte representation.
    §

    fn to_vec(&self) -> Vec<u8> ⓘ

    Encode signature as a byte vector.
    §

    fn encoded_len(&self) -> usize

    Get the length of this signature when encoded.
    §

    impl TryFrom<&[u8]> for Signature

    §

    type Error = Error

    The type returned in the event of a conversion error.
    §

    fn try_from(bytes: &[u8]) -> Result<Signature, Error>

    Performs the conversion.
    §

    impl TryFrom<&Signature> for Signature

    §

    type Error = Error

    The type returned in the event of a conversion error.
    §

    fn try_from(signature: &Signature) -> Result<Signature, Error>

    Performs the conversion.
    §

    impl TryFrom<Signature> for Signature

    §

    type Error = Error

    The type returned in the event of a conversion error.
    §

    fn try_from(signature: Signature) -> Result<Signature, Error>

    Performs the conversion.
    §

    impl UpperHex for Signature

    §

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter.
    §

    impl Copy for Signature

    §

    impl Eq for Signature

    §

    impl StructuralPartialEq for Signature

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where + S: Serializer,

    Serialize this value into the given Serde serializer. Read more
    §

    impl SignatureEncoding for Signature

    §

    type Repr = [u8; 64]

    Byte representation of a signature.
    §

    fn to_bytes(&self) -> [u8; 64]

    Encode signature as its byte representation.
    §

    fn to_vec(&self) -> Vec<u8> ⓘ

    Available on crate feature alloc only.
    Encode signature as a byte vector.
    §

    fn encoded_len(&self) -> usize

    Get the length of this signature when encoded.
    §

    impl TryFrom<&[u8]> for Signature

    §

    type Error = Error

    The type returned in the event of a conversion error.
    §

    fn try_from(bytes: &[u8]) -> Result<Signature, Error>

    Performs the conversion.
    §

    impl TryFrom<&Signature> for Signature

    Available on crate feature ed25519 only.
    §

    type Error = Error

    The type returned in the event of a conversion error.
    §

    fn try_from(signature: &Signature) -> Result<Signature, Error>

    Performs the conversion.
    §

    impl TryFrom<Signature> for Signature

    Available on crate feature ed25519 only.
    §

    type Error = Error

    The type returned in the event of a conversion error.
    §

    fn try_from(signature: Signature) -> Result<Signature, Error>

    Performs the conversion.
    §

    impl UpperHex for Signature

    §

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter.
    §

    impl Copy for Signature

    §

    impl Eq for Signature

    §

    impl StructuralPartialEq for Signature

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/iroh/metrics/index.html b/pr/3024/docs/iroh/metrics/index.html index f64bea2a36..6992fd2fba 100644 --- a/pr/3024/docs/iroh/metrics/index.html +++ b/pr/3024/docs/iroh/metrics/index.html @@ -1,2 +1,2 @@ -iroh::metrics - Rust

    Module iroh::metrics

    source ·
    Expand description

    Co-locating all of the iroh metrics structs

    +iroh::metrics - Rust

    Module iroh::metrics

    source ·
    Expand description

    Co-locating all of the iroh metrics structs

    Structs§

    \ No newline at end of file diff --git a/pr/3024/docs/iroh/metrics/struct.MagicsockMetrics.html b/pr/3024/docs/iroh/metrics/struct.MagicsockMetrics.html index 345da9fc69..02e53af3b6 100644 --- a/pr/3024/docs/iroh/metrics/struct.MagicsockMetrics.html +++ b/pr/3024/docs/iroh/metrics/struct.MagicsockMetrics.html @@ -55,8 +55,8 @@
    §nodes_contacted_directly: Counter

    Number of nodes we have managed to contact directly.

    §connection_handshake_success: Counter

    Number of connections with a successful handshake.

    §connection_became_direct: Counter

    Number of connections with a successful handshake that became direct.

    -

    Trait Implementations§

    source§

    impl Clone for Metrics

    source§

    fn clone(&self) -> Metrics

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for Metrics

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Default for Metrics

    source§

    fn default() -> Self

    Returns the “default value” for a type. Read more
    source§

    impl Iterable for Metrics

    source§

    fn iter<'a>(&'a self) -> IntoIter<(&'static str, &'a dyn Any)>

    Returns an iterator over the struct’s fields as tuples. Read more
    source§

    impl Metric for Metrics

    source§

    fn name() -> &'static str

    The name of this metric group.
    §

    fn new(registry: &mut Registry) -> Self

    Initializes this metric group.
    §

    fn with_metric<T, F>(f: F)
    where - F: FnOnce(&Self) -> T,

    Access to this metrics group to record a metric. +

    Trait Implementations§

    source§

    impl Clone for Metrics

    source§

    fn clone(&self) -> Metrics

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for Metrics

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Default for Metrics

    source§

    fn default() -> Self

    Returns the “default value” for a type. Read more
    source§

    impl Iterable for Metrics

    source§

    fn iter<'a>(&'a self) -> IntoIter<(&'static str, &'a dyn Any)>

    Returns an iterator over the struct’s fields as tuples. Read more
    source§

    impl Metric for Metrics

    source§

    fn name() -> &'static str

    The name of this metric group.
    §

    fn new(registry: &mut Registry) -> Self

    Available on crate feature metrics only.
    Initializes this metric group.
    §

    fn with_metric<T, F>(f: F)
    where + F: FnOnce(&Self) -> T,

    Available on crate feature metrics only.
    Access to this metrics group to record a metric. Only records if this metric is registered in the global registry.
    §

    fn try_get() -> Option<&'static Self>

    Attempts to get the current metric from the global registry.

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where diff --git a/pr/3024/docs/iroh/metrics/struct.NetReportMetrics.html b/pr/3024/docs/iroh/metrics/struct.NetReportMetrics.html index 37879fb743..a1fa6b06ff 100644 --- a/pr/3024/docs/iroh/metrics/struct.NetReportMetrics.html +++ b/pr/3024/docs/iroh/metrics/struct.NetReportMetrics.html @@ -7,8 +7,8 @@ pub reports: Counter, pub reports_full: Counter, }
    Expand description

    Enum of metrics for the module

    -

    Fields§

    §stun_packets_dropped: Counter§stun_packets_sent_ipv4: Counter§stun_packets_sent_ipv6: Counter§stun_packets_recv_ipv4: Counter§stun_packets_recv_ipv6: Counter§reports: Counter§reports_full: Counter

    Trait Implementations§

    source§

    impl Clone for Metrics

    source§

    fn clone(&self) -> Metrics

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for Metrics

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    source§

    impl Default for Metrics

    source§

    fn default() -> Metrics

    Returns the “default value” for a type. Read more
    source§

    impl Iterable for Metrics

    source§

    fn iter<'a>(&'a self) -> IntoIter<(&'static str, &'a (dyn Any + 'static))>

    Returns an iterator over the struct’s fields as tuples. Read more
    source§

    impl Metric for Metrics

    source§

    fn name() -> &'static str

    The name of this metric group.
    §

    fn new(registry: &mut Registry) -> Self

    Initializes this metric group.
    §

    fn with_metric<T, F>(f: F)
    where - F: FnOnce(&Self) -> T,

    Access to this metrics group to record a metric. +

    Fields§

    §stun_packets_dropped: Counter§stun_packets_sent_ipv4: Counter§stun_packets_sent_ipv6: Counter§stun_packets_recv_ipv4: Counter§stun_packets_recv_ipv6: Counter§reports: Counter§reports_full: Counter

    Trait Implementations§

    source§

    impl Clone for Metrics

    source§

    fn clone(&self) -> Metrics

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for Metrics

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    source§

    impl Default for Metrics

    source§

    fn default() -> Metrics

    Returns the “default value” for a type. Read more
    source§

    impl Iterable for Metrics

    source§

    fn iter<'a>(&'a self) -> IntoIter<(&'static str, &'a (dyn Any + 'static))>

    Returns an iterator over the struct’s fields as tuples. Read more
    source§

    impl Metric for Metrics

    source§

    fn name() -> &'static str

    The name of this metric group.
    §

    fn new(registry: &mut Registry) -> Self

    Available on crate feature metrics only.
    Initializes this metric group.
    §

    fn with_metric<T, F>(f: F)
    where + F: FnOnce(&Self) -> T,

    Available on crate feature metrics only.
    Access to this metrics group to record a metric. Only records if this metric is registered in the global registry.
    §

    fn try_get() -> Option<&'static Self>

    Attempts to get the current metric from the global registry.

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where diff --git a/pr/3024/docs/iroh/metrics/struct.PortmapMetrics.html b/pr/3024/docs/iroh/metrics/struct.PortmapMetrics.html index b0db938b80..4a244f75fb 100644 --- a/pr/3024/docs/iroh/metrics/struct.PortmapMetrics.html +++ b/pr/3024/docs/iroh/metrics/struct.PortmapMetrics.html @@ -11,8 +11,8 @@ pub pcp_probes: Counter, pub pcp_available: Counter, }
    Expand description

    Enum of metrics for the module

    -

    Fields§

    §probes_started: Counter§local_port_updates: Counter§mapping_attempts: Counter§mapping_failures: Counter§external_address_updated: Counter§upnp_probes: Counter§upnp_probes_failed: Counter§upnp_available: Counter§upnp_gateway_updated: Counter§pcp_probes: Counter§pcp_available: Counter

    Trait Implementations§

    §

    impl Clone for Metrics

    §

    fn clone(&self) -> Metrics

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    §

    impl Debug for Metrics

    §

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    §

    impl Default for Metrics

    §

    fn default() -> Metrics

    Returns the “default value” for a type. Read more
    §

    impl Iterable for Metrics

    §

    fn iter<'a>(&'a self) -> IntoIter<(&'static str, &'a (dyn Any + 'static))>

    Returns an iterator over the struct’s fields as tuples. Read more
    §

    impl Metric for Metrics

    §

    fn name() -> &'static str

    The name of this metric group.
    §

    fn new(registry: &mut Registry) -> Self

    Initializes this metric group.
    §

    fn with_metric<T, F>(f: F)
    where - F: FnOnce(&Self) -> T,

    Access to this metrics group to record a metric. +

    Fields§

    §probes_started: Counter§local_port_updates: Counter§mapping_attempts: Counter§mapping_failures: Counter§external_address_updated: Counter§upnp_probes: Counter§upnp_probes_failed: Counter§upnp_available: Counter§upnp_gateway_updated: Counter§pcp_probes: Counter§pcp_available: Counter

    Trait Implementations§

    §

    impl Clone for Metrics

    §

    fn clone(&self) -> Metrics

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    §

    impl Debug for Metrics

    §

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    §

    impl Default for Metrics

    §

    fn default() -> Metrics

    Returns the “default value” for a type. Read more
    §

    impl Iterable for Metrics

    §

    fn iter<'a>(&'a self) -> IntoIter<(&'static str, &'a (dyn Any + 'static))>

    Returns an iterator over the struct’s fields as tuples. Read more
    §

    impl Metric for Metrics

    §

    fn name() -> &'static str

    The name of this metric group.
    §

    fn new(registry: &mut Registry) -> Self

    Available on crate feature metrics only.
    Initializes this metric group.
    §

    fn with_metric<T, F>(f: F)
    where + F: FnOnce(&Self) -> T,

    Available on crate feature metrics only.
    Access to this metrics group to record a metric. Only records if this metric is registered in the global registry.
    §

    fn try_get() -> Option<&'static Self>

    Attempts to get the current metric from the global registry.

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where diff --git a/pr/3024/docs/iroh/metrics/struct.RelayMetrics.html b/pr/3024/docs/iroh/metrics/struct.RelayMetrics.html index 8cf034eec0..2828f3a914 100644 --- a/pr/3024/docs/iroh/metrics/struct.RelayMetrics.html +++ b/pr/3024/docs/iroh/metrics/struct.RelayMetrics.html @@ -42,8 +42,8 @@
    §unique_client_keys: Counter

    Number of unique client keys per day

    §websocket_accepts: Counter

    Number of accepted websocket connections

    §derp_accepts: Counter

    Number of accepted ‘iroh derp http’ connection upgrades

    -

    Trait Implementations§

    source§

    impl Clone for Metrics

    source§

    fn clone(&self) -> Metrics

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for Metrics

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    source§

    impl Default for Metrics

    source§

    fn default() -> Metrics

    Returns the “default value” for a type. Read more
    source§

    impl Iterable for Metrics

    source§

    fn iter<'a>(&'a self) -> IntoIter<(&'static str, &'a (dyn Any + 'static))>

    Returns an iterator over the struct’s fields as tuples. Read more
    source§

    impl Metric for Metrics

    source§

    fn name() -> &'static str

    The name of this metric group.
    §

    fn new(registry: &mut Registry) -> Self

    Initializes this metric group.
    §

    fn with_metric<T, F>(f: F)
    where - F: FnOnce(&Self) -> T,

    Access to this metrics group to record a metric. +

    Trait Implementations§

    source§

    impl Clone for Metrics

    source§

    fn clone(&self) -> Metrics

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for Metrics

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    source§

    impl Default for Metrics

    source§

    fn default() -> Metrics

    Returns the “default value” for a type. Read more
    source§

    impl Iterable for Metrics

    source§

    fn iter<'a>(&'a self) -> IntoIter<(&'static str, &'a (dyn Any + 'static))>

    Returns an iterator over the struct’s fields as tuples. Read more
    source§

    impl Metric for Metrics

    source§

    fn name() -> &'static str

    The name of this metric group.
    §

    fn new(registry: &mut Registry) -> Self

    Available on crate feature metrics only.
    Initializes this metric group.
    §

    fn with_metric<T, F>(f: F)
    where + F: FnOnce(&Self) -> T,

    Available on crate feature metrics only.
    Access to this metrics group to record a metric. Only records if this metric is registered in the global registry.
    §

    fn try_get() -> Option<&'static Self>

    Attempts to get the current metric from the global registry.

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where diff --git a/pr/3024/docs/iroh/struct.RelayUrl.html b/pr/3024/docs/iroh/struct.RelayUrl.html index f5e27baa0c..bf5ee34f01 100644 --- a/pr/3024/docs/iroh/struct.RelayUrl.html +++ b/pr/3024/docs/iroh/struct.RelayUrl.html @@ -311,7 +311,7 @@ For other schemes, it is the same as Url::port().

    source

    pub fn socket_addrs( &self, default_port_number: impl Fn() -> Option<u16> -) -> Result<Vec<SocketAddr>, Error>

    Resolve a URL’s host and port number to SocketAddr.

    +) -> Result<Vec<SocketAddr>, Error>

    Available on crate feature std and (Unix or Windows or Redox or WASI or HermitCore) only.

    Resolve a URL’s host and port number to SocketAddr.

    If the URL has the default port number of a scheme that is unknown to this library, default_port_number provides an opportunity to provide the actual port number. In non-example code this should be implemented either simply as || None, @@ -426,11 +426,11 @@ but the input may have been percent-encoded already.

    &self, serializer: S ) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>
    where - S: Serializer,

    Serialize with Serde using the internal representation of the Url struct.

    + S: Serializer,

    Available on crate feature serde only.

    Serialize with Serde using the internal representation of the Url struct.

    The corresponding deserialize_internal method sacrifices some invariant-checking for speed, compared to the Deserialize trait impl.

    This method is only available if the serde Cargo feature is enabled.

    -
    source

    pub fn to_file_path(&self) -> Result<PathBuf, ()>

    Assuming the URL is in the file scheme or similar, +

    source

    pub fn to_file_path(&self) -> Result<PathBuf, ()>

    Available on crate feature std and (Unix or Windows or Redox or WASI or HermitCore) only.

    Assuming the URL is in the file scheme or similar, convert its path to an absolute std::path::Path.

    Note: This does not actually check the URL’s scheme, and may give nonsensical results for other schemes. diff --git a/pr/3024/docs/iroh/test_utils/fn.create_dns_resolver.html b/pr/3024/docs/iroh/test_utils/fn.create_dns_resolver.html index 930b8d6daf..b900e27979 100644 --- a/pr/3024/docs/iroh/test_utils/fn.create_dns_resolver.html +++ b/pr/3024/docs/iroh/test_utils/fn.create_dns_resolver.html @@ -1,2 +1,2 @@ -create_dns_resolver in iroh::test_utils - Rust

    Function iroh::test_utils::create_dns_resolver

    source ·
    pub fn create_dns_resolver(nameserver: SocketAddr) -> Result<TokioResolver>
    Available on test or crate feature test-utils only.
    Expand description

    Create a DNS resolver with a single nameserver.

    +create_dns_resolver in iroh::test_utils - Rust

    Function iroh::test_utils::create_dns_resolver

    source ·
    pub fn create_dns_resolver(nameserver: SocketAddr) -> Result<TokioResolver>
    Available on crate feature test-utils only.
    Expand description

    Create a DNS resolver with a single nameserver.

    \ No newline at end of file diff --git a/pr/3024/docs/iroh/test_utils/fn.run_relay_server.html b/pr/3024/docs/iroh/test_utils/fn.run_relay_server.html index 3bb9643cf0..42c26b4ced 100644 --- a/pr/3024/docs/iroh/test_utils/fn.run_relay_server.html +++ b/pr/3024/docs/iroh/test_utils/fn.run_relay_server.html @@ -1,4 +1,4 @@ -run_relay_server in iroh::test_utils - Rust

    Function iroh::test_utils::run_relay_server

    source ·
    pub async fn run_relay_server() -> Result<(RelayMap, RelayUrl, Server)>
    Available on test or crate feature test-utils only.
    Expand description

    Runs a relay server with STUN and QUIC enabled suitable for tests.

    +run_relay_server in iroh::test_utils - Rust

    Function iroh::test_utils::run_relay_server

    source ·
    pub async fn run_relay_server() -> Result<(RelayMap, RelayUrl, Server)>
    Available on crate feature test-utils only.
    Expand description

    Runs a relay server with STUN and QUIC enabled suitable for tests.

    The returned Url is the url of the relay server in the returned RelayMap. When dropped, the returned Server does will stop running.

    \ No newline at end of file diff --git a/pr/3024/docs/iroh/test_utils/fn.run_relay_server_with.html b/pr/3024/docs/iroh/test_utils/fn.run_relay_server_with.html index 5feacf2e7f..06aaa1821e 100644 --- a/pr/3024/docs/iroh/test_utils/fn.run_relay_server_with.html +++ b/pr/3024/docs/iroh/test_utils/fn.run_relay_server_with.html @@ -1,7 +1,7 @@ run_relay_server_with in iroh::test_utils - Rust

    Function iroh::test_utils::run_relay_server_with

    source ·
    pub async fn run_relay_server_with(
         stun: Option<StunConfig>,
         quic: bool
    -) -> Result<(RelayMap, RelayUrl, Server)>
    Available on test or crate feature test-utils only.
    Expand description

    Runs a relay server.

    +) -> Result<(RelayMap, RelayUrl, Server)>
    Available on crate feature test-utils only.
    Expand description

    Runs a relay server.

    stun can be set to None to disable stun, or set to Some StunConfig, to enable stun on a specific socket.

    If quic is set to true, it will make the appropriate QuicConfig from the generated tls certificates and run the quic server at a random free port.

    diff --git a/pr/3024/docs/iroh/test_utils/fn.run_relay_server_with_stun.html b/pr/3024/docs/iroh/test_utils/fn.run_relay_server_with_stun.html index 03e1e776b6..ff80f017bf 100644 --- a/pr/3024/docs/iroh/test_utils/fn.run_relay_server_with_stun.html +++ b/pr/3024/docs/iroh/test_utils/fn.run_relay_server_with_stun.html @@ -1,5 +1,5 @@ run_relay_server_with_stun in iroh::test_utils - Rust

    Function iroh::test_utils::run_relay_server_with_stun

    source ·
    pub async fn run_relay_server_with_stun(
    -) -> Result<(RelayMap, RelayUrl, Server)>
    Available on test or crate feature test-utils only.
    Expand description

    Runs a relay server with STUN enabled suitable for tests.

    +) -> Result<(RelayMap, RelayUrl, Server)>
    Available on crate feature test-utils only.
    Expand description

    Runs a relay server with STUN enabled suitable for tests.

    The returned Url is the url of the relay server in the returned RelayMap. When dropped, the returned Server does will stop running.

    \ No newline at end of file diff --git a/pr/3024/docs/iroh/test_utils/index.html b/pr/3024/docs/iroh/test_utils/index.html index 23a8e4828f..7edb6a63bc 100644 --- a/pr/3024/docs/iroh/test_utils/index.html +++ b/pr/3024/docs/iroh/test_utils/index.html @@ -1,2 +1,2 @@ -iroh::test_utils - Rust

    Module iroh::test_utils

    source ·
    Available on test or crate feature test-utils only.
    Expand description

    Internal utilities to support testing.

    +iroh::test_utils - Rust

    Module iroh::test_utils

    source ·
    Available on crate feature test-utils only.
    Expand description

    Internal utilities to support testing.

    Structs§

    Functions§

    \ No newline at end of file diff --git a/pr/3024/docs/iroh/test_utils/struct.CleanupDropGuard.html b/pr/3024/docs/iroh/test_utils/struct.CleanupDropGuard.html index 7781c69e06..10ce4c81cd 100644 --- a/pr/3024/docs/iroh/test_utils/struct.CleanupDropGuard.html +++ b/pr/3024/docs/iroh/test_utils/struct.CleanupDropGuard.html @@ -1,4 +1,4 @@ -CleanupDropGuard in iroh::test_utils - Rust

    Struct iroh::test_utils::CleanupDropGuard

    source ·
    pub struct CleanupDropGuard(/* private fields */);
    Available on test or crate feature test-utils only.
    Expand description

    A drop guard to clean up test infrastructure.

    +CleanupDropGuard in iroh::test_utils - Rust

    Struct iroh::test_utils::CleanupDropGuard

    source ·
    pub struct CleanupDropGuard(/* private fields */);
    Available on crate feature test-utils only.
    Expand description

    A drop guard to clean up test infrastructure.

    After dropping the test infrastructure will asynchronously shutdown and release its resources.

    Trait Implementations§

    source§

    impl Debug for CleanupDropGuard

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where diff --git a/pr/3024/docs/iroh/test_utils/struct.DnsPkarrServer.html b/pr/3024/docs/iroh/test_utils/struct.DnsPkarrServer.html index 1bf6cce398..079fd3e7ff 100644 --- a/pr/3024/docs/iroh/test_utils/struct.DnsPkarrServer.html +++ b/pr/3024/docs/iroh/test_utils/struct.DnsPkarrServer.html @@ -3,7 +3,7 @@ pub nameserver: SocketAddr, pub pkarr_url: Url, /* private fields */ -}
    Available on test or crate feature test-utils only.
    Expand description

    Handle and drop guard for test DNS and Pkarr servers.

    +}
    Available on crate feature test-utils only.
    Expand description

    Handle and drop guard for test DNS and Pkarr servers.

    Once the struct is dropped the servers will shut down.

    Fields§

    §node_origin: String

    The node origin domain.

    §nameserver: SocketAddr

    The socket address of the DNS server.

    diff --git a/pr/3024/docs/iroh/ticket/enum.Error.html b/pr/3024/docs/iroh/ticket/enum.Error.html index 62caeea0e0..759f302a1d 100644 --- a/pr/3024/docs/iroh/ticket/enum.Error.html +++ b/pr/3024/docs/iroh/ticket/enum.Error.html @@ -1,4 +1,4 @@ -Error in iroh::ticket - Rust

    Enum iroh::ticket::Error

    source ·
    pub enum Error {
    +Error in iroh::ticket - Rust

    Enum iroh::ticket::Error

    source ·
    pub enum Error {
         Kind {
             expected: &'static str,
         },
    @@ -10,7 +10,7 @@
     

    Fields

    §expected: &'static str
    §

    Postcard(Error)

    This looks like a ticket, but postcard deserialization failed.

    §

    Encoding(DecodeError)

    This looks like a ticket, but base32 decoding failed.

    §

    Verify(&'static str)

    Verification of the deserialized bytes failed.

    -

    Trait Implementations§

    source§

    impl Debug for Error

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    source§

    impl Display for Error

    source§

    fn fmt(&self, __formatter: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    source§

    impl Error for Error

    source§

    fn source(&self) -> Option<&(dyn Error + 'static)>

    The lower-level source of this error, if any. Read more
    1.0.0 · source§

    fn description(&self) -> &str

    👎Deprecated since 1.42.0: use the Display impl or to_string()
    1.0.0 · source§

    fn cause(&self) -> Option<&dyn Error>

    👎Deprecated since 1.33.0: replaced by Error::source, which can support downcasting
    source§

    fn provide<'a>(&'a self, request: &mut Request<'a>)

    🔬This is a nightly-only experimental API. (error_generic_member_access)
    Provides type based access to context intended for error reports. Read more
    source§

    impl From<DecodeError> for Error

    source§

    fn from(source: DecodeError) -> Error

    Converts to this type from the input type.
    source§

    impl From<Error> for Error

    source§

    fn from(source: Error) -> Error

    Converts to this type from the input type.

    Auto Trait Implementations§

    §

    impl Freeze for Error

    §

    impl RefUnwindSafe for Error

    §

    impl Send for Error

    §

    impl Sync for Error

    §

    impl Unpin for Error

    §

    impl UnwindSafe for Error

    Blanket Implementations§

    source§

    impl<T> Any for T
    where +

    Trait Implementations§

    source§

    impl Debug for Error

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    source§

    impl Display for Error

    source§

    fn fmt(&self, __formatter: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    source§

    impl Error for Error

    source§

    fn source(&self) -> Option<&(dyn Error + 'static)>

    The lower-level source of this error, if any. Read more
    1.0.0 · source§

    fn description(&self) -> &str

    👎Deprecated since 1.42.0: use the Display impl or to_string()
    1.0.0 · source§

    fn cause(&self) -> Option<&dyn Error>

    👎Deprecated since 1.33.0: replaced by Error::source, which can support downcasting
    source§

    fn provide<'a>(&'a self, request: &mut Request<'a>)

    🔬This is a nightly-only experimental API. (error_generic_member_access)
    Provides type based access to context intended for error reports. Read more
    source§

    impl From<DecodeError> for Error

    source§

    fn from(source: DecodeError) -> Error

    Converts to this type from the input type.
    source§

    impl From<Error> for Error

    source§

    fn from(source: Error) -> Error

    Converts to this type from the input type.

    Auto Trait Implementations§

    §

    impl Freeze for Error

    §

    impl RefUnwindSafe for Error

    §

    impl Send for Error

    §

    impl Sync for Error

    §

    impl Unpin for Error

    §

    impl UnwindSafe for Error

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/iroh/ticket/index.html b/pr/3024/docs/iroh/ticket/index.html index 288da1d108..885d63bd84 100644 --- a/pr/3024/docs/iroh/ticket/index.html +++ b/pr/3024/docs/iroh/ticket/index.html @@ -1 +1 @@ -iroh::ticket - Rust

    Module iroh::ticket

    source ·

    Structs§

    • A token containing everything to get a file from the provider.
    • A token containing information for establishing a connection to a node.

    Enums§

    • An error deserializing an iroh ticket.

    Traits§

    • A ticket is a serializable object combining information required for an operation.
    \ No newline at end of file +iroh::ticket - Rust

    Module iroh::ticket

    source ·

    Structs§

    • A token containing everything to get a file from the provider.
    • A token containing information for establishing a connection to a node.

    Enums§

    • An error deserializing an iroh ticket.

    Traits§

    • A ticket is a serializable object combining information required for an operation.
    \ No newline at end of file diff --git a/pr/3024/docs/iroh/ticket/struct.BlobTicket.html b/pr/3024/docs/iroh/ticket/struct.BlobTicket.html index 09e4aaf846..4ee52fd252 100644 --- a/pr/3024/docs/iroh/ticket/struct.BlobTicket.html +++ b/pr/3024/docs/iroh/ticket/struct.BlobTicket.html @@ -19,7 +19,7 @@ sufficient, and should not be overridden without very good reason.

    Result<<S as Serializer>::Ok, <S as Serializer>::Error>
    where - S: Serializer,

    Serialize this value into the given Serde serializer. Read more
    source§

    impl Ticket for BlobTicket

    source§

    const KIND: &'static str = "blob"

    String prefix describing the kind of iroh ticket. Read more
    source§

    fn to_bytes(&self) -> Vec<u8> ⓘ

    Serialize to bytes used in the base32 string representation.
    source§

    fn from_bytes(bytes: &[u8]) -> Result<BlobTicket, Error>

    Deserialize from the base32 string representation bytes.
    source§

    fn serialize(&self) -> String

    Serialize to string.
    source§

    fn deserialize(str: &str) -> Result<Self, Error>

    Deserialize from a string.
    source§

    impl Eq for BlobTicket

    source§

    impl StructuralPartialEq for BlobTicket

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where + S: Serializer,

    Serialize this value into the given Serde serializer. Read more
    source§

    impl Ticket for BlobTicket

    source§

    const KIND: &'static str = "blob"

    String prefix describing the kind of iroh ticket. Read more
    source§

    fn to_bytes(&self) -> Vec<u8> ⓘ

    Serialize to bytes used in the base32 string representation.
    source§

    fn from_bytes(bytes: &[u8]) -> Result<BlobTicket, Error>

    Deserialize from the base32 string representation bytes.
    source§

    fn serialize(&self) -> String

    Serialize to string.
    source§

    fn deserialize(str: &str) -> Result<Self, Error>

    Deserialize from a string.
    source§

    impl Eq for BlobTicket

    source§

    impl StructuralPartialEq for BlobTicket

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/iroh/ticket/struct.NodeTicket.html b/pr/3024/docs/iroh/ticket/struct.NodeTicket.html index edb1eaca04..d827bd05f8 100644 --- a/pr/3024/docs/iroh/ticket/struct.NodeTicket.html +++ b/pr/3024/docs/iroh/ticket/struct.NodeTicket.html @@ -23,7 +23,7 @@ sufficient, and should not be overridden without very good reason.

    Result<<S as Serializer>::Ok, <S as Serializer>::Error>
    where - S: Serializer,
    Serialize this value into the given Serde serializer. Read more
    source§

    impl Ticket for NodeTicket

    source§

    const KIND: &'static str = "node"

    String prefix describing the kind of iroh ticket. Read more
    source§

    fn to_bytes(&self) -> Vec<u8> ⓘ

    Serialize to bytes used in the base32 string representation.
    source§

    fn from_bytes(bytes: &[u8]) -> Result<NodeTicket, Error>

    Deserialize from the base32 string representation bytes.
    source§

    fn serialize(&self) -> String

    Serialize to string.
    source§

    fn deserialize(str: &str) -> Result<Self, Error>

    Deserialize from a string.
    source§

    impl Eq for NodeTicket

    source§

    impl StructuralPartialEq for NodeTicket

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where + S: Serializer,

    Serialize this value into the given Serde serializer. Read more
    source§

    impl Ticket for NodeTicket

    source§

    const KIND: &'static str = "node"

    String prefix describing the kind of iroh ticket. Read more
    source§

    fn to_bytes(&self) -> Vec<u8> ⓘ

    Serialize to bytes used in the base32 string representation.
    source§

    fn from_bytes(bytes: &[u8]) -> Result<NodeTicket, Error>

    Deserialize from the base32 string representation bytes.
    source§

    fn serialize(&self) -> String

    Serialize to string.
    source§

    fn deserialize(str: &str) -> Result<Self, Error>

    Deserialize from a string.
    source§

    impl Eq for NodeTicket

    source§

    impl StructuralPartialEq for NodeTicket

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/iroh/ticket/trait.Ticket.html b/pr/3024/docs/iroh/ticket/trait.Ticket.html index e3e1c26717..a0b5fb593d 100644 --- a/pr/3024/docs/iroh/ticket/trait.Ticket.html +++ b/pr/3024/docs/iroh/ticket/trait.Ticket.html @@ -1,4 +1,4 @@ -Ticket in iroh::ticket - Rust

    Trait iroh::ticket::Ticket

    source ·
    pub trait Ticket: Sized {
    +Ticket in iroh::ticket - Rust

    Trait iroh::ticket::Ticket

    source ·
    pub trait Ticket: Sized {
         const KIND: &'static str;
     
         // Required methods
    @@ -18,10 +18,10 @@ ticket will be prepended to the string to make it somewhat self describing.

    versioning, others might not.

    The serialization format for converting the ticket from and to bytes is left to the implementer. We recommend using postcard for serialization.

    -

    Required Associated Constants§

    source

    const KIND: &'static str

    String prefix describing the kind of iroh ticket.

    +

    Required Associated Constants§

    source

    const KIND: &'static str

    String prefix describing the kind of iroh ticket.

    This should be lower case ascii characters.

    -

    Required Methods§

    source

    fn to_bytes(&self) -> Vec<u8> ⓘ

    Serialize to bytes used in the base32 string representation.

    -
    source

    fn from_bytes(bytes: &[u8]) -> Result<Self, Error>

    Deserialize from the base32 string representation bytes.

    -

    Provided Methods§

    source

    fn serialize(&self) -> String

    Serialize to string.

    -
    source

    fn deserialize(str: &str) -> Result<Self, Error>

    Deserialize from a string.

    +

    Required Methods§

    source

    fn to_bytes(&self) -> Vec<u8> ⓘ

    Serialize to bytes used in the base32 string representation.

    +
    source

    fn from_bytes(bytes: &[u8]) -> Result<Self, Error>

    Deserialize from the base32 string representation bytes.

    +

    Provided Methods§

    source

    fn serialize(&self) -> String

    Serialize to string.

    +
    source

    fn deserialize(str: &str) -> Result<Self, Error>

    Deserialize from a string.

    Object Safety§

    This trait is not object safe.

    Implementors§

    source§

    impl Ticket for BlobTicket

    source§

    const KIND: &'static str = "blob"

    source§

    impl Ticket for NodeTicket

    source§

    const KIND: &'static str = "node"

    \ No newline at end of file diff --git a/pr/3024/docs/iroh_base/base32/struct.DecodeError.html b/pr/3024/docs/iroh_base/base32/struct.DecodeError.html index 4fd705d4d6..1ac8355192 100644 --- a/pr/3024/docs/iroh_base/base32/struct.DecodeError.html +++ b/pr/3024/docs/iroh_base/base32/struct.DecodeError.html @@ -5,7 +5,7 @@

    Fields§

    §position: usize

    Error position

    This position is always a valid input position and represents the first encountered error.

    §kind: DecodeKind

    Error kind

    -

    Trait Implementations§

    §

    impl Clone for DecodeError

    §

    fn clone(&self) -> DecodeError

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    §

    impl Debug for DecodeError

    §

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    §

    impl Display for DecodeError

    §

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    §

    impl Error for DecodeError

    1.30.0 · source§

    fn source(&self) -> Option<&(dyn Error + 'static)>

    The lower-level source of this error, if any. Read more
    1.0.0 · source§

    fn description(&self) -> &str

    👎Deprecated since 1.42.0: use the Display impl or to_string()
    1.0.0 · source§

    fn cause(&self) -> Option<&dyn Error>

    👎Deprecated since 1.33.0: replaced by Error::source, which can support downcasting
    source§

    fn provide<'a>(&'a self, request: &mut Request<'a>)

    🔬This is a nightly-only experimental API. (error_generic_member_access)
    Provides type based access to context intended for error reports. Read more
    source§

    impl From<DecodeError> for Error

    source§

    fn from(source: DecodeError) -> Self

    Converts to this type from the input type.
    source§

    impl From<DecodeError> for HexOrBase32ParseError

    source§

    fn from(source: DecodeError) -> Self

    Converts to this type from the input type.
    §

    impl PartialEq for DecodeError

    §

    fn eq(&self, other: &DecodeError) -> bool

    This method tests for self and other values to be equal, and is used +

    Trait Implementations§

    §

    impl Clone for DecodeError

    §

    fn clone(&self) -> DecodeError

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    §

    impl Debug for DecodeError

    §

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    §

    impl Display for DecodeError

    §

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    §

    impl Error for DecodeError

    Available on crate feature std only.
    1.30.0 · source§

    fn source(&self) -> Option<&(dyn Error + 'static)>

    The lower-level source of this error, if any. Read more
    1.0.0 · source§

    fn description(&self) -> &str

    👎Deprecated since 1.42.0: use the Display impl or to_string()
    1.0.0 · source§

    fn cause(&self) -> Option<&dyn Error>

    👎Deprecated since 1.33.0: replaced by Error::source, which can support downcasting
    source§

    fn provide<'a>(&'a self, request: &mut Request<'a>)

    🔬This is a nightly-only experimental API. (error_generic_member_access)
    Provides type based access to context intended for error reports. Read more
    source§

    impl From<DecodeError> for Error

    source§

    fn from(source: DecodeError) -> Self

    Converts to this type from the input type.
    source§

    impl From<DecodeError> for HexOrBase32ParseError

    source§

    fn from(source: DecodeError) -> Self

    Converts to this type from the input type.
    §

    impl PartialEq for DecodeError

    §

    fn eq(&self, other: &DecodeError) -> bool

    This method tests for self and other values to be equal, and is used by ==.
    1.0.0 · source§

    fn ne(&self, other: &Rhs) -> bool

    This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
    §

    impl Copy for DecodeError

    §

    impl Eq for DecodeError

    §

    impl StructuralPartialEq for DecodeError

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    source§

    impl<T> Borrow<T> for T
    where diff --git a/pr/3024/docs/iroh_base/hash/index.html b/pr/3024/docs/iroh_base/hash/index.html index 606b4944e0..79061be1d8 100644 --- a/pr/3024/docs/iroh_base/hash/index.html +++ b/pr/3024/docs/iroh_base/hash/index.html @@ -1,2 +1,2 @@ -iroh_base::hash - Rust

    Module iroh_base::hash

    source ·
    Available on crate feature hash only.
    Expand description

    The blake3 hash used in Iroh.

    +iroh_base::hash - Rust

    Module iroh_base::hash

    source ·
    Available on crate feature hash only.
    Expand description

    The blake3 hash used in Iroh.

    Structs§

    Enums§

    \ No newline at end of file diff --git a/pr/3024/docs/iroh_base/hash/struct.Hash.html b/pr/3024/docs/iroh_base/hash/struct.Hash.html index 980811515e..ba14cea1eb 100644 --- a/pr/3024/docs/iroh_base/hash/struct.Hash.html +++ b/pr/3024/docs/iroh_base/hash/struct.Hash.html @@ -9,7 +9,7 @@ representation of the hash.

    Trait Implementations§

    source§

    impl AsRef<[u8]> for Hash

    source§

    fn as_ref(&self) -> &[u8] ⓘ

    Converts this type into a shared reference of the (usually inferred) input type.
    source§

    impl Borrow<[u8]> for Hash

    source§

    fn borrow(&self) -> &[u8] ⓘ

    Immutably borrows from an owned value. Read more
    source§

    impl Borrow<[u8; 32]> for Hash

    source§

    fn borrow(&self) -> &[u8; 32]

    Immutably borrows from an owned value. Read more
    source§

    impl Clone for Hash

    source§

    fn clone(&self) -> Hash

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for Hash

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl<'de> Deserialize<'de> for Hash

    source§

    fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
    where D: Deserializer<'de>,

    Deserialize this value from the given Serde deserializer. Read more
    source§

    impl Display for Hash

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl From<&[u8; 32]> for Hash

    source§

    fn from(value: &[u8; 32]) -> Self

    Converts to this type from the input type.
    source§

    impl From<[u8; 32]> for Hash

    source§

    fn from(value: [u8; 32]) -> Self

    Converts to this type from the input type.
    source§

    impl From<Hash> for [u8; 32]

    source§

    fn from(value: Hash) -> Self

    Converts to this type from the input type.
    source§

    impl From<Hash> for Hash

    source§

    fn from(value: Hash) -> Self

    Converts to this type from the input type.
    source§

    impl From<Hash> for Hash

    source§

    fn from(value: Hash) -> Self

    Converts to this type from the input type.
    source§

    impl FromStr for Hash

    §

    type Err = HexOrBase32ParseError

    The associated error which can be returned from parsing.
    source§

    fn from_str(s: &str) -> Result<Self, Self::Err>

    Parses a string s to return a value of this type. Read more
    source§

    impl Hash for Hash

    source§

    fn hash<__H: Hasher>(&self, state: &mut __H)

    Feeds this value into the given Hasher. Read more
    1.3.0 · source§

    fn hash_slice<H>(data: &[Self], state: &mut H)
    where H: Hasher, - Self: Sized,

    Feeds a slice of this type into the given Hasher. Read more
    source§

    impl Key for Hash

    source§

    fn compare(data1: &[u8], data2: &[u8]) -> Ordering

    Compare data1 with data2
    source§

    impl MaxSize for Hash

    source§

    const POSTCARD_MAX_SIZE: usize = 32usize

    The maximum possible size that the serialization of this + Self: Sized,
    Feeds a slice of this type into the given Hasher. Read more
    source§

    impl Key for Hash

    Available on crate feature redb only.
    source§

    fn compare(data1: &[u8], data2: &[u8]) -> Ordering

    Compare data1 with data2
    source§

    impl MaxSize for Hash

    source§

    const POSTCARD_MAX_SIZE: usize = 32usize

    The maximum possible size that the serialization of this type can have, in bytes.
    source§

    impl Ord for Hash

    source§

    fn cmp(&self, other: &Self) -> Ordering

    This method returns an Ordering between self and other. Read more
    1.21.0 · source§

    fn max(self, other: Self) -> Self
    where Self: Sized,

    Compares and returns the maximum of two values. Read more
    1.21.0 · source§

    fn min(self, other: Self) -> Self
    where Self: Sized,

    Compares and returns the minimum of two values. Read more
    1.50.0 · source§

    fn clamp(self, min: Self, max: Self) -> Self
    where @@ -18,10 +18,10 @@ by ==.

    source§

    impl PartialOrd for Hash

    source§

    fn partial_cmp(&self, other: &Self) -> Option<Ordering>

    This method returns an ordering between self and other values if one exists. Read more
    1.0.0 · source§

    fn lt(&self, other: &Rhs) -> bool

    This method tests less than (for self and other) and is used by the < operator. Read more
    1.0.0 · source§

    fn le(&self, other: &Rhs) -> bool

    This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
    1.0.0 · source§

    fn gt(&self, other: &Rhs) -> bool

    This method tests greater than (for self and other) and is used by the > operator. Read more
    1.0.0 · source§

    fn ge(&self, other: &Rhs) -> bool

    This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
    source§

    impl Serialize for Hash

    source§

    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where - S: Serializer,

    Serialize this value into the given Serde serializer. Read more
    source§

    impl Value for Hash

    §

    type SelfType<'a> = Hash

    SelfType<’a> must be the same type as Self with all lifetimes replaced with ’a
    §

    type AsBytes<'a> = &'a [u8; 32]

    source§

    fn fixed_width() -> Option<usize>

    Width of a fixed type, or None for variable width
    source§

    fn from_bytes<'a>(data: &'a [u8]) -> Self::SelfType<'a>
    where + S: Serializer,

    Serialize this value into the given Serde serializer. Read more
    source§

    impl Value for Hash

    Available on crate feature redb only.
    §

    type SelfType<'a> = Hash

    SelfType<’a> must be the same type as Self with all lifetimes replaced with ’a
    §

    type AsBytes<'a> = &'a [u8; 32]

    source§

    fn fixed_width() -> Option<usize>

    Width of a fixed type, or None for variable width
    source§

    fn from_bytes<'a>(data: &'a [u8]) -> Self::SelfType<'a>
    where Self: 'a,

    Deserializes data -Implementations may return a view over data, or an owned type
    source§

    fn as_bytes<'a, 'b: 'a>(value: &'a Self::SelfType<'b>) -> Self::AsBytes<'a>
    where - Self: 'a + 'b,

    Serialize the value to a slice
    source§

    fn type_name() -> TypeName

    Globally unique identifier for this type
    source§

    impl Copy for Hash

    source§

    impl Eq for Hash

    source§

    impl StructuralPartialEq for Hash

    Auto Trait Implementations§

    §

    impl Freeze for Hash

    §

    impl RefUnwindSafe for Hash

    §

    impl Send for Hash

    §

    impl Sync for Hash

    §

    impl Unpin for Hash

    §

    impl UnwindSafe for Hash

    Blanket Implementations§

    source§

    impl<T> Any for T
    where +Implementations may return a view over data, or an owned type

    source§

    fn as_bytes<'a, 'b: 'a>(value: &'a Self::SelfType<'b>) -> Self::AsBytes<'a>
    where + Self: 'a + 'b,

    Serialize the value to a slice
    source§

    fn type_name() -> TypeName

    Globally unique identifier for this type
    source§

    impl Copy for Hash

    source§

    impl Eq for Hash

    source§

    impl StructuralPartialEq for Hash

    Auto Trait Implementations§

    §

    impl Freeze for Hash

    §

    impl RefUnwindSafe for Hash

    §

    impl Send for Hash

    §

    impl Sync for Hash

    §

    impl Unpin for Hash

    §

    impl UnwindSafe for Hash

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    source§

    impl<T> Borrow<T> for T
    where T: ?Sized,

    source§

    fn borrow(&self) -> &T

    Immutably borrows from an owned value. Read more
    source§

    impl<T> BorrowMut<T> for T
    where T: ?Sized,

    source§

    fn borrow_mut(&mut self) -> &mut T

    Mutably borrows from an owned value. Read more
    source§

    impl<T> From<T> for T

    source§

    fn from(t: T) -> T

    Returns the argument unchanged.

    diff --git a/pr/3024/docs/iroh_base/hash/struct.HashAndFormat.html b/pr/3024/docs/iroh_base/hash/struct.HashAndFormat.html index 6561f1e13a..bec0abbe5f 100644 --- a/pr/3024/docs/iroh_base/hash/struct.HashAndFormat.html +++ b/pr/3024/docs/iroh_base/hash/struct.HashAndFormat.html @@ -4,11 +4,11 @@ }
    Available on crate feature hash only.
    Expand description

    A hash and format pair

    Fields§

    §hash: Hash

    The hash

    §format: BlobFormat

    The format

    -

    Implementations§

    source§

    impl HashAndFormat

    source

    pub fn new(hash: Hash, format: BlobFormat) -> Self

    Create a new hash and format pair.

    -
    source

    pub fn raw(hash: Hash) -> Self

    Create a new hash and format pair, using the default (raw) format.

    -
    source

    pub fn hash_seq(hash: Hash) -> Self

    Create a new hash and format pair, using the collection format.

    -

    Trait Implementations§

    source§

    impl Clone for HashAndFormat

    source§

    fn clone(&self) -> HashAndFormat

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for HashAndFormat

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl<'de> Deserialize<'de> for HashAndFormat

    source§

    fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
    where - D: Deserializer<'de>,

    Deserialize this value from the given Serde deserializer. Read more
    source§

    impl Display for HashAndFormat

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl FromStr for HashAndFormat

    §

    type Err = Error

    The associated error which can be returned from parsing.
    source§

    fn from_str(s: &str) -> Result<Self, Self::Err>

    Parses a string s to return a value of this type. Read more
    source§

    impl Hash for HashAndFormat

    source§

    fn hash<__H: Hasher>(&self, state: &mut __H)

    Feeds this value into the given Hasher. Read more
    1.3.0 · source§

    fn hash_slice<H>(data: &[Self], state: &mut H)
    where +

    Implementations§

    source§

    impl HashAndFormat

    source

    pub fn new(hash: Hash, format: BlobFormat) -> Self

    Create a new hash and format pair.

    +
    source

    pub fn raw(hash: Hash) -> Self

    Create a new hash and format pair, using the default (raw) format.

    +
    source

    pub fn hash_seq(hash: Hash) -> Self

    Create a new hash and format pair, using the collection format.

    +

    Trait Implementations§

    source§

    impl Clone for HashAndFormat

    source§

    fn clone(&self) -> HashAndFormat

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for HashAndFormat

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl<'de> Deserialize<'de> for HashAndFormat

    source§

    fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
    where + D: Deserializer<'de>,

    Deserialize this value from the given Serde deserializer. Read more
    source§

    impl Display for HashAndFormat

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl FromStr for HashAndFormat

    §

    type Err = Error

    The associated error which can be returned from parsing.
    source§

    fn from_str(s: &str) -> Result<Self, Self::Err>

    Parses a string s to return a value of this type. Read more
    source§

    impl Hash for HashAndFormat

    source§

    fn hash<__H: Hasher>(&self, state: &mut __H)

    Feeds this value into the given Hasher. Read more
    1.3.0 · source§

    fn hash_slice<H>(data: &[Self], state: &mut H)
    where H: Hasher, Self: Sized,

    Feeds a slice of this type into the given Hasher. Read more
    source§

    impl MaxSize for HashAndFormat

    source§

    const POSTCARD_MAX_SIZE: usize = 33usize

    The maximum possible size that the serialization of this type can have, in bytes.
    source§

    impl Ord for HashAndFormat

    source§

    fn cmp(&self, other: &HashAndFormat) -> Ordering

    This method returns an Ordering between self and other. Read more
    1.21.0 · source§

    fn max(self, other: Self) -> Self
    where @@ -18,11 +18,11 @@ type can have, in bytes.

    1.0.0 · source§

    fn ne(&self, other: &Rhs) -> bool

    This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
    source§

    impl PartialOrd for HashAndFormat

    source§

    fn partial_cmp(&self, other: &HashAndFormat) -> Option<Ordering>

    This method returns an ordering between self and other values if one exists. Read more
    1.0.0 · source§

    fn lt(&self, other: &Rhs) -> bool

    This method tests less than (for self and other) and is used by the < operator. Read more
    1.0.0 · source§

    fn le(&self, other: &Rhs) -> bool

    This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
    1.0.0 · source§

    fn gt(&self, other: &Rhs) -> bool

    This method tests greater than (for self and other) and is used by the > operator. Read more
    1.0.0 · source§

    fn ge(&self, other: &Rhs) -> bool

    This method tests greater than or equal to (for self and other) and is used by the >= -operator. Read more
    source§

    impl Serialize for HashAndFormat

    source§

    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where - S: Serializer,

    Serialize this value into the given Serde serializer. Read more
    source§

    impl Value for HashAndFormat

    §

    type SelfType<'a> = HashAndFormat

    SelfType<’a> must be the same type as Self with all lifetimes replaced with ’a
    §

    type AsBytes<'a> = [u8; 33]

    source§

    fn fixed_width() -> Option<usize>

    Width of a fixed type, or None for variable width
    source§

    fn from_bytes<'a>(data: &'a [u8]) -> Self::SelfType<'a>
    where +operator. Read more

    source§

    impl Serialize for HashAndFormat

    source§

    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
    where + S: Serializer,

    Serialize this value into the given Serde serializer. Read more
    source§

    impl Value for HashAndFormat

    Available on crate feature redb only.
    §

    type SelfType<'a> = HashAndFormat

    SelfType<’a> must be the same type as Self with all lifetimes replaced with ’a
    §

    type AsBytes<'a> = [u8; 33]

    source§

    fn fixed_width() -> Option<usize>

    Width of a fixed type, or None for variable width
    source§

    fn from_bytes<'a>(data: &'a [u8]) -> Self::SelfType<'a>
    where Self: 'a,

    Deserializes data -Implementations may return a view over data, or an owned type
    source§

    fn as_bytes<'a, 'b: 'a>(value: &'a Self::SelfType<'b>) -> Self::AsBytes<'a>
    where - Self: 'a + 'b,

    Serialize the value to a slice
    source§

    fn type_name() -> TypeName

    Globally unique identifier for this type
    source§

    impl Copy for HashAndFormat

    source§

    impl Eq for HashAndFormat

    source§

    impl StructuralPartialEq for HashAndFormat

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where +Implementations may return a view over data, or an owned type

    source§

    fn as_bytes<'a, 'b: 'a>(value: &'a Self::SelfType<'b>) -> Self::AsBytes<'a>
    where + Self: 'a + 'b,

    Serialize the value to a slice
    source§

    fn type_name() -> TypeName

    Globally unique identifier for this type
    source§

    impl Copy for HashAndFormat

    source§

    impl Eq for HashAndFormat

    source§

    impl StructuralPartialEq for HashAndFormat

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    source§

    impl<T> Borrow<T> for T
    where T: ?Sized,

    source§

    fn borrow(&self) -> &T

    Immutably borrows from an owned value. Read more
    source§

    impl<T> BorrowMut<T> for T
    where T: ?Sized,

    source§

    fn borrow_mut(&mut self) -> &mut T

    Mutably borrows from an owned value. Read more
    source§

    impl<T> From<T> for T

    source§

    fn from(t: T) -> T

    Returns the argument unchanged.

    diff --git a/pr/3024/docs/iroh_base/index.html b/pr/3024/docs/iroh_base/index.html index f5cd99ecbb..d4554d40d3 100644 --- a/pr/3024/docs/iroh_base/index.html +++ b/pr/3024/docs/iroh_base/index.html @@ -1,2 +1,2 @@ -iroh_base - Rust

    Crate iroh_base

    source ·
    Expand description

    Base types and utilities for Iroh

    +iroh_base - Rust

    Crate iroh_base

    source ·
    Expand description

    Base types and utilities for Iroh

    Modules§

    • base32base32
    • hashhash
      The blake3 hash used in Iroh.
    • keykey
      Cryptographic key handling for iroh.
    • Addressing for iroh nodes.
    • based on tailscale/tailcfg/derpmap.go
    • ticketbase32
    \ No newline at end of file diff --git a/pr/3024/docs/iroh_base/key/struct.Signature.html b/pr/3024/docs/iroh_base/key/struct.Signature.html index 5bec57559c..af444b5b2e 100644 --- a/pr/3024/docs/iroh_base/key/struct.Signature.html +++ b/pr/3024/docs/iroh_base/key/struct.Signature.html @@ -16,7 +16,7 @@ elements at the time a signature is verified.

    pub fn r_bytes(&self) -> &[u8; 32]

    Bytes for the R component of a signature.

    pub fn s_bytes(&self) -> &[u8; 32]

    Bytes for the s component of a signature.

    pub fn to_bytes(&self) -> [u8; 64]

    Return the inner byte array.

    -

    pub fn to_vec(&self) -> Vec<u8>

    Convert this signature into a byte vector.

    +

    pub fn to_vec(&self) -> Vec<u8>

    Available on crate feature alloc only.

    Convert this signature into a byte vector.

    Trait Implementations§

    §

    impl Clone for Signature

    §

    fn clone(&self) -> Signature

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    §

    impl Debug for Signature

    §

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    §

    impl<'de> Deserialize<'de> for Signature

    §

    fn deserialize<D>( deserializer: D ) -> Result<Signature, <D as Deserializer<'de>>::Error>
    where @@ -29,7 +29,7 @@ sufficient, and should not be overridden without very good reason.
    Result<<S as Serializer>::Ok, <S as Serializer>::Error>
    where - S: Serializer,

    Serialize this value into the given Serde serializer. Read more
    §

    impl SignatureEncoding for Signature

    §

    type Repr = [u8; 64]

    Byte representation of a signature.
    §

    fn to_bytes(&self) -> [u8; 64]

    Encode signature as its byte representation.
    §

    fn to_vec(&self) -> Vec<u8>

    Encode signature as a byte vector.
    §

    fn encoded_len(&self) -> usize

    Get the length of this signature when encoded.
    §

    impl TryFrom<&[u8]> for Signature

    §

    type Error = Error

    The type returned in the event of a conversion error.
    §

    fn try_from(bytes: &[u8]) -> Result<Signature, Error>

    Performs the conversion.
    §

    impl TryFrom<&Signature> for Signature

    §

    type Error = Error

    The type returned in the event of a conversion error.
    §

    fn try_from(signature: &Signature) -> Result<Signature, Error>

    Performs the conversion.
    §

    impl TryFrom<Signature> for Signature

    §

    type Error = Error

    The type returned in the event of a conversion error.
    §

    fn try_from(signature: Signature) -> Result<Signature, Error>

    Performs the conversion.
    §

    impl UpperHex for Signature

    §

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter.
    §

    impl Copy for Signature

    §

    impl Eq for Signature

    §

    impl StructuralPartialEq for Signature

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where + S: Serializer,

    Serialize this value into the given Serde serializer. Read more
    §

    impl SignatureEncoding for Signature

    §

    type Repr = [u8; 64]

    Byte representation of a signature.
    §

    fn to_bytes(&self) -> [u8; 64]

    Encode signature as its byte representation.
    §

    fn to_vec(&self) -> Vec<u8>

    Available on crate feature alloc only.
    Encode signature as a byte vector.
    §

    fn encoded_len(&self) -> usize

    Get the length of this signature when encoded.
    §

    impl TryFrom<&[u8]> for Signature

    §

    type Error = Error

    The type returned in the event of a conversion error.
    §

    fn try_from(bytes: &[u8]) -> Result<Signature, Error>

    Performs the conversion.
    §

    impl TryFrom<&Signature> for Signature

    Available on crate feature ed25519 only.
    §

    type Error = Error

    The type returned in the event of a conversion error.
    §

    fn try_from(signature: &Signature) -> Result<Signature, Error>

    Performs the conversion.
    §

    impl TryFrom<Signature> for Signature

    Available on crate feature ed25519 only.
    §

    type Error = Error

    The type returned in the event of a conversion error.
    §

    fn try_from(signature: Signature) -> Result<Signature, Error>

    Performs the conversion.
    §

    impl UpperHex for Signature

    §

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter.
    §

    impl Copy for Signature

    §

    impl Eq for Signature

    §

    impl StructuralPartialEq for Signature

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    source§

    impl<T> Borrow<T> for T
    where T: ?Sized,

    source§

    fn borrow(&self) -> &T

    Immutably borrows from an owned value. Read more
    source§

    impl<T> BorrowMut<T> for T
    where T: ?Sized,

    source§

    fn borrow_mut(&mut self) -> &mut T

    Mutably borrows from an owned value. Read more
    source§

    impl<T> From<T> for T

    source§

    fn from(t: T) -> T

    Returns the argument unchanged.

    diff --git a/pr/3024/docs/iroh_base/node_addr/index.html b/pr/3024/docs/iroh_base/node_addr/index.html index fb56b37791..fd34975715 100644 --- a/pr/3024/docs/iroh_base/node_addr/index.html +++ b/pr/3024/docs/iroh_base/node_addr/index.html @@ -3,4 +3,4 @@ identified by the NodeId but that does not make it addressable on the network layer. For this the addition of a RelayUrl and/or direct addresses are required.

    The primary way of addressing a node is by using the NodeAddr.

    -

    Structs§

    • Network-level addressing information for an iroh node.
    • A URL identifying a relay server.

    Enums§

    \ No newline at end of file +

    Structs§

    • Network-level addressing information for an iroh node.
    • RelayUrlrelay or key
      A URL identifying a relay server.

    Enums§

    \ No newline at end of file diff --git a/pr/3024/docs/iroh_base/node_addr/struct.RelayUrl.html b/pr/3024/docs/iroh_base/node_addr/struct.RelayUrl.html index 1eeb660edb..507a88ec20 100644 --- a/pr/3024/docs/iroh_base/node_addr/struct.RelayUrl.html +++ b/pr/3024/docs/iroh_base/node_addr/struct.RelayUrl.html @@ -1,4 +1,4 @@ -RelayUrl in iroh_base::node_addr - Rust

    Struct iroh_base::node_addr::RelayUrl

    source ·
    pub struct RelayUrl(/* private fields */);
    Available on crate feature key only.
    Expand description

    A URL identifying a relay server.

    +RelayUrl in iroh_base::node_addr - Rust

    Struct iroh_base::node_addr::RelayUrl

    source ·
    pub struct RelayUrl(/* private fields */);
    Available on crate feature key and (crate features relay or key) only.
    Expand description

    A URL identifying a relay server.

    This is but a wrapper around Url, with a few custom tweaks:

    • @@ -311,7 +311,7 @@ For other schemes, it is the same as Url::port().

    source

    pub fn socket_addrs( &self, default_port_number: impl Fn() -> Option<u16> -) -> Result<Vec<SocketAddr>, Error>

    Resolve a URL’s host and port number to SocketAddr.

    +) -> Result<Vec<SocketAddr>, Error>
    Available on crate feature std and (Unix or Windows or Redox or WASI or HermitCore) only.

    Resolve a URL’s host and port number to SocketAddr.

    If the URL has the default port number of a scheme that is unknown to this library, default_port_number provides an opportunity to provide the actual port number. In non-example code this should be implemented either simply as || None, @@ -426,11 +426,11 @@ but the input may have been percent-encoded already.

    &self, serializer: S ) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>
    where - S: Serializer,

    Serialize with Serde using the internal representation of the Url struct.

    + S: Serializer,
    Available on crate feature serde only.

    Serialize with Serde using the internal representation of the Url struct.

    The corresponding deserialize_internal method sacrifices some invariant-checking for speed, compared to the Deserialize trait impl.

    This method is only available if the serde Cargo feature is enabled.

    -
    source

    pub fn to_file_path(&self) -> Result<PathBuf, ()>

    Assuming the URL is in the file scheme or similar, +

    source

    pub fn to_file_path(&self) -> Result<PathBuf, ()>

    Available on crate feature std and (Unix or Windows or Redox or WASI or HermitCore) only.

    Assuming the URL is in the file scheme or similar, convert its path to an absolute std::path::Path.

    Note: This does not actually check the URL’s scheme, and may give nonsensical results for other schemes. diff --git a/pr/3024/docs/iroh_base/relay_map/index.html b/pr/3024/docs/iroh_base/relay_map/index.html index 709b907a3a..e4856334fa 100644 --- a/pr/3024/docs/iroh_base/relay_map/index.html +++ b/pr/3024/docs/iroh_base/relay_map/index.html @@ -1,4 +1,4 @@ iroh_base::relay_map - Rust

    Module iroh_base::relay_map

    source ·
    Available on crate feature relay only.
    Expand description

    based on tailscale/tailcfg/derpmap.go

    Structs§

    • Configuration for speaking to the QUIC endpoint on the relay -server to do QUIC address discovery.
    • Configuration of all the relay servers that can be used.
    • Information on a specific relay server.
    • A URL identifying a relay server.

    Constants§

    • The default QUIC port used by the Relay server to accept QUIC connections +server to do QUIC address discovery.
    • Configuration of all the relay servers that can be used.
    • Information on a specific relay server.
    • RelayUrlrelay or key
      A URL identifying a relay server.

    Constants§

    \ No newline at end of file diff --git a/pr/3024/docs/iroh_base/relay_map/struct.RelayUrl.html b/pr/3024/docs/iroh_base/relay_map/struct.RelayUrl.html index e042e871b9..d8c09b3be3 100644 --- a/pr/3024/docs/iroh_base/relay_map/struct.RelayUrl.html +++ b/pr/3024/docs/iroh_base/relay_map/struct.RelayUrl.html @@ -1,4 +1,4 @@ -RelayUrl in iroh_base::relay_map - Rust

    Struct iroh_base::relay_map::RelayUrl

    source ·
    pub struct RelayUrl(/* private fields */);
    Available on crate feature relay only.
    Expand description

    A URL identifying a relay server.

    +RelayUrl in iroh_base::relay_map - Rust

    Struct iroh_base::relay_map::RelayUrl

    source ·
    pub struct RelayUrl(/* private fields */);
    Available on crate feature relay and (crate features relay or key) only.
    Expand description

    A URL identifying a relay server.

    This is but a wrapper around Url, with a few custom tweaks:

    • @@ -311,7 +311,7 @@ For other schemes, it is the same as Url::port().

    source

    pub fn socket_addrs( &self, default_port_number: impl Fn() -> Option<u16> -) -> Result<Vec<SocketAddr>, Error>

    Resolve a URL’s host and port number to SocketAddr.

    +) -> Result<Vec<SocketAddr>, Error>
    Available on crate feature std and (Unix or Windows or Redox or WASI or HermitCore) only.

    Resolve a URL’s host and port number to SocketAddr.

    If the URL has the default port number of a scheme that is unknown to this library, default_port_number provides an opportunity to provide the actual port number. In non-example code this should be implemented either simply as || None, @@ -426,11 +426,11 @@ but the input may have been percent-encoded already.

    &self, serializer: S ) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>
    where - S: Serializer,

    Serialize with Serde using the internal representation of the Url struct.

    + S: Serializer,
    Available on crate feature serde only.

    Serialize with Serde using the internal representation of the Url struct.

    The corresponding deserialize_internal method sacrifices some invariant-checking for speed, compared to the Deserialize trait impl.

    This method is only available if the serde Cargo feature is enabled.

    -
    source

    pub fn to_file_path(&self) -> Result<PathBuf, ()>

    Assuming the URL is in the file scheme or similar, +

    source

    pub fn to_file_path(&self) -> Result<PathBuf, ()>

    Available on crate feature std and (Unix or Windows or Redox or WASI or HermitCore) only.

    Assuming the URL is in the file scheme or similar, convert its path to an absolute std::path::Path.

    Note: This does not actually check the URL’s scheme, and may give nonsensical results for other schemes. diff --git a/pr/3024/docs/iroh_base/ticket/enum.Error.html b/pr/3024/docs/iroh_base/ticket/enum.Error.html index 7b0b45c4fb..f1daa36231 100644 --- a/pr/3024/docs/iroh_base/ticket/enum.Error.html +++ b/pr/3024/docs/iroh_base/ticket/enum.Error.html @@ -1,4 +1,4 @@ -Error in iroh_base::ticket - Rust

    Enum iroh_base::ticket::Error

    source ·
    pub enum Error {
    +Error in iroh_base::ticket - Rust

    Enum iroh_base::ticket::Error

    source ·
    pub enum Error {
         Kind {
             expected: &'static str,
         },
    @@ -10,7 +10,7 @@
     

    Fields

    §expected: &'static str
    §

    Postcard(Error)

    This looks like a ticket, but postcard deserialization failed.

    §

    Encoding(DecodeError)

    This looks like a ticket, but base32 decoding failed.

    §

    Verify(&'static str)

    Verification of the deserialized bytes failed.

    -

    Trait Implementations§

    source§

    impl Debug for Error

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Display for Error

    source§

    fn fmt(&self, __formatter: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Error for Error

    source§

    fn source(&self) -> Option<&(dyn Error + 'static)>

    The lower-level source of this error, if any. Read more
    1.0.0 · source§

    fn description(&self) -> &str

    👎Deprecated since 1.42.0: use the Display impl or to_string()
    1.0.0 · source§

    fn cause(&self) -> Option<&dyn Error>

    👎Deprecated since 1.33.0: replaced by Error::source, which can support downcasting
    source§

    fn provide<'a>(&'a self, request: &mut Request<'a>)

    🔬This is a nightly-only experimental API. (error_generic_member_access)
    Provides type based access to context intended for error reports. Read more
    source§

    impl From<DecodeError> for Error

    source§

    fn from(source: DecodeError) -> Self

    Converts to this type from the input type.
    source§

    impl From<Error> for Error

    source§

    fn from(source: Error) -> Self

    Converts to this type from the input type.

    Auto Trait Implementations§

    §

    impl Freeze for Error

    §

    impl RefUnwindSafe for Error

    §

    impl Send for Error

    §

    impl Sync for Error

    §

    impl Unpin for Error

    §

    impl UnwindSafe for Error

    Blanket Implementations§

    source§

    impl<T> Any for T
    where +

    Trait Implementations§

    source§

    impl Debug for Error

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Display for Error

    source§

    fn fmt(&self, __formatter: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Error for Error

    source§

    fn source(&self) -> Option<&(dyn Error + 'static)>

    The lower-level source of this error, if any. Read more
    1.0.0 · source§

    fn description(&self) -> &str

    👎Deprecated since 1.42.0: use the Display impl or to_string()
    1.0.0 · source§

    fn cause(&self) -> Option<&dyn Error>

    👎Deprecated since 1.33.0: replaced by Error::source, which can support downcasting
    source§

    fn provide<'a>(&'a self, request: &mut Request<'a>)

    🔬This is a nightly-only experimental API. (error_generic_member_access)
    Provides type based access to context intended for error reports. Read more
    source§

    impl From<DecodeError> for Error

    source§

    fn from(source: DecodeError) -> Self

    Converts to this type from the input type.
    source§

    impl From<Error> for Error

    source§

    fn from(source: Error) -> Self

    Converts to this type from the input type.

    Auto Trait Implementations§

    §

    impl Freeze for Error

    §

    impl RefUnwindSafe for Error

    §

    impl Send for Error

    §

    impl Sync for Error

    §

    impl Unpin for Error

    §

    impl UnwindSafe for Error

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    source§

    impl<T> Borrow<T> for T
    where T: ?Sized,

    source§

    fn borrow(&self) -> &T

    Immutably borrows from an owned value. Read more
    source§

    impl<T> BorrowMut<T> for T
    where T: ?Sized,

    source§

    fn borrow_mut(&mut self) -> &mut T

    Mutably borrows from an owned value. Read more
    source§

    impl<T> From<T> for T

    source§

    fn from(t: T) -> T

    Returns the argument unchanged.

    diff --git a/pr/3024/docs/iroh_base/ticket/index.html b/pr/3024/docs/iroh_base/ticket/index.html index 422717bdfb..dca4f496b8 100644 --- a/pr/3024/docs/iroh_base/ticket/index.html +++ b/pr/3024/docs/iroh_base/ticket/index.html @@ -1 +1 @@ -iroh_base::ticket - Rust

    Module iroh_base::ticket

    source ·
    Available on crate feature base32 only.

    Structs§

    • A token containing everything to get a file from the provider.
    • A token containing information for establishing a connection to a node.

    Enums§

    • An error deserializing an iroh ticket.

    Traits§

    • A ticket is a serializable object combining information required for an operation.
    \ No newline at end of file +iroh_base::ticket - Rust

    Module iroh_base::ticket

    source ·
    Available on crate feature base32 only.

    Structs§

    • A token containing everything to get a file from the provider.
    • A token containing information for establishing a connection to a node.

    Enums§

    • An error deserializing an iroh ticket.

    Traits§

    • A ticket is a serializable object combining information required for an operation.
    \ No newline at end of file diff --git a/pr/3024/docs/iroh_base/ticket/struct.BlobTicket.html b/pr/3024/docs/iroh_base/ticket/struct.BlobTicket.html index 0e8d470a96..80cdfeb3a1 100644 --- a/pr/3024/docs/iroh_base/ticket/struct.BlobTicket.html +++ b/pr/3024/docs/iroh_base/ticket/struct.BlobTicket.html @@ -8,7 +8,7 @@
    source

    pub fn into_parts(self) -> (NodeAddr, Hash, BlobFormat)

    Get the contents of the ticket, consuming it.

    Trait Implementations§

    source§

    impl Clone for BlobTicket

    source§

    fn clone(&self) -> BlobTicket

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for BlobTicket

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl<'de> Deserialize<'de> for BlobTicket

    source§

    fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>

    Deserialize this value from the given Serde deserializer. Read more
    source§

    impl Display for BlobTicket

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl FromStr for BlobTicket

    §

    type Err = Error

    The associated error which can be returned from parsing.
    source§

    fn from_str(s: &str) -> Result<Self, Self::Err>

    Parses a string s to return a value of this type. Read more
    source§

    impl PartialEq for BlobTicket

    source§

    fn eq(&self, other: &BlobTicket) -> bool

    This method tests for self and other values to be equal, and is used by ==.
    1.0.0 · source§

    fn ne(&self, other: &Rhs) -> bool

    This method tests for !=. The default implementation is almost always -sufficient, and should not be overridden without very good reason.
    source§

    impl Serialize for BlobTicket

    source§

    fn serialize<S: Serializer>(&self, serializer: S) -> Result<S::Ok, S::Error>

    Serialize this value into the given Serde serializer. Read more
    source§

    impl Ticket for BlobTicket

    source§

    const KIND: &'static str = "blob"

    String prefix describing the kind of iroh ticket. Read more
    source§

    fn to_bytes(&self) -> Vec<u8>

    Serialize to bytes used in the base32 string representation.
    source§

    fn from_bytes(bytes: &[u8]) -> Result<Self, Error>

    Deserialize from the base32 string representation bytes.
    source§

    fn serialize(&self) -> String

    Serialize to string.
    source§

    fn deserialize(str: &str) -> Result<Self, Error>

    Deserialize from a string.
    source§

    impl Eq for BlobTicket

    source§

    impl StructuralPartialEq for BlobTicket

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where +sufficient, and should not be overridden without very good reason.

    source§

    impl Serialize for BlobTicket

    source§

    fn serialize<S: Serializer>(&self, serializer: S) -> Result<S::Ok, S::Error>

    Serialize this value into the given Serde serializer. Read more
    source§

    impl Ticket for BlobTicket

    source§

    const KIND: &'static str = "blob"

    String prefix describing the kind of iroh ticket. Read more
    source§

    fn to_bytes(&self) -> Vec<u8>

    Serialize to bytes used in the base32 string representation.
    source§

    fn from_bytes(bytes: &[u8]) -> Result<Self, Error>

    Deserialize from the base32 string representation bytes.
    source§

    fn serialize(&self) -> String

    Serialize to string.
    source§

    fn deserialize(str: &str) -> Result<Self, Error>

    Deserialize from a string.
    source§

    impl Eq for BlobTicket

    source§

    impl StructuralPartialEq for BlobTicket

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    source§

    impl<T> Borrow<T> for T
    where T: ?Sized,

    source§

    fn borrow(&self) -> &T

    Immutably borrows from an owned value. Read more
    source§

    impl<T> BorrowMut<T> for T
    where T: ?Sized,

    source§

    fn borrow_mut(&mut self) -> &mut T

    Mutably borrows from an owned value. Read more
    source§

    impl<T> From<T> for T

    source§

    fn from(t: T) -> T

    Returns the argument unchanged.

    diff --git a/pr/3024/docs/iroh_base/ticket/struct.NodeTicket.html b/pr/3024/docs/iroh_base/ticket/struct.NodeTicket.html index be539f0cc2..a21973446a 100644 --- a/pr/3024/docs/iroh_base/ticket/struct.NodeTicket.html +++ b/pr/3024/docs/iroh_base/ticket/struct.NodeTicket.html @@ -16,7 +16,7 @@ used to round-trip the ticket to string.

    source§

    impl From<NodeTicket> for NodeAddr

    source§

    fn from(ticket: NodeTicket) -> Self

    Returns the addressing info from given ticket.

    source§

    impl FromStr for NodeTicket

    §

    type Err = Error

    The associated error which can be returned from parsing.
    source§

    fn from_str(s: &str) -> Result<Self, Self::Err>

    Parses a string s to return a value of this type. Read more
    source§

    impl PartialEq for NodeTicket

    source§

    fn eq(&self, other: &NodeTicket) -> bool

    This method tests for self and other values to be equal, and is used by ==.
    1.0.0 · source§

    fn ne(&self, other: &Rhs) -> bool

    This method tests for !=. The default implementation is almost always -sufficient, and should not be overridden without very good reason.
    source§

    impl Serialize for NodeTicket

    source§

    fn serialize<S: Serializer>(&self, serializer: S) -> Result<S::Ok, S::Error>

    Serialize this value into the given Serde serializer. Read more
    source§

    impl Ticket for NodeTicket

    source§

    const KIND: &'static str = "node"

    String prefix describing the kind of iroh ticket. Read more
    source§

    fn to_bytes(&self) -> Vec<u8>

    Serialize to bytes used in the base32 string representation.
    source§

    fn from_bytes(bytes: &[u8]) -> Result<Self, Error>

    Deserialize from the base32 string representation bytes.
    source§

    fn serialize(&self) -> String

    Serialize to string.
    source§

    fn deserialize(str: &str) -> Result<Self, Error>

    Deserialize from a string.
    source§

    impl Eq for NodeTicket

    source§

    impl StructuralPartialEq for NodeTicket

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where +sufficient, and should not be overridden without very good reason.

    source§

    impl Serialize for NodeTicket

    source§

    fn serialize<S: Serializer>(&self, serializer: S) -> Result<S::Ok, S::Error>

    Serialize this value into the given Serde serializer. Read more
    source§

    impl Ticket for NodeTicket

    source§

    const KIND: &'static str = "node"

    String prefix describing the kind of iroh ticket. Read more
    source§

    fn to_bytes(&self) -> Vec<u8>

    Serialize to bytes used in the base32 string representation.
    source§

    fn from_bytes(bytes: &[u8]) -> Result<Self, Error>

    Deserialize from the base32 string representation bytes.
    source§

    fn serialize(&self) -> String

    Serialize to string.
    source§

    fn deserialize(str: &str) -> Result<Self, Error>

    Deserialize from a string.
    source§

    impl Eq for NodeTicket

    source§

    impl StructuralPartialEq for NodeTicket

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    source§

    impl<T> Borrow<T> for T
    where T: ?Sized,

    source§

    fn borrow(&self) -> &T

    Immutably borrows from an owned value. Read more
    source§

    impl<T> BorrowMut<T> for T
    where T: ?Sized,

    source§

    fn borrow_mut(&mut self) -> &mut T

    Mutably borrows from an owned value. Read more
    source§

    impl<T> From<T> for T

    source§

    fn from(t: T) -> T

    Returns the argument unchanged.

    diff --git a/pr/3024/docs/iroh_base/ticket/trait.Ticket.html b/pr/3024/docs/iroh_base/ticket/trait.Ticket.html index 3b82e369a0..8cac8cc1b8 100644 --- a/pr/3024/docs/iroh_base/ticket/trait.Ticket.html +++ b/pr/3024/docs/iroh_base/ticket/trait.Ticket.html @@ -1,4 +1,4 @@ -Ticket in iroh_base::ticket - Rust

    Trait iroh_base::ticket::Ticket

    source ·
    pub trait Ticket: Sized {
    +Ticket in iroh_base::ticket - Rust

    Trait iroh_base::ticket::Ticket

    source ·
    pub trait Ticket: Sized {
         const KIND: &'static str;
     
         // Required methods
    @@ -18,10 +18,10 @@ ticket will be prepended to the string to make it somewhat self describing.

    versioning, others might not.

    The serialization format for converting the ticket from and to bytes is left to the implementer. We recommend using postcard for serialization.

    -

    Required Associated Constants§

    source

    const KIND: &'static str

    String prefix describing the kind of iroh ticket.

    +

    Required Associated Constants§

    source

    const KIND: &'static str

    String prefix describing the kind of iroh ticket.

    This should be lower case ascii characters.

    -

    Required Methods§

    source

    fn to_bytes(&self) -> Vec<u8>

    Serialize to bytes used in the base32 string representation.

    -
    source

    fn from_bytes(bytes: &[u8]) -> Result<Self, Error>

    Deserialize from the base32 string representation bytes.

    -

    Provided Methods§

    source

    fn serialize(&self) -> String

    Serialize to string.

    -
    source

    fn deserialize(str: &str) -> Result<Self, Error>

    Deserialize from a string.

    +

    Required Methods§

    source

    fn to_bytes(&self) -> Vec<u8>

    Serialize to bytes used in the base32 string representation.

    +
    source

    fn from_bytes(bytes: &[u8]) -> Result<Self, Error>

    Deserialize from the base32 string representation bytes.

    +

    Provided Methods§

    source

    fn serialize(&self) -> String

    Serialize to string.

    +
    source

    fn deserialize(str: &str) -> Result<Self, Error>

    Deserialize from a string.

    Object Safety§

    This trait is not object safe.

    Implementors§

    source§

    impl Ticket for BlobTicket

    Available on crate feature key only.
    source§

    const KIND: &'static str = "blob"

    source§

    impl Ticket for NodeTicket

    Available on crate feature key only.
    source§

    const KIND: &'static str = "node"

    \ No newline at end of file diff --git a/pr/3024/docs/iroh_net_report/struct.Client.html b/pr/3024/docs/iroh_net_report/struct.Client.html index fb36aed4cc..ab5f8ac0fa 100644 --- a/pr/3024/docs/iroh_net_report/struct.Client.html +++ b/pr/3024/docs/iroh_net_report/struct.Client.html @@ -16,7 +16,7 @@ stop running.

    allows sending messages to the actor.

    source

    pub async fn get_report( &mut self, - dm: RelayMap, + dm: RelayMap, stun_conn4: Option<Arc<UdpSocket>>, stun_conn6: Option<Arc<UdpSocket>> ) -> Result<Arc<Report>>

    Runs a net_report, returning the report.

    @@ -31,7 +31,7 @@ responses and function correctly.

    may not be as reliable.

    source

    pub async fn get_report_channel( &mut self, - dm: RelayMap, + dm: RelayMap, stun_conn4: Option<Arc<UdpSocket>>, stun_conn6: Option<Arc<UdpSocket>> ) -> Result<Receiver<Result<Arc<Report>>>>

    Get report with channel

    diff --git a/pr/3024/docs/iroh_net_report/struct.RelayLatencies.html b/pr/3024/docs/iroh_net_report/struct.RelayLatencies.html index 9ddd64af24..b3dabb0356 100644 --- a/pr/3024/docs/iroh_net_report/struct.RelayLatencies.html +++ b/pr/3024/docs/iroh_net_report/struct.RelayLatencies.html @@ -1,5 +1,5 @@ RelayLatencies in iroh_net_report - Rust

    Struct iroh_net_report::RelayLatencies

    source ·
    pub struct RelayLatencies(/* private fields */);
    Expand description

    Latencies per relay node.

    -

    Implementations§

    source§

    impl RelayLatencies

    source

    pub fn iter(&self) -> impl Iterator<Item = (&RelayUrl, Duration)> + '_

    Returns an iterator over all the relays and their latencies.

    +

    Implementations§

    source§

    impl RelayLatencies

    source

    pub fn iter(&self) -> impl Iterator<Item = (&RelayUrl, Duration)> + '_

    Returns an iterator over all the relays and their latencies.

    Trait Implementations§

    source§

    impl Clone for RelayLatencies

    source§

    fn clone(&self) -> RelayLatencies

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for RelayLatencies

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Default for RelayLatencies

    source§

    fn default() -> RelayLatencies

    Returns the “default value” for a type. Read more
    source§

    impl PartialEq for RelayLatencies

    source§

    fn eq(&self, other: &RelayLatencies) -> bool

    This method tests for self and other values to be equal, and is used by ==.
    1.0.0 · source§

    fn ne(&self, other: &Rhs) -> bool

    This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
    source§

    impl Eq for RelayLatencies

    source§

    impl StructuralPartialEq for RelayLatencies

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where diff --git a/pr/3024/docs/iroh_net_report/struct.Report.html b/pr/3024/docs/iroh_net_report/struct.Report.html index 21c62c01df..60daa8fba1 100644 --- a/pr/3024/docs/iroh_net_report/struct.Report.html +++ b/pr/3024/docs/iroh_net_report/struct.Report.html @@ -11,7 +11,7 @@ pub mapping_varies_by_dest_ipv6: Option<bool>, pub hair_pinning: Option<bool>, pub portmap_probe: Option<ProbeOutput>, - pub preferred_relay: Option<RelayUrl>, + pub preferred_relay: Option<RelayUrl>, pub relay_latency: RelayLatencies, pub relay_v4_latency: RelayLatencies, pub relay_v6_latency: RelayLatencies, @@ -35,7 +35,7 @@ detecting rather than using it. For now.

    §hair_pinning: Option<bool>

    Whether the router supports communicating between two local devices through the NATted public IP address (on IPv4).

    §portmap_probe: Option<ProbeOutput>

    Probe indicating the presence of port mapping protocols on the LAN.

    -
    §preferred_relay: Option<RelayUrl>

    None for unknown

    +
    §preferred_relay: Option<RelayUrl>

    None for unknown

    §relay_latency: RelayLatencies

    keyed by relay Url

    §relay_v4_latency: RelayLatencies

    keyed by relay Url

    §relay_v6_latency: RelayLatencies

    keyed by relay Url

    diff --git a/pr/3024/docs/iroh_relay/client/index.html b/pr/3024/docs/iroh_relay/client/index.html index 64a38ed50b..acd7c5ac17 100644 --- a/pr/3024/docs/iroh_relay/client/index.html +++ b/pr/3024/docs/iroh_relay/client/index.html @@ -1,3 +1,3 @@ -iroh_relay::client - Rust

    Module iroh_relay::client

    source ·
    Expand description

    Exposes Client, which allows to establish connections to a relay server.

    +iroh_relay::client - Rust

    Module iroh_relay::client

    source ·
    Expand description

    Exposes Client, which allows to establish connections to a relay server.

    Based on tailscale/derp/derphttp/derphttp_client.go

    Structs§

    Enums§

    \ No newline at end of file diff --git a/pr/3024/docs/iroh_relay/client/struct.Client.html b/pr/3024/docs/iroh_relay/client/struct.Client.html index c24d10d69f..7b34a088d9 100644 --- a/pr/3024/docs/iroh_relay/client/struct.Client.html +++ b/pr/3024/docs/iroh_relay/client/struct.Client.html @@ -1,32 +1,32 @@ Client in iroh_relay::client - Rust

    Struct iroh_relay::client::Client

    source ·
    pub struct Client { /* private fields */ }
    Expand description

    An HTTP Relay client.

    Cheaply clonable.

    -

    Implementations§

    source§

    impl Client

    source

    pub fn public_key(&self) -> PublicKey

    The public key for this client

    -
    source

    pub async fn connect(&self) -> Result<Conn, ClientError>

    Connects to a relay Server and returns the underlying relay connection.

    +

    Implementations§

    source§

    impl Client

    source

    pub fn public_key(&self) -> PublicKey

    The public key for this client

    +
    source

    pub async fn connect(&self) -> Result<Conn, ClientError>

    Connects to a relay Server and returns the underlying relay connection.

    Returns ClientError::Closed if the Client is closed.

    If there is already an active relay connection, returns the already connected crate::RelayConn.

    -
    source

    pub async fn note_preferred(&self, is_preferred: bool)

    Let the server know that this client is the preferred client

    -
    source

    pub async fn local_addr(&self) -> Option<SocketAddr>

    Get the local addr of the connection. If there is no current underlying relay connection +

    source

    pub async fn note_preferred(&self, is_preferred: bool)

    Let the server know that this client is the preferred client

    +
    source

    pub async fn local_addr(&self) -> Option<SocketAddr>

    Get the local addr of the connection. If there is no current underlying relay connection or the Client is closed, returns None.

    -
    source

    pub async fn ping(&self) -> Result<Duration, ClientError>

    Send a ping to the server. Return once we get an expected pong.

    +
    source

    pub async fn ping(&self) -> Result<Duration, ClientError>

    Send a ping to the server. Return once we get an expected pong.

    There must be a task polling recv_detail to process the pong response.

    -
    source

    pub async fn send_pong(&self, data: [u8; 8]) -> Result<(), ClientError>

    Send a pong back to the server.

    +
    source

    pub async fn send_pong(&self, data: [u8; 8]) -> Result<(), ClientError>

    Send a pong back to the server.

    If there is no underlying active relay connection, it creates one before attempting to send the pong message.

    If there is an error sending pong, it closes the underlying relay connection before returning.

    -
    source

    pub async fn send( +

    source

    pub async fn send( &self, - dst_key: PublicKey, + dst_key: PublicKey, b: Bytes ) -> Result<(), ClientError>

    Send a packet to the server.

    If there is no underlying active relay connection, it creates one before attempting to send the message.

    If there is an error sending the packet, it closes the underlying relay connection before returning.

    -
    source

    pub async fn close(self) -> Result<(), ClientError>

    Close the http relay connection.

    -
    source

    pub async fn close_for_reconnect(&self) -> Result<(), ClientError>

    Disconnect the http relay connection.

    -
    source

    pub async fn is_connected(&self) -> Result<bool, ClientError>

    Returns true if the underlying relay connection is established.

    +
    source

    pub async fn close(self) -> Result<(), ClientError>

    Close the http relay connection.

    +
    source

    pub async fn close_for_reconnect(&self) -> Result<(), ClientError>

    Disconnect the http relay connection.

    +
    source

    pub async fn is_connected(&self) -> Result<bool, ClientError>

    Returns true if the underlying relay connection is established.

    Trait Implementations§

    source§

    impl Clone for Client

    source§

    fn clone(&self) -> Client

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for Client

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more

    Auto Trait Implementations§

    §

    impl Freeze for Client

    §

    impl RefUnwindSafe for Client

    §

    impl Send for Client

    §

    impl Sync for Client

    §

    impl Unpin for Client

    §

    impl UnwindSafe for Client

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where diff --git a/pr/3024/docs/iroh_relay/client/struct.ClientBuilder.html b/pr/3024/docs/iroh_relay/client/struct.ClientBuilder.html index 89d39ec243..af45375003 100644 --- a/pr/3024/docs/iroh_relay/client/struct.ClientBuilder.html +++ b/pr/3024/docs/iroh_relay/client/struct.ClientBuilder.html @@ -1,27 +1,27 @@ -ClientBuilder in iroh_relay::client - Rust

    Struct iroh_relay::client::ClientBuilder

    source ·
    pub struct ClientBuilder { /* private fields */ }
    Expand description

    Build a Client.

    -

    Implementations§

    source§

    impl ClientBuilder

    source

    pub fn new(url: impl Into<RelayUrl>) -> Self

    Create a new ClientBuilder

    -
    source

    pub fn server_url(self, url: impl Into<RelayUrl>) -> Self

    Sets the server url

    -
    source

    pub fn protocol(self, protocol: Protocol) -> Self

    Sets whether to connect to the relay via websockets or not. +ClientBuilder in iroh_relay::client - Rust

    Struct iroh_relay::client::ClientBuilder

    source ·
    pub struct ClientBuilder { /* private fields */ }
    Expand description

    Build a Client.

    +

    Implementations§

    source§

    impl ClientBuilder

    source

    pub fn new(url: impl Into<RelayUrl>) -> Self

    Create a new ClientBuilder

    +
    source

    pub fn server_url(self, url: impl Into<RelayUrl>) -> Self

    Sets the server url

    +
    source

    pub fn protocol(self, protocol: Protocol) -> Self

    Sets whether to connect to the relay via websockets or not. Set to use non-websocket, normal relaying by default.

    -
    source

    pub fn address_family_selector<S>(self, selector: S) -> Self
    where +

    source

    pub fn address_family_selector<S>(self, selector: S) -> Self
    where S: Fn() -> BoxFuture<bool> + Send + Sync + 'static,

    Returns if we should prefer ipv6 it replaces the relayhttp.AddressFamilySelector we pass It provides the hint as to whether in an IPv4-vs-IPv6 race that IPv4 should be held back a bit to give IPv6 a better-than-50/50 chance of winning. We only return true when we believe IPv6 will work anyway, so we don’t artificially delay the connection speed.

    -
    source

    pub fn is_preferred(self, is: bool) -> Self

    Indicate this client is the preferred way to communicate -to the peer with this client’s [PublicKey]

    -
    source

    pub fn is_prober(self, is: bool) -> Self

    Indicates this client is a prober

    -
    source

    pub fn insecure_skip_cert_verify(self, skip: bool) -> Self

    Available on test or crate feature test-utils only.

    Skip the verification of the relay server’s SSL certificates.

    +
    source

    pub fn is_preferred(self, is: bool) -> Self

    Indicate this client is the preferred way to communicate +to the peer with this client’s PublicKey

    +
    source

    pub fn is_prober(self, is: bool) -> Self

    Indicates this client is a prober

    +
    source

    pub fn insecure_skip_cert_verify(self, skip: bool) -> Self

    Available on crate feature test-utils only.

    Skip the verification of the relay server’s SSL certificates.

    May only be used in tests.

    -
    source

    pub fn proxy_url(self, url: Url) -> Self

    Set an explicit proxy url to proxy all HTTP(S) traffic through.

    -
    source

    pub fn build( +

    source

    pub fn proxy_url(self, url: Url) -> Self

    Set an explicit proxy url to proxy all HTTP(S) traffic through.

    +
    source

    pub fn build( self, - key: SecretKey, + key: SecretKey, dns_resolver: DnsResolver ) -> (Client, ClientReceiver)

    Build the Client

    -
    source

    pub fn server_public_key(self, server_public_key: PublicKey) -> Self

    The expected [PublicKey] of the relay server we are connecting to.

    +
    source

    pub fn server_public_key(self, server_public_key: PublicKey) -> Self

    The expected PublicKey of the relay server we are connecting to.

    Trait Implementations§

    source§

    impl Debug for ClientBuilder

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where diff --git a/pr/3024/docs/iroh_relay/client/struct.ClientReceiver.html b/pr/3024/docs/iroh_relay/client/struct.ClientReceiver.html index cd9c95d16a..da27690095 100644 --- a/pr/3024/docs/iroh_relay/client/struct.ClientReceiver.html +++ b/pr/3024/docs/iroh_relay/client/struct.ClientReceiver.html @@ -1,5 +1,5 @@ ClientReceiver in iroh_relay::client - Rust

    Struct iroh_relay::client::ClientReceiver

    source ·
    pub struct ClientReceiver { /* private fields */ }
    Expand description

    Receiving end of a Client.

    -

    Implementations§

    source§

    impl ClientReceiver

    source

    pub async fn recv(&mut self) -> Option<Result<ReceivedMessage, ClientError>>

    Reads a message from the server.

    +

    Implementations§

    source§

    impl ClientReceiver

    source

    pub async fn recv(&mut self) -> Option<Result<ReceivedMessage, ClientError>>

    Reads a message from the server.

    Trait Implementations§

    source§

    impl Debug for ClientReceiver

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where diff --git a/pr/3024/docs/iroh_relay/defaults/constant.DEFAULT_RELAY_QUIC_PORT.html b/pr/3024/docs/iroh_relay/defaults/constant.DEFAULT_RELAY_QUIC_PORT.html index 1aae343a05..1cefe9e1c2 100644 --- a/pr/3024/docs/iroh_relay/defaults/constant.DEFAULT_RELAY_QUIC_PORT.html +++ b/pr/3024/docs/iroh_relay/defaults/constant.DEFAULT_RELAY_QUIC_PORT.html @@ -1,4 +1,4 @@ -DEFAULT_RELAY_QUIC_PORT in iroh_relay::defaults - Rust

    Constant iroh_relay::defaults::DEFAULT_RELAY_QUIC_PORT

    pub const DEFAULT_RELAY_QUIC_PORT: u16 = 7842; // 7_842u16
    Expand description

    The default QUIC port used by the Relay server to accept QUIC connections +DEFAULT_RELAY_QUIC_PORT in iroh_relay::defaults - Rust

    Constant iroh_relay::defaults::DEFAULT_RELAY_QUIC_PORT

    source ·
    pub const DEFAULT_RELAY_QUIC_PORT: u16 = 7842; // 7_842u16
    Expand description

    The default QUIC port used by the Relay server to accept QUIC connections for QUIC address discovery

    The port is “QUIC” typed on a phone keypad.

    \ No newline at end of file diff --git a/pr/3024/docs/iroh_relay/defaults/constant.DEFAULT_STUN_PORT.html b/pr/3024/docs/iroh_relay/defaults/constant.DEFAULT_STUN_PORT.html index a5f601c406..741d41ad3d 100644 --- a/pr/3024/docs/iroh_relay/defaults/constant.DEFAULT_STUN_PORT.html +++ b/pr/3024/docs/iroh_relay/defaults/constant.DEFAULT_STUN_PORT.html @@ -1,3 +1,3 @@ -DEFAULT_STUN_PORT in iroh_relay::defaults - Rust

    Constant iroh_relay::defaults::DEFAULT_STUN_PORT

    pub const DEFAULT_STUN_PORT: u16 = 3478; // 3_478u16
    Expand description

    The default STUN port used by the Relay server.

    +DEFAULT_STUN_PORT in iroh_relay::defaults - Rust

    Constant iroh_relay::defaults::DEFAULT_STUN_PORT

    source ·
    pub const DEFAULT_STUN_PORT: u16 = 3478; // 3_478u16
    Expand description

    The default STUN port used by the Relay server.

    The STUN port as defined by RFC 8489

    \ No newline at end of file diff --git a/pr/3024/docs/iroh_relay/defaults/index.html b/pr/3024/docs/iroh_relay/defaults/index.html index ce58af8f48..218e5678e4 100644 --- a/pr/3024/docs/iroh_relay/defaults/index.html +++ b/pr/3024/docs/iroh_relay/defaults/index.html @@ -1,3 +1,3 @@ -iroh_relay::defaults - Rust

    Module iroh_relay::defaults

    source ·
    Expand description

    Default values used in the relay.

    +iroh_relay::defaults - Rust

    Module iroh_relay::defaults

    source ·
    Expand description

    Default values used in the relay.

    Constants§

    \ No newline at end of file diff --git a/pr/3024/docs/iroh_relay/enum.ReceivedMessage.html b/pr/3024/docs/iroh_relay/enum.ReceivedMessage.html index 784f6548a1..b70f0828f6 100644 --- a/pr/3024/docs/iroh_relay/enum.ReceivedMessage.html +++ b/pr/3024/docs/iroh_relay/enum.ReceivedMessage.html @@ -1,9 +1,9 @@ ReceivedMessage in iroh_relay - Rust

    Enum iroh_relay::ReceivedMessage

    source ·
    pub enum ReceivedMessage {
         ReceivedPacket {
    -        remote_node_id: NodeId,
    +        remote_node_id: NodeId,
             data: Bytes,
         },
    -    NodeGone(NodeId),
    +    NodeGone(NodeId),
         Ping([u8; 8]),
         Pong([u8; 8]),
         KeepAlive,
    @@ -16,9 +16,9 @@
         },
     }
    Expand description

    The type of message received by the Conn from a relay server.

    Variants§

    §

    ReceivedPacket

    Represents an incoming packet.

    -

    Fields

    §remote_node_id: NodeId

    The [NodeId] of the packet sender.

    +

    Fields

    §remote_node_id: NodeId

    The NodeId of the packet sender.

    §data: Bytes

    The received packet bytes.

    -
    §

    NodeGone(NodeId)

    Indicates that the client identified by the underlying public key had previously sent you a +

    §

    NodeGone(NodeId)

    Indicates that the client identified by the underlying public key had previously sent you a packet but has now disconnected from the server.

    §

    Ping([u8; 8])

    Request from a client or server to reply to the other side with a ReceivedMessage::Pong with the given payload.

    diff --git a/pr/3024/docs/iroh_relay/http/constant.RELAY_PATH.html b/pr/3024/docs/iroh_relay/http/constant.RELAY_PATH.html index 438ba1d4aa..5b11c91fa3 100644 --- a/pr/3024/docs/iroh_relay/http/constant.RELAY_PATH.html +++ b/pr/3024/docs/iroh_relay/http/constant.RELAY_PATH.html @@ -1,3 +1,3 @@ -RELAY_PATH in iroh_relay::http - Rust

    Constant iroh_relay::http::RELAY_PATH

    source ·
    pub const RELAY_PATH: &str = "/relay";
    Expand description

    The HTTP path under which the relay accepts relaying connections +RELAY_PATH in iroh_relay::http - Rust

    Constant iroh_relay::http::RELAY_PATH

    source ·
    pub const RELAY_PATH: &str = "/relay";
    Expand description

    The HTTP path under which the relay accepts relaying connections (over websockets and a custom upgrade protocol).

    \ No newline at end of file diff --git a/pr/3024/docs/iroh_relay/http/constant.RELAY_PROBE_PATH.html b/pr/3024/docs/iroh_relay/http/constant.RELAY_PROBE_PATH.html index f79d263e61..e9cf158b64 100644 --- a/pr/3024/docs/iroh_relay/http/constant.RELAY_PROBE_PATH.html +++ b/pr/3024/docs/iroh_relay/http/constant.RELAY_PROBE_PATH.html @@ -1,2 +1,2 @@ -RELAY_PROBE_PATH in iroh_relay::http - Rust

    Constant iroh_relay::http::RELAY_PROBE_PATH

    source ·
    pub const RELAY_PROBE_PATH: &str = "/ping";
    Expand description

    The HTTP path under which the relay allows doing latency queries for testing.

    +RELAY_PROBE_PATH in iroh_relay::http - Rust

    Constant iroh_relay::http::RELAY_PROBE_PATH

    source ·
    pub const RELAY_PROBE_PATH: &str = "/ping";
    Expand description

    The HTTP path under which the relay allows doing latency queries for testing.

    \ No newline at end of file diff --git a/pr/3024/docs/iroh_relay/http/enum.Protocol.html b/pr/3024/docs/iroh_relay/http/enum.Protocol.html index 2e8e3c23b7..022e3abee7 100644 --- a/pr/3024/docs/iroh_relay/http/enum.Protocol.html +++ b/pr/3024/docs/iroh_relay/http/enum.Protocol.html @@ -1,15 +1,15 @@ -Protocol in iroh_relay::http - Rust

    Enum iroh_relay::http::Protocol

    source ·
    pub enum Protocol {
    +Protocol in iroh_relay::http - Rust

    Enum iroh_relay::http::Protocol

    source ·
    pub enum Protocol {
         Relay,
         Websocket,
     }
    Expand description

    The HTTP upgrade protocol used for relaying.

    Variants§

    §

    Relay

    Relays over the custom relaying protocol with a custom HTTP upgrade header.

    §

    Websocket

    Relays over websockets.

    Originally introduced to support browser connections.

    -

    Implementations§

    source§

    impl Protocol

    source

    pub const fn upgrade_header(&self) -> &'static str

    The HTTP upgrade header used or expected.

    -
    source

    pub fn parse_header(header: &HeaderValue) -> Option<Self>

    Tries to match the value of an HTTP upgrade header to figure out which protocol should be initiated.

    -

    Trait Implementations§

    source§

    impl Clone for Protocol

    source§

    fn clone(&self) -> Protocol

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for Protocol

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl PartialEq for Protocol

    source§

    fn eq(&self, other: &Protocol) -> bool

    This method tests for self and other values to be equal, and is used +

    Implementations§

    source§

    impl Protocol

    source

    pub const fn upgrade_header(&self) -> &'static str

    The HTTP upgrade header used or expected.

    +
    source

    pub fn parse_header(header: &HeaderValue) -> Option<Self>

    Tries to match the value of an HTTP upgrade header to figure out which protocol should be initiated.

    +

    Trait Implementations§

    source§

    impl Clone for Protocol

    source§

    fn clone(&self) -> Protocol

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for Protocol

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl PartialEq for Protocol

    source§

    fn eq(&self, other: &Protocol) -> bool

    This method tests for self and other values to be equal, and is used by ==.
    1.0.0 · source§

    fn ne(&self, other: &Rhs) -> bool

    This method tests for !=. The default implementation is almost always -sufficient, and should not be overridden without very good reason.
    source§

    impl Copy for Protocol

    source§

    impl Eq for Protocol

    source§

    impl StructuralPartialEq for Protocol

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where +sufficient, and should not be overridden without very good reason.

    source§

    impl Copy for Protocol

    source§

    impl Eq for Protocol

    source§

    impl StructuralPartialEq for Protocol

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/iroh_relay/http/index.html b/pr/3024/docs/iroh_relay/http/index.html index 48ac01fe67..3c5cfa2345 100644 --- a/pr/3024/docs/iroh_relay/http/index.html +++ b/pr/3024/docs/iroh_relay/http/index.html @@ -1,3 +1,3 @@ -iroh_relay::http - Rust

    Module iroh_relay::http

    source ·
    Expand description

    HTTP-specific constants for the relay server and client.

    +iroh_relay::http - Rust

    Module iroh_relay::http

    source ·
    Expand description

    HTTP-specific constants for the relay server and client.

    Enums§

    • The HTTP upgrade protocol used for relaying.

    Constants§

    • The HTTP path under which the relay accepts relaying connections (over websockets and a custom upgrade protocol).
    • The HTTP path under which the relay allows doing latency queries for testing.
    \ No newline at end of file diff --git a/pr/3024/docs/iroh_relay/index.html b/pr/3024/docs/iroh_relay/index.html index 14eb06e67a..8d1b4725ef 100644 --- a/pr/3024/docs/iroh_relay/index.html +++ b/pr/3024/docs/iroh_relay/index.html @@ -1,4 +1,4 @@ -iroh_relay - Rust

    Crate iroh_relay

    source ·
    Expand description

    Iroh’s relay is a feature within iroh, a peer-to-peer +iroh_relay - Rust

    Crate iroh_relay

    source ·
    Expand description

    Iroh’s relay is a feature within iroh, a peer-to-peer networking system designed to facilitate direct, encrypted connections between devices. Iroh aims to simplify decentralized communication by automatically handling connections through “relays” when direct connections aren’t immediately possible. The relay server helps establish diff --git a/pr/3024/docs/iroh_relay/protos/relay/index.html b/pr/3024/docs/iroh_relay/protos/relay/index.html index 0a81bbec7b..d7c1f9622f 100644 --- a/pr/3024/docs/iroh_relay/protos/relay/index.html +++ b/pr/3024/docs/iroh_relay/protos/relay/index.html @@ -1,4 +1,4 @@ -iroh_relay::protos::relay - Rust

    Module iroh_relay::protos::relay

    source ·
    Expand description

    This module implements the relaying protocol used by the server and client.

    +iroh_relay::protos::relay - Rust

    Module iroh_relay::protos::relay

    source ·
    Expand description

    This module implements the relaying protocol used by the server and client.

    Protocol flow:

    Login:

      diff --git a/pr/3024/docs/iroh_relay/protos/stun/struct.TransactionId.html b/pr/3024/docs/iroh_relay/protos/stun/struct.TransactionId.html index 4087bfcc8f..1dc307d94b 100644 --- a/pr/3024/docs/iroh_relay/protos/stun/struct.TransactionId.html +++ b/pr/3024/docs/iroh_relay/protos/stun/struct.TransactionId.html @@ -1044,25 +1044,25 @@ code in the form of a C-string literal (c"...").

      let expected = stringify!(c"\xFErris the 🦀\u{7}"); assert_eq!(lit, expected); }

    -
    1.23.0 · source

    pub fn to_ascii_uppercase(&self) -> Vec<u8> ⓘ

    Returns a vector containing a copy of this slice where each byte +

    1.23.0 · source

    pub fn to_ascii_uppercase(&self) -> Vec<u8> ⓘ

    Available on non-no_global_oom_handling only.

    Returns a vector containing a copy of this slice where each byte is mapped to its ASCII upper case equivalent.

    ASCII letters ‘a’ to ‘z’ are mapped to ‘A’ to ‘Z’, but non-ASCII letters are unchanged.

    To uppercase the value in-place, use make_ascii_uppercase.

    -
    1.23.0 · source

    pub fn to_ascii_lowercase(&self) -> Vec<u8> ⓘ

    Returns a vector containing a copy of this slice where each byte +

    1.23.0 · source

    pub fn to_ascii_lowercase(&self) -> Vec<u8> ⓘ

    Available on non-no_global_oom_handling only.

    Returns a vector containing a copy of this slice where each byte is mapped to its ASCII lower case equivalent.

    ASCII letters ‘A’ to ‘Z’ are mapped to ‘a’ to ‘z’, but non-ASCII letters are unchanged.

    To lowercase the value in-place, use make_ascii_lowercase.

    1.0.0 · source

    pub fn to_vec(&self) -> Vec<T>
    where - T: Clone,

    Copies self into a new Vec.

    + T: Clone,

    Available on non-no_global_oom_handling only.

    Copies self into a new Vec.

    §Examples
    let s = [10, 40, 30];
     let x = s.to_vec();
     // Here, `s` and `x` can be modified independently.
    source

    pub fn to_vec_in<A>(&self, alloc: A) -> Vec<T, A>
    where A: Allocator, - T: Clone,

    🔬This is a nightly-only experimental API. (allocator_api)

    Copies self into a new Vec with an allocator.

    + T: Clone,

    🔬This is a nightly-only experimental API. (allocator_api)
    Available on non-no_global_oom_handling only.

    Copies self into a new Vec with an allocator.

    §Examples
    #![feature(allocator_api)]
     
    @@ -1072,7 +1072,7 @@ but non-ASCII letters are unchanged.

    let x = s.to_vec_in(System); // Here, `s` and `x` can be modified independently.
    1.40.0 · source

    pub fn repeat(&self, n: usize) -> Vec<T>
    where - T: Copy,

    Creates a vector by copying a slice n times.

    + T: Copy,

    Available on non-no_global_oom_handling only.

    Creates a vector by copying a slice n times.

    §Panics

    This function will panic if the capacity would overflow.

    §Examples
    diff --git a/pr/3024/docs/iroh_relay/quic/index.html b/pr/3024/docs/iroh_relay/quic/index.html index ca6c731a31..36f98128a3 100644 --- a/pr/3024/docs/iroh_relay/quic/index.html +++ b/pr/3024/docs/iroh_relay/quic/index.html @@ -1,3 +1,3 @@ -iroh_relay::quic - Rust

    Module iroh_relay::quic

    source ·
    Expand description

    Create a QUIC server that accepts connections +iroh_relay::quic - Rust

    Module iroh_relay::quic

    source ·
    Expand description

    Create a QUIC server that accepts connections for QUIC address discovery.

    Structs§

    • Handles the client side of QUIC address discovery.

    Constants§

    \ No newline at end of file diff --git a/pr/3024/docs/iroh_relay/quic/struct.QuicClient.html b/pr/3024/docs/iroh_relay/quic/struct.QuicClient.html index f5c0154a6a..24cc80926a 100644 --- a/pr/3024/docs/iroh_relay/quic/struct.QuicClient.html +++ b/pr/3024/docs/iroh_relay/quic/struct.QuicClient.html @@ -1,7 +1,7 @@ -QuicClient in iroh_relay::quic - Rust

    Struct iroh_relay::quic::QuicClient

    source ·
    pub struct QuicClient { /* private fields */ }
    Expand description

    Handles the client side of QUIC address discovery.

    -

    Implementations§

    source§

    impl QuicClient

    source

    pub fn new(ep: Endpoint, client_config: ClientConfig) -> Result<Self>

    Create a new QuicClient to handle the client side of QUIC +QuicClient in iroh_relay::quic - Rust

    Struct iroh_relay::quic::QuicClient

    source ·
    pub struct QuicClient { /* private fields */ }
    Expand description

    Handles the client side of QUIC address discovery.

    +

    Implementations§

    source§

    impl QuicClient

    source

    pub fn new(ep: Endpoint, client_config: ClientConfig) -> Result<Self>

    Create a new QuicClient to handle the client side of QUIC address discovery.

    -
    source

    pub async fn get_addr_and_latency( +

    source

    pub async fn get_addr_and_latency( &self, server_addr: SocketAddr, host: &str @@ -9,7 +9,7 @@ address discovery.

    Creates a connection and returns the observed address and estimated latency of the connection.

    Consumes and gracefully closes the connection.

    -

    Trait Implementations§

    source§

    impl Debug for QuicClient

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where +

    Trait Implementations§

    source§

    impl Debug for QuicClient

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/iroh_relay/server/enum.CertConfig.html b/pr/3024/docs/iroh_relay/server/enum.CertConfig.html index 127e75463c..464a9456bb 100644 --- a/pr/3024/docs/iroh_relay/server/enum.CertConfig.html +++ b/pr/3024/docs/iroh_relay/server/enum.CertConfig.html @@ -1,4 +1,4 @@ -CertConfig in iroh_relay::server - Rust

    Enum iroh_relay::server::CertConfig

    source ·
    pub enum CertConfig<EC: Debug, EA: Debug = EC> {
    +CertConfig in iroh_relay::server - Rust

    Enum iroh_relay::server::CertConfig

    source ·
    pub enum CertConfig<EC: Debug, EA: Debug = EC> {
         LetsEncrypt {
             state: AcmeState<EC, EA>,
         },
    @@ -10,7 +10,7 @@
     

    Fields

    §state: AcmeState<EC, EA>

    State for Let’s Encrypt certificates.

    §

    Manual

    Use a static TLS key and certificate chain.

    Fields

    §certs: Vec<CertificateDer<'static>>

    The TLS certificate chain.

    -

    Trait Implementations§

    source§

    impl<EC: Debug, EA: Debug> Debug for CertConfig<EC, EA>

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more

    Auto Trait Implementations§

    §

    impl<EC, EA> Freeze for CertConfig<EC, EA>

    §

    impl<EC, EA = EC> !RefUnwindSafe for CertConfig<EC, EA>

    §

    impl<EC, EA> Send for CertConfig<EC, EA>

    §

    impl<EC, EA = EC> !Sync for CertConfig<EC, EA>

    §

    impl<EC, EA> Unpin for CertConfig<EC, EA>

    §

    impl<EC, EA = EC> !UnwindSafe for CertConfig<EC, EA>

    Blanket Implementations§

    source§

    impl<T> Any for T
    where +

    Trait Implementations§

    source§

    impl<EC: Debug, EA: Debug> Debug for CertConfig<EC, EA>

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more

    Auto Trait Implementations§

    §

    impl<EC, EA> Freeze for CertConfig<EC, EA>

    §

    impl<EC, EA = EC> !RefUnwindSafe for CertConfig<EC, EA>

    §

    impl<EC, EA> Send for CertConfig<EC, EA>

    §

    impl<EC, EA = EC> !Sync for CertConfig<EC, EA>

    §

    impl<EC, EA> Unpin for CertConfig<EC, EA>

    §

    impl<EC, EA = EC> !UnwindSafe for CertConfig<EC, EA>

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/iroh_relay/server/index.html b/pr/3024/docs/iroh_relay/server/index.html index cf9cad6ddb..2d7a9de723 100644 --- a/pr/3024/docs/iroh_relay/server/index.html +++ b/pr/3024/docs/iroh_relay/server/index.html @@ -1,4 +1,4 @@ -iroh_relay::server - Rust

    Module iroh_relay::server

    source ·
    Available on crate feature server only.
    Expand description

    A fully-fledged iroh-relay server over HTTP or HTTPS.

    +iroh_relay::server - Rust

    Module iroh_relay::server

    source ·
    Available on crate feature server only.
    Expand description

    A fully-fledged iroh-relay server over HTTP or HTTPS.

    This module provides an API to run a full fledged iroh-relay server. It is primarily used by the iroh-relay binary in this crate. It can be used to run a relay server in other locations however.

    diff --git a/pr/3024/docs/iroh_relay/server/struct.ClientConnRateLimit.html b/pr/3024/docs/iroh_relay/server/struct.ClientConnRateLimit.html index 4d8e3abc17..f35199142e 100644 --- a/pr/3024/docs/iroh_relay/server/struct.ClientConnRateLimit.html +++ b/pr/3024/docs/iroh_relay/server/struct.ClientConnRateLimit.html @@ -1,10 +1,10 @@ -ClientConnRateLimit in iroh_relay::server - Rust

    Struct iroh_relay::server::ClientConnRateLimit

    source ·
    pub struct ClientConnRateLimit {
    +ClientConnRateLimit in iroh_relay::server - Rust

    Struct iroh_relay::server::ClientConnRateLimit

    source ·
    pub struct ClientConnRateLimit {
         pub bytes_per_second: NonZeroU32,
         pub max_burst_bytes: Option<NonZeroU32>,
     }
    Available on crate feature server only.
    Expand description

    Per-client rate limit configuration.

    Fields§

    §bytes_per_second: NonZeroU32

    Max number of bytes per second to read from the client connection.

    §max_burst_bytes: Option<NonZeroU32>

    Max number of bytes to read in a single burst.

    -

    Trait Implementations§

    source§

    impl Clone for ClientConnRateLimit

    source§

    fn clone(&self) -> ClientConnRateLimit

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for ClientConnRateLimit

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Copy for ClientConnRateLimit

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where +

    Trait Implementations§

    source§

    impl Clone for ClientConnRateLimit

    source§

    fn clone(&self) -> ClientConnRateLimit

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for ClientConnRateLimit

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Copy for ClientConnRateLimit

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/iroh_relay/server/struct.Limits.html b/pr/3024/docs/iroh_relay/server/struct.Limits.html index e586e04ce9..b6d4c013ca 100644 --- a/pr/3024/docs/iroh_relay/server/struct.Limits.html +++ b/pr/3024/docs/iroh_relay/server/struct.Limits.html @@ -1,4 +1,4 @@ -Limits in iroh_relay::server - Rust

    Struct iroh_relay::server::Limits

    source ·
    pub struct Limits {
    +Limits in iroh_relay::server - Rust

    Struct iroh_relay::server::Limits

    source ·
    pub struct Limits {
         pub accept_conn_limit: Option<f64>,
         pub accept_conn_burst: Option<usize>,
         pub client_rx: Option<ClientConnRateLimit>,
    @@ -6,7 +6,7 @@
     

    Fields§

    §accept_conn_limit: Option<f64>

    Rate limit for accepting new connection. Unlimited if not set.

    §accept_conn_burst: Option<usize>

    Burst limit for accepting new connection. Unlimited if not set.

    §client_rx: Option<ClientConnRateLimit>

    Rate limits for incoming traffic from a client connection.

    -

    Trait Implementations§

    source§

    impl Debug for Limits

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Default for Limits

    source§

    fn default() -> Limits

    Returns the “default value” for a type. Read more

    Auto Trait Implementations§

    §

    impl Freeze for Limits

    §

    impl RefUnwindSafe for Limits

    §

    impl Send for Limits

    §

    impl Sync for Limits

    §

    impl Unpin for Limits

    §

    impl UnwindSafe for Limits

    Blanket Implementations§

    source§

    impl<T> Any for T
    where +

    Trait Implementations§

    source§

    impl Debug for Limits

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Default for Limits

    source§

    fn default() -> Limits

    Returns the “default value” for a type. Read more

    Auto Trait Implementations§

    §

    impl Freeze for Limits

    §

    impl RefUnwindSafe for Limits

    §

    impl Send for Limits

    §

    impl Sync for Limits

    §

    impl Unpin for Limits

    §

    impl UnwindSafe for Limits

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/iroh_relay/server/struct.Metrics.html b/pr/3024/docs/iroh_relay/server/struct.Metrics.html index 01b046ebd2..cece1b9242 100644 --- a/pr/3024/docs/iroh_relay/server/struct.Metrics.html +++ b/pr/3024/docs/iroh_relay/server/struct.Metrics.html @@ -42,8 +42,8 @@

    §unique_client_keys: Counter

    Number of unique client keys per day

    §websocket_accepts: Counter

    Number of accepted websocket connections

    §derp_accepts: Counter

    Number of accepted ‘iroh derp http’ connection upgrades

    -

    Trait Implementations§

    source§

    impl Clone for Metrics

    source§

    fn clone(&self) -> Metrics

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for Metrics

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Default for Metrics

    source§

    fn default() -> Self

    Returns the “default value” for a type. Read more
    source§

    impl Iterable for Metrics

    source§

    fn iter<'a>(&'a self) -> IntoIter<(&'static str, &'a dyn Any)>

    Returns an iterator over the struct’s fields as tuples. Read more
    source§

    impl Metric for Metrics

    source§

    fn name() -> &'static str

    The name of this metric group.
    §

    fn new(registry: &mut Registry) -> Self

    Initializes this metric group.
    §

    fn with_metric<T, F>(f: F)
    where - F: FnOnce(&Self) -> T,

    Access to this metrics group to record a metric. +

    Trait Implementations§

    source§

    impl Clone for Metrics

    source§

    fn clone(&self) -> Metrics

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for Metrics

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Default for Metrics

    source§

    fn default() -> Self

    Returns the “default value” for a type. Read more
    source§

    impl Iterable for Metrics

    source§

    fn iter<'a>(&'a self) -> IntoIter<(&'static str, &'a dyn Any)>

    Returns an iterator over the struct’s fields as tuples. Read more
    source§

    impl Metric for Metrics

    source§

    fn name() -> &'static str

    The name of this metric group.
    §

    fn new(registry: &mut Registry) -> Self

    Available on crate feature metrics only.
    Initializes this metric group.
    §

    fn with_metric<T, F>(f: F)
    where + F: FnOnce(&Self) -> T,

    Available on crate feature metrics only.
    Access to this metrics group to record a metric. Only records if this metric is registered in the global registry.
    §

    fn try_get() -> Option<&'static Self>

    Attempts to get the current metric from the global registry.

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where diff --git a/pr/3024/docs/iroh_relay/server/struct.QuicConfig.html b/pr/3024/docs/iroh_relay/server/struct.QuicConfig.html index b0d61b5800..ab76b90638 100644 --- a/pr/3024/docs/iroh_relay/server/struct.QuicConfig.html +++ b/pr/3024/docs/iroh_relay/server/struct.QuicConfig.html @@ -1,4 +1,4 @@ -QuicConfig in iroh_relay::server - Rust

    Struct iroh_relay::server::QuicConfig

    source ·
    pub struct QuicConfig {
    +QuicConfig in iroh_relay::server - Rust

    Struct iroh_relay::server::QuicConfig

    source ·
    pub struct QuicConfig {
         pub bind_addr: SocketAddr,
         pub server_config: ServerConfig,
     }
    Available on crate feature server only.
    Expand description

    Configuration for the QUIC server.

    @@ -7,7 +7,7 @@
    §server_config: ServerConfig

    The TLS server configuration for the QUIC server.

    If this [rustls::ServerConfig] does not support TLS 1.3, the QUIC server will fail to spawn.

    -

    Trait Implementations§

    source§

    impl Debug for QuicConfig

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where +

    Trait Implementations§

    source§

    impl Debug for QuicConfig

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/iroh_relay/server/struct.RelayConfig.html b/pr/3024/docs/iroh_relay/server/struct.RelayConfig.html index 3bd9c4ef54..9bb9a959e3 100644 --- a/pr/3024/docs/iroh_relay/server/struct.RelayConfig.html +++ b/pr/3024/docs/iroh_relay/server/struct.RelayConfig.html @@ -1,4 +1,4 @@ -RelayConfig in iroh_relay::server - Rust

    Struct iroh_relay::server::RelayConfig

    source ·
    pub struct RelayConfig<EC: Debug, EA: Debug = EC> {
    +RelayConfig in iroh_relay::server - Rust

    Struct iroh_relay::server::RelayConfig

    source ·
    pub struct RelayConfig<EC: Debug, EA: Debug = EC> {
         pub http_bind_addr: SocketAddr,
         pub tls: Option<TlsConfig<EC, EA>>,
         pub limits: Limits,
    @@ -14,8 +14,8 @@ TLS.

    If None all the HTTP services that would be served here are served from RelayConfig::http_bind_addr.

    §limits: Limits

    Rate limits.

    -

    Trait Implementations§

    source§

    impl<EC: Debug, EA: Debug> Debug for RelayConfig<EC, EA>
    where - Option<TlsConfig<EC, EA>>: Debug,

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more

    Auto Trait Implementations§

    §

    impl<EC, EA> Freeze for RelayConfig<EC, EA>

    §

    impl<EC, EA = EC> !RefUnwindSafe for RelayConfig<EC, EA>

    §

    impl<EC, EA> Send for RelayConfig<EC, EA>

    §

    impl<EC, EA = EC> !Sync for RelayConfig<EC, EA>

    §

    impl<EC, EA> Unpin for RelayConfig<EC, EA>

    §

    impl<EC, EA = EC> !UnwindSafe for RelayConfig<EC, EA>

    Blanket Implementations§

    source§

    impl<T> Any for T
    where +

    Trait Implementations§

    source§

    impl<EC: Debug, EA: Debug> Debug for RelayConfig<EC, EA>
    where + Option<TlsConfig<EC, EA>>: Debug,

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more

    Auto Trait Implementations§

    §

    impl<EC, EA> Freeze for RelayConfig<EC, EA>

    §

    impl<EC, EA = EC> !RefUnwindSafe for RelayConfig<EC, EA>

    §

    impl<EC, EA> Send for RelayConfig<EC, EA>

    §

    impl<EC, EA = EC> !Sync for RelayConfig<EC, EA>

    §

    impl<EC, EA> Unpin for RelayConfig<EC, EA>

    §

    impl<EC, EA = EC> !UnwindSafe for RelayConfig<EC, EA>

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/iroh_relay/server/struct.Server.html b/pr/3024/docs/iroh_relay/server/struct.Server.html index d04361aebd..1511c1eccf 100644 --- a/pr/3024/docs/iroh_relay/server/struct.Server.html +++ b/pr/3024/docs/iroh_relay/server/struct.Server.html @@ -1,24 +1,24 @@ -Server in iroh_relay::server - Rust

    Struct iroh_relay::server::Server

    source ·
    pub struct Server { /* private fields */ }
    Available on crate feature server only.
    Expand description

    A running Relay + STUN server.

    +Server in iroh_relay::server - Rust

    Struct iroh_relay::server::Server

    source ·
    pub struct Server { /* private fields */ }
    Available on crate feature server only.
    Expand description

    A running Relay + STUN server.

    This is a full Relay server, including STUN, Relay and various associated HTTP services.

    Dropping this will stop the server.

    -

    Implementations§

    source§

    impl Server

    source

    pub async fn spawn<EC, EA>(config: ServerConfig<EC, EA>) -> Result<Self>
    where +

    Implementations§

    source§

    impl Server

    source

    pub async fn spawn<EC, EA>(config: ServerConfig<EC, EA>) -> Result<Self>
    where EC: Debug + 'static, EA: Debug + 'static,

    Starts the server.

    -
    source

    pub async fn shutdown(self) -> Result<()>

    Requests graceful shutdown.

    +
    source

    pub async fn shutdown(self) -> Result<()>

    Requests graceful shutdown.

    Returns once all server tasks have stopped.

    -
    source

    pub fn task_handle(&mut self) -> &mut AbortOnDropHandle<Result<()>>

    Returns the handle for the task.

    +
    source

    pub fn task_handle(&mut self) -> &mut AbortOnDropHandle<Result<()>>

    Returns the handle for the task.

    This allows waiting for the server’s supervisor task to finish. Can be useful in case there is an error in the server before it is shut down.

    -
    source

    pub fn https_addr(&self) -> Option<SocketAddr>

    The socket address the HTTPS server is listening on.

    -
    source

    pub fn http_addr(&self) -> Option<SocketAddr>

    The socket address the HTTP server is listening on.

    -
    source

    pub fn quic_addr(&self) -> Option<SocketAddr>

    The socket address the QUIC server is listening on.

    -
    source

    pub fn stun_addr(&self) -> Option<SocketAddr>

    The socket address the STUN server is listening on.

    -
    source

    pub fn certificates(&self) -> Option<Vec<CertificateDer<'static>>>

    The certificates chain if configured with manual TLS certificates.

    -
    source

    pub fn https_url(&self) -> Option<RelayUrl>

    Available on crate feature test-utils only.

    Get the server’s https RelayUrl.

    +
    source

    pub fn https_addr(&self) -> Option<SocketAddr>

    The socket address the HTTPS server is listening on.

    +
    source

    pub fn http_addr(&self) -> Option<SocketAddr>

    The socket address the HTTP server is listening on.

    +
    source

    pub fn quic_addr(&self) -> Option<SocketAddr>

    The socket address the QUIC server is listening on.

    +
    source

    pub fn stun_addr(&self) -> Option<SocketAddr>

    The socket address the STUN server is listening on.

    +
    source

    pub fn certificates(&self) -> Option<Vec<CertificateDer<'static>>>

    The certificates chain if configured with manual TLS certificates.

    +
    source

    pub fn https_url(&self) -> Option<RelayUrl>

    Available on crate feature test-utils only.

    Get the server’s https RelayUrl.

    This uses Self::https_addr so it’s mostly useful for local development.

    -
    source

    pub fn http_url(&self) -> Option<RelayUrl>

    Available on crate feature test-utils only.

    Get the server’s http RelayUrl.

    +
    source

    pub fn http_url(&self) -> Option<RelayUrl>

    Available on crate feature test-utils only.

    Get the server’s http RelayUrl.

    This uses Self::http_addr so it’s mostly useful for local development.

    -

    Trait Implementations§

    source§

    impl Debug for Server

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more

    Auto Trait Implementations§

    §

    impl Freeze for Server

    §

    impl RefUnwindSafe for Server

    §

    impl Send for Server

    §

    impl Sync for Server

    §

    impl Unpin for Server

    §

    impl UnwindSafe for Server

    Blanket Implementations§

    source§

    impl<T> Any for T
    where +

    Trait Implementations§

    source§

    impl Debug for Server

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more

    Auto Trait Implementations§

    §

    impl Freeze for Server

    §

    impl RefUnwindSafe for Server

    §

    impl Send for Server

    §

    impl Sync for Server

    §

    impl Unpin for Server

    §

    impl UnwindSafe for Server

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/iroh_relay/server/struct.ServerConfig.html b/pr/3024/docs/iroh_relay/server/struct.ServerConfig.html index 4b0ebf9b3c..81f7e32427 100644 --- a/pr/3024/docs/iroh_relay/server/struct.ServerConfig.html +++ b/pr/3024/docs/iroh_relay/server/struct.ServerConfig.html @@ -1,4 +1,4 @@ -ServerConfig in iroh_relay::server - Rust

    Struct iroh_relay::server::ServerConfig

    source ·
    pub struct ServerConfig<EC: Debug, EA: Debug = EC> {
    +ServerConfig in iroh_relay::server - Rust

    Struct iroh_relay::server::ServerConfig

    source ·
    pub struct ServerConfig<EC: Debug, EA: Debug = EC> {
         pub relay: Option<RelayConfig<EC, EA>>,
         pub stun: Option<StunConfig>,
         pub quic: Option<QuicConfig>,
    @@ -10,8 +10,8 @@ If not used dummy ones need to be provided, e.g. ServerConfig::<(), ()&
     
    §stun: Option<StunConfig>

    Configuration for the STUN server, disabled if None.

    §quic: Option<QuicConfig>

    Configuration for the QUIC server, disabled if None.

    §metrics_addr: Option<SocketAddr>
    Available on crate feature metrics only.

    Socket to serve metrics on.

    -

    Trait Implementations§

    source§

    impl<EC: Debug, EA: Debug> Debug for ServerConfig<EC, EA>
    where - Option<RelayConfig<EC, EA>>: Debug,

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl<EC: Default + Debug, EA: Default + Debug> Default for ServerConfig<EC, EA>

    source§

    fn default() -> ServerConfig<EC, EA>

    Returns the “default value” for a type. Read more

    Auto Trait Implementations§

    §

    impl<EC, EA> Freeze for ServerConfig<EC, EA>

    §

    impl<EC, EA = EC> !RefUnwindSafe for ServerConfig<EC, EA>

    §

    impl<EC, EA> Send for ServerConfig<EC, EA>

    §

    impl<EC, EA = EC> !Sync for ServerConfig<EC, EA>

    §

    impl<EC, EA> Unpin for ServerConfig<EC, EA>

    §

    impl<EC, EA = EC> !UnwindSafe for ServerConfig<EC, EA>

    Blanket Implementations§

    source§

    impl<T> Any for T
    where +

    Trait Implementations§

    source§

    impl<EC: Debug, EA: Debug> Debug for ServerConfig<EC, EA>
    where + Option<RelayConfig<EC, EA>>: Debug,

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl<EC: Default + Debug, EA: Default + Debug> Default for ServerConfig<EC, EA>

    source§

    fn default() -> ServerConfig<EC, EA>

    Returns the “default value” for a type. Read more

    Auto Trait Implementations§

    §

    impl<EC, EA> Freeze for ServerConfig<EC, EA>

    §

    impl<EC, EA = EC> !RefUnwindSafe for ServerConfig<EC, EA>

    §

    impl<EC, EA> Send for ServerConfig<EC, EA>

    §

    impl<EC, EA = EC> !Sync for ServerConfig<EC, EA>

    §

    impl<EC, EA> Unpin for ServerConfig<EC, EA>

    §

    impl<EC, EA = EC> !UnwindSafe for ServerConfig<EC, EA>

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/iroh_relay/server/struct.StunConfig.html b/pr/3024/docs/iroh_relay/server/struct.StunConfig.html index 09539c3acb..27a80871fd 100644 --- a/pr/3024/docs/iroh_relay/server/struct.StunConfig.html +++ b/pr/3024/docs/iroh_relay/server/struct.StunConfig.html @@ -1,9 +1,9 @@ -StunConfig in iroh_relay::server - Rust

    Struct iroh_relay::server::StunConfig

    source ·
    pub struct StunConfig {
    +StunConfig in iroh_relay::server - Rust

    Struct iroh_relay::server::StunConfig

    source ·
    pub struct StunConfig {
         pub bind_addr: SocketAddr,
     }
    Available on crate feature server only.
    Expand description

    Configuration for the STUN server.

    Fields§

    §bind_addr: SocketAddr

    The socket address on which the STUN server should bind.

    Normally you’d chose port 3478, see crate::defaults::DEFAULT_STUN_PORT.

    -

    Trait Implementations§

    source§

    impl Debug for StunConfig

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where +

    Trait Implementations§

    source§

    impl Debug for StunConfig

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/iroh_relay/server/struct.StunMetrics.html b/pr/3024/docs/iroh_relay/server/struct.StunMetrics.html index 8332d77aa1..65df705739 100644 --- a/pr/3024/docs/iroh_relay/server/struct.StunMetrics.html +++ b/pr/3024/docs/iroh_relay/server/struct.StunMetrics.html @@ -10,8 +10,8 @@

    §ipv6_success: Counter

    Number of successful requests over ipv6

    §bad_requests: Counter

    Number of bad requests, either non-stun packets or incorrect binding request

    §failures: Counter

    Number of failures

    -

    Trait Implementations§

    source§

    impl Clone for StunMetrics

    source§

    fn clone(&self) -> StunMetrics

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for StunMetrics

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Default for StunMetrics

    source§

    fn default() -> Self

    Returns the “default value” for a type. Read more
    source§

    impl Iterable for StunMetrics

    source§

    fn iter<'a>(&'a self) -> IntoIter<(&'static str, &'a dyn Any)>

    Returns an iterator over the struct’s fields as tuples. Read more
    source§

    impl Metric for StunMetrics

    source§

    fn name() -> &'static str

    The name of this metric group.
    §

    fn new(registry: &mut Registry) -> Self

    Initializes this metric group.
    §

    fn with_metric<T, F>(f: F)
    where - F: FnOnce(&Self) -> T,

    Access to this metrics group to record a metric. +

    Trait Implementations§

    source§

    impl Clone for StunMetrics

    source§

    fn clone(&self) -> StunMetrics

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for StunMetrics

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more
    source§

    impl Default for StunMetrics

    source§

    fn default() -> Self

    Returns the “default value” for a type. Read more
    source§

    impl Iterable for StunMetrics

    source§

    fn iter<'a>(&'a self) -> IntoIter<(&'static str, &'a dyn Any)>

    Returns an iterator over the struct’s fields as tuples. Read more
    source§

    impl Metric for StunMetrics

    source§

    fn name() -> &'static str

    The name of this metric group.
    §

    fn new(registry: &mut Registry) -> Self

    Available on crate feature metrics only.
    Initializes this metric group.
    §

    fn with_metric<T, F>(f: F)
    where + F: FnOnce(&Self) -> T,

    Available on crate feature metrics only.
    Access to this metrics group to record a metric. Only records if this metric is registered in the global registry.
    §

    fn try_get() -> Option<&'static Self>

    Attempts to get the current metric from the global registry.

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where diff --git a/pr/3024/docs/iroh_relay/server/struct.TlsConfig.html b/pr/3024/docs/iroh_relay/server/struct.TlsConfig.html index f35be39850..51c902b21b 100644 --- a/pr/3024/docs/iroh_relay/server/struct.TlsConfig.html +++ b/pr/3024/docs/iroh_relay/server/struct.TlsConfig.html @@ -1,4 +1,4 @@ -TlsConfig in iroh_relay::server - Rust

    Struct iroh_relay::server::TlsConfig

    source ·
    pub struct TlsConfig<EC: Debug, EA: Debug = EC> {
    +TlsConfig in iroh_relay::server - Rust

    Struct iroh_relay::server::TlsConfig

    source ·
    pub struct TlsConfig<EC: Debug, EA: Debug = EC> {
         pub https_bind_addr: SocketAddr,
         pub quic_bind_addr: SocketAddr,
         pub cert: CertConfig<EC, EA>,
    @@ -13,8 +13,8 @@ this is served on the §quic_bind_addr: SocketAddr

    The socket address on which to server the QUIC server is QUIC is enabled.

    §cert: CertConfig<EC, EA>

    Mode for getting a cert.

    §server_config: ServerConfig

    The server configuration.

    -

    Trait Implementations§

    source§

    impl<EC: Debug, EA: Debug> Debug for TlsConfig<EC, EA>
    where - CertConfig<EC, EA>: Debug,

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more

    Auto Trait Implementations§

    §

    impl<EC, EA> Freeze for TlsConfig<EC, EA>

    §

    impl<EC, EA = EC> !RefUnwindSafe for TlsConfig<EC, EA>

    §

    impl<EC, EA> Send for TlsConfig<EC, EA>

    §

    impl<EC, EA = EC> !Sync for TlsConfig<EC, EA>

    §

    impl<EC, EA> Unpin for TlsConfig<EC, EA>

    §

    impl<EC, EA = EC> !UnwindSafe for TlsConfig<EC, EA>

    Blanket Implementations§

    source§

    impl<T> Any for T
    where +

    Trait Implementations§

    source§

    impl<EC: Debug, EA: Debug> Debug for TlsConfig<EC, EA>
    where + CertConfig<EC, EA>: Debug,

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result

    Formats the value using the given formatter. Read more

    Auto Trait Implementations§

    §

    impl<EC, EA> Freeze for TlsConfig<EC, EA>

    §

    impl<EC, EA = EC> !RefUnwindSafe for TlsConfig<EC, EA>

    §

    impl<EC, EA> Send for TlsConfig<EC, EA>

    §

    impl<EC, EA = EC> !Sync for TlsConfig<EC, EA>

    §

    impl<EC, EA> Unpin for TlsConfig<EC, EA>

    §

    impl<EC, EA = EC> !UnwindSafe for TlsConfig<EC, EA>

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/iroh_relay/struct.RelayConn.html b/pr/3024/docs/iroh_relay/struct.RelayConn.html index 815bdca24c..1981646da6 100644 --- a/pr/3024/docs/iroh_relay/struct.RelayConn.html +++ b/pr/3024/docs/iroh_relay/struct.RelayConn.html @@ -1,7 +1,7 @@ RelayConn in iroh_relay - Rust

    Struct iroh_relay::RelayConn

    source ·
    pub struct RelayConn { /* private fields */ }
    Expand description

    A connection to a relay server.

    Cheaply clonable. Call close to shut down the write loop and read functionality.

    -

    Implementations§

    source§

    impl Conn

    source

    pub async fn send(&self, dst: NodeId, packet: Bytes) -> Result<()>

    Sends a packet to the node identified by dstkey

    +

    Implementations§

    source§

    impl Conn

    source

    pub async fn send(&self, dst: NodeId, packet: Bytes) -> Result<()>

    Sends a packet to the node identified by dstkey

    Errors if the packet is larger than MAX_PACKET_SIZE

    source

    pub async fn send_ping(&self, data: [u8; 8]) -> Result<()>

    Send a ping with 8 bytes of random data.

    source

    pub async fn send_pong(&self, data: [u8; 8]) -> Result<()>

    Respond to a ping request. The data field should be filled diff --git a/pr/3024/docs/iroh_relay/struct.RelayUrl.html b/pr/3024/docs/iroh_relay/struct.RelayUrl.html index 2ee0728f8e..91f699c05c 100644 --- a/pr/3024/docs/iroh_relay/struct.RelayUrl.html +++ b/pr/3024/docs/iroh_relay/struct.RelayUrl.html @@ -1,4 +1,4 @@ -RelayUrl in iroh_relay - Rust

    Struct iroh_relay::RelayUrl

    pub struct RelayUrl(/* private fields */);
    Expand description

    A URL identifying a relay server.

    +RelayUrl in iroh_relay - Rust

    Struct iroh_relay::RelayUrl

    source ·
    pub struct RelayUrl(/* private fields */);
    Expand description

    A URL identifying a relay server.

    This is but a wrapper around Url, with a few custom tweaks:

    • @@ -311,7 +311,7 @@ For other schemes, it is the same as Url::port().

    source

    pub fn socket_addrs( &self, default_port_number: impl Fn() -> Option<u16> -) -> Result<Vec<SocketAddr>, Error>

    Resolve a URL’s host and port number to SocketAddr.

    +) -> Result<Vec<SocketAddr>, Error>

    Available on crate feature std and (Unix or Windows or Redox or WASI or HermitCore) only.

    Resolve a URL’s host and port number to SocketAddr.

    If the URL has the default port number of a scheme that is unknown to this library, default_port_number provides an opportunity to provide the actual port number. In non-example code this should be implemented either simply as || None, @@ -426,11 +426,11 @@ but the input may have been percent-encoded already.

    &self, serializer: S ) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>
    where - S: Serializer,

    Serialize with Serde using the internal representation of the Url struct.

    + S: Serializer,

    Available on crate feature serde only.

    Serialize with Serde using the internal representation of the Url struct.

    The corresponding deserialize_internal method sacrifices some invariant-checking for speed, compared to the Deserialize trait impl.

    This method is only available if the serde Cargo feature is enabled.

    -
    source

    pub fn to_file_path(&self) -> Result<PathBuf, ()>

    Assuming the URL is in the file scheme or similar, +

    source

    pub fn to_file_path(&self) -> Result<PathBuf, ()>

    Available on crate feature std and (Unix or Windows or Redox or WASI or HermitCore) only.

    Assuming the URL is in the file scheme or similar, convert its path to an absolute std::path::Path.

    Note: This does not actually check the URL’s scheme, and may give nonsensical results for other schemes. @@ -443,30 +443,30 @@ or if Path::new_opt() returns None. (That is, if the percent-decoded path contains a NUL byte or, for a Windows path, is not UTF-8.)

    This method is only available if the std Cargo feature is enabled.

    -

    Trait Implementations§

    §

    impl Clone for RelayUrl

    §

    fn clone(&self) -> RelayUrl

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    §

    impl Debug for RelayUrl

    §

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    §

    impl Deref for RelayUrl

    Dereferences to the wrapped Url.

    +

    Trait Implementations§

    source§

    impl Clone for RelayUrl

    source§

    fn clone(&self) -> RelayUrl

    Returns a copy of the value. Read more
    1.0.0 · source§

    fn clone_from(&mut self, source: &Self)

    Performs copy-assignment from source. Read more
    source§

    impl Debug for RelayUrl

    source§

    fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    source§

    impl Deref for RelayUrl

    Dereferences to the wrapped Url.

    Note that DerefMut is not implemented on purpose, so this type has more flexibility to change the inner later.

    -
    §

    type Target = Url

    The resulting type after dereferencing.
    §

    fn deref(&self) -> &<RelayUrl as Deref>::Target

    Dereferences the value.
    §

    impl<'de> Deserialize<'de> for RelayUrl

    §

    fn deserialize<__D>( +

    §

    type Target = Url

    The resulting type after dereferencing.
    source§

    fn deref(&self) -> &<RelayUrl as Deref>::Target

    Dereferences the value.
    source§

    impl<'de> Deserialize<'de> for RelayUrl

    source§

    fn deserialize<__D>( __deserializer: __D ) -> Result<RelayUrl, <__D as Deserializer<'de>>::Error>
    where - __D: Deserializer<'de>,

    Deserialize this value from the given Serde deserializer. Read more
    §

    impl Display for RelayUrl

    §

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    §

    impl From<RelayUrl> for Url

    §

    fn from(value: RelayUrl) -> Url

    Converts to this type from the input type.
    §

    impl From<Url> for RelayUrl

    §

    fn from(url: Url) -> RelayUrl

    Converts to this type from the input type.
    §

    impl FromStr for RelayUrl

    Support for parsing strings directly.

    + __D: Deserializer<'de>,

    Deserialize this value from the given Serde deserializer. Read more

    source§

    impl Display for RelayUrl

    source§

    fn fmt(&self, __derive_more_f: &mut Formatter<'_>) -> Result<(), Error>

    Formats the value using the given formatter. Read more
    source§

    impl From<RelayUrl> for Url

    source§

    fn from(value: RelayUrl) -> Url

    Converts to this type from the input type.
    source§

    impl From<Url> for RelayUrl

    source§

    fn from(url: Url) -> RelayUrl

    Converts to this type from the input type.
    source§

    impl FromStr for RelayUrl

    Support for parsing strings directly.

    If you need more control over the error first create a Url and use RelayUrl::from instead.

    -
    §

    type Err = Error

    The associated error which can be returned from parsing.
    §

    fn from_str(s: &str) -> Result<RelayUrl, <RelayUrl as FromStr>::Err>

    Parses a string s to return a value of this type. Read more
    §

    impl Hash for RelayUrl

    §

    fn hash<__H>(&self, state: &mut __H)
    where +
    §

    type Err = Error

    The associated error which can be returned from parsing.
    source§

    fn from_str(s: &str) -> Result<RelayUrl, <RelayUrl as FromStr>::Err>

    Parses a string s to return a value of this type. Read more

    source§

    impl Hash for RelayUrl

    source§

    fn hash<__H>(&self, state: &mut __H)
    where __H: Hasher,

    Feeds this value into the given Hasher. Read more
    1.3.0 · source§

    fn hash_slice<H>(data: &[Self], state: &mut H)
    where H: Hasher, - Self: Sized,

    Feeds a slice of this type into the given Hasher. Read more
    §

    impl Ord for RelayUrl

    §

    fn cmp(&self, other: &RelayUrl) -> Ordering

    This method returns an Ordering between self and other. Read more
    1.21.0 · source§

    fn max(self, other: Self) -> Self
    where + Self: Sized,

    Feeds a slice of this type into the given Hasher. Read more
    source§

    impl Ord for RelayUrl

    source§

    fn cmp(&self, other: &RelayUrl) -> Ordering

    This method returns an Ordering between self and other. Read more
    1.21.0 · source§

    fn max(self, other: Self) -> Self
    where Self: Sized,

    Compares and returns the maximum of two values. Read more
    1.21.0 · source§

    fn min(self, other: Self) -> Self
    where Self: Sized,

    Compares and returns the minimum of two values. Read more
    1.50.0 · source§

    fn clamp(self, min: Self, max: Self) -> Self
    where - Self: Sized + PartialOrd,

    Restrict a value to a certain interval. Read more
    §

    impl PartialEq for RelayUrl

    §

    fn eq(&self, other: &RelayUrl) -> bool

    This method tests for self and other values to be equal, and is used + Self: Sized + PartialOrd,

    Restrict a value to a certain interval. Read more
    source§

    impl PartialEq for RelayUrl

    source§

    fn eq(&self, other: &RelayUrl) -> bool

    This method tests for self and other values to be equal, and is used by ==.
    1.0.0 · source§

    fn ne(&self, other: &Rhs) -> bool

    This method tests for !=. The default implementation is almost always -sufficient, and should not be overridden without very good reason.
    §

    impl PartialOrd for RelayUrl

    §

    fn partial_cmp(&self, other: &RelayUrl) -> Option<Ordering>

    This method returns an ordering between self and other values if one exists. Read more
    1.0.0 · source§

    fn lt(&self, other: &Rhs) -> bool

    This method tests less than (for self and other) and is used by the < operator. Read more
    1.0.0 · source§

    fn le(&self, other: &Rhs) -> bool

    This method tests less than or equal to (for self and other) and is used by the <= +sufficient, and should not be overridden without very good reason.
    source§

    impl PartialOrd for RelayUrl

    source§

    fn partial_cmp(&self, other: &RelayUrl) -> Option<Ordering>

    This method returns an ordering between self and other values if one exists. Read more
    1.0.0 · source§

    fn lt(&self, other: &Rhs) -> bool

    This method tests less than (for self and other) and is used by the < operator. Read more
    1.0.0 · source§

    fn le(&self, other: &Rhs) -> bool

    This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
    1.0.0 · source§

    fn gt(&self, other: &Rhs) -> bool

    This method tests greater than (for self and other) and is used by the > operator. Read more
    1.0.0 · source§

    fn ge(&self, other: &Rhs) -> bool

    This method tests greater than or equal to (for self and other) and is used by the >= -operator. Read more
    §

    impl Serialize for RelayUrl

    §

    fn serialize<__S>( +operator. Read more

    source§

    impl Serialize for RelayUrl

    source§

    fn serialize<__S>( &self, __serializer: __S ) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>
    where - __S: Serializer,

    Serialize this value into the given Serde serializer. Read more
    §

    impl Eq for RelayUrl

    §

    impl StructuralPartialEq for RelayUrl

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where + __S: Serializer,

    Serialize this value into the given Serde serializer. Read more
    source§

    impl Eq for RelayUrl

    source§

    impl StructuralPartialEq for RelayUrl

    Auto Trait Implementations§

    Blanket Implementations§

    source§

    impl<T> Any for T
    where T: 'static + ?Sized,

    source§

    fn type_id(&self) -> TypeId

    Gets the TypeId of self. Read more
    §

    impl<'a, T, E> AsTaggedExplicit<'a, E> for T
    where T: 'a,

    §

    fn explicit(self, class: Class, tag: u32) -> TaggedParser<'a, Explicit, Self, E>

    §

    impl<'a, T, E> AsTaggedImplicit<'a, E> for T
    where T: 'a,

    §

    fn implicit( diff --git a/pr/3024/docs/src/iroh/discovery.rs.html b/pr/3024/docs/src/iroh/discovery.rs.html index 9f6cf4dad8..d5c9c4fe4c 100644 --- a/pr/3024/docs/src/iroh/discovery.rs.html +++ b/pr/3024/docs/src/iroh/discovery.rs.html @@ -885,7 +885,6 @@ 885 886 887 -888

    //! Node address discovery.
     //!
     //! To connect to an iroh node a [`NodeAddr`] is needed, which may contain a
    @@ -1014,7 +1013,6 @@
     pub mod dns;
     
     #[cfg(feature = "discovery-local-network")]
    -#[cfg_attr(iroh_docsrs, doc(cfg(feature = "discovery-local-network")))]
     pub mod local_swarm_discovery;
     pub mod pkarr;
     pub mod static_provider;
    diff --git a/pr/3024/docs/src/iroh/discovery/pkarr.rs.html b/pr/3024/docs/src/iroh/discovery/pkarr.rs.html
    index 75fde8585e..0630b3c586 100644
    --- a/pr/3024/docs/src/iroh/discovery/pkarr.rs.html
    +++ b/pr/3024/docs/src/iroh/discovery/pkarr.rs.html
    @@ -411,7 +411,6 @@
     411
     412
     413
    -414
     
    //! A discovery service which publishes and resolves node information using a [pkarr] relay.
     //!
     //! Public-Key Addressable Resource Records, [pkarr], is a system which allows publishing
    @@ -481,7 +480,6 @@
     };
     
     #[cfg(feature = "discovery-pkarr-dht")]
    -#[cfg_attr(iroh_docsrs, doc(cfg(feature = "discovery-pkarr-dht")))]
     pub mod dht;
     
     /// The production pkarr relay run by [number 0].
    diff --git a/pr/3024/docs/src/iroh/endpoint.rs.html b/pr/3024/docs/src/iroh/endpoint.rs.html
    index 917054b45f..8ae8aea01b 100644
    --- a/pr/3024/docs/src/iroh/endpoint.rs.html
    +++ b/pr/3024/docs/src/iroh/endpoint.rs.html
    @@ -1886,11 +1886,6 @@
     1886
     1887
     1888
    -1889
    -1890
    -1891
    -1892
    -1893
     
    //! The [`Endpoint`] allows establishing connections to other iroh nodes.
     //!
     //! The [`Endpoint`] is the main API interface to manage a local iroh node.  It allows
    @@ -1989,7 +1984,6 @@
         node_map: Option<Vec<NodeAddr>>,
         dns_resolver: Option<DnsResolver>,
         #[cfg(any(test, feature = "test-utils"))]
    -    #[cfg_attr(iroh_docsrs, doc(cfg(any(test, feature = "test-utils"))))]
         insecure_skip_relay_cert_verify: bool,
         addr_v4: Option<SocketAddrV4>,
         addr_v6: Option<SocketAddrV6>,
    @@ -2200,7 +2194,6 @@
         }
     
         #[cfg(feature = "discovery-pkarr-dht")]
    -    #[cfg_attr(iroh_docsrs, doc(cfg(feature = "discovery-pkarr-dht")))]
         /// Configures the endpoint to also use the mainline DHT with default settings.
         ///
         /// This is equivalent to adding a [`crate::discovery::pkarr::dht::DhtDiscovery`]
    @@ -2221,7 +2214,6 @@
         }
     
         #[cfg(feature = "discovery-local-network")]
    -    #[cfg_attr(iroh_docsrs, doc(cfg(feature = "discovery-local-network")))]
         /// Configures the endpoint to also use local network discovery.
         ///
         /// This is equivalent to adding a [`crate::discovery::local_swarm_discovery::LocalSwarmDiscovery`]
    @@ -2305,7 +2297,6 @@
         ///
         /// May only be used in tests.
         #[cfg(any(test, feature = "test-utils"))]
    -    #[cfg_attr(iroh_docsrs, doc(cfg(any(test, feature = "test-utils"))))]
         pub fn insecure_skip_relay_cert_verify(mut self, skip_verify: bool) -> Self {
             self.insecure_skip_relay_cert_verify = skip_verify;
             self
    @@ -3272,7 +3263,6 @@
     }
     
     /// Environment variable to force the use of staging relays.
    -#[cfg_attr(iroh_docsrs, doc(cfg(not(test))))]
     pub const ENV_FORCE_STAGING_RELAYS: &str = "IROH_FORCE_STAGING_RELAYS";
     
     /// Returns `true` if the use of staging relays is forced.
    diff --git a/pr/3024/docs/src/iroh/lib.rs.html b/pr/3024/docs/src/iroh/lib.rs.html
    index d2d32639c9..7e43db69ac 100644
    --- a/pr/3024/docs/src/iroh/lib.rs.html
    +++ b/pr/3024/docs/src/iroh/lib.rs.html
    @@ -256,7 +256,6 @@
     256
     257
     258
    -259
     
    //! Peer-to-peer QUIC connections.
     //!
     //! iroh is a library to establish direct connectivity between peers.  It exposes an
    @@ -490,7 +489,7 @@
     
     #![recursion_limit = "256"]
     #![deny(missing_docs, rustdoc::broken_intra_doc_links)]
    -#![cfg_attr(iroh_docsrs, feature(doc_cfg))]
    +#![cfg_attr(iroh_docsrs, feature(doc_auto_cfg))]
     
     pub mod defaults;
     mod disco;
    @@ -514,6 +513,5 @@
     pub use iroh_relay as relay;
     
     #[cfg(any(test, feature = "test-utils"))]
    -#[cfg_attr(iroh_docsrs, doc(cfg(any(test, feature = "test-utils"))))]
     pub mod test_utils;
     

    \ No newline at end of file diff --git a/pr/3024/docs/src/iroh/magicsock.rs.html b/pr/3024/docs/src/iroh/magicsock.rs.html index d599ac859d..64493bae43 100644 --- a/pr/3024/docs/src/iroh/magicsock.rs.html +++ b/pr/3024/docs/src/iroh/magicsock.rs.html @@ -4085,6 +4085,20 @@ 4085 4086 4087 +4088 +4089 +4090 +4091 +4092 +4093 +4094 +4095 +4096 +4097 +4098 +4099 +4100 +4101
    //! Implements a socket that can change its communication path while in use, actively searching for the best way to communicate.
     //!
     //! Based on tailscale/wgengine/magicsock
    @@ -4214,7 +4228,6 @@
         ///
         /// May only be used in tests.
         #[cfg(any(test, feature = "test-utils"))]
    -    #[cfg_attr(iroh_docsrs, doc(cfg(any(test, feature = "test-utils"))))]
         pub(crate) insecure_skip_relay_cert_verify: bool,
     }
     
    @@ -4336,7 +4349,6 @@
         ///
         /// May only be used in tests.
         #[cfg(any(test, feature = "test-utils"))]
    -    #[cfg_attr(iroh_docsrs, doc(cfg(any(test, feature = "test-utils"))))]
         insecure_skip_relay_cert_verify: bool,
     }
     
    @@ -4605,8 +4617,14 @@
                                 udp_sent = true;
                             }
                             Err(err) => {
    -                            error!(node = %node_id.fmt_short(), dst = %addr,
    -                                   "failed to send udp: {err:#}");
    +                            // No need to print "WouldBlock" errors to the console
    +                            if err.kind() != io::ErrorKind::WouldBlock {
    +                                warn!(
    +                                    node = %node_id.fmt_short(),
    +                                    dst = %addr,
    +                                    "failed to send udp: {err:#}"
    +                                );
    +                            }
                                 udp_error = Some(err);
                             }
                         }
    @@ -4650,16 +4668,26 @@
                             // at any time so these errors should be treated as transient and
                             // are just timeouts.  Hence we opt for returning Ok.  See
                             // test_try_send_no_udp_addr_or_relay_url to explore this further.
    -                        error!(
    +                        debug!(
                                 node = %node_id.fmt_short(),
    -                            "no UDP or relay paths available for node",
    +                            "no UDP or relay paths available for node, voiding transmit",
                             );
    -                    }
    +                        // We log this as debug instead of error, because this is a
    +                        // situation that comes up under normal operation. If this were an
    +                        // error log, it would unnecessarily pollute logs.
    +                        // This situation happens essentially when `pings_sent` is false,
    +                        // `relay_url` is `None`, so `relay_sent` is false, and the UDP
    +                        // path is blocking, so `udp_sent` is false and `udp_pending` is
    +                        // true.
    +                        // Alternatively returning a WouldBlock error here would
    +                        // potentially needlessly block sending on the relay path for the
    +                        // next datagram.
    +                    }
                         Ok(())
                     }
                 }
                 None => {
    -                error!(%dest, "no NodeState for mapped address");
    +                error!(%dest, "no NodeState for mapped address, voiding transmit");
                     // Returning Ok here means we let QUIC timeout.  Returning WouldBlock
                     // triggers a hot loop.  Returning an error would immediately fail a
                     // connection.  The philosophy of quinn-udp is that a UDP connection could
    diff --git a/pr/3024/docs/src/iroh/metrics.rs.html b/pr/3024/docs/src/iroh/metrics.rs.html
    index 5aea102825..d7babdd694 100644
    --- a/pr/3024/docs/src/iroh/metrics.rs.html
    +++ b/pr/3024/docs/src/iroh/metrics.rs.html
    @@ -5,10 +5,8 @@
     5
     6
     7
    -8
     
    //! Co-locating all of the iroh metrics structs
     #[cfg(feature = "test-utils")]
    -#[cfg_attr(iroh_docsrs, doc(cfg(feature = "test-utils")))]
     pub use iroh_relay::server::Metrics as RelayMetrics;
     pub use net_report::Metrics as NetReportMetrics;
     pub use portmapper::Metrics as PortmapMetrics;
    diff --git a/pr/3024/docs/src/iroh_base/hash.rs.html b/pr/3024/docs/src/iroh_base/hash.rs.html
    index 030114e323..5da2391290 100644
    --- a/pr/3024/docs/src/iroh_base/hash.rs.html
    +++ b/pr/3024/docs/src/iroh_base/hash.rs.html
    @@ -563,7 +563,6 @@
     563
     564
     565
    -566
     
    //! The blake3 hash used in Iroh.
     
     use std::{borrow::Borrow, fmt, str::FromStr};
    @@ -796,7 +795,6 @@
     }
     
     #[cfg(feature = "redb")]
    -#[cfg_attr(iroh_docsrs, cfg(feature = "redb"))]
     mod redb_support {
         use postcard::experimental::max_size::MaxSize;
         use redb::{Key as RedbKey, Value as RedbValue};
    diff --git a/pr/3024/docs/src/iroh_base/lib.rs.html b/pr/3024/docs/src/iroh_base/lib.rs.html
    index 81c222edfc..85906d782e 100644
    --- a/pr/3024/docs/src/iroh_base/lib.rs.html
    +++ b/pr/3024/docs/src/iroh_base/lib.rs.html
    @@ -15,33 +15,21 @@
     15
     16
     17
    -18
    -19
    -20
    -21
    -22
    -23
     
    //! Base types and utilities for Iroh
    -#![cfg_attr(iroh_docsrs, feature(doc_cfg))]
    +#![cfg_attr(iroh_docsrs, feature(doc_auto_cfg))]
     
     #[cfg(feature = "base32")]
    -#[cfg_attr(iroh_docsrs, doc(cfg(feature = "base32")))]
     pub mod base32;
     #[cfg(feature = "hash")]
    -#[cfg_attr(iroh_docsrs, doc(cfg(feature = "hash")))]
     pub mod hash;
     #[cfg(feature = "key")]
    -#[cfg_attr(iroh_docsrs, doc(cfg(feature = "key")))]
     pub mod key;
     #[cfg(feature = "key")]
    -#[cfg_attr(iroh_docsrs, doc(cfg(feature = "key")))]
     pub mod node_addr;
     #[cfg(feature = "relay")]
    -#[cfg_attr(iroh_docsrs, doc(cfg(feature = "relay")))]
     pub mod relay_map;
     #[cfg(any(feature = "relay", feature = "key"))]
     mod relay_url;
     #[cfg(feature = "base32")]
    -#[cfg_attr(iroh_docsrs, doc(cfg(feature = "base32")))]
     pub mod ticket;
     

    \ No newline at end of file diff --git a/pr/3024/docs/src/iroh_base/ticket.rs.html b/pr/3024/docs/src/iroh_base/ticket.rs.html index 0104920677..a7795baa42 100644 --- a/pr/3024/docs/src/iroh_base/ticket.rs.html +++ b/pr/3024/docs/src/iroh_base/ticket.rs.html @@ -86,9 +86,6 @@ 86 87 88 -89 -90 -91
    use std::{collections::BTreeSet, net::SocketAddr};
     
     use serde::{Deserialize, Serialize};
    @@ -96,13 +93,10 @@
     use crate::{base32, key::NodeId, node_addr::RelayUrl};
     
     #[cfg(feature = "key")]
    -#[cfg_attr(iroh_docsrs, doc(cfg(feature = "key")))]
     mod blob;
     #[cfg(feature = "key")]
    -#[cfg_attr(iroh_docsrs, doc(cfg(feature = "key")))]
     mod node;
     #[cfg(feature = "key")]
    -#[cfg_attr(iroh_docsrs, doc(cfg(feature = "key")))]
     pub use self::{blob::BlobTicket, node::NodeTicket};
     
     /// A ticket is a serializable object combining information required for an operation.
    diff --git a/pr/3024/docs/src/iroh_relay/client.rs.html b/pr/3024/docs/src/iroh_relay/client.rs.html
    index 8356790247..388e808529 100644
    --- a/pr/3024/docs/src/iroh_relay/client.rs.html
    +++ b/pr/3024/docs/src/iroh_relay/client.rs.html
    @@ -1192,9 +1192,6 @@
     1192
     1193
     1194
    -1195
    -1196
    -1197
     
    //! Exposes [`Client`], which allows to establish connections to a relay server.
     //!
     //! Based on tailscale/derp/derphttp/derphttp_client.go
    @@ -1400,7 +1397,6 @@
         protocol: Protocol,
         /// Allow self-signed certificates from relay servers
         #[cfg(any(test, feature = "test-utils"))]
    -    #[cfg_attr(iroh_docsrs, doc(cfg(any(test, feature = "test-utils"))))]
         insecure_skip_cert_verify: bool,
         /// HTTP Proxy
         proxy_url: Option<Url>,
    @@ -1466,7 +1462,6 @@
         ///
         /// May only be used in tests.
         #[cfg(any(test, feature = "test-utils"))]
    -    #[cfg_attr(iroh_docsrs, doc(cfg(any(test, feature = "test-utils"))))]
         pub fn insecure_skip_cert_verify(mut self, skip: bool) -> Self {
             self.insecure_skip_cert_verify = skip;
             self
    @@ -2290,7 +2285,6 @@
     
     /// Used to allow self signed certificates in tests
     #[cfg(any(test, feature = "test-utils"))]
    -#[cfg_attr(iroh_docsrs, doc(cfg(any(test, feature = "test-utils"))))]
     #[derive(Debug)]
     struct NoCertVerifier;
     
    diff --git a/pr/3024/docs/src/iroh_relay/defaults.rs.html b/pr/3024/docs/src/iroh_relay/defaults.rs.html
    index ea4b15377c..beed7c43cd 100644
    --- a/pr/3024/docs/src/iroh_relay/defaults.rs.html
    +++ b/pr/3024/docs/src/iroh_relay/defaults.rs.html
    @@ -35,7 +35,6 @@
     35
     36
     37
    -38
     
    //! Default values used in the relay.
     
     pub use iroh_base::relay_map::{DEFAULT_RELAY_QUIC_PORT, DEFAULT_STUN_PORT};
    @@ -71,7 +70,6 @@
     
         /// Maximum time the server will attempt to get a successful write to the connection.
         #[cfg(feature = "server")]
    -    #[cfg_attr(iroh_docsrs, doc(cfg(feature = "server")))]
         pub(crate) const SERVER_WRITE_TIMEOUT: Duration = Duration::from_secs(2);
     }
     
    \ No newline at end of file diff --git a/pr/3024/docs/src/iroh_relay/http.rs.html b/pr/3024/docs/src/iroh_relay/http.rs.html index dfe08658a6..1142d11400 100644 --- a/pr/3024/docs/src/iroh_relay/http.rs.html +++ b/pr/3024/docs/src/iroh_relay/http.rs.html @@ -47,14 +47,11 @@ 47 48 49 -50 -51
    //! HTTP-specific constants for the relay server and client.
     
     pub(crate) const HTTP_UPGRADE_PROTOCOL: &str = "iroh derp http";
     pub(crate) const WEBSOCKET_UPGRADE_PROTOCOL: &str = "websocket";
     #[cfg(feature = "server")] // only used in the server for now
    -#[cfg_attr(iroh_docsrs, doc(cfg(feature = "server")))]
     pub(crate) const SUPPORTED_WEBSOCKET_VERSION: &str = "13";
     
     /// The HTTP path under which the relay accepts relaying connections
    @@ -65,7 +62,6 @@
     /// The legacy HTTP path under which the relay used to accept relaying connections.
     /// We keep this for backwards compatibility.
     #[cfg(feature = "server")] // legacy paths only used on server-side for backwards compat
    -#[cfg_attr(iroh_docsrs, doc(cfg(feature = "server")))]
     pub(crate) const LEGACY_RELAY_PATH: &str = "/derp";
     
     /// The HTTP upgrade protocol used for relaying.
    diff --git a/pr/3024/docs/src/iroh_relay/lib.rs.html b/pr/3024/docs/src/iroh_relay/lib.rs.html
    index e236d4c00a..8d191e15e5 100644
    --- a/pr/3024/docs/src/iroh_relay/lib.rs.html
    +++ b/pr/3024/docs/src/iroh_relay/lib.rs.html
    @@ -48,7 +48,6 @@
     48
     49
     50
    -51
     
    //! Iroh's relay is a feature within [iroh](https://github.com/n0-computer/iroh), a peer-to-peer
     //! networking system designed to facilitate direct, encrypted connections between devices. Iroh
     //! aims to simplify decentralized communication by automatically handling connections through
    @@ -77,7 +76,7 @@
     //!   STUN support and expose metrics.
     // Based on tailscale/derp/derp.go
     
    -#![cfg_attr(iroh_docsrs, feature(doc_cfg))]
    +#![cfg_attr(iroh_docsrs, feature(doc_auto_cfg))]
     #![deny(missing_docs, rustdoc::broken_intra_doc_links)]
     
     pub mod client;
    @@ -86,7 +85,6 @@
     pub mod protos;
     pub mod quic;
     #[cfg(feature = "server")]
    -#[cfg_attr(iroh_docsrs, doc(cfg(feature = "server")))]
     pub mod server;
     
     #[cfg(test)]
    diff --git a/pr/3024/docs/src/iroh_relay/protos/relay.rs.html b/pr/3024/docs/src/iroh_relay/protos/relay.rs.html
    index a6e0f7ea75..1638b57694 100644
    --- a/pr/3024/docs/src/iroh_relay/protos/relay.rs.html
    +++ b/pr/3024/docs/src/iroh_relay/protos/relay.rs.html
    @@ -821,11 +821,6 @@
     821
     822
     823
    -824
    -825
    -826
    -827
    -828
     
    //! This module implements the relaying protocol used by the `server` and `client`.
     //!
     //! Protocol flow:
    @@ -867,11 +862,9 @@
     const MAGIC: &str = "RELAY🔑";
     
     #[cfg(feature = "server")]
    -#[cfg_attr(iroh_docsrs, doc(cfg(feature = "server")))]
     pub(crate) const KEEP_ALIVE: Duration = Duration::from_secs(60);
     // TODO: what should this be?
     #[cfg(feature = "server")]
    -#[cfg_attr(iroh_docsrs, doc(cfg(feature = "server")))]
     pub(crate) const SERVER_CHANNEL_SIZE: usize = 1024 * 100;
     /// The number of packets buffered for sending per client
     pub(crate) const PER_CLIENT_SEND_QUEUE_DEPTH: usize = 512; //32;
    @@ -998,7 +991,6 @@
     /// Reads the `FrameType::ClientInfo` frame from the client (its proof of identity)
     /// upon it's initial connection.
     #[cfg(any(test, feature = "server"))]
    -#[cfg_attr(iroh_docsrs, doc(cfg(feature = "server")))]
     pub(crate) async fn recv_client_key<S: Stream<Item = anyhow::Result<Frame>> + Unpin>(
         stream: S,
     ) -> anyhow::Result<(PublicKey, ClientInfo)> {
    @@ -1117,7 +1109,6 @@
     
         /// Serialized length with frame header.
         #[cfg(feature = "server")]
    -    #[cfg_attr(iroh_docsrs, doc(cfg(feature = "server")))]
         pub(crate) fn len_with_header(&self) -> usize {
             self.len() + HEADER_LEN
         }
    @@ -1381,7 +1372,6 @@
     /// Receives the next frame and matches the frame type. If the correct type is found returns the content,
     /// otherwise an error.
     #[cfg(any(test, feature = "server"))]
    -#[cfg_attr(iroh_docsrs, doc(cfg(feature = "server")))]
     pub(crate) async fn recv_frame<S: Stream<Item = anyhow::Result<Frame>> + Unpin>(
         frame_type: FrameType,
         mut stream: S,
    diff --git a/pr/3024/docs/src/iroh_relay/quic.rs.html b/pr/3024/docs/src/iroh_relay/quic.rs.html
    index 02df9dbd43..3737d2ac2a 100644
    --- a/pr/3024/docs/src/iroh_relay/quic.rs.html
    +++ b/pr/3024/docs/src/iroh_relay/quic.rs.html
    @@ -314,7 +314,6 @@
     314
     315
     316
    -317
     
    //! Create a QUIC server that accepts connections
     //! for QUIC address discovery.
     use std::{net::SocketAddr, sync::Arc};
    @@ -330,7 +329,6 @@
     pub const QUIC_ADDR_DISC_CLOSE_REASON: &[u8] = b"finished";
     
     #[cfg(feature = "server")]
    -#[cfg_attr(iroh_docsrs, doc(cfg(feature = "server")))]
     pub(crate) mod server {
         use quinn::{crypto::rustls::QuicServerConfig, ApplicationClose};
         use tokio::task::JoinSet;
    diff --git a/pr/3024/docs/src/iroh_relay/server.rs.html b/pr/3024/docs/src/iroh_relay/server.rs.html
    index 4382b5b8ac..1a3a045f97 100644
    --- a/pr/3024/docs/src/iroh_relay/server.rs.html
    +++ b/pr/3024/docs/src/iroh_relay/server.rs.html
    @@ -1124,10 +1124,6 @@
     1124
     1125
     1126
    -1127
    -1128
    -1129
    -1130
     
    //! A fully-fledged iroh-relay server over HTTP or HTTPS.
     //!
     //! This module provides an API to run a full fledged iroh-relay server.  It is primarily
    @@ -1178,7 +1174,6 @@
     mod metrics;
     pub(crate) mod streams;
     #[cfg(feature = "test-utils")]
    -#[cfg_attr(iroh_docsrs, doc(cfg(feature = "test-utils")))]
     pub mod testing;
     
     pub use self::{
    @@ -1224,7 +1219,6 @@
         pub quic: Option<QuicConfig>,
         /// Socket to serve metrics on.
         #[cfg(feature = "metrics")]
    -    #[cfg_attr(iroh_docsrs, doc(cfg(feature = "metrics")))]
         pub metrics_addr: Option<SocketAddr>,
     }
     
    @@ -1578,7 +1572,6 @@
         ///
         /// This uses [`Self::https_addr`] so it's mostly useful for local development.
         #[cfg(feature = "test-utils")]
    -    #[cfg_attr(iroh_docsrs, doc(cfg(feature = "test-utils")))]
         pub fn https_url(&self) -> Option<RelayUrl> {
             self.https_addr.map(|addr| {
                 url::Url::parse(&format!("https://{addr}"))
    @@ -1591,7 +1584,6 @@
         ///
         /// This uses [`Self::http_addr`] so it's mostly useful for local development.
         #[cfg(feature = "test-utils")]
    -    #[cfg_attr(iroh_docsrs, doc(cfg(feature = "test-utils")))]
         pub fn http_url(&self) -> Option<RelayUrl> {
             self.http_addr.map(|addr| {
                 url::Url::parse(&format!("http://{addr}"))