Expand description
Node address discovery.
+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 @@
-
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.
+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 @@
-
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.
+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.
+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 @@ -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.
+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.
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§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
A discovery service which publishes and resolves node information using a pkarr relay.
+iroh::discovery::pkarr - Rust 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
sourcepub fn new(secret_key: SecretKey, pkarr_relay: Url) -> Self
Creates a new publisher for the SecretKey.
+Implementations§
source§impl PkarrPublisher
sourcepub 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.
-sourcepub fn with_options(
+
sourcepub 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.
-sourcepub fn n0_dns(secret_key: SecretKey) -> Self
Creates a pkarr publisher which uses the number 0 pkarr relay server.
+sourcepub 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.
-sourcepub fn update_addr_info(
+
sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for PkarrPublisher
Trait Implementations§
source§impl Clone for PkarrPublisher
source§fn clone(&self) -> PkarrPublisher
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for PkarrPublisher
Auto Trait Implementations§
§impl Freeze for PkarrPublisher
§impl !RefUnwindSafe for PkarrPublisher
§impl Send for PkarrPublisher
§impl Sync for PkarrPublisher
§impl Unpin for PkarrPublisher
§impl !UnwindSafe for PkarrPublisher
Blanket Implementations§
Auto Trait Implementations§
§impl Freeze for PkarrPublisher
§impl !RefUnwindSafe for PkarrPublisher
§impl Send for PkarrPublisher
§impl Sync for PkarrPublisher
§impl Unpin for PkarrPublisher
§impl !UnwindSafe for PkarrPublisher
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§
Trait Implementations§
source§impl Clone for PkarrRelayClient
source§fn clone(&self) -> PkarrRelayClient
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for PkarrRelayClient
§impl !RefUnwindSafe for PkarrRelayClient
§impl Send for PkarrRelayClient
§impl Sync for PkarrRelayClient
§impl Unpin for PkarrRelayClient
§impl !UnwindSafe for PkarrRelayClient
Blanket Implementations§
source§impl<T> Any for Twhere
+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§
Trait Implementations§
source§impl Clone for PkarrRelayClient
source§fn clone(&self) -> PkarrRelayClient
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for PkarrRelayClient
§impl !RefUnwindSafe for PkarrRelayClient
§impl Send for PkarrRelayClient
§impl Sync for PkarrRelayClient
§impl Unpin for PkarrRelayClient
§impl !UnwindSafe for PkarrRelayClient
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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
sourcepub fn new(pkarr_relay: Url) -> Self
Creates a new publisher using the pkarr relay server at the URL.
-Implementations§
source§impl PkarrResolver
sourcepub fn new(pkarr_relay: Url) -> Self
Creates a new publisher using the pkarr relay server at the URL.
+sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for PkarrResolver
Trait Implementations§
source§impl Clone for PkarrResolver
source§fn clone(&self) -> PkarrResolver
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for PkarrResolver
Auto Trait Implementations§
§impl Freeze for PkarrResolver
§impl !RefUnwindSafe for PkarrResolver
§impl Send for PkarrResolver
§impl Sync for PkarrResolver
§impl Unpin for PkarrResolver
§impl !UnwindSafe for PkarrResolver
Blanket Implementations§
Auto Trait Implementations§
§impl Freeze for PkarrResolver
§impl !RefUnwindSafe for PkarrResolver
§impl Send for PkarrResolver
§impl Sync for PkarrResolver
§impl Unpin for PkarrResolver
§impl !UnwindSafe for PkarrResolver
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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>>>
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§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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
sourcepub fn empty() -> Self
Creates an empty ConcurrentDiscovery.
-sourcepub fn from_services(services: Vec<Box<dyn Discovery>>) -> Self
Creates a new ConcurrentDiscovery.
-Trait Implementations§
source§impl Debug for ConcurrentDiscovery
source§impl Default for ConcurrentDiscovery
source§fn default() -> ConcurrentDiscovery
Returns the “default value” for a type. Read moresource§impl Discovery for ConcurrentDiscovery
Implementations§
source§impl ConcurrentDiscovery
sourcepub fn empty() -> Self
Creates an empty ConcurrentDiscovery.
+sourcepub fn from_services(services: Vec<Box<dyn Discovery>>) -> Self
Creates a new ConcurrentDiscovery.
+Trait Implementations§
source§impl Debug for ConcurrentDiscovery
source§impl Default for ConcurrentDiscovery
source§fn default() -> ConcurrentDiscovery
Returns the “default value” for a type. Read moresource§impl Discovery for ConcurrentDiscovery
source§impl<T> From<T> for ConcurrentDiscovery
Auto Trait Implementations§
§impl Freeze for ConcurrentDiscovery
§impl !RefUnwindSafe for ConcurrentDiscovery
§impl Send for ConcurrentDiscovery
§impl Sync for ConcurrentDiscovery
§impl Unpin for ConcurrentDiscovery
§impl !UnwindSafe for ConcurrentDiscovery
Blanket Implementations§
source§impl<T> From<T> for ConcurrentDiscovery
Auto Trait Implementations§
§impl Freeze for ConcurrentDiscovery
§impl !RefUnwindSafe for ConcurrentDiscovery
§impl Send for ConcurrentDiscovery
§impl Sync for ConcurrentDiscovery
§impl Unpin for ConcurrentDiscovery
§impl !UnwindSafe for ConcurrentDiscovery
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for DiscoveryItem
§impl RefUnwindSafe for DiscoveryItem
§impl Send for DiscoveryItem
§impl Sync for DiscoveryItem
§impl Unpin for DiscoveryItem
§impl UnwindSafe for DiscoveryItem
Blanket Implementations§
source§impl<T> Any for Twhere
+Trait Implementations§
source§impl Clone for DiscoveryItem
source§fn clone(&self) -> DiscoveryItem
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for DiscoveryItem
§impl RefUnwindSafe for DiscoveryItem
§impl Send for DiscoveryItem
§impl Sync for DiscoveryItem
§impl Unpin for DiscoveryItem
§impl UnwindSafe for DiscoveryItem
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 pub trait Discovery: Debug + Send + Sync {
+Discovery in iroh::discovery - Rust 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§
sourcefn publish(&self, _url: Option<&RelayUrl>, _addrs: &BTreeSet<SocketAddr>)
Publishes the given RelayUrl and direct addreesses to the discovery mechanism.
+Provided Methods§
sourcefn 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.
-sourcefn 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.
-sourcefn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>
Subscribe to all addresses that get passively discovered.
+sourcefn 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddrType
source§impl Display for DirectAddrType
source§impl Hash for DirectAddrType
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddrType
source§impl Display for DirectAddrType
source§impl Hash for DirectAddrType
source§impl Ord for DirectAddrType
source§impl Ord for DirectAddrType
source§fn cmp(&self, other: &DirectAddrType) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read moresource§impl PartialEq for DirectAddrType
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 ==.source§impl PartialOrd for DirectAddrType
source§impl PartialOrd for DirectAddrType
source§fn partial_cmp(&self, other: &DirectAddrType) -> Option<Ordering>
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 moresource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 pub enum RelayMode {
+RelayMode in iroh::endpoint - Rust 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§
Trait Implementations§
source§impl PartialEq for RelayMode
Implementations§
Trait Implementations§
source§impl PartialEq for RelayMode
source§impl Eq for RelayMode
source§impl StructuralPartialEq for RelayMode
Auto Trait Implementations§
§impl Freeze for RelayMode
§impl RefUnwindSafe for RelayMode
§impl Send for RelayMode
§impl Sync for RelayMode
§impl Unpin for RelayMode
§impl UnwindSafe for RelayMode
Blanket Implementations§
source§impl Eq for RelayMode
source§impl StructuralPartialEq for RelayMode
Auto Trait Implementations§
§impl Freeze for RelayMode
§impl RefUnwindSafe for RelayMode
§impl Send for RelayMode
§impl Sync for RelayMode
§impl Unpin for RelayMode
§impl UnwindSafe for RelayMode
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
The Endpoint allows establishing connections to other iroh nodes.
+iroh::endpoint - Rust 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§
- Future produced by
Endpoint::accept. - Future produced by
Connection::accept_bi - Future produced by
Connection::accept_uni - Parameters for controlling the peer’s acknowledgement frequency
- Reason given by an application for closing the connection
- Builder for
Endpoint. - A cheaply cloneable and sliceable chunk of contiguous memory.
- A chunk of data from the receive stream
- Error indicating that a stream has not been opened or has already been finished or reset
- In-progress connection attempt future
- A QUIC connection.
- Reason given by the transport for closing the connection
- Connection statistics
- Stream returning
ConnectionTypes - Generic crypto errors
- A direct address on which an iroh-node might be contactable.
- Information about a direct address.
- Stream returning local endpoints as they change.
- Controls an iroh node, establishing connections with other nodes.
- Error returned by [Session::export_keying_material].
- Number of frames transmitted of each frame type
- An incoming connection for which the server has not yet begun its parts of the
handshake.
- Parameters governing MTU discovery.
- Network-level addressing information for an iroh node.
- Future produced by
Connection::open_bi - Future produced by
Connection::open_uni - Statistics related to a transmission path
- Future produced by
Connection::read_datagram - A stream that can only be used to receive data
- Details about a remote iroh node which is known to this node.
- Error for attempting to retry an [
Incoming] which already bears an address
validation token from a previous retry - A stream that can only be used to send data
- Parameters governing incoming connections
- Identifier for a stream within a particular connection
- Parameters governing the core QUIC state machine
- Transport-level errors occur when a peer violates the protocol specification
- Transport-level error code
- Statistics about UDP datagrams transmitted or received on a connection
- Error indicating that the specified QUIC version is not supported
- An integer less than 2^62
- A handle to some connection internals, use with care.
- Indicates how many bytes and chunks had been transferred in a write operation
- Future that completes when a connection is fully established
Enums§
- Options to configure what is included in a
NodeAddr. - Reasons why a connection might be lost
- The type of connection we have to the endpoint.
- The type of control message we have received.
- The type of direct address.
- Errors that arise from reading from a stream.
- Errors that arise from reading from a stream.
- Errors from
RecvStream::read_to_end - Configuration of the relay servers for an
Endpoint. - Errors that arise while waiting for a stream to be reset
- Errors that can arise when sending a datagram
- The origin or source through which an address associated with a remote node
-was discovered.
- Errors that arise while monitoring for a send stream stop from the peer
- Errors that arise from writing to a stream
Constants§
- ENV_FORCE_STAGING_RELAYSNon-
testEnvironment variable to force the use of staging relays.
Traits§
- A key for sealing data with AEAD-based algorithms
- Common interface for different congestion controllers
- Constructs controllers on demand
- Server-side configuration for the crypto protocol
- A pseudo random key for HKDF
Functions§
- Returns the default relay mode.
- Returns
true if the use of staging relays is forced. - Extract the
PublicKey from the peer’s TLS certificate. - Creates a
ServerConfig with the given secret key and limits.
\ 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§
- Environment variable to force the use of staging relays.
Traits§
- A key for sealing data with AEAD-based algorithms
- Common interface for different congestion controllers
- Constructs controllers on demand
- Server-side configuration for the crypto protocol
- A pseudo random key for HKDF
Functions§
- Returns the default relay mode.
- Returns
true if the use of staging relays is forced. - Extract the
PublicKey from the peer’s TLS certificate. - Creates a
ServerConfig with the given secret key and limits.
\ 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 pub struct Accept<'a> { /* private fields */ }
Expand description
Future produced by Endpoint::accept.
-Trait Implementations§
source§impl<'pin, 'a> Unpin for Accept<'a>where
+Accept in iroh::endpoint - Rust pub struct Accept<'a> { /* private fields */ }
Expand description
Future produced by Endpoint::accept.
+Trait Implementations§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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>,§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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 pub struct Builder { /* private fields */ }
Expand description
Builder for Endpoint.
+Builder in iroh::endpoint - Rust 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
sourcepub fn bind_addr_v4(self, addr: SocketAddrV4) -> Self
Sets the IPv4 bind address.
+Implementations§
source§impl Builder
sourcepub 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.
-sourcepub fn bind_addr_v6(self, addr: SocketAddrV6) -> Self
Sets the IPv6 bind address.
+sourcepub 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.
-sourcepub fn secret_key(self, secret_key: SecretKey) -> Self
Sets a secret key to authenticate with other peers.
+sourcepub fn secret_key(self, secret_key: SecretKey) -> Self
sourcepub fn alpns(self, alpn_protocols: Vec<Vec<u8>>) -> Self
Sets the ALPN protocols that this endpoint will accept on incoming connections.
+sourcepub fn relay_mode(self, relay_mode: RelayMode) -> Self
Sets the relay servers to assist in establishing connectivity.
+sourcepub 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.
-sourcepub fn clear_discovery(self) -> Self
Removes all discovery services from the builder.
-sourcepub fn discovery(self, discovery: Box<dyn Discovery>) -> Self
Optionally sets a discovery mechanism for this endpoint.
+sourcepub fn clear_discovery(self) -> Self
Removes all discovery services from the builder.
+sourcepub 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.
-sourcepub fn add_discovery<F, D>(self, discovery: F) -> Selfwhere
+
sourcepub fn add_discovery<F, D>(self, discovery: F) -> Self
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.
-sourcepub fn discovery_n0(self) -> Self
Configures the endpoint to use the default n0 DNS discovery service.
+sourcepub 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.
-sourcepub 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.
+sourcepub 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.
-sourcepub fn discovery_local_network(self) -> Self
Available on crate feature discovery-local-network only.
Configures the endpoint to also use local network discovery.
+sourcepub 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.
-sourcepub fn known_nodes(self, nodes: Vec<NodeAddr>) -> Self
Optionally set a list of known nodes.
-sourcepub fn transport_config(self, transport_config: TransportConfig) -> Self
Sets a custom quinn::TransportConfig for this endpoint.
+sourcepub fn known_nodes(self, nodes: Vec<NodeAddr>) -> Self
Optionally set a list of known nodes.
+sourcepub 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.
-sourcepub fn dns_resolver(self, dns_resolver: DnsResolver) -> Self
Optionally sets a custom DNS resolver to use for this endpoint.
+sourcepub 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.
-sourcepub fn proxy_url(self, url: Url) -> Self
Sets an explicit proxy url to proxy all HTTP(S) traffic through.
-sourcepub fn proxy_from_env(self) -> Self
Sets the proxy url from the environment, in this order:
+sourcepub fn proxy_url(self, url: Url) -> Self
Sets an explicit proxy url to proxy all HTTP(S) traffic through.
+sourcepub fn proxy_from_env(self) -> Self
Sets the proxy url from the environment, in this order:
HTTP_PROXY
http_proxy
HTTPS_PROXY
https_proxy
-sourcepub fn keylog(self, keylog: bool) -> Self
Enables saving the TLS pre-master key for connections.
+sourcepub 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.
-sourcepub 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
+sourcepub 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§
Auto Trait Implementations§
§impl !Freeze for Builder
§impl !RefUnwindSafe for Builder
§impl Send for Builder
§impl Sync for Builder
§impl Unpin for Builder
§impl !UnwindSafe for Builder
Blanket Implementations§
Trait Implementations§
Auto Trait Implementations§
§impl !Freeze for Builder
§impl !RefUnwindSafe for Builder
§impl Send for Builder
§impl Sync for Builder
§impl Unpin for Builder
§impl !UnwindSafe for Builder
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§
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 · sourcepub fn to_ascii_uppercase(&self) -> Vec<u8> ⓘ
Returns a vector containing a copy of this slice where each byte
+
1.23.0 · sourcepub 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 · sourcepub fn to_ascii_lowercase(&self) -> Vec<u8> ⓘ
Returns a vector containing a copy of this slice where each byte
+
1.23.0 · sourcepub 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 · sourcepub 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.
sourcepub fn to_vec_in<A>(&self, alloc: A) -> Vec<T, A>
🔬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 · sourcepub 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.§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 copy_to_bytes(&mut self, len: usize) -> Bytes
§fn chunks_vectored<'a>(&'a self, dst: &mut [IoSlice<'a>]) -> usize
§fn chunks_vectored<'a>(&'a self, dst: &mut [IoSlice<'a>]) -> usize
Available on crate feature std only.§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])
§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 moreSized,§impl FromIterator<u8> for Bytes
§impl FromIterator<u8> for Bytes
§impl<S> FromRequest<S> for Bytes
§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 Hwhere
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>
§fn in_current_span(self) -> Instrumented<Self>
source§impl<T, U> Into<U> for Twhere
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
sourcepub fn into_0rtt(self) -> Result<(Connection, ZeroRttAccepted), Self>
Convert into a 0-RTT or 0.5-RTT connection at the cost of weakened security.
-sourcepub async fn handshake_data(&mut self) -> Result<Box<dyn Any>, ConnectionError>
Parameters negotiated during the handshake
-sourcepub fn local_ip(&self) -> Option<IpAddr>
The local IP address which was used when the peer established the connection.
-sourcepub fn remote_address(&self) -> SocketAddr
The peer’s UDP address.
-Trait Implementations§
source§impl Debug for Connecting
source§impl Future for Connecting
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for Connectingwhere
+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
sourcepub fn into_0rtt(self) -> Result<(Connection, ZeroRttAccepted), Self>
Convert into a 0-RTT or 0.5-RTT connection at the cost of weakened security.
+sourcepub async fn handshake_data(&mut self) -> Result<Box<dyn Any>, ConnectionError>
Parameters negotiated during the handshake
+sourcepub fn local_ip(&self) -> Option<IpAddr>
The local IP address which was used when the peer established the connection.
+sourcepub fn remote_address(&self) -> SocketAddr
The peer’s UDP address.
+Trait Implementations§
source§impl Debug for Connecting
source§impl Future for Connecting
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for Connectingwhere
PinnedFieldsOf<__Connecting<'pin>>: Unpin,
Auto Trait Implementations§
§impl Freeze for Connecting
§impl !RefUnwindSafe for Connecting
§impl Send for Connecting
§impl Sync for Connecting
§impl !UnwindSafe for Connecting
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§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§impl<S> StreamExt for Swhere
+ 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§impl<S> StreamExt for Swhere
S: Stream + ?Sized,
Sized,
S: Stream<Item = Self::Item>,
§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§impl<S1> StreamExt for S1where
+ 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 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 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 moreRead 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§impl<T> StreamExt for Twhere
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, ()>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>
) -> FlatMapUnordered<Self, U, F>
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 moreRuns 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 moreSized,
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 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>>
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>>
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>
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>
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>,
Available on crate features sink and alloc only.§fn inspect<F>(self, f: F) -> Inspect<Self, F>
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: SocketAddrThe address.
§typ: DirectAddrTypeThe origin of this direct address.
-Trait Implementations§
source§impl Clone for DirectAddr
source§fn clone(&self) -> DirectAddr
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddr
source§impl Hash for DirectAddr
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddr
source§impl Hash for DirectAddr
source§impl Ord for DirectAddr
source§impl Ord for DirectAddr
source§fn cmp(&self, other: &DirectAddr) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read moresource§impl PartialEq for DirectAddr
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 ==.source§impl PartialOrd for DirectAddr
source§impl PartialOrd for DirectAddr
source§fn partial_cmp(&self, other: &DirectAddr) -> Option<Ordering>
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 moresource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§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§impl Stream for DirectAddrsStream
Sized,
S: Stream<Item = Self::Item>,§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
§impl<S> StreamExt for Swhere
+ 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§impl<S> StreamExt for Swhere
S: Stream + ?Sized,
Sized,
S: Stream<Item = Self::Item>,§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§impl<S1> StreamExt for S1where
+ 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 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 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 moreRead 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
§impl<T> StreamExt for Twhere
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, ()>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>
) -> FlatMapUnordered<Self, U, F>
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 moreRuns 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 moreSized,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 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>>
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>>
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>
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>
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>,
Available on crate features sink and alloc only.§fn inspect<F>(self, f: F) -> Inspect<Self, F>
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 pub struct Endpoint { /* private fields */ }
Expand description
Controls an iroh node, establishing connections with other nodes.
+Endpoint in iroh::endpoint - Rust 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
sourcepub fn builder() -> Builder
Returns the builder for an Endpoint, with a production configuration.
-sourcepub fn set_alpns(&self, alpns: Vec<Vec<u8>>) -> Result<()>
Sets the list of accepted ALPN protocols.
+Implementations§
source§impl Endpoint
sourcepub fn builder() -> Builder
Returns the builder for an Endpoint, with a production configuration.
+sourcepub 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.
-
sourcepub 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.
-sourcepub fn add_node_addr(&self, node_addr: NodeAddr) -> Result<()>
Informs this Endpoint about addresses of the iroh node.
+sourcepub 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.
-sourcepub fn add_node_addr_with_source(
+
sourcepub fn secret_key(&self) -> &SecretKey
Returns the secret_key of this endpoint.
-sourcepub fn secret_key(&self) -> &SecretKey
Returns the secret_key of this endpoint.
+sourcepub 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.
-sourcepub async fn node_addr(&self) -> Result<NodeAddr>
Returns the current NodeAddr for this endpoint.
+sourcepub 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.
-sourcepub fn home_relay(&self) -> Option<RelayUrl>
Returns the RelayUrl of the Relay server used as home relay.
+sourcepub 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.
-sourcepub fn watch_home_relay(&self) -> impl Stream<Item = RelayUrl>
Watches for changes to the home relay.
+sourcepub 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.
-sourcepub fn direct_addresses(&self) -> DirectAddrsStream
Returns the direct addresses of this Endpoint.
+sourcepub 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;
-sourcepub fn bound_sockets(&self) -> (SocketAddr, Option<SocketAddr>)
Returns the local socket addresses on which the underlying sockets are bound.
+sourcepub 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.
-sourcepub fn remote_info(&self, node_id: NodeId) -> Option<RemoteInfo>
Returns information about the remote node identified by a NodeId.
+sourcepub 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.
-sourcepub fn remote_info_iter(&self) -> impl Iterator<Item = RemoteInfo>
Returns information about all the remote nodes this Endpoint knows about.
+sourcepub 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.
-sourcepub fn conn_type_stream(&self, node_id: NodeId) -> Result<ConnectionTypeStream>
Returns a stream that reports connection type changes for the remote node.
+sourcepub 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.
-sourcepub fn dns_resolver(&self) -> &DnsResolver
Returns the DNS resolver used in this Endpoint.
+sourcepub fn dns_resolver(&self) -> &DnsResolver
Returns the DNS resolver used in this Endpoint.
See Builder::discovery.
-sourcepub fn discovery(&self) -> Option<&dyn Discovery>
Returns the discovery mechanism, if configured.
+sourcepub fn discovery(&self) -> Option<&dyn Discovery>
Returns the discovery mechanism, if configured.
-sourcepub async fn network_change(&self)
Notifies the system of potential network changes.
+sourcepub 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.
-sourcepub 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.
-Trait Implementations§
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§
Trait Implementations§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 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 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
sourcepub fn accept(self) -> Result<Connecting, ConnectionError>
Attempts to accept this incoming connection (an error may still occur).
+Implementations§
source§impl Incoming
sourcepub 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.
-sourcepub fn accept_with(
+
sourcepub fn accept_with(
self,
server_config: Arc<ServerConfig>
) -> Result<Connecting, ConnectionError>
Accepts this incoming connection using a custom configuration.
See accept() for more details.
-sourcepub fn retry(self) -> Result<(), RetryError>
Responds with a retry packet.
+sourcepub 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.
-sourcepub fn ignore(self)
Ignores this incoming connection attempt, not sending any packet in response.
-sourcepub fn local_ip(&self) -> Option<IpAddr>
Returns the local IP address which was used when the peer established the
+
sourcepub fn ignore(self)
Ignores this incoming connection attempt, not sending any packet in response.
+sourcepub fn local_ip(&self) -> Option<IpAddr>
Returns the local IP address which was used when the peer established the
connection.
-sourcepub fn remote_address(&self) -> SocketAddr
Returns the peer’s UDP address.
-sourcepub fn remote_address_validated(&self) -> bool
Whether the socket address that is initiating this connection has been validated.
+sourcepub fn remote_address(&self) -> SocketAddr
Returns the peer’s UDP address.
+sourcepub 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 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 moreAuto Trait Implementations§
§impl !Freeze for Incoming
§impl !RefUnwindSafe for Incoming
§impl Send for Incoming
§impl Sync for Incoming
§impl Unpin for Incoming
§impl !UnwindSafe for Incoming
Blanket Implementations§
Trait Implementations§
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 moreAuto Trait Implementations§
§impl !Freeze for Incoming
§impl !RefUnwindSafe for Incoming
§impl Send for Incoming
§impl Sync for Incoming
§impl Unpin for Incoming
§impl !UnwindSafe for Incoming
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§impl Future for IncomingFuture
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for IncomingFuturewhere
+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§impl Future for IncomingFuture
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for IncomingFuturewhere
PinnedFieldsOf<__IncomingFuture<'pin>>: Unpin,
Auto Trait Implementations§
§impl !Freeze for IncomingFuture
§impl !RefUnwindSafe for IncomingFuture
§impl Send for IncomingFuture
§impl Sync for IncomingFuture
§impl !UnwindSafe for IncomingFuture
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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
§fn poll_write(
+
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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 Expand description
The blake3 hash used in Iroh.
+iroh::hash - Rust
\ 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 moresource§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
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more1.21.0 · source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more1.50.0 · source§fn clamp(self, min: Self, max: Self) -> Selfwhere
@@ -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 widthsource§fn from_bytes<'a>(data: &'a [u8]) -> <Hash as Value>::SelfType<'a>where
+ S: Serializer,
Serialize this value into the given Serde serializer. Read moresource§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 widthsource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: HashThe hash
§format: BlobFormatThe format
-Implementations§
source§impl HashAndFormat
sourcepub fn new(hash: Hash, format: BlobFormat) -> HashAndFormat
Create a new hash and format pair.
-sourcepub fn raw(hash: Hash) -> HashAndFormat
Create a new hash and format pair, using the default (raw) format.
-sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for HashAndFormat
source§impl<'de> Deserialize<'de> for HashAndFormat
source§fn deserialize<D>(
+
Implementations§
source§impl HashAndFormat
sourcepub fn new(hash: Hash, format: BlobFormat) -> HashAndFormat
Create a new hash and format pair.
+sourcepub fn raw(hash: Hash) -> HashAndFormat
Create a new hash and format pair, using the default (raw) format.
+sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for HashAndFormat
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 moresource§impl Display for HashAndFormat
source§impl FromStr for HashAndFormat
source§impl Hash for HashAndFormat
source§impl Display for HashAndFormat
source§impl FromStr for HashAndFormat
source§impl Hash for HashAndFormat
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.source§impl PartialOrd for HashAndFormat
source§fn partial_cmp(&self, other: &HashAndFormat) -> Option<Ordering>
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 moresource§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 moresource§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 widthsource§fn from_bytes<'a>(data: &'a [u8]) -> <HashAndFormat as Value>::SelfType<'a>where
+ S: Serializer,
Serialize this value into the given Serde serializer. Read moresource§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 widthsource§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 typesource§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§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
Peer-to-peer QUIC connections.
+iroh - Rust 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§
pub use endpoint::Endpoint;pub use endpoint::RelayMode;pub use iroh_relay as relay;
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_utils
test or test-utilsInternal 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§
- Options to configure what is included in a
NodeAddr.
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-utilsInternal 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§
- Options to configure what is included in a
NodeAddr.
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 Expand description
Cryptographic key handling for iroh.
+iroh::key - Rust
\ 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.
Trait Implementations§
§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 Copy for Signature
§impl Eq for Signature
§impl StructuralPartialEq for Signature
Auto Trait Implementations§
§impl Freeze for Signature
§impl RefUnwindSafe for Signature
§impl Send for Signature
§impl Sync for Signature
§impl Unpin for Signature
§impl UnwindSafe for Signature
Blanket Implementations§
source§impl<T> Any for Twhere
+ S: Serializer,
Serialize this value into the given Serde serializer. Read more§impl SignatureEncoding for Signature
§impl Copy for Signature
§impl Eq for Signature
§impl StructuralPartialEq for Signature
Auto Trait Implementations§
§impl Freeze for Signature
§impl RefUnwindSafe for Signature
§impl Send for Signature
§impl Sync for Signature
§impl Unpin for Signature
§impl UnwindSafe for Signature
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
Co-locating all of the iroh metrics structs
+iroh::metrics - Rust Expand description
Co-locating all of the iroh metrics structs
Structs§
- Enum of metrics for the module
- Enum of metrics for the module
- Enum of metrics for the module
- RelayMetrics
test-utilsMetrics tracked for the relay server
\ 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: CounterNumber of nodes we have managed to contact directly.
§connection_handshake_success: CounterNumber of connections with a successful handshake.
§connection_became_direct: CounterNumber of connections with a successful handshake that became direct.
-Trait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
Access to this metrics group to record a metric.
+Trait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterTrait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
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: CounterTrait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterTrait Implementations§
§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
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: CounterTrait Implementations§
§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterNumber of unique client keys per day
§websocket_accepts: CounterNumber of accepted websocket connections
§derp_accepts: CounterNumber of accepted ‘iroh derp http’ connection upgrades
-Trait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
Access to this metrics group to record a metric.
+Trait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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().
sourcepub 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.
-sourcepub fn to_file_path(&self) -> Result<PathBuf, ()>
Assuming the URL is in the file scheme or similar,
+
sourcepub 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.
\ 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.
\ 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§
- A drop guard to clean up test infrastructure.
- Handle and drop guard for test DNS and Pkarr servers.
Functions§
- Create a DNS resolver with a single nameserver.
- Runs a relay server with STUN and QUIC enabled suitable for tests.
- Runs a relay server.
- Runs a relay server with STUN enabled suitable for tests.
\ 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§
Auto Trait Implementations§
§impl Freeze for CleanupDropGuard
§impl !RefUnwindSafe for CleanupDropGuard
§impl Send for CleanupDropGuard
§impl Sync for CleanupDropGuard
§impl Unpin for CleanupDropGuard
§impl !UnwindSafe for CleanupDropGuard
Blanket Implementations§
source§impl<T> Any for Twhere
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: StringThe node origin domain.
§nameserver: SocketAddrThe 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
Expand description
A discovery service which publishes and resolves node information using a pkarr relay.
+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 @@
-
Struct iroh::discovery::pkarr::PkarrPublisher
source · pub struct PkarrPublisher { /* private fields */ }Expand description
Publisher of node discovery information to a pkarr relay.
+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
impl PkarrPublisher
sourcepub fn new(secret_key: SecretKey, pkarr_relay: Url) -> Self
pub fn new(secret_key: SecretKey, pkarr_relay: Url) -> Self
Creates a new publisher for the SecretKey.
Implementations§
source§impl PkarrPublisher
impl PkarrPublisher
sourcepub fn new(secret_key: SecretKey, pkarr_relay: Url) -> Self
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.
sourcepub fn with_options(
+
pub fn with_options( +
sourcepub fn with_options(
secret_key: SecretKey,
pkarr_relay: Url,
ttl: u32,
@@ -18,23 +18,23 @@ information is unchanged.
) -> Self
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.
sourcepub fn n0_dns(secret_key: SecretKey) -> Self
pub fn n0_dns(secret_key: SecretKey) -> Self
Creates a pkarr publisher which uses the number 0 pkarr relay server.
+sourcepub fn n0_dns(secret_key: SecretKey) -> Self
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.
sourcepub fn update_addr_info(
+
pub fn update_addr_info( +
sourcepub fn update_addr_info(
&self,
url: Option<&RelayUrl>,
addrs: &BTreeSet<SocketAddr>
)
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
impl Clone for PkarrPublisher
source§fn clone(&self) -> PkarrPublisher
fn clone(&self) -> PkarrPublisher
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moresource§impl Debug for PkarrPublisher
impl Debug for PkarrPublisher
Trait Implementations§
source§impl Clone for PkarrPublisher
impl Clone for PkarrPublisher
source§fn clone(&self) -> PkarrPublisher
fn clone(&self) -> PkarrPublisher
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moresource§impl Debug for PkarrPublisher
impl Debug for PkarrPublisher
Auto Trait Implementations§
impl Freeze for PkarrPublisher
impl !RefUnwindSafe for PkarrPublisher
impl Send for PkarrPublisher
impl Sync for PkarrPublisher
impl Unpin for PkarrPublisher
impl !UnwindSafe for PkarrPublisher
Blanket Implementations§
Auto Trait Implementations§
impl Freeze for PkarrPublisher
impl !RefUnwindSafe for PkarrPublisher
impl Send for PkarrPublisher
impl Sync for PkarrPublisher
impl Unpin for PkarrPublisher
impl !UnwindSafe for PkarrPublisher
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§
Trait Implementations§
source§impl Clone for PkarrRelayClient
source§fn clone(&self) -> PkarrRelayClient
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for PkarrRelayClient
§impl !RefUnwindSafe for PkarrRelayClient
§impl Send for PkarrRelayClient
§impl Sync for PkarrRelayClient
§impl Unpin for PkarrRelayClient
§impl !UnwindSafe for PkarrRelayClient
Blanket Implementations§
source§impl<T> Any for Twhere
+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§
Trait Implementations§
source§impl Clone for PkarrRelayClient
source§fn clone(&self) -> PkarrRelayClient
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for PkarrRelayClient
§impl !RefUnwindSafe for PkarrRelayClient
§impl Send for PkarrRelayClient
§impl Sync for PkarrRelayClient
§impl Unpin for PkarrRelayClient
§impl !UnwindSafe for PkarrRelayClient
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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
sourcepub fn new(pkarr_relay: Url) -> Self
Creates a new publisher using the pkarr relay server at the URL.
-Implementations§
source§impl PkarrResolver
sourcepub fn new(pkarr_relay: Url) -> Self
Creates a new publisher using the pkarr relay server at the URL.
+sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for PkarrResolver
Trait Implementations§
source§impl Clone for PkarrResolver
source§fn clone(&self) -> PkarrResolver
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for PkarrResolver
Auto Trait Implementations§
§impl Freeze for PkarrResolver
§impl !RefUnwindSafe for PkarrResolver
§impl Send for PkarrResolver
§impl Sync for PkarrResolver
§impl Unpin for PkarrResolver
§impl !UnwindSafe for PkarrResolver
Blanket Implementations§
Auto Trait Implementations§
§impl Freeze for PkarrResolver
§impl !RefUnwindSafe for PkarrResolver
§impl Send for PkarrResolver
§impl Sync for PkarrResolver
§impl Unpin for PkarrResolver
§impl !UnwindSafe for PkarrResolver
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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>>>
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§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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
sourcepub fn empty() -> Self
Creates an empty ConcurrentDiscovery.
-sourcepub fn from_services(services: Vec<Box<dyn Discovery>>) -> Self
Creates a new ConcurrentDiscovery.
-Trait Implementations§
source§impl Debug for ConcurrentDiscovery
source§impl Default for ConcurrentDiscovery
source§fn default() -> ConcurrentDiscovery
Returns the “default value” for a type. Read moresource§impl Discovery for ConcurrentDiscovery
Implementations§
source§impl ConcurrentDiscovery
sourcepub fn empty() -> Self
Creates an empty ConcurrentDiscovery.
+sourcepub fn from_services(services: Vec<Box<dyn Discovery>>) -> Self
Creates a new ConcurrentDiscovery.
+Trait Implementations§
source§impl Debug for ConcurrentDiscovery
source§impl Default for ConcurrentDiscovery
source§fn default() -> ConcurrentDiscovery
Returns the “default value” for a type. Read moresource§impl Discovery for ConcurrentDiscovery
source§impl<T> From<T> for ConcurrentDiscovery
Auto Trait Implementations§
§impl Freeze for ConcurrentDiscovery
§impl !RefUnwindSafe for ConcurrentDiscovery
§impl Send for ConcurrentDiscovery
§impl Sync for ConcurrentDiscovery
§impl Unpin for ConcurrentDiscovery
§impl !UnwindSafe for ConcurrentDiscovery
Blanket Implementations§
source§impl<T> From<T> for ConcurrentDiscovery
Auto Trait Implementations§
§impl Freeze for ConcurrentDiscovery
§impl !RefUnwindSafe for ConcurrentDiscovery
§impl Send for ConcurrentDiscovery
§impl Sync for ConcurrentDiscovery
§impl Unpin for ConcurrentDiscovery
§impl !UnwindSafe for ConcurrentDiscovery
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for DiscoveryItem
§impl RefUnwindSafe for DiscoveryItem
§impl Send for DiscoveryItem
§impl Sync for DiscoveryItem
§impl Unpin for DiscoveryItem
§impl UnwindSafe for DiscoveryItem
Blanket Implementations§
source§impl<T> Any for Twhere
+Trait Implementations§
source§impl Clone for DiscoveryItem
source§fn clone(&self) -> DiscoveryItem
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for DiscoveryItem
§impl RefUnwindSafe for DiscoveryItem
§impl Send for DiscoveryItem
§impl Sync for DiscoveryItem
§impl Unpin for DiscoveryItem
§impl UnwindSafe for DiscoveryItem
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 pub trait Discovery: Debug + Send + Sync {
+Discovery in iroh::discovery - Rust 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§
sourcefn publish(&self, _url: Option<&RelayUrl>, _addrs: &BTreeSet<SocketAddr>)
Publishes the given RelayUrl and direct addreesses to the discovery mechanism.
+Provided Methods§
sourcefn 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.
-sourcefn 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.
-sourcefn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>
Subscribe to all addresses that get passively discovered.
+sourcefn 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddrType
source§impl Display for DirectAddrType
source§impl Hash for DirectAddrType
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddrType
source§impl Display for DirectAddrType
source§impl Hash for DirectAddrType
source§impl Ord for DirectAddrType
source§impl Ord for DirectAddrType
source§fn cmp(&self, other: &DirectAddrType) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read moresource§impl PartialEq for DirectAddrType
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 ==.source§impl PartialOrd for DirectAddrType
source§impl PartialOrd for DirectAddrType
source§fn partial_cmp(&self, other: &DirectAddrType) -> Option<Ordering>
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 moresource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 pub enum RelayMode {
+RelayMode in iroh::endpoint - Rust 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§
Trait Implementations§
source§impl PartialEq for RelayMode
Implementations§
Trait Implementations§
source§impl PartialEq for RelayMode
source§impl Eq for RelayMode
source§impl StructuralPartialEq for RelayMode
Auto Trait Implementations§
§impl Freeze for RelayMode
§impl RefUnwindSafe for RelayMode
§impl Send for RelayMode
§impl Sync for RelayMode
§impl Unpin for RelayMode
§impl UnwindSafe for RelayMode
Blanket Implementations§
source§impl Eq for RelayMode
source§impl StructuralPartialEq for RelayMode
Auto Trait Implementations§
§impl Freeze for RelayMode
§impl RefUnwindSafe for RelayMode
§impl Send for RelayMode
§impl Sync for RelayMode
§impl Unpin for RelayMode
§impl UnwindSafe for RelayMode
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
The Endpoint allows establishing connections to other iroh nodes.
+iroh::endpoint - Rust 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§
- Future produced by
Endpoint::accept. - Future produced by
Connection::accept_bi - Future produced by
Connection::accept_uni - Parameters for controlling the peer’s acknowledgement frequency
- Reason given by an application for closing the connection
- Builder for
Endpoint. - A cheaply cloneable and sliceable chunk of contiguous memory.
- A chunk of data from the receive stream
- Error indicating that a stream has not been opened or has already been finished or reset
- In-progress connection attempt future
- A QUIC connection.
- Reason given by the transport for closing the connection
- Connection statistics
- Stream returning
ConnectionTypes - Generic crypto errors
- A direct address on which an iroh-node might be contactable.
- Information about a direct address.
- Stream returning local endpoints as they change.
- Controls an iroh node, establishing connections with other nodes.
- Error returned by [Session::export_keying_material].
- Number of frames transmitted of each frame type
- An incoming connection for which the server has not yet begun its parts of the
handshake.
- Parameters governing MTU discovery.
- Network-level addressing information for an iroh node.
- Future produced by
Connection::open_bi - Future produced by
Connection::open_uni - Statistics related to a transmission path
- Future produced by
Connection::read_datagram - A stream that can only be used to receive data
- Details about a remote iroh node which is known to this node.
- Error for attempting to retry an [
Incoming] which already bears an address
validation token from a previous retry - A stream that can only be used to send data
- Parameters governing incoming connections
- Identifier for a stream within a particular connection
- Parameters governing the core QUIC state machine
- Transport-level errors occur when a peer violates the protocol specification
- Transport-level error code
- Statistics about UDP datagrams transmitted or received on a connection
- Error indicating that the specified QUIC version is not supported
- An integer less than 2^62
- A handle to some connection internals, use with care.
- Indicates how many bytes and chunks had been transferred in a write operation
- Future that completes when a connection is fully established
Enums§
- Options to configure what is included in a
NodeAddr. - Reasons why a connection might be lost
- The type of connection we have to the endpoint.
- The type of control message we have received.
- The type of direct address.
- Errors that arise from reading from a stream.
- Errors that arise from reading from a stream.
- Errors from
RecvStream::read_to_end - Configuration of the relay servers for an
Endpoint. - Errors that arise while waiting for a stream to be reset
- Errors that can arise when sending a datagram
- The origin or source through which an address associated with a remote node
-was discovered.
- Errors that arise while monitoring for a send stream stop from the peer
- Errors that arise from writing to a stream
Constants§
- ENV_FORCE_STAGING_RELAYSNon-
testEnvironment variable to force the use of staging relays.
Traits§
- A key for sealing data with AEAD-based algorithms
- Common interface for different congestion controllers
- Constructs controllers on demand
- Server-side configuration for the crypto protocol
- A pseudo random key for HKDF
Functions§
- Returns the default relay mode.
- Returns
true if the use of staging relays is forced. - Extract the
PublicKey from the peer’s TLS certificate. - Creates a
ServerConfig with the given secret key and limits.
\ 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§
- Environment variable to force the use of staging relays.
Traits§
- A key for sealing data with AEAD-based algorithms
- Common interface for different congestion controllers
- Constructs controllers on demand
- Server-side configuration for the crypto protocol
- A pseudo random key for HKDF
Functions§
- Returns the default relay mode.
- Returns
true if the use of staging relays is forced. - Extract the
PublicKey from the peer’s TLS certificate. - Creates a
ServerConfig with the given secret key and limits.
\ 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 pub struct Accept<'a> { /* private fields */ }
Expand description
Future produced by Endpoint::accept.
-Trait Implementations§
source§impl<'pin, 'a> Unpin for Accept<'a>where
+Accept in iroh::endpoint - Rust pub struct Accept<'a> { /* private fields */ }
Expand description
Future produced by Endpoint::accept.
+Trait Implementations§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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>,§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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 pub struct Builder { /* private fields */ }
Expand description
Builder for Endpoint.
+Builder in iroh::endpoint - Rust 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
sourcepub fn bind_addr_v4(self, addr: SocketAddrV4) -> Self
Sets the IPv4 bind address.
+Implementations§
source§impl Builder
sourcepub 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.
-sourcepub fn bind_addr_v6(self, addr: SocketAddrV6) -> Self
Sets the IPv6 bind address.
+sourcepub 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.
-sourcepub fn secret_key(self, secret_key: SecretKey) -> Self
Sets a secret key to authenticate with other peers.
+sourcepub fn secret_key(self, secret_key: SecretKey) -> Self
sourcepub fn alpns(self, alpn_protocols: Vec<Vec<u8>>) -> Self
Sets the ALPN protocols that this endpoint will accept on incoming connections.
+sourcepub fn relay_mode(self, relay_mode: RelayMode) -> Self
Sets the relay servers to assist in establishing connectivity.
+sourcepub 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.
-sourcepub fn clear_discovery(self) -> Self
Removes all discovery services from the builder.
-sourcepub fn discovery(self, discovery: Box<dyn Discovery>) -> Self
Optionally sets a discovery mechanism for this endpoint.
+sourcepub fn clear_discovery(self) -> Self
Removes all discovery services from the builder.
+sourcepub 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.
-sourcepub fn add_discovery<F, D>(self, discovery: F) -> Selfwhere
+
sourcepub fn add_discovery<F, D>(self, discovery: F) -> Self
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.
-sourcepub fn discovery_n0(self) -> Self
Configures the endpoint to use the default n0 DNS discovery service.
+sourcepub 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.
-sourcepub 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.
+sourcepub 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.
-sourcepub fn discovery_local_network(self) -> Self
Available on crate feature discovery-local-network only.
Configures the endpoint to also use local network discovery.
+sourcepub 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.
-sourcepub fn known_nodes(self, nodes: Vec<NodeAddr>) -> Self
Optionally set a list of known nodes.
-sourcepub fn transport_config(self, transport_config: TransportConfig) -> Self
Sets a custom quinn::TransportConfig for this endpoint.
+sourcepub fn known_nodes(self, nodes: Vec<NodeAddr>) -> Self
Optionally set a list of known nodes.
+sourcepub 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.
-sourcepub fn dns_resolver(self, dns_resolver: DnsResolver) -> Self
Optionally sets a custom DNS resolver to use for this endpoint.
+sourcepub 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.
-sourcepub fn proxy_url(self, url: Url) -> Self
Sets an explicit proxy url to proxy all HTTP(S) traffic through.
-sourcepub fn proxy_from_env(self) -> Self
Sets the proxy url from the environment, in this order:
+sourcepub fn proxy_url(self, url: Url) -> Self
Sets an explicit proxy url to proxy all HTTP(S) traffic through.
+sourcepub fn proxy_from_env(self) -> Self
Sets the proxy url from the environment, in this order:
HTTP_PROXY
http_proxy
HTTPS_PROXY
https_proxy
-sourcepub fn keylog(self, keylog: bool) -> Self
Enables saving the TLS pre-master key for connections.
+sourcepub 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.
-sourcepub 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
+sourcepub 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§
Auto Trait Implementations§
§impl !Freeze for Builder
§impl !RefUnwindSafe for Builder
§impl Send for Builder
§impl Sync for Builder
§impl Unpin for Builder
§impl !UnwindSafe for Builder
Blanket Implementations§
Trait Implementations§
Auto Trait Implementations§
§impl !Freeze for Builder
§impl !RefUnwindSafe for Builder
§impl Send for Builder
§impl Sync for Builder
§impl Unpin for Builder
§impl !UnwindSafe for Builder
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§
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 · sourcepub fn to_ascii_uppercase(&self) -> Vec<u8> ⓘ
Returns a vector containing a copy of this slice where each byte
+
1.23.0 · sourcepub 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 · sourcepub fn to_ascii_lowercase(&self) -> Vec<u8> ⓘ
Returns a vector containing a copy of this slice where each byte
+
1.23.0 · sourcepub 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 · sourcepub 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.
sourcepub fn to_vec_in<A>(&self, alloc: A) -> Vec<T, A>
🔬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 · sourcepub 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.§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 copy_to_bytes(&mut self, len: usize) -> Bytes
§fn chunks_vectored<'a>(&'a self, dst: &mut [IoSlice<'a>]) -> usize
§fn chunks_vectored<'a>(&'a self, dst: &mut [IoSlice<'a>]) -> usize
Available on crate feature std only.§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])
§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 moreSized,§impl FromIterator<u8> for Bytes
§impl FromIterator<u8> for Bytes
§impl<S> FromRequest<S> for Bytes
§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 Hwhere
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>
§fn in_current_span(self) -> Instrumented<Self>
source§impl<T, U> Into<U> for Twhere
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
sourcepub fn into_0rtt(self) -> Result<(Connection, ZeroRttAccepted), Self>
Convert into a 0-RTT or 0.5-RTT connection at the cost of weakened security.
-sourcepub async fn handshake_data(&mut self) -> Result<Box<dyn Any>, ConnectionError>
Parameters negotiated during the handshake
-sourcepub fn local_ip(&self) -> Option<IpAddr>
The local IP address which was used when the peer established the connection.
-sourcepub fn remote_address(&self) -> SocketAddr
The peer’s UDP address.
-Trait Implementations§
source§impl Debug for Connecting
source§impl Future for Connecting
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for Connectingwhere
+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
sourcepub fn into_0rtt(self) -> Result<(Connection, ZeroRttAccepted), Self>
Convert into a 0-RTT or 0.5-RTT connection at the cost of weakened security.
+sourcepub async fn handshake_data(&mut self) -> Result<Box<dyn Any>, ConnectionError>
Parameters negotiated during the handshake
+sourcepub fn local_ip(&self) -> Option<IpAddr>
The local IP address which was used when the peer established the connection.
+sourcepub fn remote_address(&self) -> SocketAddr
The peer’s UDP address.
+Trait Implementations§
source§impl Debug for Connecting
source§impl Future for Connecting
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for Connectingwhere
PinnedFieldsOf<__Connecting<'pin>>: Unpin,
Auto Trait Implementations§
§impl Freeze for Connecting
§impl !RefUnwindSafe for Connecting
§impl Send for Connecting
§impl Sync for Connecting
§impl !UnwindSafe for Connecting
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§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§impl<S> StreamExt for Swhere
+ 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§impl<S> StreamExt for Swhere
S: Stream + ?Sized,
Sized,
S: Stream<Item = Self::Item>,
§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§impl<S1> StreamExt for S1where
+ 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 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 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 moreRead 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§impl<T> StreamExt for Twhere
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, ()>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>
) -> FlatMapUnordered<Self, U, F>
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 moreRuns 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 moreSized,
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 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>>
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>>
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>
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>
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>,
Available on crate features sink and alloc only.§fn inspect<F>(self, f: F) -> Inspect<Self, F>
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: SocketAddrThe address.
§typ: DirectAddrTypeThe origin of this direct address.
-Trait Implementations§
source§impl Clone for DirectAddr
source§fn clone(&self) -> DirectAddr
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddr
source§impl Hash for DirectAddr
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddr
source§impl Hash for DirectAddr
source§impl Ord for DirectAddr
source§impl Ord for DirectAddr
source§fn cmp(&self, other: &DirectAddr) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read moresource§impl PartialEq for DirectAddr
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 ==.source§impl PartialOrd for DirectAddr
source§impl PartialOrd for DirectAddr
source§fn partial_cmp(&self, other: &DirectAddr) -> Option<Ordering>
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 moresource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§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§impl Stream for DirectAddrsStream
Sized,
S: Stream<Item = Self::Item>,§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
§impl<S> StreamExt for Swhere
+ 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§impl<S> StreamExt for Swhere
S: Stream + ?Sized,
Sized,
S: Stream<Item = Self::Item>,§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§impl<S1> StreamExt for S1where
+ 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 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 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 moreRead 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
§impl<T> StreamExt for Twhere
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, ()>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>
) -> FlatMapUnordered<Self, U, F>
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 moreRuns 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 moreSized,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 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>>
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>>
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>
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>
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>,
Available on crate features sink and alloc only.§fn inspect<F>(self, f: F) -> Inspect<Self, F>
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 pub struct Endpoint { /* private fields */ }
Expand description
Controls an iroh node, establishing connections with other nodes.
+Endpoint in iroh::endpoint - Rust 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
sourcepub fn builder() -> Builder
Returns the builder for an Endpoint, with a production configuration.
-sourcepub fn set_alpns(&self, alpns: Vec<Vec<u8>>) -> Result<()>
Sets the list of accepted ALPN protocols.
+Implementations§
source§impl Endpoint
sourcepub fn builder() -> Builder
Returns the builder for an Endpoint, with a production configuration.
+sourcepub 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.
-
sourcepub 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.
-sourcepub fn add_node_addr(&self, node_addr: NodeAddr) -> Result<()>
Informs this Endpoint about addresses of the iroh node.
+sourcepub 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.
-sourcepub fn add_node_addr_with_source(
+
sourcepub fn secret_key(&self) -> &SecretKey
Returns the secret_key of this endpoint.
-sourcepub fn secret_key(&self) -> &SecretKey
Returns the secret_key of this endpoint.
+sourcepub 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.
-sourcepub async fn node_addr(&self) -> Result<NodeAddr>
Returns the current NodeAddr for this endpoint.
+sourcepub 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.
-sourcepub fn home_relay(&self) -> Option<RelayUrl>
Returns the RelayUrl of the Relay server used as home relay.
+sourcepub 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.
-sourcepub fn watch_home_relay(&self) -> impl Stream<Item = RelayUrl>
Watches for changes to the home relay.
+sourcepub 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.
-sourcepub fn direct_addresses(&self) -> DirectAddrsStream
Returns the direct addresses of this Endpoint.
+sourcepub 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;
-sourcepub fn bound_sockets(&self) -> (SocketAddr, Option<SocketAddr>)
Returns the local socket addresses on which the underlying sockets are bound.
+sourcepub 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.
-sourcepub fn remote_info(&self, node_id: NodeId) -> Option<RemoteInfo>
Returns information about the remote node identified by a NodeId.
+sourcepub 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.
-sourcepub fn remote_info_iter(&self) -> impl Iterator<Item = RemoteInfo>
Returns information about all the remote nodes this Endpoint knows about.
+sourcepub 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.
-sourcepub fn conn_type_stream(&self, node_id: NodeId) -> Result<ConnectionTypeStream>
Returns a stream that reports connection type changes for the remote node.
+sourcepub 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.
-sourcepub fn dns_resolver(&self) -> &DnsResolver
Returns the DNS resolver used in this Endpoint.
+sourcepub fn dns_resolver(&self) -> &DnsResolver
Returns the DNS resolver used in this Endpoint.
See Builder::discovery.
-sourcepub fn discovery(&self) -> Option<&dyn Discovery>
Returns the discovery mechanism, if configured.
+sourcepub fn discovery(&self) -> Option<&dyn Discovery>
Returns the discovery mechanism, if configured.
-sourcepub async fn network_change(&self)
Notifies the system of potential network changes.
+sourcepub 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.
-sourcepub 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.
-Trait Implementations§
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§
Trait Implementations§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 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 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
sourcepub fn accept(self) -> Result<Connecting, ConnectionError>
Attempts to accept this incoming connection (an error may still occur).
+Implementations§
source§impl Incoming
sourcepub 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.
-sourcepub fn accept_with(
+
sourcepub fn accept_with(
self,
server_config: Arc<ServerConfig>
) -> Result<Connecting, ConnectionError>
Accepts this incoming connection using a custom configuration.
See accept() for more details.
-sourcepub fn retry(self) -> Result<(), RetryError>
Responds with a retry packet.
+sourcepub 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.
-sourcepub fn ignore(self)
Ignores this incoming connection attempt, not sending any packet in response.
-sourcepub fn local_ip(&self) -> Option<IpAddr>
Returns the local IP address which was used when the peer established the
+
sourcepub fn ignore(self)
Ignores this incoming connection attempt, not sending any packet in response.
+sourcepub fn local_ip(&self) -> Option<IpAddr>
Returns the local IP address which was used when the peer established the
connection.
-sourcepub fn remote_address(&self) -> SocketAddr
Returns the peer’s UDP address.
-sourcepub fn remote_address_validated(&self) -> bool
Whether the socket address that is initiating this connection has been validated.
+sourcepub fn remote_address(&self) -> SocketAddr
Returns the peer’s UDP address.
+sourcepub 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 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 moreAuto Trait Implementations§
§impl !Freeze for Incoming
§impl !RefUnwindSafe for Incoming
§impl Send for Incoming
§impl Sync for Incoming
§impl Unpin for Incoming
§impl !UnwindSafe for Incoming
Blanket Implementations§
Trait Implementations§
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 moreAuto Trait Implementations§
§impl !Freeze for Incoming
§impl !RefUnwindSafe for Incoming
§impl Send for Incoming
§impl Sync for Incoming
§impl Unpin for Incoming
§impl !UnwindSafe for Incoming
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§impl Future for IncomingFuture
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for IncomingFuturewhere
+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§impl Future for IncomingFuture
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for IncomingFuturewhere
PinnedFieldsOf<__IncomingFuture<'pin>>: Unpin,
Auto Trait Implementations§
§impl !Freeze for IncomingFuture
§impl !RefUnwindSafe for IncomingFuture
§impl Send for IncomingFuture
§impl Sync for IncomingFuture
§impl !UnwindSafe for IncomingFuture
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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
§fn poll_write(
+
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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 Expand description
The blake3 hash used in Iroh.
+iroh::hash - Rust
\ 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 moresource§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
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more1.21.0 · source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more1.50.0 · source§fn clamp(self, min: Self, max: Self) -> Selfwhere
@@ -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 widthsource§fn from_bytes<'a>(data: &'a [u8]) -> <Hash as Value>::SelfType<'a>where
+ S: Serializer,
Serialize this value into the given Serde serializer. Read moresource§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 widthsource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: HashThe hash
§format: BlobFormatThe format
-Implementations§
source§impl HashAndFormat
sourcepub fn new(hash: Hash, format: BlobFormat) -> HashAndFormat
Create a new hash and format pair.
-sourcepub fn raw(hash: Hash) -> HashAndFormat
Create a new hash and format pair, using the default (raw) format.
-sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for HashAndFormat
source§impl<'de> Deserialize<'de> for HashAndFormat
source§fn deserialize<D>(
+
Implementations§
source§impl HashAndFormat
sourcepub fn new(hash: Hash, format: BlobFormat) -> HashAndFormat
Create a new hash and format pair.
+sourcepub fn raw(hash: Hash) -> HashAndFormat
Create a new hash and format pair, using the default (raw) format.
+sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for HashAndFormat
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 moresource§impl Display for HashAndFormat
source§impl FromStr for HashAndFormat
source§impl Hash for HashAndFormat
source§impl Display for HashAndFormat
source§impl FromStr for HashAndFormat
source§impl Hash for HashAndFormat
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.source§impl PartialOrd for HashAndFormat
source§fn partial_cmp(&self, other: &HashAndFormat) -> Option<Ordering>
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 moresource§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 moresource§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 widthsource§fn from_bytes<'a>(data: &'a [u8]) -> <HashAndFormat as Value>::SelfType<'a>where
+ S: Serializer,
Serialize this value into the given Serde serializer. Read moresource§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 widthsource§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 typesource§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§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
Peer-to-peer QUIC connections.
+iroh - Rust 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§
pub use endpoint::Endpoint;pub use endpoint::RelayMode;pub use iroh_relay as relay;
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_utils
test or test-utilsInternal 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§
- Options to configure what is included in a
NodeAddr.
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-utilsInternal 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§
- Options to configure what is included in a
NodeAddr.
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 Expand description
Cryptographic key handling for iroh.
+iroh::key - Rust
\ 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.
Trait Implementations§
§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 Copy for Signature
§impl Eq for Signature
§impl StructuralPartialEq for Signature
Auto Trait Implementations§
§impl Freeze for Signature
§impl RefUnwindSafe for Signature
§impl Send for Signature
§impl Sync for Signature
§impl Unpin for Signature
§impl UnwindSafe for Signature
Blanket Implementations§
source§impl<T> Any for Twhere
+ S: Serializer,
Serialize this value into the given Serde serializer. Read more§impl SignatureEncoding for Signature
§impl Copy for Signature
§impl Eq for Signature
§impl StructuralPartialEq for Signature
Auto Trait Implementations§
§impl Freeze for Signature
§impl RefUnwindSafe for Signature
§impl Send for Signature
§impl Sync for Signature
§impl Unpin for Signature
§impl UnwindSafe for Signature
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
Co-locating all of the iroh metrics structs
+iroh::metrics - Rust Expand description
Co-locating all of the iroh metrics structs
Structs§
- Enum of metrics for the module
- Enum of metrics for the module
- Enum of metrics for the module
- RelayMetrics
test-utilsMetrics tracked for the relay server
\ 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: CounterNumber of nodes we have managed to contact directly.
§connection_handshake_success: CounterNumber of connections with a successful handshake.
§connection_became_direct: CounterNumber of connections with a successful handshake that became direct.
-Trait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
Access to this metrics group to record a metric.
+Trait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterTrait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
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: CounterTrait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterTrait Implementations§
§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
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: CounterTrait Implementations§
§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterNumber of unique client keys per day
§websocket_accepts: CounterNumber of accepted websocket connections
§derp_accepts: CounterNumber of accepted ‘iroh derp http’ connection upgrades
-Trait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
Access to this metrics group to record a metric.
+Trait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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().
sourcepub 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.
-sourcepub fn to_file_path(&self) -> Result<PathBuf, ()>
Assuming the URL is in the file scheme or similar,
+
sourcepub 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.
\ 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.
\ 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§
- A drop guard to clean up test infrastructure.
- Handle and drop guard for test DNS and Pkarr servers.
Functions§
- Create a DNS resolver with a single nameserver.
- Runs a relay server with STUN and QUIC enabled suitable for tests.
- Runs a relay server.
- Runs a relay server with STUN enabled suitable for tests.
\ 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§
Auto Trait Implementations§
§impl Freeze for CleanupDropGuard
§impl !RefUnwindSafe for CleanupDropGuard
§impl Send for CleanupDropGuard
§impl Sync for CleanupDropGuard
§impl Unpin for CleanupDropGuard
§impl !UnwindSafe for CleanupDropGuard
Blanket Implementations§
source§impl<T> Any for Twhere
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: StringThe node origin domain.
§nameserver: SocketAddrThe 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
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§
Trait Implementations§
source§impl Clone for PkarrRelayClient
impl Clone for PkarrRelayClient
source§fn clone(&self) -> PkarrRelayClient
fn clone(&self) -> PkarrRelayClient
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl Freeze for PkarrRelayClient
impl !RefUnwindSafe for PkarrRelayClient
impl Send for PkarrRelayClient
impl Sync for PkarrRelayClient
impl Unpin for PkarrRelayClient
impl !UnwindSafe for PkarrRelayClient
Blanket Implementations§
source§impl<T> Any for Twhere
+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§
Trait Implementations§
source§impl Clone for PkarrRelayClient
source§fn clone(&self) -> PkarrRelayClient
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for PkarrRelayClient
§impl !RefUnwindSafe for PkarrRelayClient
§impl Send for PkarrRelayClient
§impl Sync for PkarrRelayClient
§impl Unpin for PkarrRelayClient
§impl !UnwindSafe for PkarrRelayClient
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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
sourcepub fn new(pkarr_relay: Url) -> Self
Creates a new publisher using the pkarr relay server at the URL.
-Implementations§
source§impl PkarrResolver
sourcepub fn new(pkarr_relay: Url) -> Self
Creates a new publisher using the pkarr relay server at the URL.
+sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for PkarrResolver
Trait Implementations§
source§impl Clone for PkarrResolver
source§fn clone(&self) -> PkarrResolver
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for PkarrResolver
Auto Trait Implementations§
§impl Freeze for PkarrResolver
§impl !RefUnwindSafe for PkarrResolver
§impl Send for PkarrResolver
§impl Sync for PkarrResolver
§impl Unpin for PkarrResolver
§impl !UnwindSafe for PkarrResolver
Blanket Implementations§
Auto Trait Implementations§
§impl Freeze for PkarrResolver
§impl !RefUnwindSafe for PkarrResolver
§impl Send for PkarrResolver
§impl Sync for PkarrResolver
§impl Unpin for PkarrResolver
§impl !UnwindSafe for PkarrResolver
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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>>>
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§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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
sourcepub fn empty() -> Self
Creates an empty ConcurrentDiscovery.
-sourcepub fn from_services(services: Vec<Box<dyn Discovery>>) -> Self
Creates a new ConcurrentDiscovery.
-Trait Implementations§
source§impl Debug for ConcurrentDiscovery
source§impl Default for ConcurrentDiscovery
source§fn default() -> ConcurrentDiscovery
Returns the “default value” for a type. Read moresource§impl Discovery for ConcurrentDiscovery
Implementations§
source§impl ConcurrentDiscovery
sourcepub fn empty() -> Self
Creates an empty ConcurrentDiscovery.
+sourcepub fn from_services(services: Vec<Box<dyn Discovery>>) -> Self
Creates a new ConcurrentDiscovery.
+Trait Implementations§
source§impl Debug for ConcurrentDiscovery
source§impl Default for ConcurrentDiscovery
source§fn default() -> ConcurrentDiscovery
Returns the “default value” for a type. Read moresource§impl Discovery for ConcurrentDiscovery
source§impl<T> From<T> for ConcurrentDiscovery
Auto Trait Implementations§
§impl Freeze for ConcurrentDiscovery
§impl !RefUnwindSafe for ConcurrentDiscovery
§impl Send for ConcurrentDiscovery
§impl Sync for ConcurrentDiscovery
§impl Unpin for ConcurrentDiscovery
§impl !UnwindSafe for ConcurrentDiscovery
Blanket Implementations§
source§impl<T> From<T> for ConcurrentDiscovery
Auto Trait Implementations§
§impl Freeze for ConcurrentDiscovery
§impl !RefUnwindSafe for ConcurrentDiscovery
§impl Send for ConcurrentDiscovery
§impl Sync for ConcurrentDiscovery
§impl Unpin for ConcurrentDiscovery
§impl !UnwindSafe for ConcurrentDiscovery
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for DiscoveryItem
§impl RefUnwindSafe for DiscoveryItem
§impl Send for DiscoveryItem
§impl Sync for DiscoveryItem
§impl Unpin for DiscoveryItem
§impl UnwindSafe for DiscoveryItem
Blanket Implementations§
source§impl<T> Any for Twhere
+Trait Implementations§
source§impl Clone for DiscoveryItem
source§fn clone(&self) -> DiscoveryItem
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for DiscoveryItem
§impl RefUnwindSafe for DiscoveryItem
§impl Send for DiscoveryItem
§impl Sync for DiscoveryItem
§impl Unpin for DiscoveryItem
§impl UnwindSafe for DiscoveryItem
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 pub trait Discovery: Debug + Send + Sync {
+Discovery in iroh::discovery - Rust 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§
sourcefn publish(&self, _url: Option<&RelayUrl>, _addrs: &BTreeSet<SocketAddr>)
Publishes the given RelayUrl and direct addreesses to the discovery mechanism.
+Provided Methods§
sourcefn 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.
-sourcefn 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.
-sourcefn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>
Subscribe to all addresses that get passively discovered.
+sourcefn 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddrType
source§impl Display for DirectAddrType
source§impl Hash for DirectAddrType
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddrType
source§impl Display for DirectAddrType
source§impl Hash for DirectAddrType
source§impl Ord for DirectAddrType
source§impl Ord for DirectAddrType
source§fn cmp(&self, other: &DirectAddrType) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read moresource§impl PartialEq for DirectAddrType
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 ==.source§impl PartialOrd for DirectAddrType
source§impl PartialOrd for DirectAddrType
source§fn partial_cmp(&self, other: &DirectAddrType) -> Option<Ordering>
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 moresource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 pub enum RelayMode {
+RelayMode in iroh::endpoint - Rust 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§
Trait Implementations§
source§impl PartialEq for RelayMode
Implementations§
Trait Implementations§
source§impl PartialEq for RelayMode
source§impl Eq for RelayMode
source§impl StructuralPartialEq for RelayMode
Auto Trait Implementations§
§impl Freeze for RelayMode
§impl RefUnwindSafe for RelayMode
§impl Send for RelayMode
§impl Sync for RelayMode
§impl Unpin for RelayMode
§impl UnwindSafe for RelayMode
Blanket Implementations§
source§impl Eq for RelayMode
source§impl StructuralPartialEq for RelayMode
Auto Trait Implementations§
§impl Freeze for RelayMode
§impl RefUnwindSafe for RelayMode
§impl Send for RelayMode
§impl Sync for RelayMode
§impl Unpin for RelayMode
§impl UnwindSafe for RelayMode
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
The Endpoint allows establishing connections to other iroh nodes.
+iroh::endpoint - Rust 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§
- Future produced by
Endpoint::accept. - Future produced by
Connection::accept_bi - Future produced by
Connection::accept_uni - Parameters for controlling the peer’s acknowledgement frequency
- Reason given by an application for closing the connection
- Builder for
Endpoint. - A cheaply cloneable and sliceable chunk of contiguous memory.
- A chunk of data from the receive stream
- Error indicating that a stream has not been opened or has already been finished or reset
- In-progress connection attempt future
- A QUIC connection.
- Reason given by the transport for closing the connection
- Connection statistics
- Stream returning
ConnectionTypes - Generic crypto errors
- A direct address on which an iroh-node might be contactable.
- Information about a direct address.
- Stream returning local endpoints as they change.
- Controls an iroh node, establishing connections with other nodes.
- Error returned by [Session::export_keying_material].
- Number of frames transmitted of each frame type
- An incoming connection for which the server has not yet begun its parts of the
handshake.
- Parameters governing MTU discovery.
- Network-level addressing information for an iroh node.
- Future produced by
Connection::open_bi - Future produced by
Connection::open_uni - Statistics related to a transmission path
- Future produced by
Connection::read_datagram - A stream that can only be used to receive data
- Details about a remote iroh node which is known to this node.
- Error for attempting to retry an [
Incoming] which already bears an address
validation token from a previous retry - A stream that can only be used to send data
- Parameters governing incoming connections
- Identifier for a stream within a particular connection
- Parameters governing the core QUIC state machine
- Transport-level errors occur when a peer violates the protocol specification
- Transport-level error code
- Statistics about UDP datagrams transmitted or received on a connection
- Error indicating that the specified QUIC version is not supported
- An integer less than 2^62
- A handle to some connection internals, use with care.
- Indicates how many bytes and chunks had been transferred in a write operation
- Future that completes when a connection is fully established
Enums§
- Options to configure what is included in a
NodeAddr. - Reasons why a connection might be lost
- The type of connection we have to the endpoint.
- The type of control message we have received.
- The type of direct address.
- Errors that arise from reading from a stream.
- Errors that arise from reading from a stream.
- Errors from
RecvStream::read_to_end - Configuration of the relay servers for an
Endpoint. - Errors that arise while waiting for a stream to be reset
- Errors that can arise when sending a datagram
- The origin or source through which an address associated with a remote node
-was discovered.
- Errors that arise while monitoring for a send stream stop from the peer
- Errors that arise from writing to a stream
Constants§
- ENV_FORCE_STAGING_RELAYSNon-
testEnvironment variable to force the use of staging relays.
Traits§
- A key for sealing data with AEAD-based algorithms
- Common interface for different congestion controllers
- Constructs controllers on demand
- Server-side configuration for the crypto protocol
- A pseudo random key for HKDF
Functions§
- Returns the default relay mode.
- Returns
true if the use of staging relays is forced. - Extract the
PublicKey from the peer’s TLS certificate. - Creates a
ServerConfig with the given secret key and limits.
\ 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§
- Environment variable to force the use of staging relays.
Traits§
- A key for sealing data with AEAD-based algorithms
- Common interface for different congestion controllers
- Constructs controllers on demand
- Server-side configuration for the crypto protocol
- A pseudo random key for HKDF
Functions§
- Returns the default relay mode.
- Returns
true if the use of staging relays is forced. - Extract the
PublicKey from the peer’s TLS certificate. - Creates a
ServerConfig with the given secret key and limits.
\ 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 pub struct Accept<'a> { /* private fields */ }
Expand description
Future produced by Endpoint::accept.
-Trait Implementations§
source§impl<'pin, 'a> Unpin for Accept<'a>where
+Accept in iroh::endpoint - Rust pub struct Accept<'a> { /* private fields */ }
Expand description
Future produced by Endpoint::accept.
+Trait Implementations§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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>,§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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 pub struct Builder { /* private fields */ }
Expand description
Builder for Endpoint.
+Builder in iroh::endpoint - Rust 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
sourcepub fn bind_addr_v4(self, addr: SocketAddrV4) -> Self
Sets the IPv4 bind address.
+Implementations§
source§impl Builder
sourcepub 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.
-sourcepub fn bind_addr_v6(self, addr: SocketAddrV6) -> Self
Sets the IPv6 bind address.
+sourcepub 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.
-sourcepub fn secret_key(self, secret_key: SecretKey) -> Self
Sets a secret key to authenticate with other peers.
+sourcepub fn secret_key(self, secret_key: SecretKey) -> Self
sourcepub fn alpns(self, alpn_protocols: Vec<Vec<u8>>) -> Self
Sets the ALPN protocols that this endpoint will accept on incoming connections.
+sourcepub fn relay_mode(self, relay_mode: RelayMode) -> Self
Sets the relay servers to assist in establishing connectivity.
+sourcepub 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.
-sourcepub fn clear_discovery(self) -> Self
Removes all discovery services from the builder.
-sourcepub fn discovery(self, discovery: Box<dyn Discovery>) -> Self
Optionally sets a discovery mechanism for this endpoint.
+sourcepub fn clear_discovery(self) -> Self
Removes all discovery services from the builder.
+sourcepub 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.
-sourcepub fn add_discovery<F, D>(self, discovery: F) -> Selfwhere
+
sourcepub fn add_discovery<F, D>(self, discovery: F) -> Self
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.
-sourcepub fn discovery_n0(self) -> Self
Configures the endpoint to use the default n0 DNS discovery service.
+sourcepub 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.
-sourcepub 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.
+sourcepub 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.
-sourcepub fn discovery_local_network(self) -> Self
Available on crate feature discovery-local-network only.
Configures the endpoint to also use local network discovery.
+sourcepub 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.
-sourcepub fn known_nodes(self, nodes: Vec<NodeAddr>) -> Self
Optionally set a list of known nodes.
-sourcepub fn transport_config(self, transport_config: TransportConfig) -> Self
Sets a custom quinn::TransportConfig for this endpoint.
+sourcepub fn known_nodes(self, nodes: Vec<NodeAddr>) -> Self
Optionally set a list of known nodes.
+sourcepub 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.
-sourcepub fn dns_resolver(self, dns_resolver: DnsResolver) -> Self
Optionally sets a custom DNS resolver to use for this endpoint.
+sourcepub 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.
-sourcepub fn proxy_url(self, url: Url) -> Self
Sets an explicit proxy url to proxy all HTTP(S) traffic through.
-sourcepub fn proxy_from_env(self) -> Self
Sets the proxy url from the environment, in this order:
+sourcepub fn proxy_url(self, url: Url) -> Self
Sets an explicit proxy url to proxy all HTTP(S) traffic through.
+sourcepub fn proxy_from_env(self) -> Self
Sets the proxy url from the environment, in this order:
HTTP_PROXY
http_proxy
HTTPS_PROXY
https_proxy
-sourcepub fn keylog(self, keylog: bool) -> Self
Enables saving the TLS pre-master key for connections.
+sourcepub 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.
-sourcepub 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
+sourcepub 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§
Auto Trait Implementations§
§impl !Freeze for Builder
§impl !RefUnwindSafe for Builder
§impl Send for Builder
§impl Sync for Builder
§impl Unpin for Builder
§impl !UnwindSafe for Builder
Blanket Implementations§
Trait Implementations§
Auto Trait Implementations§
§impl !Freeze for Builder
§impl !RefUnwindSafe for Builder
§impl Send for Builder
§impl Sync for Builder
§impl Unpin for Builder
§impl !UnwindSafe for Builder
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§
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 · sourcepub fn to_ascii_uppercase(&self) -> Vec<u8> ⓘ
Returns a vector containing a copy of this slice where each byte
+
1.23.0 · sourcepub 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 · sourcepub fn to_ascii_lowercase(&self) -> Vec<u8> ⓘ
Returns a vector containing a copy of this slice where each byte
+
1.23.0 · sourcepub 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 · sourcepub 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.
sourcepub fn to_vec_in<A>(&self, alloc: A) -> Vec<T, A>
🔬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 · sourcepub 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.§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 copy_to_bytes(&mut self, len: usize) -> Bytes
§fn chunks_vectored<'a>(&'a self, dst: &mut [IoSlice<'a>]) -> usize
§fn chunks_vectored<'a>(&'a self, dst: &mut [IoSlice<'a>]) -> usize
Available on crate feature std only.§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])
§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 moreSized,§impl FromIterator<u8> for Bytes
§impl FromIterator<u8> for Bytes
§impl<S> FromRequest<S> for Bytes
§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 Hwhere
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>
§fn in_current_span(self) -> Instrumented<Self>
source§impl<T, U> Into<U> for Twhere
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
sourcepub fn into_0rtt(self) -> Result<(Connection, ZeroRttAccepted), Self>
Convert into a 0-RTT or 0.5-RTT connection at the cost of weakened security.
-sourcepub async fn handshake_data(&mut self) -> Result<Box<dyn Any>, ConnectionError>
Parameters negotiated during the handshake
-sourcepub fn local_ip(&self) -> Option<IpAddr>
The local IP address which was used when the peer established the connection.
-sourcepub fn remote_address(&self) -> SocketAddr
The peer’s UDP address.
-Trait Implementations§
source§impl Debug for Connecting
source§impl Future for Connecting
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for Connectingwhere
+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
sourcepub fn into_0rtt(self) -> Result<(Connection, ZeroRttAccepted), Self>
Convert into a 0-RTT or 0.5-RTT connection at the cost of weakened security.
+sourcepub async fn handshake_data(&mut self) -> Result<Box<dyn Any>, ConnectionError>
Parameters negotiated during the handshake
+sourcepub fn local_ip(&self) -> Option<IpAddr>
The local IP address which was used when the peer established the connection.
+sourcepub fn remote_address(&self) -> SocketAddr
The peer’s UDP address.
+Trait Implementations§
source§impl Debug for Connecting
source§impl Future for Connecting
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for Connectingwhere
PinnedFieldsOf<__Connecting<'pin>>: Unpin,
Auto Trait Implementations§
§impl Freeze for Connecting
§impl !RefUnwindSafe for Connecting
§impl Send for Connecting
§impl Sync for Connecting
§impl !UnwindSafe for Connecting
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§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§impl<S> StreamExt for Swhere
+ 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§impl<S> StreamExt for Swhere
S: Stream + ?Sized,
Sized,
S: Stream<Item = Self::Item>,
§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§impl<S1> StreamExt for S1where
+ 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 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 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 moreRead 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§impl<T> StreamExt for Twhere
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, ()>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>
) -> FlatMapUnordered<Self, U, F>
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 moreRuns 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 moreSized,
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 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>>
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>>
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>
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>
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>,
Available on crate features sink and alloc only.§fn inspect<F>(self, f: F) -> Inspect<Self, F>
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: SocketAddrThe address.
§typ: DirectAddrTypeThe origin of this direct address.
-Trait Implementations§
source§impl Clone for DirectAddr
source§fn clone(&self) -> DirectAddr
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddr
source§impl Hash for DirectAddr
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddr
source§impl Hash for DirectAddr
source§impl Ord for DirectAddr
source§impl Ord for DirectAddr
source§fn cmp(&self, other: &DirectAddr) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read moresource§impl PartialEq for DirectAddr
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 ==.source§impl PartialOrd for DirectAddr
source§impl PartialOrd for DirectAddr
source§fn partial_cmp(&self, other: &DirectAddr) -> Option<Ordering>
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 moresource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§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§impl Stream for DirectAddrsStream
Sized,
S: Stream<Item = Self::Item>,§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
§impl<S> StreamExt for Swhere
+ 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§impl<S> StreamExt for Swhere
S: Stream + ?Sized,
Sized,
S: Stream<Item = Self::Item>,§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§impl<S1> StreamExt for S1where
+ 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 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 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 moreRead 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
§impl<T> StreamExt for Twhere
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, ()>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>
) -> FlatMapUnordered<Self, U, F>
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 moreRuns 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 moreSized,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 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>>
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>>
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>
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>
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>,
Available on crate features sink and alloc only.§fn inspect<F>(self, f: F) -> Inspect<Self, F>
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 pub struct Endpoint { /* private fields */ }
Expand description
Controls an iroh node, establishing connections with other nodes.
+Endpoint in iroh::endpoint - Rust 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
sourcepub fn builder() -> Builder
Returns the builder for an Endpoint, with a production configuration.
-sourcepub fn set_alpns(&self, alpns: Vec<Vec<u8>>) -> Result<()>
Sets the list of accepted ALPN protocols.
+Implementations§
source§impl Endpoint
sourcepub fn builder() -> Builder
Returns the builder for an Endpoint, with a production configuration.
+sourcepub 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.
-
sourcepub 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.
-sourcepub fn add_node_addr(&self, node_addr: NodeAddr) -> Result<()>
Informs this Endpoint about addresses of the iroh node.
+sourcepub 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.
-sourcepub fn add_node_addr_with_source(
+
sourcepub fn secret_key(&self) -> &SecretKey
Returns the secret_key of this endpoint.
-sourcepub fn secret_key(&self) -> &SecretKey
Returns the secret_key of this endpoint.
+sourcepub 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.
-sourcepub async fn node_addr(&self) -> Result<NodeAddr>
Returns the current NodeAddr for this endpoint.
+sourcepub 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.
-sourcepub fn home_relay(&self) -> Option<RelayUrl>
Returns the RelayUrl of the Relay server used as home relay.
+sourcepub 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.
-sourcepub fn watch_home_relay(&self) -> impl Stream<Item = RelayUrl>
Watches for changes to the home relay.
+sourcepub 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.
-sourcepub fn direct_addresses(&self) -> DirectAddrsStream
Returns the direct addresses of this Endpoint.
+sourcepub 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;
-sourcepub fn bound_sockets(&self) -> (SocketAddr, Option<SocketAddr>)
Returns the local socket addresses on which the underlying sockets are bound.
+sourcepub 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.
-sourcepub fn remote_info(&self, node_id: NodeId) -> Option<RemoteInfo>
Returns information about the remote node identified by a NodeId.
+sourcepub 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.
-sourcepub fn remote_info_iter(&self) -> impl Iterator<Item = RemoteInfo>
Returns information about all the remote nodes this Endpoint knows about.
+sourcepub 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.
-sourcepub fn conn_type_stream(&self, node_id: NodeId) -> Result<ConnectionTypeStream>
Returns a stream that reports connection type changes for the remote node.
+sourcepub 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.
-sourcepub fn dns_resolver(&self) -> &DnsResolver
Returns the DNS resolver used in this Endpoint.
+sourcepub fn dns_resolver(&self) -> &DnsResolver
Returns the DNS resolver used in this Endpoint.
See Builder::discovery.
-sourcepub fn discovery(&self) -> Option<&dyn Discovery>
Returns the discovery mechanism, if configured.
+sourcepub fn discovery(&self) -> Option<&dyn Discovery>
Returns the discovery mechanism, if configured.
-sourcepub async fn network_change(&self)
Notifies the system of potential network changes.
+sourcepub 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.
-sourcepub 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.
-Trait Implementations§
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§
Trait Implementations§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 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 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
sourcepub fn accept(self) -> Result<Connecting, ConnectionError>
Attempts to accept this incoming connection (an error may still occur).
+Implementations§
source§impl Incoming
sourcepub 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.
-sourcepub fn accept_with(
+
sourcepub fn accept_with(
self,
server_config: Arc<ServerConfig>
) -> Result<Connecting, ConnectionError>
Accepts this incoming connection using a custom configuration.
See accept() for more details.
-sourcepub fn retry(self) -> Result<(), RetryError>
Responds with a retry packet.
+sourcepub 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.
-sourcepub fn ignore(self)
Ignores this incoming connection attempt, not sending any packet in response.
-sourcepub fn local_ip(&self) -> Option<IpAddr>
Returns the local IP address which was used when the peer established the
+
sourcepub fn ignore(self)
Ignores this incoming connection attempt, not sending any packet in response.
+sourcepub fn local_ip(&self) -> Option<IpAddr>
Returns the local IP address which was used when the peer established the
connection.
-sourcepub fn remote_address(&self) -> SocketAddr
Returns the peer’s UDP address.
-sourcepub fn remote_address_validated(&self) -> bool
Whether the socket address that is initiating this connection has been validated.
+sourcepub fn remote_address(&self) -> SocketAddr
Returns the peer’s UDP address.
+sourcepub 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 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 moreAuto Trait Implementations§
§impl !Freeze for Incoming
§impl !RefUnwindSafe for Incoming
§impl Send for Incoming
§impl Sync for Incoming
§impl Unpin for Incoming
§impl !UnwindSafe for Incoming
Blanket Implementations§
Trait Implementations§
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 moreAuto Trait Implementations§
§impl !Freeze for Incoming
§impl !RefUnwindSafe for Incoming
§impl Send for Incoming
§impl Sync for Incoming
§impl Unpin for Incoming
§impl !UnwindSafe for Incoming
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§impl Future for IncomingFuture
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for IncomingFuturewhere
+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§impl Future for IncomingFuture
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for IncomingFuturewhere
PinnedFieldsOf<__IncomingFuture<'pin>>: Unpin,
Auto Trait Implementations§
§impl !Freeze for IncomingFuture
§impl !RefUnwindSafe for IncomingFuture
§impl Send for IncomingFuture
§impl Sync for IncomingFuture
§impl !UnwindSafe for IncomingFuture
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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
§fn poll_write(
+
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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 Expand description
The blake3 hash used in Iroh.
+iroh::hash - Rust
\ 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 moresource§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
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more1.21.0 · source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more1.50.0 · source§fn clamp(self, min: Self, max: Self) -> Selfwhere
@@ -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 widthsource§fn from_bytes<'a>(data: &'a [u8]) -> <Hash as Value>::SelfType<'a>where
+ S: Serializer,
Serialize this value into the given Serde serializer. Read moresource§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 widthsource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: HashThe hash
§format: BlobFormatThe format
-Implementations§
source§impl HashAndFormat
sourcepub fn new(hash: Hash, format: BlobFormat) -> HashAndFormat
Create a new hash and format pair.
-sourcepub fn raw(hash: Hash) -> HashAndFormat
Create a new hash and format pair, using the default (raw) format.
-sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for HashAndFormat
source§impl<'de> Deserialize<'de> for HashAndFormat
source§fn deserialize<D>(
+
Implementations§
source§impl HashAndFormat
sourcepub fn new(hash: Hash, format: BlobFormat) -> HashAndFormat
Create a new hash and format pair.
+sourcepub fn raw(hash: Hash) -> HashAndFormat
Create a new hash and format pair, using the default (raw) format.
+sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for HashAndFormat
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 moresource§impl Display for HashAndFormat
source§impl FromStr for HashAndFormat
source§impl Hash for HashAndFormat
source§impl Display for HashAndFormat
source§impl FromStr for HashAndFormat
source§impl Hash for HashAndFormat
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.source§impl PartialOrd for HashAndFormat
source§fn partial_cmp(&self, other: &HashAndFormat) -> Option<Ordering>
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 moresource§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 moresource§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 widthsource§fn from_bytes<'a>(data: &'a [u8]) -> <HashAndFormat as Value>::SelfType<'a>where
+ S: Serializer,
Serialize this value into the given Serde serializer. Read moresource§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 widthsource§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 typesource§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§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
Peer-to-peer QUIC connections.
+iroh - Rust 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§
pub use endpoint::Endpoint;pub use endpoint::RelayMode;pub use iroh_relay as relay;
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_utils
test or test-utilsInternal 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§
- Options to configure what is included in a
NodeAddr.
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-utilsInternal 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§
- Options to configure what is included in a
NodeAddr.
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 Expand description
Cryptographic key handling for iroh.
+iroh::key - Rust
\ 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.
Trait Implementations§
§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 Copy for Signature
§impl Eq for Signature
§impl StructuralPartialEq for Signature
Auto Trait Implementations§
§impl Freeze for Signature
§impl RefUnwindSafe for Signature
§impl Send for Signature
§impl Sync for Signature
§impl Unpin for Signature
§impl UnwindSafe for Signature
Blanket Implementations§
source§impl<T> Any for Twhere
+ S: Serializer,
Serialize this value into the given Serde serializer. Read more§impl SignatureEncoding for Signature
§impl Copy for Signature
§impl Eq for Signature
§impl StructuralPartialEq for Signature
Auto Trait Implementations§
§impl Freeze for Signature
§impl RefUnwindSafe for Signature
§impl Send for Signature
§impl Sync for Signature
§impl Unpin for Signature
§impl UnwindSafe for Signature
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
Co-locating all of the iroh metrics structs
+iroh::metrics - Rust Expand description
Co-locating all of the iroh metrics structs
Structs§
- Enum of metrics for the module
- Enum of metrics for the module
- Enum of metrics for the module
- RelayMetrics
test-utilsMetrics tracked for the relay server
\ 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: CounterNumber of nodes we have managed to contact directly.
§connection_handshake_success: CounterNumber of connections with a successful handshake.
§connection_became_direct: CounterNumber of connections with a successful handshake that became direct.
-Trait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
Access to this metrics group to record a metric.
+Trait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterTrait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
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: CounterTrait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterTrait Implementations§
§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
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: CounterTrait Implementations§
§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterNumber of unique client keys per day
§websocket_accepts: CounterNumber of accepted websocket connections
§derp_accepts: CounterNumber of accepted ‘iroh derp http’ connection upgrades
-Trait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
Access to this metrics group to record a metric.
+Trait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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().
sourcepub 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.
-sourcepub fn to_file_path(&self) -> Result<PathBuf, ()>
Assuming the URL is in the file scheme or similar,
+
sourcepub 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.
\ 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.
\ 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§
- A drop guard to clean up test infrastructure.
- Handle and drop guard for test DNS and Pkarr servers.
Functions§
- Create a DNS resolver with a single nameserver.
- Runs a relay server with STUN and QUIC enabled suitable for tests.
- Runs a relay server.
- Runs a relay server with STUN enabled suitable for tests.
\ 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§
Auto Trait Implementations§
§impl Freeze for CleanupDropGuard
§impl !RefUnwindSafe for CleanupDropGuard
§impl Send for CleanupDropGuard
§impl Sync for CleanupDropGuard
§impl Unpin for CleanupDropGuard
§impl !UnwindSafe for CleanupDropGuard
Blanket Implementations§
source§impl<T> Any for Twhere
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: StringThe node origin domain.
§nameserver: SocketAddrThe 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
impl<T> Any for Twhere
+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§
Trait Implementations§
source§impl Clone for PkarrRelayClient
source§fn clone(&self) -> PkarrRelayClient
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for PkarrRelayClient
§impl !RefUnwindSafe for PkarrRelayClient
§impl Send for PkarrRelayClient
§impl Sync for PkarrRelayClient
§impl Unpin for PkarrRelayClient
§impl !UnwindSafe for PkarrRelayClient
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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
sourcepub fn new(pkarr_relay: Url) -> Self
Creates a new publisher using the pkarr relay server at the URL.
-Implementations§
source§impl PkarrResolver
sourcepub fn new(pkarr_relay: Url) -> Self
Creates a new publisher using the pkarr relay server at the URL.
+sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for PkarrResolver
Trait Implementations§
source§impl Clone for PkarrResolver
source§fn clone(&self) -> PkarrResolver
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for PkarrResolver
Auto Trait Implementations§
§impl Freeze for PkarrResolver
§impl !RefUnwindSafe for PkarrResolver
§impl Send for PkarrResolver
§impl Sync for PkarrResolver
§impl Unpin for PkarrResolver
§impl !UnwindSafe for PkarrResolver
Blanket Implementations§
Auto Trait Implementations§
§impl Freeze for PkarrResolver
§impl !RefUnwindSafe for PkarrResolver
§impl Send for PkarrResolver
§impl Sync for PkarrResolver
§impl Unpin for PkarrResolver
§impl !UnwindSafe for PkarrResolver
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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>>>
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§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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
sourcepub fn empty() -> Self
Creates an empty ConcurrentDiscovery.
-sourcepub fn from_services(services: Vec<Box<dyn Discovery>>) -> Self
Creates a new ConcurrentDiscovery.
-Trait Implementations§
source§impl Debug for ConcurrentDiscovery
source§impl Default for ConcurrentDiscovery
source§fn default() -> ConcurrentDiscovery
Returns the “default value” for a type. Read moresource§impl Discovery for ConcurrentDiscovery
Implementations§
source§impl ConcurrentDiscovery
sourcepub fn empty() -> Self
Creates an empty ConcurrentDiscovery.
+sourcepub fn from_services(services: Vec<Box<dyn Discovery>>) -> Self
Creates a new ConcurrentDiscovery.
+Trait Implementations§
source§impl Debug for ConcurrentDiscovery
source§impl Default for ConcurrentDiscovery
source§fn default() -> ConcurrentDiscovery
Returns the “default value” for a type. Read moresource§impl Discovery for ConcurrentDiscovery
source§impl<T> From<T> for ConcurrentDiscovery
Auto Trait Implementations§
§impl Freeze for ConcurrentDiscovery
§impl !RefUnwindSafe for ConcurrentDiscovery
§impl Send for ConcurrentDiscovery
§impl Sync for ConcurrentDiscovery
§impl Unpin for ConcurrentDiscovery
§impl !UnwindSafe for ConcurrentDiscovery
Blanket Implementations§
source§impl<T> From<T> for ConcurrentDiscovery
Auto Trait Implementations§
§impl Freeze for ConcurrentDiscovery
§impl !RefUnwindSafe for ConcurrentDiscovery
§impl Send for ConcurrentDiscovery
§impl Sync for ConcurrentDiscovery
§impl Unpin for ConcurrentDiscovery
§impl !UnwindSafe for ConcurrentDiscovery
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for DiscoveryItem
§impl RefUnwindSafe for DiscoveryItem
§impl Send for DiscoveryItem
§impl Sync for DiscoveryItem
§impl Unpin for DiscoveryItem
§impl UnwindSafe for DiscoveryItem
Blanket Implementations§
source§impl<T> Any for Twhere
+Trait Implementations§
source§impl Clone for DiscoveryItem
source§fn clone(&self) -> DiscoveryItem
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for DiscoveryItem
§impl RefUnwindSafe for DiscoveryItem
§impl Send for DiscoveryItem
§impl Sync for DiscoveryItem
§impl Unpin for DiscoveryItem
§impl UnwindSafe for DiscoveryItem
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 pub trait Discovery: Debug + Send + Sync {
+Discovery in iroh::discovery - Rust 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§
sourcefn publish(&self, _url: Option<&RelayUrl>, _addrs: &BTreeSet<SocketAddr>)
Publishes the given RelayUrl and direct addreesses to the discovery mechanism.
+Provided Methods§
sourcefn 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.
-sourcefn 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.
-sourcefn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>
Subscribe to all addresses that get passively discovered.
+sourcefn 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddrType
source§impl Display for DirectAddrType
source§impl Hash for DirectAddrType
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddrType
source§impl Display for DirectAddrType
source§impl Hash for DirectAddrType
source§impl Ord for DirectAddrType
source§impl Ord for DirectAddrType
source§fn cmp(&self, other: &DirectAddrType) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read moresource§impl PartialEq for DirectAddrType
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 ==.source§impl PartialOrd for DirectAddrType
source§impl PartialOrd for DirectAddrType
source§fn partial_cmp(&self, other: &DirectAddrType) -> Option<Ordering>
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 moresource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 pub enum RelayMode {
+RelayMode in iroh::endpoint - Rust 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§
Trait Implementations§
source§impl PartialEq for RelayMode
Implementations§
Trait Implementations§
source§impl PartialEq for RelayMode
source§impl Eq for RelayMode
source§impl StructuralPartialEq for RelayMode
Auto Trait Implementations§
§impl Freeze for RelayMode
§impl RefUnwindSafe for RelayMode
§impl Send for RelayMode
§impl Sync for RelayMode
§impl Unpin for RelayMode
§impl UnwindSafe for RelayMode
Blanket Implementations§
source§impl Eq for RelayMode
source§impl StructuralPartialEq for RelayMode
Auto Trait Implementations§
§impl Freeze for RelayMode
§impl RefUnwindSafe for RelayMode
§impl Send for RelayMode
§impl Sync for RelayMode
§impl Unpin for RelayMode
§impl UnwindSafe for RelayMode
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
The Endpoint allows establishing connections to other iroh nodes.
+iroh::endpoint - Rust 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§
- Future produced by
Endpoint::accept. - Future produced by
Connection::accept_bi - Future produced by
Connection::accept_uni - Parameters for controlling the peer’s acknowledgement frequency
- Reason given by an application for closing the connection
- Builder for
Endpoint. - A cheaply cloneable and sliceable chunk of contiguous memory.
- A chunk of data from the receive stream
- Error indicating that a stream has not been opened or has already been finished or reset
- In-progress connection attempt future
- A QUIC connection.
- Reason given by the transport for closing the connection
- Connection statistics
- Stream returning
ConnectionTypes - Generic crypto errors
- A direct address on which an iroh-node might be contactable.
- Information about a direct address.
- Stream returning local endpoints as they change.
- Controls an iroh node, establishing connections with other nodes.
- Error returned by [Session::export_keying_material].
- Number of frames transmitted of each frame type
- An incoming connection for which the server has not yet begun its parts of the
handshake.
- Parameters governing MTU discovery.
- Network-level addressing information for an iroh node.
- Future produced by
Connection::open_bi - Future produced by
Connection::open_uni - Statistics related to a transmission path
- Future produced by
Connection::read_datagram - A stream that can only be used to receive data
- Details about a remote iroh node which is known to this node.
- Error for attempting to retry an [
Incoming] which already bears an address
validation token from a previous retry - A stream that can only be used to send data
- Parameters governing incoming connections
- Identifier for a stream within a particular connection
- Parameters governing the core QUIC state machine
- Transport-level errors occur when a peer violates the protocol specification
- Transport-level error code
- Statistics about UDP datagrams transmitted or received on a connection
- Error indicating that the specified QUIC version is not supported
- An integer less than 2^62
- A handle to some connection internals, use with care.
- Indicates how many bytes and chunks had been transferred in a write operation
- Future that completes when a connection is fully established
Enums§
- Options to configure what is included in a
NodeAddr. - Reasons why a connection might be lost
- The type of connection we have to the endpoint.
- The type of control message we have received.
- The type of direct address.
- Errors that arise from reading from a stream.
- Errors that arise from reading from a stream.
- Errors from
RecvStream::read_to_end - Configuration of the relay servers for an
Endpoint. - Errors that arise while waiting for a stream to be reset
- Errors that can arise when sending a datagram
- The origin or source through which an address associated with a remote node
-was discovered.
- Errors that arise while monitoring for a send stream stop from the peer
- Errors that arise from writing to a stream
Constants§
- ENV_FORCE_STAGING_RELAYSNon-
testEnvironment variable to force the use of staging relays.
Traits§
- A key for sealing data with AEAD-based algorithms
- Common interface for different congestion controllers
- Constructs controllers on demand
- Server-side configuration for the crypto protocol
- A pseudo random key for HKDF
Functions§
- Returns the default relay mode.
- Returns
true if the use of staging relays is forced. - Extract the
PublicKey from the peer’s TLS certificate. - Creates a
ServerConfig with the given secret key and limits.
\ 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§
- Environment variable to force the use of staging relays.
Traits§
- A key for sealing data with AEAD-based algorithms
- Common interface for different congestion controllers
- Constructs controllers on demand
- Server-side configuration for the crypto protocol
- A pseudo random key for HKDF
Functions§
- Returns the default relay mode.
- Returns
true if the use of staging relays is forced. - Extract the
PublicKey from the peer’s TLS certificate. - Creates a
ServerConfig with the given secret key and limits.
\ 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 pub struct Accept<'a> { /* private fields */ }
Expand description
Future produced by Endpoint::accept.
-Trait Implementations§
source§impl<'pin, 'a> Unpin for Accept<'a>where
+Accept in iroh::endpoint - Rust pub struct Accept<'a> { /* private fields */ }
Expand description
Future produced by Endpoint::accept.
+Trait Implementations§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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>,§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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 pub struct Builder { /* private fields */ }
Expand description
Builder for Endpoint.
+Builder in iroh::endpoint - Rust 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
sourcepub fn bind_addr_v4(self, addr: SocketAddrV4) -> Self
Sets the IPv4 bind address.
+Implementations§
source§impl Builder
sourcepub 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.
-sourcepub fn bind_addr_v6(self, addr: SocketAddrV6) -> Self
Sets the IPv6 bind address.
+sourcepub 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.
-sourcepub fn secret_key(self, secret_key: SecretKey) -> Self
Sets a secret key to authenticate with other peers.
+sourcepub fn secret_key(self, secret_key: SecretKey) -> Self
sourcepub fn alpns(self, alpn_protocols: Vec<Vec<u8>>) -> Self
Sets the ALPN protocols that this endpoint will accept on incoming connections.
+sourcepub fn relay_mode(self, relay_mode: RelayMode) -> Self
Sets the relay servers to assist in establishing connectivity.
+sourcepub 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.
-sourcepub fn clear_discovery(self) -> Self
Removes all discovery services from the builder.
-sourcepub fn discovery(self, discovery: Box<dyn Discovery>) -> Self
Optionally sets a discovery mechanism for this endpoint.
+sourcepub fn clear_discovery(self) -> Self
Removes all discovery services from the builder.
+sourcepub 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.
-sourcepub fn add_discovery<F, D>(self, discovery: F) -> Selfwhere
+
sourcepub fn add_discovery<F, D>(self, discovery: F) -> Self
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.
-sourcepub fn discovery_n0(self) -> Self
Configures the endpoint to use the default n0 DNS discovery service.
+sourcepub 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.
-sourcepub 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.
+sourcepub 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.
-sourcepub fn discovery_local_network(self) -> Self
Available on crate feature discovery-local-network only.
Configures the endpoint to also use local network discovery.
+sourcepub 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.
-sourcepub fn known_nodes(self, nodes: Vec<NodeAddr>) -> Self
Optionally set a list of known nodes.
-sourcepub fn transport_config(self, transport_config: TransportConfig) -> Self
Sets a custom quinn::TransportConfig for this endpoint.
+sourcepub fn known_nodes(self, nodes: Vec<NodeAddr>) -> Self
Optionally set a list of known nodes.
+sourcepub 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.
-sourcepub fn dns_resolver(self, dns_resolver: DnsResolver) -> Self
Optionally sets a custom DNS resolver to use for this endpoint.
+sourcepub 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.
-sourcepub fn proxy_url(self, url: Url) -> Self
Sets an explicit proxy url to proxy all HTTP(S) traffic through.
-sourcepub fn proxy_from_env(self) -> Self
Sets the proxy url from the environment, in this order:
+sourcepub fn proxy_url(self, url: Url) -> Self
Sets an explicit proxy url to proxy all HTTP(S) traffic through.
+sourcepub fn proxy_from_env(self) -> Self
Sets the proxy url from the environment, in this order:
HTTP_PROXY
http_proxy
HTTPS_PROXY
https_proxy
-sourcepub fn keylog(self, keylog: bool) -> Self
Enables saving the TLS pre-master key for connections.
+sourcepub 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.
-sourcepub 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
+sourcepub 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§
Auto Trait Implementations§
§impl !Freeze for Builder
§impl !RefUnwindSafe for Builder
§impl Send for Builder
§impl Sync for Builder
§impl Unpin for Builder
§impl !UnwindSafe for Builder
Blanket Implementations§
Trait Implementations§
Auto Trait Implementations§
§impl !Freeze for Builder
§impl !RefUnwindSafe for Builder
§impl Send for Builder
§impl Sync for Builder
§impl Unpin for Builder
§impl !UnwindSafe for Builder
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§
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 · sourcepub fn to_ascii_uppercase(&self) -> Vec<u8> ⓘ
Returns a vector containing a copy of this slice where each byte
+
1.23.0 · sourcepub 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 · sourcepub fn to_ascii_lowercase(&self) -> Vec<u8> ⓘ
Returns a vector containing a copy of this slice where each byte
+
1.23.0 · sourcepub 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 · sourcepub 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.
sourcepub fn to_vec_in<A>(&self, alloc: A) -> Vec<T, A>
🔬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 · sourcepub 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.§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 copy_to_bytes(&mut self, len: usize) -> Bytes
§fn chunks_vectored<'a>(&'a self, dst: &mut [IoSlice<'a>]) -> usize
§fn chunks_vectored<'a>(&'a self, dst: &mut [IoSlice<'a>]) -> usize
Available on crate feature std only.§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])
§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 moreSized,§impl FromIterator<u8> for Bytes
§impl FromIterator<u8> for Bytes
§impl<S> FromRequest<S> for Bytes
§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 Hwhere
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>
§fn in_current_span(self) -> Instrumented<Self>
source§impl<T, U> Into<U> for Twhere
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
sourcepub fn into_0rtt(self) -> Result<(Connection, ZeroRttAccepted), Self>
Convert into a 0-RTT or 0.5-RTT connection at the cost of weakened security.
-sourcepub async fn handshake_data(&mut self) -> Result<Box<dyn Any>, ConnectionError>
Parameters negotiated during the handshake
-sourcepub fn local_ip(&self) -> Option<IpAddr>
The local IP address which was used when the peer established the connection.
-sourcepub fn remote_address(&self) -> SocketAddr
The peer’s UDP address.
-Trait Implementations§
source§impl Debug for Connecting
source§impl Future for Connecting
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for Connectingwhere
+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
sourcepub fn into_0rtt(self) -> Result<(Connection, ZeroRttAccepted), Self>
Convert into a 0-RTT or 0.5-RTT connection at the cost of weakened security.
+sourcepub async fn handshake_data(&mut self) -> Result<Box<dyn Any>, ConnectionError>
Parameters negotiated during the handshake
+sourcepub fn local_ip(&self) -> Option<IpAddr>
The local IP address which was used when the peer established the connection.
+sourcepub fn remote_address(&self) -> SocketAddr
The peer’s UDP address.
+Trait Implementations§
source§impl Debug for Connecting
source§impl Future for Connecting
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for Connectingwhere
PinnedFieldsOf<__Connecting<'pin>>: Unpin,
Auto Trait Implementations§
§impl Freeze for Connecting
§impl !RefUnwindSafe for Connecting
§impl Send for Connecting
§impl Sync for Connecting
§impl !UnwindSafe for Connecting
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§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§impl<S> StreamExt for Swhere
+ 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§impl<S> StreamExt for Swhere
S: Stream + ?Sized,
Sized,
S: Stream<Item = Self::Item>,
§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§impl<S1> StreamExt for S1where
+ 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 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 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 moreRead 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§impl<T> StreamExt for Twhere
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, ()>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>
) -> FlatMapUnordered<Self, U, F>
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 moreRuns 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 moreSized,
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 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>>
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>>
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>
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>
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>,
Available on crate features sink and alloc only.§fn inspect<F>(self, f: F) -> Inspect<Self, F>
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: SocketAddrThe address.
§typ: DirectAddrTypeThe origin of this direct address.
-Trait Implementations§
source§impl Clone for DirectAddr
source§fn clone(&self) -> DirectAddr
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddr
source§impl Hash for DirectAddr
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddr
source§impl Hash for DirectAddr
source§impl Ord for DirectAddr
source§impl Ord for DirectAddr
source§fn cmp(&self, other: &DirectAddr) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read moresource§impl PartialEq for DirectAddr
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 ==.source§impl PartialOrd for DirectAddr
source§impl PartialOrd for DirectAddr
source§fn partial_cmp(&self, other: &DirectAddr) -> Option<Ordering>
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 moresource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§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§impl Stream for DirectAddrsStream
Sized,
S: Stream<Item = Self::Item>,§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
§impl<S> StreamExt for Swhere
+ 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§impl<S> StreamExt for Swhere
S: Stream + ?Sized,
Sized,
S: Stream<Item = Self::Item>,§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§impl<S1> StreamExt for S1where
+ 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 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 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 moreRead 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
§impl<T> StreamExt for Twhere
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, ()>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>
) -> FlatMapUnordered<Self, U, F>
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 moreRuns 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 moreSized,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 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>>
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>>
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>
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>
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>,
Available on crate features sink and alloc only.§fn inspect<F>(self, f: F) -> Inspect<Self, F>
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 pub struct Endpoint { /* private fields */ }
Expand description
Controls an iroh node, establishing connections with other nodes.
+Endpoint in iroh::endpoint - Rust 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
sourcepub fn builder() -> Builder
Returns the builder for an Endpoint, with a production configuration.
-sourcepub fn set_alpns(&self, alpns: Vec<Vec<u8>>) -> Result<()>
Sets the list of accepted ALPN protocols.
+Implementations§
source§impl Endpoint
sourcepub fn builder() -> Builder
Returns the builder for an Endpoint, with a production configuration.
+sourcepub 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.
-
sourcepub 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.
-sourcepub fn add_node_addr(&self, node_addr: NodeAddr) -> Result<()>
Informs this Endpoint about addresses of the iroh node.
+sourcepub 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.
-sourcepub fn add_node_addr_with_source(
+
sourcepub fn secret_key(&self) -> &SecretKey
Returns the secret_key of this endpoint.
-sourcepub fn secret_key(&self) -> &SecretKey
Returns the secret_key of this endpoint.
+sourcepub 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.
-sourcepub async fn node_addr(&self) -> Result<NodeAddr>
Returns the current NodeAddr for this endpoint.
+sourcepub 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.
-sourcepub fn home_relay(&self) -> Option<RelayUrl>
Returns the RelayUrl of the Relay server used as home relay.
+sourcepub 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.
-sourcepub fn watch_home_relay(&self) -> impl Stream<Item = RelayUrl>
Watches for changes to the home relay.
+sourcepub 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.
-sourcepub fn direct_addresses(&self) -> DirectAddrsStream
Returns the direct addresses of this Endpoint.
+sourcepub 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;
-sourcepub fn bound_sockets(&self) -> (SocketAddr, Option<SocketAddr>)
Returns the local socket addresses on which the underlying sockets are bound.
+sourcepub 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.
-sourcepub fn remote_info(&self, node_id: NodeId) -> Option<RemoteInfo>
Returns information about the remote node identified by a NodeId.
+sourcepub 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.
-sourcepub fn remote_info_iter(&self) -> impl Iterator<Item = RemoteInfo>
Returns information about all the remote nodes this Endpoint knows about.
+sourcepub 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.
-sourcepub fn conn_type_stream(&self, node_id: NodeId) -> Result<ConnectionTypeStream>
Returns a stream that reports connection type changes for the remote node.
+sourcepub 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.
-sourcepub fn dns_resolver(&self) -> &DnsResolver
Returns the DNS resolver used in this Endpoint.
+sourcepub fn dns_resolver(&self) -> &DnsResolver
Returns the DNS resolver used in this Endpoint.
See Builder::discovery.
-sourcepub fn discovery(&self) -> Option<&dyn Discovery>
Returns the discovery mechanism, if configured.
+sourcepub fn discovery(&self) -> Option<&dyn Discovery>
Returns the discovery mechanism, if configured.
-sourcepub async fn network_change(&self)
Notifies the system of potential network changes.
+sourcepub 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.
-sourcepub 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.
-Trait Implementations§
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§
Trait Implementations§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 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 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
sourcepub fn accept(self) -> Result<Connecting, ConnectionError>
Attempts to accept this incoming connection (an error may still occur).
+Implementations§
source§impl Incoming
sourcepub 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.
-sourcepub fn accept_with(
+
sourcepub fn accept_with(
self,
server_config: Arc<ServerConfig>
) -> Result<Connecting, ConnectionError>
Accepts this incoming connection using a custom configuration.
See accept() for more details.
-sourcepub fn retry(self) -> Result<(), RetryError>
Responds with a retry packet.
+sourcepub 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.
-sourcepub fn ignore(self)
Ignores this incoming connection attempt, not sending any packet in response.
-sourcepub fn local_ip(&self) -> Option<IpAddr>
Returns the local IP address which was used when the peer established the
+
sourcepub fn ignore(self)
Ignores this incoming connection attempt, not sending any packet in response.
+sourcepub fn local_ip(&self) -> Option<IpAddr>
Returns the local IP address which was used when the peer established the
connection.
-sourcepub fn remote_address(&self) -> SocketAddr
Returns the peer’s UDP address.
-sourcepub fn remote_address_validated(&self) -> bool
Whether the socket address that is initiating this connection has been validated.
+sourcepub fn remote_address(&self) -> SocketAddr
Returns the peer’s UDP address.
+sourcepub 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 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 moreAuto Trait Implementations§
§impl !Freeze for Incoming
§impl !RefUnwindSafe for Incoming
§impl Send for Incoming
§impl Sync for Incoming
§impl Unpin for Incoming
§impl !UnwindSafe for Incoming
Blanket Implementations§
Trait Implementations§
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 moreAuto Trait Implementations§
§impl !Freeze for Incoming
§impl !RefUnwindSafe for Incoming
§impl Send for Incoming
§impl Sync for Incoming
§impl Unpin for Incoming
§impl !UnwindSafe for Incoming
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§impl Future for IncomingFuture
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for IncomingFuturewhere
+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§impl Future for IncomingFuture
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for IncomingFuturewhere
PinnedFieldsOf<__IncomingFuture<'pin>>: Unpin,
Auto Trait Implementations§
§impl !Freeze for IncomingFuture
§impl !RefUnwindSafe for IncomingFuture
§impl Send for IncomingFuture
§impl Sync for IncomingFuture
§impl !UnwindSafe for IncomingFuture
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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
§fn poll_write(
+
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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 Expand description
The blake3 hash used in Iroh.
+iroh::hash - Rust
\ 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 moresource§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
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more1.21.0 · source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more1.50.0 · source§fn clamp(self, min: Self, max: Self) -> Selfwhere
@@ -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 widthsource§fn from_bytes<'a>(data: &'a [u8]) -> <Hash as Value>::SelfType<'a>where
+ S: Serializer,
Serialize this value into the given Serde serializer. Read moresource§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 widthsource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: HashThe hash
§format: BlobFormatThe format
-Implementations§
source§impl HashAndFormat
sourcepub fn new(hash: Hash, format: BlobFormat) -> HashAndFormat
Create a new hash and format pair.
-sourcepub fn raw(hash: Hash) -> HashAndFormat
Create a new hash and format pair, using the default (raw) format.
-sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for HashAndFormat
source§impl<'de> Deserialize<'de> for HashAndFormat
source§fn deserialize<D>(
+
Implementations§
source§impl HashAndFormat
sourcepub fn new(hash: Hash, format: BlobFormat) -> HashAndFormat
Create a new hash and format pair.
+sourcepub fn raw(hash: Hash) -> HashAndFormat
Create a new hash and format pair, using the default (raw) format.
+sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for HashAndFormat
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 moresource§impl Display for HashAndFormat
source§impl FromStr for HashAndFormat
source§impl Hash for HashAndFormat
source§impl Display for HashAndFormat
source§impl FromStr for HashAndFormat
source§impl Hash for HashAndFormat
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.source§impl PartialOrd for HashAndFormat
source§fn partial_cmp(&self, other: &HashAndFormat) -> Option<Ordering>
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 moresource§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 moresource§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 widthsource§fn from_bytes<'a>(data: &'a [u8]) -> <HashAndFormat as Value>::SelfType<'a>where
+ S: Serializer,
Serialize this value into the given Serde serializer. Read moresource§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 widthsource§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 typesource§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§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
Peer-to-peer QUIC connections.
+iroh - Rust 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§
pub use endpoint::Endpoint;pub use endpoint::RelayMode;pub use iroh_relay as relay;
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_utils
test or test-utilsInternal 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§
- Options to configure what is included in a
NodeAddr.
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-utilsInternal 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§
- Options to configure what is included in a
NodeAddr.
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 Expand description
Cryptographic key handling for iroh.
+iroh::key - Rust
\ 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.
Trait Implementations§
§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 Copy for Signature
§impl Eq for Signature
§impl StructuralPartialEq for Signature
Auto Trait Implementations§
§impl Freeze for Signature
§impl RefUnwindSafe for Signature
§impl Send for Signature
§impl Sync for Signature
§impl Unpin for Signature
§impl UnwindSafe for Signature
Blanket Implementations§
source§impl<T> Any for Twhere
+ S: Serializer,
Serialize this value into the given Serde serializer. Read more§impl SignatureEncoding for Signature
§impl Copy for Signature
§impl Eq for Signature
§impl StructuralPartialEq for Signature
Auto Trait Implementations§
§impl Freeze for Signature
§impl RefUnwindSafe for Signature
§impl Send for Signature
§impl Sync for Signature
§impl Unpin for Signature
§impl UnwindSafe for Signature
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
Co-locating all of the iroh metrics structs
+iroh::metrics - Rust Expand description
Co-locating all of the iroh metrics structs
Structs§
- Enum of metrics for the module
- Enum of metrics for the module
- Enum of metrics for the module
- RelayMetrics
test-utilsMetrics tracked for the relay server
\ 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: CounterNumber of nodes we have managed to contact directly.
§connection_handshake_success: CounterNumber of connections with a successful handshake.
§connection_became_direct: CounterNumber of connections with a successful handshake that became direct.
-Trait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
Access to this metrics group to record a metric.
+Trait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterTrait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
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: CounterTrait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterTrait Implementations§
§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
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: CounterTrait Implementations§
§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterNumber of unique client keys per day
§websocket_accepts: CounterNumber of accepted websocket connections
§derp_accepts: CounterNumber of accepted ‘iroh derp http’ connection upgrades
-Trait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
Access to this metrics group to record a metric.
+Trait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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().
sourcepub 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.
-sourcepub fn to_file_path(&self) -> Result<PathBuf, ()>
Assuming the URL is in the file scheme or similar,
+
sourcepub 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.
\ 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.
\ 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§
- A drop guard to clean up test infrastructure.
- Handle and drop guard for test DNS and Pkarr servers.
Functions§
- Create a DNS resolver with a single nameserver.
- Runs a relay server with STUN and QUIC enabled suitable for tests.
- Runs a relay server.
- Runs a relay server with STUN enabled suitable for tests.
\ 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§
Auto Trait Implementations§
§impl Freeze for CleanupDropGuard
§impl !RefUnwindSafe for CleanupDropGuard
§impl Send for CleanupDropGuard
§impl Sync for CleanupDropGuard
§impl Unpin for CleanupDropGuard
§impl !UnwindSafe for CleanupDropGuard
Blanket Implementations§
source§impl<T> Any for Twhere
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: StringThe node origin domain.
§nameserver: SocketAddrThe 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
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§
Trait Implementations§
source§impl Clone for PkarrRelayClient
impl Clone for PkarrRelayClient
source§fn clone(&self) -> PkarrRelayClient
fn clone(&self) -> PkarrRelayClient
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl Freeze for PkarrRelayClient
impl !RefUnwindSafe for PkarrRelayClient
impl Send for PkarrRelayClient
impl Sync for PkarrRelayClient
impl Unpin for PkarrRelayClient
impl !UnwindSafe for PkarrRelayClient
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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
sourcepub fn new(pkarr_relay: Url) -> Self
Creates a new publisher using the pkarr relay server at the URL.
-Implementations§
source§impl PkarrResolver
sourcepub fn new(pkarr_relay: Url) -> Self
Creates a new publisher using the pkarr relay server at the URL.
+sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for PkarrResolver
Trait Implementations§
source§impl Clone for PkarrResolver
source§fn clone(&self) -> PkarrResolver
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for PkarrResolver
Auto Trait Implementations§
§impl Freeze for PkarrResolver
§impl !RefUnwindSafe for PkarrResolver
§impl Send for PkarrResolver
§impl Sync for PkarrResolver
§impl Unpin for PkarrResolver
§impl !UnwindSafe for PkarrResolver
Blanket Implementations§
Auto Trait Implementations§
§impl Freeze for PkarrResolver
§impl !RefUnwindSafe for PkarrResolver
§impl Send for PkarrResolver
§impl Sync for PkarrResolver
§impl Unpin for PkarrResolver
§impl !UnwindSafe for PkarrResolver
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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>>>
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§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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
sourcepub fn empty() -> Self
Creates an empty ConcurrentDiscovery.
-sourcepub fn from_services(services: Vec<Box<dyn Discovery>>) -> Self
Creates a new ConcurrentDiscovery.
-Trait Implementations§
source§impl Debug for ConcurrentDiscovery
source§impl Default for ConcurrentDiscovery
source§fn default() -> ConcurrentDiscovery
Returns the “default value” for a type. Read moresource§impl Discovery for ConcurrentDiscovery
Implementations§
source§impl ConcurrentDiscovery
sourcepub fn empty() -> Self
Creates an empty ConcurrentDiscovery.
+sourcepub fn from_services(services: Vec<Box<dyn Discovery>>) -> Self
Creates a new ConcurrentDiscovery.
+Trait Implementations§
source§impl Debug for ConcurrentDiscovery
source§impl Default for ConcurrentDiscovery
source§fn default() -> ConcurrentDiscovery
Returns the “default value” for a type. Read moresource§impl Discovery for ConcurrentDiscovery
source§impl<T> From<T> for ConcurrentDiscovery
Auto Trait Implementations§
§impl Freeze for ConcurrentDiscovery
§impl !RefUnwindSafe for ConcurrentDiscovery
§impl Send for ConcurrentDiscovery
§impl Sync for ConcurrentDiscovery
§impl Unpin for ConcurrentDiscovery
§impl !UnwindSafe for ConcurrentDiscovery
Blanket Implementations§
source§impl<T> From<T> for ConcurrentDiscovery
Auto Trait Implementations§
§impl Freeze for ConcurrentDiscovery
§impl !RefUnwindSafe for ConcurrentDiscovery
§impl Send for ConcurrentDiscovery
§impl Sync for ConcurrentDiscovery
§impl Unpin for ConcurrentDiscovery
§impl !UnwindSafe for ConcurrentDiscovery
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for DiscoveryItem
§impl RefUnwindSafe for DiscoveryItem
§impl Send for DiscoveryItem
§impl Sync for DiscoveryItem
§impl Unpin for DiscoveryItem
§impl UnwindSafe for DiscoveryItem
Blanket Implementations§
source§impl<T> Any for Twhere
+Trait Implementations§
source§impl Clone for DiscoveryItem
source§fn clone(&self) -> DiscoveryItem
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for DiscoveryItem
§impl RefUnwindSafe for DiscoveryItem
§impl Send for DiscoveryItem
§impl Sync for DiscoveryItem
§impl Unpin for DiscoveryItem
§impl UnwindSafe for DiscoveryItem
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 pub trait Discovery: Debug + Send + Sync {
+Discovery in iroh::discovery - Rust 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§
sourcefn publish(&self, _url: Option<&RelayUrl>, _addrs: &BTreeSet<SocketAddr>)
Publishes the given RelayUrl and direct addreesses to the discovery mechanism.
+Provided Methods§
sourcefn 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.
-sourcefn 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.
-sourcefn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>
Subscribe to all addresses that get passively discovered.
+sourcefn 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddrType
source§impl Display for DirectAddrType
source§impl Hash for DirectAddrType
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddrType
source§impl Display for DirectAddrType
source§impl Hash for DirectAddrType
source§impl Ord for DirectAddrType
source§impl Ord for DirectAddrType
source§fn cmp(&self, other: &DirectAddrType) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read moresource§impl PartialEq for DirectAddrType
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 ==.source§impl PartialOrd for DirectAddrType
source§impl PartialOrd for DirectAddrType
source§fn partial_cmp(&self, other: &DirectAddrType) -> Option<Ordering>
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 moresource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 pub enum RelayMode {
+RelayMode in iroh::endpoint - Rust 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§
Trait Implementations§
source§impl PartialEq for RelayMode
Implementations§
Trait Implementations§
source§impl PartialEq for RelayMode
source§impl Eq for RelayMode
source§impl StructuralPartialEq for RelayMode
Auto Trait Implementations§
§impl Freeze for RelayMode
§impl RefUnwindSafe for RelayMode
§impl Send for RelayMode
§impl Sync for RelayMode
§impl Unpin for RelayMode
§impl UnwindSafe for RelayMode
Blanket Implementations§
source§impl Eq for RelayMode
source§impl StructuralPartialEq for RelayMode
Auto Trait Implementations§
§impl Freeze for RelayMode
§impl RefUnwindSafe for RelayMode
§impl Send for RelayMode
§impl Sync for RelayMode
§impl Unpin for RelayMode
§impl UnwindSafe for RelayMode
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
The Endpoint allows establishing connections to other iroh nodes.
+iroh::endpoint - Rust 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§
- Future produced by
Endpoint::accept. - Future produced by
Connection::accept_bi - Future produced by
Connection::accept_uni - Parameters for controlling the peer’s acknowledgement frequency
- Reason given by an application for closing the connection
- Builder for
Endpoint. - A cheaply cloneable and sliceable chunk of contiguous memory.
- A chunk of data from the receive stream
- Error indicating that a stream has not been opened or has already been finished or reset
- In-progress connection attempt future
- A QUIC connection.
- Reason given by the transport for closing the connection
- Connection statistics
- Stream returning
ConnectionTypes - Generic crypto errors
- A direct address on which an iroh-node might be contactable.
- Information about a direct address.
- Stream returning local endpoints as they change.
- Controls an iroh node, establishing connections with other nodes.
- Error returned by [Session::export_keying_material].
- Number of frames transmitted of each frame type
- An incoming connection for which the server has not yet begun its parts of the
handshake.
- Parameters governing MTU discovery.
- Network-level addressing information for an iroh node.
- Future produced by
Connection::open_bi - Future produced by
Connection::open_uni - Statistics related to a transmission path
- Future produced by
Connection::read_datagram - A stream that can only be used to receive data
- Details about a remote iroh node which is known to this node.
- Error for attempting to retry an [
Incoming] which already bears an address
validation token from a previous retry - A stream that can only be used to send data
- Parameters governing incoming connections
- Identifier for a stream within a particular connection
- Parameters governing the core QUIC state machine
- Transport-level errors occur when a peer violates the protocol specification
- Transport-level error code
- Statistics about UDP datagrams transmitted or received on a connection
- Error indicating that the specified QUIC version is not supported
- An integer less than 2^62
- A handle to some connection internals, use with care.
- Indicates how many bytes and chunks had been transferred in a write operation
- Future that completes when a connection is fully established
Enums§
- Options to configure what is included in a
NodeAddr. - Reasons why a connection might be lost
- The type of connection we have to the endpoint.
- The type of control message we have received.
- The type of direct address.
- Errors that arise from reading from a stream.
- Errors that arise from reading from a stream.
- Errors from
RecvStream::read_to_end - Configuration of the relay servers for an
Endpoint. - Errors that arise while waiting for a stream to be reset
- Errors that can arise when sending a datagram
- The origin or source through which an address associated with a remote node
-was discovered.
- Errors that arise while monitoring for a send stream stop from the peer
- Errors that arise from writing to a stream
Constants§
- ENV_FORCE_STAGING_RELAYSNon-
testEnvironment variable to force the use of staging relays.
Traits§
- A key for sealing data with AEAD-based algorithms
- Common interface for different congestion controllers
- Constructs controllers on demand
- Server-side configuration for the crypto protocol
- A pseudo random key for HKDF
Functions§
- Returns the default relay mode.
- Returns
true if the use of staging relays is forced. - Extract the
PublicKey from the peer’s TLS certificate. - Creates a
ServerConfig with the given secret key and limits.
\ 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§
- Environment variable to force the use of staging relays.
Traits§
- A key for sealing data with AEAD-based algorithms
- Common interface for different congestion controllers
- Constructs controllers on demand
- Server-side configuration for the crypto protocol
- A pseudo random key for HKDF
Functions§
- Returns the default relay mode.
- Returns
true if the use of staging relays is forced. - Extract the
PublicKey from the peer’s TLS certificate. - Creates a
ServerConfig with the given secret key and limits.
\ 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 pub struct Accept<'a> { /* private fields */ }
Expand description
Future produced by Endpoint::accept.
-Trait Implementations§
source§impl<'pin, 'a> Unpin for Accept<'a>where
+Accept in iroh::endpoint - Rust pub struct Accept<'a> { /* private fields */ }
Expand description
Future produced by Endpoint::accept.
+Trait Implementations§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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>,§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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 pub struct Builder { /* private fields */ }
Expand description
Builder for Endpoint.
+Builder in iroh::endpoint - Rust 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
sourcepub fn bind_addr_v4(self, addr: SocketAddrV4) -> Self
Sets the IPv4 bind address.
+Implementations§
source§impl Builder
sourcepub 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.
-sourcepub fn bind_addr_v6(self, addr: SocketAddrV6) -> Self
Sets the IPv6 bind address.
+sourcepub 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.
-sourcepub fn secret_key(self, secret_key: SecretKey) -> Self
Sets a secret key to authenticate with other peers.
+sourcepub fn secret_key(self, secret_key: SecretKey) -> Self
sourcepub fn alpns(self, alpn_protocols: Vec<Vec<u8>>) -> Self
Sets the ALPN protocols that this endpoint will accept on incoming connections.
+sourcepub fn relay_mode(self, relay_mode: RelayMode) -> Self
Sets the relay servers to assist in establishing connectivity.
+sourcepub 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.
-sourcepub fn clear_discovery(self) -> Self
Removes all discovery services from the builder.
-sourcepub fn discovery(self, discovery: Box<dyn Discovery>) -> Self
Optionally sets a discovery mechanism for this endpoint.
+sourcepub fn clear_discovery(self) -> Self
Removes all discovery services from the builder.
+sourcepub 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.
-sourcepub fn add_discovery<F, D>(self, discovery: F) -> Selfwhere
+
sourcepub fn add_discovery<F, D>(self, discovery: F) -> Self
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.
-sourcepub fn discovery_n0(self) -> Self
Configures the endpoint to use the default n0 DNS discovery service.
+sourcepub 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.
-sourcepub 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.
+sourcepub 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.
-sourcepub fn discovery_local_network(self) -> Self
Available on crate feature discovery-local-network only.
Configures the endpoint to also use local network discovery.
+sourcepub 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.
-sourcepub fn known_nodes(self, nodes: Vec<NodeAddr>) -> Self
Optionally set a list of known nodes.
-sourcepub fn transport_config(self, transport_config: TransportConfig) -> Self
Sets a custom quinn::TransportConfig for this endpoint.
+sourcepub fn known_nodes(self, nodes: Vec<NodeAddr>) -> Self
Optionally set a list of known nodes.
+sourcepub 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.
-sourcepub fn dns_resolver(self, dns_resolver: DnsResolver) -> Self
Optionally sets a custom DNS resolver to use for this endpoint.
+sourcepub 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.
-sourcepub fn proxy_url(self, url: Url) -> Self
Sets an explicit proxy url to proxy all HTTP(S) traffic through.
-sourcepub fn proxy_from_env(self) -> Self
Sets the proxy url from the environment, in this order:
+sourcepub fn proxy_url(self, url: Url) -> Self
Sets an explicit proxy url to proxy all HTTP(S) traffic through.
+sourcepub fn proxy_from_env(self) -> Self
Sets the proxy url from the environment, in this order:
HTTP_PROXY
http_proxy
HTTPS_PROXY
https_proxy
-sourcepub fn keylog(self, keylog: bool) -> Self
Enables saving the TLS pre-master key for connections.
+sourcepub 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.
-sourcepub 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
+sourcepub 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§
Auto Trait Implementations§
§impl !Freeze for Builder
§impl !RefUnwindSafe for Builder
§impl Send for Builder
§impl Sync for Builder
§impl Unpin for Builder
§impl !UnwindSafe for Builder
Blanket Implementations§
Trait Implementations§
Auto Trait Implementations§
§impl !Freeze for Builder
§impl !RefUnwindSafe for Builder
§impl Send for Builder
§impl Sync for Builder
§impl Unpin for Builder
§impl !UnwindSafe for Builder
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§
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 · sourcepub fn to_ascii_uppercase(&self) -> Vec<u8> ⓘ
Returns a vector containing a copy of this slice where each byte
+
1.23.0 · sourcepub 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 · sourcepub fn to_ascii_lowercase(&self) -> Vec<u8> ⓘ
Returns a vector containing a copy of this slice where each byte
+
1.23.0 · sourcepub 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 · sourcepub 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.
sourcepub fn to_vec_in<A>(&self, alloc: A) -> Vec<T, A>
🔬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 · sourcepub 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.§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 copy_to_bytes(&mut self, len: usize) -> Bytes
§fn chunks_vectored<'a>(&'a self, dst: &mut [IoSlice<'a>]) -> usize
§fn chunks_vectored<'a>(&'a self, dst: &mut [IoSlice<'a>]) -> usize
Available on crate feature std only.§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])
§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 moreSized,§impl FromIterator<u8> for Bytes
§impl FromIterator<u8> for Bytes
§impl<S> FromRequest<S> for Bytes
§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 Hwhere
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>
§fn in_current_span(self) -> Instrumented<Self>
source§impl<T, U> Into<U> for Twhere
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
sourcepub fn into_0rtt(self) -> Result<(Connection, ZeroRttAccepted), Self>
Convert into a 0-RTT or 0.5-RTT connection at the cost of weakened security.
-sourcepub async fn handshake_data(&mut self) -> Result<Box<dyn Any>, ConnectionError>
Parameters negotiated during the handshake
-sourcepub fn local_ip(&self) -> Option<IpAddr>
The local IP address which was used when the peer established the connection.
-sourcepub fn remote_address(&self) -> SocketAddr
The peer’s UDP address.
-Trait Implementations§
source§impl Debug for Connecting
source§impl Future for Connecting
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for Connectingwhere
+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
sourcepub fn into_0rtt(self) -> Result<(Connection, ZeroRttAccepted), Self>
Convert into a 0-RTT or 0.5-RTT connection at the cost of weakened security.
+sourcepub async fn handshake_data(&mut self) -> Result<Box<dyn Any>, ConnectionError>
Parameters negotiated during the handshake
+sourcepub fn local_ip(&self) -> Option<IpAddr>
The local IP address which was used when the peer established the connection.
+sourcepub fn remote_address(&self) -> SocketAddr
The peer’s UDP address.
+Trait Implementations§
source§impl Debug for Connecting
source§impl Future for Connecting
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for Connectingwhere
PinnedFieldsOf<__Connecting<'pin>>: Unpin,
Auto Trait Implementations§
§impl Freeze for Connecting
§impl !RefUnwindSafe for Connecting
§impl Send for Connecting
§impl Sync for Connecting
§impl !UnwindSafe for Connecting
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§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§impl<S> StreamExt for Swhere
+ 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§impl<S> StreamExt for Swhere
S: Stream + ?Sized,
Sized,
S: Stream<Item = Self::Item>,
§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§impl<S1> StreamExt for S1where
+ 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 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 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 moreRead 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§impl<T> StreamExt for Twhere
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, ()>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>
) -> FlatMapUnordered<Self, U, F>
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 moreRuns 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 moreSized,
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 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>>
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>>
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>
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>
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>,
Available on crate features sink and alloc only.§fn inspect<F>(self, f: F) -> Inspect<Self, F>
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: SocketAddrThe address.
§typ: DirectAddrTypeThe origin of this direct address.
-Trait Implementations§
source§impl Clone for DirectAddr
source§fn clone(&self) -> DirectAddr
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddr
source§impl Hash for DirectAddr
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddr
source§impl Hash for DirectAddr
source§impl Ord for DirectAddr
source§impl Ord for DirectAddr
source§fn cmp(&self, other: &DirectAddr) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read moresource§impl PartialEq for DirectAddr
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 ==.source§impl PartialOrd for DirectAddr
source§impl PartialOrd for DirectAddr
source§fn partial_cmp(&self, other: &DirectAddr) -> Option<Ordering>
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 moresource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§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§impl Stream for DirectAddrsStream
Sized,
S: Stream<Item = Self::Item>,§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
§impl<S> StreamExt for Swhere
+ 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§impl<S> StreamExt for Swhere
S: Stream + ?Sized,
Sized,
S: Stream<Item = Self::Item>,§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§impl<S1> StreamExt for S1where
+ 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 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 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 moreRead 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
§impl<T> StreamExt for Twhere
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, ()>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>
) -> FlatMapUnordered<Self, U, F>
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 moreRuns 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 moreSized,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 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>>
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>>
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>
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>
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>,
Available on crate features sink and alloc only.§fn inspect<F>(self, f: F) -> Inspect<Self, F>
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 pub struct Endpoint { /* private fields */ }
Expand description
Controls an iroh node, establishing connections with other nodes.
+Endpoint in iroh::endpoint - Rust 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
sourcepub fn builder() -> Builder
Returns the builder for an Endpoint, with a production configuration.
-sourcepub fn set_alpns(&self, alpns: Vec<Vec<u8>>) -> Result<()>
Sets the list of accepted ALPN protocols.
+Implementations§
source§impl Endpoint
sourcepub fn builder() -> Builder
Returns the builder for an Endpoint, with a production configuration.
+sourcepub 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.
-
sourcepub 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.
-sourcepub fn add_node_addr(&self, node_addr: NodeAddr) -> Result<()>
Informs this Endpoint about addresses of the iroh node.
+sourcepub 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.
-sourcepub fn add_node_addr_with_source(
+
sourcepub fn secret_key(&self) -> &SecretKey
Returns the secret_key of this endpoint.
-sourcepub fn secret_key(&self) -> &SecretKey
Returns the secret_key of this endpoint.
+sourcepub 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.
-sourcepub async fn node_addr(&self) -> Result<NodeAddr>
Returns the current NodeAddr for this endpoint.
+sourcepub 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.
-sourcepub fn home_relay(&self) -> Option<RelayUrl>
Returns the RelayUrl of the Relay server used as home relay.
+sourcepub 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.
-sourcepub fn watch_home_relay(&self) -> impl Stream<Item = RelayUrl>
Watches for changes to the home relay.
+sourcepub 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.
-sourcepub fn direct_addresses(&self) -> DirectAddrsStream
Returns the direct addresses of this Endpoint.
+sourcepub 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;
-sourcepub fn bound_sockets(&self) -> (SocketAddr, Option<SocketAddr>)
Returns the local socket addresses on which the underlying sockets are bound.
+sourcepub 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.
-sourcepub fn remote_info(&self, node_id: NodeId) -> Option<RemoteInfo>
Returns information about the remote node identified by a NodeId.
+sourcepub 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.
-sourcepub fn remote_info_iter(&self) -> impl Iterator<Item = RemoteInfo>
Returns information about all the remote nodes this Endpoint knows about.
+sourcepub 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.
-sourcepub fn conn_type_stream(&self, node_id: NodeId) -> Result<ConnectionTypeStream>
Returns a stream that reports connection type changes for the remote node.
+sourcepub 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.
-sourcepub fn dns_resolver(&self) -> &DnsResolver
Returns the DNS resolver used in this Endpoint.
+sourcepub fn dns_resolver(&self) -> &DnsResolver
Returns the DNS resolver used in this Endpoint.
See Builder::discovery.
-sourcepub fn discovery(&self) -> Option<&dyn Discovery>
Returns the discovery mechanism, if configured.
+sourcepub fn discovery(&self) -> Option<&dyn Discovery>
Returns the discovery mechanism, if configured.
-sourcepub async fn network_change(&self)
Notifies the system of potential network changes.
+sourcepub 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.
-sourcepub 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.
-Trait Implementations§
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§
Trait Implementations§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 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 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
sourcepub fn accept(self) -> Result<Connecting, ConnectionError>
Attempts to accept this incoming connection (an error may still occur).
+Implementations§
source§impl Incoming
sourcepub 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.
-sourcepub fn accept_with(
+
sourcepub fn accept_with(
self,
server_config: Arc<ServerConfig>
) -> Result<Connecting, ConnectionError>
Accepts this incoming connection using a custom configuration.
See accept() for more details.
-sourcepub fn retry(self) -> Result<(), RetryError>
Responds with a retry packet.
+sourcepub 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.
-sourcepub fn ignore(self)
Ignores this incoming connection attempt, not sending any packet in response.
-sourcepub fn local_ip(&self) -> Option<IpAddr>
Returns the local IP address which was used when the peer established the
+
sourcepub fn ignore(self)
Ignores this incoming connection attempt, not sending any packet in response.
+sourcepub fn local_ip(&self) -> Option<IpAddr>
Returns the local IP address which was used when the peer established the
connection.
-sourcepub fn remote_address(&self) -> SocketAddr
Returns the peer’s UDP address.
-sourcepub fn remote_address_validated(&self) -> bool
Whether the socket address that is initiating this connection has been validated.
+sourcepub fn remote_address(&self) -> SocketAddr
Returns the peer’s UDP address.
+sourcepub 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 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 moreAuto Trait Implementations§
§impl !Freeze for Incoming
§impl !RefUnwindSafe for Incoming
§impl Send for Incoming
§impl Sync for Incoming
§impl Unpin for Incoming
§impl !UnwindSafe for Incoming
Blanket Implementations§
Trait Implementations§
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 moreAuto Trait Implementations§
§impl !Freeze for Incoming
§impl !RefUnwindSafe for Incoming
§impl Send for Incoming
§impl Sync for Incoming
§impl Unpin for Incoming
§impl !UnwindSafe for Incoming
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§impl Future for IncomingFuture
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for IncomingFuturewhere
+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§impl Future for IncomingFuture
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for IncomingFuturewhere
PinnedFieldsOf<__IncomingFuture<'pin>>: Unpin,
Auto Trait Implementations§
§impl !Freeze for IncomingFuture
§impl !RefUnwindSafe for IncomingFuture
§impl Send for IncomingFuture
§impl Sync for IncomingFuture
§impl !UnwindSafe for IncomingFuture
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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
§fn poll_write(
+
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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 Expand description
The blake3 hash used in Iroh.
+iroh::hash - Rust
\ 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 moresource§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
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more1.21.0 · source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more1.50.0 · source§fn clamp(self, min: Self, max: Self) -> Selfwhere
@@ -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 widthsource§fn from_bytes<'a>(data: &'a [u8]) -> <Hash as Value>::SelfType<'a>where
+ S: Serializer,
Serialize this value into the given Serde serializer. Read moresource§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 widthsource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: HashThe hash
§format: BlobFormatThe format
-Implementations§
source§impl HashAndFormat
sourcepub fn new(hash: Hash, format: BlobFormat) -> HashAndFormat
Create a new hash and format pair.
-sourcepub fn raw(hash: Hash) -> HashAndFormat
Create a new hash and format pair, using the default (raw) format.
-sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for HashAndFormat
source§impl<'de> Deserialize<'de> for HashAndFormat
source§fn deserialize<D>(
+
Implementations§
source§impl HashAndFormat
sourcepub fn new(hash: Hash, format: BlobFormat) -> HashAndFormat
Create a new hash and format pair.
+sourcepub fn raw(hash: Hash) -> HashAndFormat
Create a new hash and format pair, using the default (raw) format.
+sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for HashAndFormat
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 moresource§impl Display for HashAndFormat
source§impl FromStr for HashAndFormat
source§impl Hash for HashAndFormat
source§impl Display for HashAndFormat
source§impl FromStr for HashAndFormat
source§impl Hash for HashAndFormat
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.source§impl PartialOrd for HashAndFormat
source§fn partial_cmp(&self, other: &HashAndFormat) -> Option<Ordering>
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 moresource§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 moresource§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 widthsource§fn from_bytes<'a>(data: &'a [u8]) -> <HashAndFormat as Value>::SelfType<'a>where
+ S: Serializer,
Serialize this value into the given Serde serializer. Read moresource§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 widthsource§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 typesource§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§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
Peer-to-peer QUIC connections.
+iroh - Rust 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§
pub use endpoint::Endpoint;pub use endpoint::RelayMode;pub use iroh_relay as relay;
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_utils
test or test-utilsInternal 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§
- Options to configure what is included in a
NodeAddr.
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-utilsInternal 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§
- Options to configure what is included in a
NodeAddr.
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 Expand description
Cryptographic key handling for iroh.
+iroh::key - Rust
\ 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.
Trait Implementations§
§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 Copy for Signature
§impl Eq for Signature
§impl StructuralPartialEq for Signature
Auto Trait Implementations§
§impl Freeze for Signature
§impl RefUnwindSafe for Signature
§impl Send for Signature
§impl Sync for Signature
§impl Unpin for Signature
§impl UnwindSafe for Signature
Blanket Implementations§
source§impl<T> Any for Twhere
+ S: Serializer,
Serialize this value into the given Serde serializer. Read more§impl SignatureEncoding for Signature
§impl Copy for Signature
§impl Eq for Signature
§impl StructuralPartialEq for Signature
Auto Trait Implementations§
§impl Freeze for Signature
§impl RefUnwindSafe for Signature
§impl Send for Signature
§impl Sync for Signature
§impl Unpin for Signature
§impl UnwindSafe for Signature
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
Co-locating all of the iroh metrics structs
+iroh::metrics - Rust Expand description
Co-locating all of the iroh metrics structs
Structs§
- Enum of metrics for the module
- Enum of metrics for the module
- Enum of metrics for the module
- RelayMetrics
test-utilsMetrics tracked for the relay server
\ 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: CounterNumber of nodes we have managed to contact directly.
§connection_handshake_success: CounterNumber of connections with a successful handshake.
§connection_became_direct: CounterNumber of connections with a successful handshake that became direct.
-Trait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
Access to this metrics group to record a metric.
+Trait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterTrait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
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: CounterTrait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterTrait Implementations§
§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
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: CounterTrait Implementations§
§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterNumber of unique client keys per day
§websocket_accepts: CounterNumber of accepted websocket connections
§derp_accepts: CounterNumber of accepted ‘iroh derp http’ connection upgrades
-Trait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
Access to this metrics group to record a metric.
+Trait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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().
sourcepub 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.
-sourcepub fn to_file_path(&self) -> Result<PathBuf, ()>
Assuming the URL is in the file scheme or similar,
+
sourcepub 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.
\ 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.
\ 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§
- A drop guard to clean up test infrastructure.
- Handle and drop guard for test DNS and Pkarr servers.
Functions§
- Create a DNS resolver with a single nameserver.
- Runs a relay server with STUN and QUIC enabled suitable for tests.
- Runs a relay server.
- Runs a relay server with STUN enabled suitable for tests.
\ 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§
Auto Trait Implementations§
§impl Freeze for CleanupDropGuard
§impl !RefUnwindSafe for CleanupDropGuard
§impl Send for CleanupDropGuard
§impl Sync for CleanupDropGuard
§impl Unpin for CleanupDropGuard
§impl !UnwindSafe for CleanupDropGuard
Blanket Implementations§
source§impl<T> Any for Twhere
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: StringThe node origin domain.
§nameserver: SocketAddrThe 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
Struct iroh::discovery::pkarr::PkarrResolver
source · pub struct PkarrResolver { /* private fields */ }Expand description
Resolver of node discovery information from a pkarr relay.
+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
impl PkarrResolver
sourcepub fn new(pkarr_relay: Url) -> Self
pub fn new(pkarr_relay: Url) -> Self
Creates a new publisher using the pkarr relay server at the URL.
-Implementations§
source§impl PkarrResolver
impl PkarrResolver
sourcepub fn new(pkarr_relay: Url) -> Self
pub fn new(pkarr_relay: Url) -> Self
Creates a new publisher using the pkarr relay server at the URL.
+sourcepub fn n0_dns() -> Self
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
impl Clone for PkarrResolver
source§fn clone(&self) -> PkarrResolver
fn clone(&self) -> PkarrResolver
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moresource§impl Debug for PkarrResolver
impl Debug for PkarrResolver
Trait Implementations§
source§impl Clone for PkarrResolver
impl Clone for PkarrResolver
source§fn clone(&self) -> PkarrResolver
fn clone(&self) -> PkarrResolver
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moresource§impl Debug for PkarrResolver
impl Debug for PkarrResolver
Auto Trait Implementations§
impl Freeze for PkarrResolver
impl !RefUnwindSafe for PkarrResolver
impl Send for PkarrResolver
impl Sync for PkarrResolver
impl Unpin for PkarrResolver
impl !UnwindSafe for PkarrResolver
Blanket Implementations§
Auto Trait Implementations§
impl Freeze for PkarrResolver
impl !RefUnwindSafe for PkarrResolver
impl Send for PkarrResolver
impl Sync for PkarrResolver
impl Unpin for PkarrResolver
impl !UnwindSafe for PkarrResolver
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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>>>
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§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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
sourcepub fn empty() -> Self
Creates an empty ConcurrentDiscovery.
-sourcepub fn from_services(services: Vec<Box<dyn Discovery>>) -> Self
Creates a new ConcurrentDiscovery.
-Trait Implementations§
source§impl Debug for ConcurrentDiscovery
source§impl Default for ConcurrentDiscovery
source§fn default() -> ConcurrentDiscovery
Returns the “default value” for a type. Read moresource§impl Discovery for ConcurrentDiscovery
Implementations§
source§impl ConcurrentDiscovery
sourcepub fn empty() -> Self
Creates an empty ConcurrentDiscovery.
+sourcepub fn from_services(services: Vec<Box<dyn Discovery>>) -> Self
Creates a new ConcurrentDiscovery.
+Trait Implementations§
source§impl Debug for ConcurrentDiscovery
source§impl Default for ConcurrentDiscovery
source§fn default() -> ConcurrentDiscovery
Returns the “default value” for a type. Read moresource§impl Discovery for ConcurrentDiscovery
source§impl<T> From<T> for ConcurrentDiscovery
Auto Trait Implementations§
§impl Freeze for ConcurrentDiscovery
§impl !RefUnwindSafe for ConcurrentDiscovery
§impl Send for ConcurrentDiscovery
§impl Sync for ConcurrentDiscovery
§impl Unpin for ConcurrentDiscovery
§impl !UnwindSafe for ConcurrentDiscovery
Blanket Implementations§
source§impl<T> From<T> for ConcurrentDiscovery
Auto Trait Implementations§
§impl Freeze for ConcurrentDiscovery
§impl !RefUnwindSafe for ConcurrentDiscovery
§impl Send for ConcurrentDiscovery
§impl Sync for ConcurrentDiscovery
§impl Unpin for ConcurrentDiscovery
§impl !UnwindSafe for ConcurrentDiscovery
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for DiscoveryItem
§impl RefUnwindSafe for DiscoveryItem
§impl Send for DiscoveryItem
§impl Sync for DiscoveryItem
§impl Unpin for DiscoveryItem
§impl UnwindSafe for DiscoveryItem
Blanket Implementations§
source§impl<T> Any for Twhere
+Trait Implementations§
source§impl Clone for DiscoveryItem
source§fn clone(&self) -> DiscoveryItem
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for DiscoveryItem
§impl RefUnwindSafe for DiscoveryItem
§impl Send for DiscoveryItem
§impl Sync for DiscoveryItem
§impl Unpin for DiscoveryItem
§impl UnwindSafe for DiscoveryItem
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 pub trait Discovery: Debug + Send + Sync {
+Discovery in iroh::discovery - Rust 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§
sourcefn publish(&self, _url: Option<&RelayUrl>, _addrs: &BTreeSet<SocketAddr>)
Publishes the given RelayUrl and direct addreesses to the discovery mechanism.
+Provided Methods§
sourcefn 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.
-sourcefn 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.
-sourcefn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>
Subscribe to all addresses that get passively discovered.
+sourcefn 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddrType
source§impl Display for DirectAddrType
source§impl Hash for DirectAddrType
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddrType
source§impl Display for DirectAddrType
source§impl Hash for DirectAddrType
source§impl Ord for DirectAddrType
source§impl Ord for DirectAddrType
source§fn cmp(&self, other: &DirectAddrType) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read moresource§impl PartialEq for DirectAddrType
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 ==.source§impl PartialOrd for DirectAddrType
source§impl PartialOrd for DirectAddrType
source§fn partial_cmp(&self, other: &DirectAddrType) -> Option<Ordering>
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 moresource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 pub enum RelayMode {
+RelayMode in iroh::endpoint - Rust 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§
Trait Implementations§
source§impl PartialEq for RelayMode
Implementations§
Trait Implementations§
source§impl PartialEq for RelayMode
source§impl Eq for RelayMode
source§impl StructuralPartialEq for RelayMode
Auto Trait Implementations§
§impl Freeze for RelayMode
§impl RefUnwindSafe for RelayMode
§impl Send for RelayMode
§impl Sync for RelayMode
§impl Unpin for RelayMode
§impl UnwindSafe for RelayMode
Blanket Implementations§
source§impl Eq for RelayMode
source§impl StructuralPartialEq for RelayMode
Auto Trait Implementations§
§impl Freeze for RelayMode
§impl RefUnwindSafe for RelayMode
§impl Send for RelayMode
§impl Sync for RelayMode
§impl Unpin for RelayMode
§impl UnwindSafe for RelayMode
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
The Endpoint allows establishing connections to other iroh nodes.
+iroh::endpoint - Rust 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§
- Future produced by
Endpoint::accept. - Future produced by
Connection::accept_bi - Future produced by
Connection::accept_uni - Parameters for controlling the peer’s acknowledgement frequency
- Reason given by an application for closing the connection
- Builder for
Endpoint. - A cheaply cloneable and sliceable chunk of contiguous memory.
- A chunk of data from the receive stream
- Error indicating that a stream has not been opened or has already been finished or reset
- In-progress connection attempt future
- A QUIC connection.
- Reason given by the transport for closing the connection
- Connection statistics
- Stream returning
ConnectionTypes - Generic crypto errors
- A direct address on which an iroh-node might be contactable.
- Information about a direct address.
- Stream returning local endpoints as they change.
- Controls an iroh node, establishing connections with other nodes.
- Error returned by [Session::export_keying_material].
- Number of frames transmitted of each frame type
- An incoming connection for which the server has not yet begun its parts of the
handshake.
- Parameters governing MTU discovery.
- Network-level addressing information for an iroh node.
- Future produced by
Connection::open_bi - Future produced by
Connection::open_uni - Statistics related to a transmission path
- Future produced by
Connection::read_datagram - A stream that can only be used to receive data
- Details about a remote iroh node which is known to this node.
- Error for attempting to retry an [
Incoming] which already bears an address
validation token from a previous retry - A stream that can only be used to send data
- Parameters governing incoming connections
- Identifier for a stream within a particular connection
- Parameters governing the core QUIC state machine
- Transport-level errors occur when a peer violates the protocol specification
- Transport-level error code
- Statistics about UDP datagrams transmitted or received on a connection
- Error indicating that the specified QUIC version is not supported
- An integer less than 2^62
- A handle to some connection internals, use with care.
- Indicates how many bytes and chunks had been transferred in a write operation
- Future that completes when a connection is fully established
Enums§
- Options to configure what is included in a
NodeAddr. - Reasons why a connection might be lost
- The type of connection we have to the endpoint.
- The type of control message we have received.
- The type of direct address.
- Errors that arise from reading from a stream.
- Errors that arise from reading from a stream.
- Errors from
RecvStream::read_to_end - Configuration of the relay servers for an
Endpoint. - Errors that arise while waiting for a stream to be reset
- Errors that can arise when sending a datagram
- The origin or source through which an address associated with a remote node
-was discovered.
- Errors that arise while monitoring for a send stream stop from the peer
- Errors that arise from writing to a stream
Constants§
- ENV_FORCE_STAGING_RELAYSNon-
testEnvironment variable to force the use of staging relays.
Traits§
- A key for sealing data with AEAD-based algorithms
- Common interface for different congestion controllers
- Constructs controllers on demand
- Server-side configuration for the crypto protocol
- A pseudo random key for HKDF
Functions§
- Returns the default relay mode.
- Returns
true if the use of staging relays is forced. - Extract the
PublicKey from the peer’s TLS certificate. - Creates a
ServerConfig with the given secret key and limits.
\ 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§
- Environment variable to force the use of staging relays.
Traits§
- A key for sealing data with AEAD-based algorithms
- Common interface for different congestion controllers
- Constructs controllers on demand
- Server-side configuration for the crypto protocol
- A pseudo random key for HKDF
Functions§
- Returns the default relay mode.
- Returns
true if the use of staging relays is forced. - Extract the
PublicKey from the peer’s TLS certificate. - Creates a
ServerConfig with the given secret key and limits.
\ 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 pub struct Accept<'a> { /* private fields */ }
Expand description
Future produced by Endpoint::accept.
-Trait Implementations§
source§impl<'pin, 'a> Unpin for Accept<'a>where
+Accept in iroh::endpoint - Rust pub struct Accept<'a> { /* private fields */ }
Expand description
Future produced by Endpoint::accept.
+Trait Implementations§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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>,§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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 pub struct Builder { /* private fields */ }
Expand description
Builder for Endpoint.
+Builder in iroh::endpoint - Rust 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
sourcepub fn bind_addr_v4(self, addr: SocketAddrV4) -> Self
Sets the IPv4 bind address.
+Implementations§
source§impl Builder
sourcepub 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.
-sourcepub fn bind_addr_v6(self, addr: SocketAddrV6) -> Self
Sets the IPv6 bind address.
+sourcepub 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.
-sourcepub fn secret_key(self, secret_key: SecretKey) -> Self
Sets a secret key to authenticate with other peers.
+sourcepub fn secret_key(self, secret_key: SecretKey) -> Self
sourcepub fn alpns(self, alpn_protocols: Vec<Vec<u8>>) -> Self
Sets the ALPN protocols that this endpoint will accept on incoming connections.
+sourcepub fn relay_mode(self, relay_mode: RelayMode) -> Self
Sets the relay servers to assist in establishing connectivity.
+sourcepub 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.
-sourcepub fn clear_discovery(self) -> Self
Removes all discovery services from the builder.
-sourcepub fn discovery(self, discovery: Box<dyn Discovery>) -> Self
Optionally sets a discovery mechanism for this endpoint.
+sourcepub fn clear_discovery(self) -> Self
Removes all discovery services from the builder.
+sourcepub 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.
-sourcepub fn add_discovery<F, D>(self, discovery: F) -> Selfwhere
+
sourcepub fn add_discovery<F, D>(self, discovery: F) -> Self
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.
-sourcepub fn discovery_n0(self) -> Self
Configures the endpoint to use the default n0 DNS discovery service.
+sourcepub 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.
-sourcepub 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.
+sourcepub 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.
-sourcepub fn discovery_local_network(self) -> Self
Available on crate feature discovery-local-network only.
Configures the endpoint to also use local network discovery.
+sourcepub 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.
-sourcepub fn known_nodes(self, nodes: Vec<NodeAddr>) -> Self
Optionally set a list of known nodes.
-sourcepub fn transport_config(self, transport_config: TransportConfig) -> Self
Sets a custom quinn::TransportConfig for this endpoint.
+sourcepub fn known_nodes(self, nodes: Vec<NodeAddr>) -> Self
Optionally set a list of known nodes.
+sourcepub 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.
-sourcepub fn dns_resolver(self, dns_resolver: DnsResolver) -> Self
Optionally sets a custom DNS resolver to use for this endpoint.
+sourcepub 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.
-sourcepub fn proxy_url(self, url: Url) -> Self
Sets an explicit proxy url to proxy all HTTP(S) traffic through.
-sourcepub fn proxy_from_env(self) -> Self
Sets the proxy url from the environment, in this order:
+sourcepub fn proxy_url(self, url: Url) -> Self
Sets an explicit proxy url to proxy all HTTP(S) traffic through.
+sourcepub fn proxy_from_env(self) -> Self
Sets the proxy url from the environment, in this order:
HTTP_PROXY
http_proxy
HTTPS_PROXY
https_proxy
-sourcepub fn keylog(self, keylog: bool) -> Self
Enables saving the TLS pre-master key for connections.
+sourcepub 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.
-sourcepub 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
+sourcepub 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§
Auto Trait Implementations§
§impl !Freeze for Builder
§impl !RefUnwindSafe for Builder
§impl Send for Builder
§impl Sync for Builder
§impl Unpin for Builder
§impl !UnwindSafe for Builder
Blanket Implementations§
Trait Implementations§
Auto Trait Implementations§
§impl !Freeze for Builder
§impl !RefUnwindSafe for Builder
§impl Send for Builder
§impl Sync for Builder
§impl Unpin for Builder
§impl !UnwindSafe for Builder
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§
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 · sourcepub fn to_ascii_uppercase(&self) -> Vec<u8> ⓘ
Returns a vector containing a copy of this slice where each byte
+
1.23.0 · sourcepub 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 · sourcepub fn to_ascii_lowercase(&self) -> Vec<u8> ⓘ
Returns a vector containing a copy of this slice where each byte
+
1.23.0 · sourcepub 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 · sourcepub 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.
sourcepub fn to_vec_in<A>(&self, alloc: A) -> Vec<T, A>
🔬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 · sourcepub 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.§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 copy_to_bytes(&mut self, len: usize) -> Bytes
§fn chunks_vectored<'a>(&'a self, dst: &mut [IoSlice<'a>]) -> usize
§fn chunks_vectored<'a>(&'a self, dst: &mut [IoSlice<'a>]) -> usize
Available on crate feature std only.§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])
§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 moreSized,§impl FromIterator<u8> for Bytes
§impl FromIterator<u8> for Bytes
§impl<S> FromRequest<S> for Bytes
§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 Hwhere
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>
§fn in_current_span(self) -> Instrumented<Self>
source§impl<T, U> Into<U> for Twhere
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
sourcepub fn into_0rtt(self) -> Result<(Connection, ZeroRttAccepted), Self>
Convert into a 0-RTT or 0.5-RTT connection at the cost of weakened security.
-sourcepub async fn handshake_data(&mut self) -> Result<Box<dyn Any>, ConnectionError>
Parameters negotiated during the handshake
-sourcepub fn local_ip(&self) -> Option<IpAddr>
The local IP address which was used when the peer established the connection.
-sourcepub fn remote_address(&self) -> SocketAddr
The peer’s UDP address.
-Trait Implementations§
source§impl Debug for Connecting
source§impl Future for Connecting
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for Connectingwhere
+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
sourcepub fn into_0rtt(self) -> Result<(Connection, ZeroRttAccepted), Self>
Convert into a 0-RTT or 0.5-RTT connection at the cost of weakened security.
+sourcepub async fn handshake_data(&mut self) -> Result<Box<dyn Any>, ConnectionError>
Parameters negotiated during the handshake
+sourcepub fn local_ip(&self) -> Option<IpAddr>
The local IP address which was used when the peer established the connection.
+sourcepub fn remote_address(&self) -> SocketAddr
The peer’s UDP address.
+Trait Implementations§
source§impl Debug for Connecting
source§impl Future for Connecting
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for Connectingwhere
PinnedFieldsOf<__Connecting<'pin>>: Unpin,
Auto Trait Implementations§
§impl Freeze for Connecting
§impl !RefUnwindSafe for Connecting
§impl Send for Connecting
§impl Sync for Connecting
§impl !UnwindSafe for Connecting
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§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§impl<S> StreamExt for Swhere
+ 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§impl<S> StreamExt for Swhere
S: Stream + ?Sized,
Sized,
S: Stream<Item = Self::Item>,
§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§impl<S1> StreamExt for S1where
+ 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 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 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 moreRead 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§impl<T> StreamExt for Twhere
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, ()>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>
) -> FlatMapUnordered<Self, U, F>
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 moreRuns 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 moreSized,
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 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>>
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>>
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>
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>
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>,
Available on crate features sink and alloc only.§fn inspect<F>(self, f: F) -> Inspect<Self, F>
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: SocketAddrThe address.
§typ: DirectAddrTypeThe origin of this direct address.
-Trait Implementations§
source§impl Clone for DirectAddr
source§fn clone(&self) -> DirectAddr
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddr
source§impl Hash for DirectAddr
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddr
source§impl Hash for DirectAddr
source§impl Ord for DirectAddr
source§impl Ord for DirectAddr
source§fn cmp(&self, other: &DirectAddr) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read moresource§impl PartialEq for DirectAddr
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 ==.source§impl PartialOrd for DirectAddr
source§impl PartialOrd for DirectAddr
source§fn partial_cmp(&self, other: &DirectAddr) -> Option<Ordering>
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 moresource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§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§impl Stream for DirectAddrsStream
Sized,
S: Stream<Item = Self::Item>,§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
§impl<S> StreamExt for Swhere
+ 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§impl<S> StreamExt for Swhere
S: Stream + ?Sized,
Sized,
S: Stream<Item = Self::Item>,§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§impl<S1> StreamExt for S1where
+ 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 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 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 moreRead 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
§impl<T> StreamExt for Twhere
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, ()>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>
) -> FlatMapUnordered<Self, U, F>
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 moreRuns 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 moreSized,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 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>>
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>>
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>
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>
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>,
Available on crate features sink and alloc only.§fn inspect<F>(self, f: F) -> Inspect<Self, F>
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 pub struct Endpoint { /* private fields */ }
Expand description
Controls an iroh node, establishing connections with other nodes.
+Endpoint in iroh::endpoint - Rust 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
sourcepub fn builder() -> Builder
Returns the builder for an Endpoint, with a production configuration.
-sourcepub fn set_alpns(&self, alpns: Vec<Vec<u8>>) -> Result<()>
Sets the list of accepted ALPN protocols.
+Implementations§
source§impl Endpoint
sourcepub fn builder() -> Builder
Returns the builder for an Endpoint, with a production configuration.
+sourcepub 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.
-
sourcepub 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.
-sourcepub fn add_node_addr(&self, node_addr: NodeAddr) -> Result<()>
Informs this Endpoint about addresses of the iroh node.
+sourcepub 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.
-sourcepub fn add_node_addr_with_source(
+
sourcepub fn secret_key(&self) -> &SecretKey
Returns the secret_key of this endpoint.
-sourcepub fn secret_key(&self) -> &SecretKey
Returns the secret_key of this endpoint.
+sourcepub 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.
-sourcepub async fn node_addr(&self) -> Result<NodeAddr>
Returns the current NodeAddr for this endpoint.
+sourcepub 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.
-sourcepub fn home_relay(&self) -> Option<RelayUrl>
Returns the RelayUrl of the Relay server used as home relay.
+sourcepub 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.
-sourcepub fn watch_home_relay(&self) -> impl Stream<Item = RelayUrl>
Watches for changes to the home relay.
+sourcepub 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.
-sourcepub fn direct_addresses(&self) -> DirectAddrsStream
Returns the direct addresses of this Endpoint.
+sourcepub 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;
-sourcepub fn bound_sockets(&self) -> (SocketAddr, Option<SocketAddr>)
Returns the local socket addresses on which the underlying sockets are bound.
+sourcepub 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.
-sourcepub fn remote_info(&self, node_id: NodeId) -> Option<RemoteInfo>
Returns information about the remote node identified by a NodeId.
+sourcepub 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.
-sourcepub fn remote_info_iter(&self) -> impl Iterator<Item = RemoteInfo>
Returns information about all the remote nodes this Endpoint knows about.
+sourcepub 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.
-sourcepub fn conn_type_stream(&self, node_id: NodeId) -> Result<ConnectionTypeStream>
Returns a stream that reports connection type changes for the remote node.
+sourcepub 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.
-sourcepub fn dns_resolver(&self) -> &DnsResolver
Returns the DNS resolver used in this Endpoint.
+sourcepub fn dns_resolver(&self) -> &DnsResolver
Returns the DNS resolver used in this Endpoint.
See Builder::discovery.
-sourcepub fn discovery(&self) -> Option<&dyn Discovery>
Returns the discovery mechanism, if configured.
+sourcepub fn discovery(&self) -> Option<&dyn Discovery>
Returns the discovery mechanism, if configured.
-sourcepub async fn network_change(&self)
Notifies the system of potential network changes.
+sourcepub 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.
-sourcepub 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.
-Trait Implementations§
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§
Trait Implementations§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 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 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
sourcepub fn accept(self) -> Result<Connecting, ConnectionError>
Attempts to accept this incoming connection (an error may still occur).
+Implementations§
source§impl Incoming
sourcepub 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.
-sourcepub fn accept_with(
+
sourcepub fn accept_with(
self,
server_config: Arc<ServerConfig>
) -> Result<Connecting, ConnectionError>
Accepts this incoming connection using a custom configuration.
See accept() for more details.
-sourcepub fn retry(self) -> Result<(), RetryError>
Responds with a retry packet.
+sourcepub 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.
-sourcepub fn ignore(self)
Ignores this incoming connection attempt, not sending any packet in response.
-sourcepub fn local_ip(&self) -> Option<IpAddr>
Returns the local IP address which was used when the peer established the
+
sourcepub fn ignore(self)
Ignores this incoming connection attempt, not sending any packet in response.
+sourcepub fn local_ip(&self) -> Option<IpAddr>
Returns the local IP address which was used when the peer established the
connection.
-sourcepub fn remote_address(&self) -> SocketAddr
Returns the peer’s UDP address.
-sourcepub fn remote_address_validated(&self) -> bool
Whether the socket address that is initiating this connection has been validated.
+sourcepub fn remote_address(&self) -> SocketAddr
Returns the peer’s UDP address.
+sourcepub 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 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 moreAuto Trait Implementations§
§impl !Freeze for Incoming
§impl !RefUnwindSafe for Incoming
§impl Send for Incoming
§impl Sync for Incoming
§impl Unpin for Incoming
§impl !UnwindSafe for Incoming
Blanket Implementations§
Trait Implementations§
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 moreAuto Trait Implementations§
§impl !Freeze for Incoming
§impl !RefUnwindSafe for Incoming
§impl Send for Incoming
§impl Sync for Incoming
§impl Unpin for Incoming
§impl !UnwindSafe for Incoming
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§impl Future for IncomingFuture
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for IncomingFuturewhere
+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§impl Future for IncomingFuture
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for IncomingFuturewhere
PinnedFieldsOf<__IncomingFuture<'pin>>: Unpin,
Auto Trait Implementations§
§impl !Freeze for IncomingFuture
§impl !RefUnwindSafe for IncomingFuture
§impl Send for IncomingFuture
§impl Sync for IncomingFuture
§impl !UnwindSafe for IncomingFuture
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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
§fn poll_write(
+
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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 Expand description
The blake3 hash used in Iroh.
+iroh::hash - Rust
\ 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 moresource§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
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more1.21.0 · source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more1.50.0 · source§fn clamp(self, min: Self, max: Self) -> Selfwhere
@@ -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 widthsource§fn from_bytes<'a>(data: &'a [u8]) -> <Hash as Value>::SelfType<'a>where
+ S: Serializer,
Serialize this value into the given Serde serializer. Read moresource§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 widthsource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: HashThe hash
§format: BlobFormatThe format
-Implementations§
source§impl HashAndFormat
sourcepub fn new(hash: Hash, format: BlobFormat) -> HashAndFormat
Create a new hash and format pair.
-sourcepub fn raw(hash: Hash) -> HashAndFormat
Create a new hash and format pair, using the default (raw) format.
-sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for HashAndFormat
source§impl<'de> Deserialize<'de> for HashAndFormat
source§fn deserialize<D>(
+
Implementations§
source§impl HashAndFormat
sourcepub fn new(hash: Hash, format: BlobFormat) -> HashAndFormat
Create a new hash and format pair.
+sourcepub fn raw(hash: Hash) -> HashAndFormat
Create a new hash and format pair, using the default (raw) format.
+sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for HashAndFormat
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 moresource§impl Display for HashAndFormat
source§impl FromStr for HashAndFormat
source§impl Hash for HashAndFormat
source§impl Display for HashAndFormat
source§impl FromStr for HashAndFormat
source§impl Hash for HashAndFormat
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.source§impl PartialOrd for HashAndFormat
source§fn partial_cmp(&self, other: &HashAndFormat) -> Option<Ordering>
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 moresource§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 moresource§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 widthsource§fn from_bytes<'a>(data: &'a [u8]) -> <HashAndFormat as Value>::SelfType<'a>where
+ S: Serializer,
Serialize this value into the given Serde serializer. Read moresource§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 widthsource§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 typesource§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§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
Peer-to-peer QUIC connections.
+iroh - Rust 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§
pub use endpoint::Endpoint;pub use endpoint::RelayMode;pub use iroh_relay as relay;
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_utils
test or test-utilsInternal 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§
- Options to configure what is included in a
NodeAddr.
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-utilsInternal 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§
- Options to configure what is included in a
NodeAddr.
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 Expand description
Cryptographic key handling for iroh.
+iroh::key - Rust
\ 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.
Trait Implementations§
§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 Copy for Signature
§impl Eq for Signature
§impl StructuralPartialEq for Signature
Auto Trait Implementations§
§impl Freeze for Signature
§impl RefUnwindSafe for Signature
§impl Send for Signature
§impl Sync for Signature
§impl Unpin for Signature
§impl UnwindSafe for Signature
Blanket Implementations§
source§impl<T> Any for Twhere
+ S: Serializer,
Serialize this value into the given Serde serializer. Read more§impl SignatureEncoding for Signature
§impl Copy for Signature
§impl Eq for Signature
§impl StructuralPartialEq for Signature
Auto Trait Implementations§
§impl Freeze for Signature
§impl RefUnwindSafe for Signature
§impl Send for Signature
§impl Sync for Signature
§impl Unpin for Signature
§impl UnwindSafe for Signature
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
Co-locating all of the iroh metrics structs
+iroh::metrics - Rust Expand description
Co-locating all of the iroh metrics structs
Structs§
- Enum of metrics for the module
- Enum of metrics for the module
- Enum of metrics for the module
- RelayMetrics
test-utilsMetrics tracked for the relay server
\ 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: CounterNumber of nodes we have managed to contact directly.
§connection_handshake_success: CounterNumber of connections with a successful handshake.
§connection_became_direct: CounterNumber of connections with a successful handshake that became direct.
-Trait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
Access to this metrics group to record a metric.
+Trait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterTrait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
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: CounterTrait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterTrait Implementations§
§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
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: CounterTrait Implementations§
§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterNumber of unique client keys per day
§websocket_accepts: CounterNumber of accepted websocket connections
§derp_accepts: CounterNumber of accepted ‘iroh derp http’ connection upgrades
-Trait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
Access to this metrics group to record a metric.
+Trait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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().
sourcepub 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.
-sourcepub fn to_file_path(&self) -> Result<PathBuf, ()>
Assuming the URL is in the file scheme or similar,
+
sourcepub 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.
\ 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.
\ 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§
- A drop guard to clean up test infrastructure.
- Handle and drop guard for test DNS and Pkarr servers.
Functions§
- Create a DNS resolver with a single nameserver.
- Runs a relay server with STUN and QUIC enabled suitable for tests.
- Runs a relay server.
- Runs a relay server with STUN enabled suitable for tests.
\ 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§
Auto Trait Implementations§
§impl Freeze for CleanupDropGuard
§impl !RefUnwindSafe for CleanupDropGuard
§impl Send for CleanupDropGuard
§impl Sync for CleanupDropGuard
§impl Unpin for CleanupDropGuard
§impl !UnwindSafe for CleanupDropGuard
Blanket Implementations§
source§impl<T> Any for Twhere
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: StringThe node origin domain.
§nameserver: SocketAddrThe 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
Struct iroh::discovery::ConcurrentDiscovery
source · pub struct ConcurrentDiscovery { /* private fields */ }Expand description
A discovery service that combines multiple discovery sources.
+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
impl ConcurrentDiscovery
sourcepub fn empty() -> Self
pub fn empty() -> Self
Creates an empty ConcurrentDiscovery.
sourcepub fn from_services(services: Vec<Box<dyn Discovery>>) -> Self
pub fn from_services(services: Vec<Box<dyn Discovery>>) -> Self
Creates a new ConcurrentDiscovery.
Trait Implementations§
source§impl Debug for ConcurrentDiscovery
impl Debug for ConcurrentDiscovery
source§impl Default for ConcurrentDiscovery
impl Default for ConcurrentDiscovery
source§fn default() -> ConcurrentDiscovery
fn default() -> ConcurrentDiscovery
source§impl Discovery for ConcurrentDiscovery
impl Discovery for ConcurrentDiscovery
Implementations§
source§impl ConcurrentDiscovery
impl ConcurrentDiscovery
sourcepub fn empty() -> Self
pub fn empty() -> Self
Creates an empty ConcurrentDiscovery.
sourcepub fn from_services(services: Vec<Box<dyn Discovery>>) -> Self
pub fn from_services(services: Vec<Box<dyn Discovery>>) -> Self
Creates a new ConcurrentDiscovery.
Trait Implementations§
source§impl Debug for ConcurrentDiscovery
impl Debug for ConcurrentDiscovery
source§impl Default for ConcurrentDiscovery
impl Default for ConcurrentDiscovery
source§fn default() -> ConcurrentDiscovery
fn default() -> ConcurrentDiscovery
source§impl Discovery for ConcurrentDiscovery
impl Discovery for ConcurrentDiscovery
source§impl<T> From<T> for ConcurrentDiscovery
impl<T> From<T> for ConcurrentDiscovery
Auto Trait Implementations§
impl Freeze for ConcurrentDiscovery
impl !RefUnwindSafe for ConcurrentDiscovery
impl Send for ConcurrentDiscovery
impl Sync for ConcurrentDiscovery
impl Unpin for ConcurrentDiscovery
impl !UnwindSafe for ConcurrentDiscovery
Blanket Implementations§
source§impl<T> From<T> for ConcurrentDiscovery
impl<T> From<T> for ConcurrentDiscovery
Auto Trait Implementations§
impl Freeze for ConcurrentDiscovery
impl !RefUnwindSafe for ConcurrentDiscovery
impl Send for ConcurrentDiscovery
impl Sync for ConcurrentDiscovery
impl Unpin for ConcurrentDiscovery
impl !UnwindSafe for ConcurrentDiscovery
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for DiscoveryItem
§impl RefUnwindSafe for DiscoveryItem
§impl Send for DiscoveryItem
§impl Sync for DiscoveryItem
§impl Unpin for DiscoveryItem
§impl UnwindSafe for DiscoveryItem
Blanket Implementations§
source§impl<T> Any for Twhere
+Trait Implementations§
source§impl Clone for DiscoveryItem
source§fn clone(&self) -> DiscoveryItem
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for DiscoveryItem
§impl RefUnwindSafe for DiscoveryItem
§impl Send for DiscoveryItem
§impl Sync for DiscoveryItem
§impl Unpin for DiscoveryItem
§impl UnwindSafe for DiscoveryItem
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 pub trait Discovery: Debug + Send + Sync {
+Discovery in iroh::discovery - Rust 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§
sourcefn publish(&self, _url: Option<&RelayUrl>, _addrs: &BTreeSet<SocketAddr>)
Publishes the given RelayUrl and direct addreesses to the discovery mechanism.
+Provided Methods§
sourcefn 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.
-sourcefn 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.
-sourcefn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>
Subscribe to all addresses that get passively discovered.
+sourcefn 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddrType
source§impl Display for DirectAddrType
source§impl Hash for DirectAddrType
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddrType
source§impl Display for DirectAddrType
source§impl Hash for DirectAddrType
source§impl Ord for DirectAddrType
source§impl Ord for DirectAddrType
source§fn cmp(&self, other: &DirectAddrType) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read moresource§impl PartialEq for DirectAddrType
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 ==.source§impl PartialOrd for DirectAddrType
source§impl PartialOrd for DirectAddrType
source§fn partial_cmp(&self, other: &DirectAddrType) -> Option<Ordering>
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 moresource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 pub enum RelayMode {
+RelayMode in iroh::endpoint - Rust 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§
Trait Implementations§
source§impl PartialEq for RelayMode
Implementations§
Trait Implementations§
source§impl PartialEq for RelayMode
source§impl Eq for RelayMode
source§impl StructuralPartialEq for RelayMode
Auto Trait Implementations§
§impl Freeze for RelayMode
§impl RefUnwindSafe for RelayMode
§impl Send for RelayMode
§impl Sync for RelayMode
§impl Unpin for RelayMode
§impl UnwindSafe for RelayMode
Blanket Implementations§
source§impl Eq for RelayMode
source§impl StructuralPartialEq for RelayMode
Auto Trait Implementations§
§impl Freeze for RelayMode
§impl RefUnwindSafe for RelayMode
§impl Send for RelayMode
§impl Sync for RelayMode
§impl Unpin for RelayMode
§impl UnwindSafe for RelayMode
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
The Endpoint allows establishing connections to other iroh nodes.
+iroh::endpoint - Rust 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§
- Future produced by
Endpoint::accept. - Future produced by
Connection::accept_bi - Future produced by
Connection::accept_uni - Parameters for controlling the peer’s acknowledgement frequency
- Reason given by an application for closing the connection
- Builder for
Endpoint. - A cheaply cloneable and sliceable chunk of contiguous memory.
- A chunk of data from the receive stream
- Error indicating that a stream has not been opened or has already been finished or reset
- In-progress connection attempt future
- A QUIC connection.
- Reason given by the transport for closing the connection
- Connection statistics
- Stream returning
ConnectionTypes - Generic crypto errors
- A direct address on which an iroh-node might be contactable.
- Information about a direct address.
- Stream returning local endpoints as they change.
- Controls an iroh node, establishing connections with other nodes.
- Error returned by [Session::export_keying_material].
- Number of frames transmitted of each frame type
- An incoming connection for which the server has not yet begun its parts of the
handshake.
- Parameters governing MTU discovery.
- Network-level addressing information for an iroh node.
- Future produced by
Connection::open_bi - Future produced by
Connection::open_uni - Statistics related to a transmission path
- Future produced by
Connection::read_datagram - A stream that can only be used to receive data
- Details about a remote iroh node which is known to this node.
- Error for attempting to retry an [
Incoming] which already bears an address
validation token from a previous retry - A stream that can only be used to send data
- Parameters governing incoming connections
- Identifier for a stream within a particular connection
- Parameters governing the core QUIC state machine
- Transport-level errors occur when a peer violates the protocol specification
- Transport-level error code
- Statistics about UDP datagrams transmitted or received on a connection
- Error indicating that the specified QUIC version is not supported
- An integer less than 2^62
- A handle to some connection internals, use with care.
- Indicates how many bytes and chunks had been transferred in a write operation
- Future that completes when a connection is fully established
Enums§
- Options to configure what is included in a
NodeAddr. - Reasons why a connection might be lost
- The type of connection we have to the endpoint.
- The type of control message we have received.
- The type of direct address.
- Errors that arise from reading from a stream.
- Errors that arise from reading from a stream.
- Errors from
RecvStream::read_to_end - Configuration of the relay servers for an
Endpoint. - Errors that arise while waiting for a stream to be reset
- Errors that can arise when sending a datagram
- The origin or source through which an address associated with a remote node
-was discovered.
- Errors that arise while monitoring for a send stream stop from the peer
- Errors that arise from writing to a stream
Constants§
- ENV_FORCE_STAGING_RELAYSNon-
testEnvironment variable to force the use of staging relays.
Traits§
- A key for sealing data with AEAD-based algorithms
- Common interface for different congestion controllers
- Constructs controllers on demand
- Server-side configuration for the crypto protocol
- A pseudo random key for HKDF
Functions§
- Returns the default relay mode.
- Returns
true if the use of staging relays is forced. - Extract the
PublicKey from the peer’s TLS certificate. - Creates a
ServerConfig with the given secret key and limits.
\ 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§
- Environment variable to force the use of staging relays.
Traits§
- A key for sealing data with AEAD-based algorithms
- Common interface for different congestion controllers
- Constructs controllers on demand
- Server-side configuration for the crypto protocol
- A pseudo random key for HKDF
Functions§
- Returns the default relay mode.
- Returns
true if the use of staging relays is forced. - Extract the
PublicKey from the peer’s TLS certificate. - Creates a
ServerConfig with the given secret key and limits.
\ 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 pub struct Accept<'a> { /* private fields */ }
Expand description
Future produced by Endpoint::accept.
-Trait Implementations§
source§impl<'pin, 'a> Unpin for Accept<'a>where
+Accept in iroh::endpoint - Rust pub struct Accept<'a> { /* private fields */ }
Expand description
Future produced by Endpoint::accept.
+Trait Implementations§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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>,§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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 pub struct Builder { /* private fields */ }
Expand description
Builder for Endpoint.
+Builder in iroh::endpoint - Rust 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
sourcepub fn bind_addr_v4(self, addr: SocketAddrV4) -> Self
Sets the IPv4 bind address.
+Implementations§
source§impl Builder
sourcepub 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.
-sourcepub fn bind_addr_v6(self, addr: SocketAddrV6) -> Self
Sets the IPv6 bind address.
+sourcepub 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.
-sourcepub fn secret_key(self, secret_key: SecretKey) -> Self
Sets a secret key to authenticate with other peers.
+sourcepub fn secret_key(self, secret_key: SecretKey) -> Self
sourcepub fn alpns(self, alpn_protocols: Vec<Vec<u8>>) -> Self
Sets the ALPN protocols that this endpoint will accept on incoming connections.
+sourcepub fn relay_mode(self, relay_mode: RelayMode) -> Self
Sets the relay servers to assist in establishing connectivity.
+sourcepub 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.
-sourcepub fn clear_discovery(self) -> Self
Removes all discovery services from the builder.
-sourcepub fn discovery(self, discovery: Box<dyn Discovery>) -> Self
Optionally sets a discovery mechanism for this endpoint.
+sourcepub fn clear_discovery(self) -> Self
Removes all discovery services from the builder.
+sourcepub 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.
-sourcepub fn add_discovery<F, D>(self, discovery: F) -> Selfwhere
+
sourcepub fn add_discovery<F, D>(self, discovery: F) -> Self
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.
-sourcepub fn discovery_n0(self) -> Self
Configures the endpoint to use the default n0 DNS discovery service.
+sourcepub 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.
-sourcepub 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.
+sourcepub 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.
-sourcepub fn discovery_local_network(self) -> Self
Available on crate feature discovery-local-network only.
Configures the endpoint to also use local network discovery.
+sourcepub 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.
-sourcepub fn known_nodes(self, nodes: Vec<NodeAddr>) -> Self
Optionally set a list of known nodes.
-sourcepub fn transport_config(self, transport_config: TransportConfig) -> Self
Sets a custom quinn::TransportConfig for this endpoint.
+sourcepub fn known_nodes(self, nodes: Vec<NodeAddr>) -> Self
Optionally set a list of known nodes.
+sourcepub 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.
-sourcepub fn dns_resolver(self, dns_resolver: DnsResolver) -> Self
Optionally sets a custom DNS resolver to use for this endpoint.
+sourcepub 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.
-sourcepub fn proxy_url(self, url: Url) -> Self
Sets an explicit proxy url to proxy all HTTP(S) traffic through.
-sourcepub fn proxy_from_env(self) -> Self
Sets the proxy url from the environment, in this order:
+sourcepub fn proxy_url(self, url: Url) -> Self
Sets an explicit proxy url to proxy all HTTP(S) traffic through.
+sourcepub fn proxy_from_env(self) -> Self
Sets the proxy url from the environment, in this order:
HTTP_PROXY
http_proxy
HTTPS_PROXY
https_proxy
-sourcepub fn keylog(self, keylog: bool) -> Self
Enables saving the TLS pre-master key for connections.
+sourcepub 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.
-sourcepub 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
+sourcepub 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§
Auto Trait Implementations§
§impl !Freeze for Builder
§impl !RefUnwindSafe for Builder
§impl Send for Builder
§impl Sync for Builder
§impl Unpin for Builder
§impl !UnwindSafe for Builder
Blanket Implementations§
Trait Implementations§
Auto Trait Implementations§
§impl !Freeze for Builder
§impl !RefUnwindSafe for Builder
§impl Send for Builder
§impl Sync for Builder
§impl Unpin for Builder
§impl !UnwindSafe for Builder
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§
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 · sourcepub fn to_ascii_uppercase(&self) -> Vec<u8> ⓘ
Returns a vector containing a copy of this slice where each byte
+
1.23.0 · sourcepub 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 · sourcepub fn to_ascii_lowercase(&self) -> Vec<u8> ⓘ
Returns a vector containing a copy of this slice where each byte
+
1.23.0 · sourcepub 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 · sourcepub 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.
sourcepub fn to_vec_in<A>(&self, alloc: A) -> Vec<T, A>
🔬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 · sourcepub 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.§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 copy_to_bytes(&mut self, len: usize) -> Bytes
§fn chunks_vectored<'a>(&'a self, dst: &mut [IoSlice<'a>]) -> usize
§fn chunks_vectored<'a>(&'a self, dst: &mut [IoSlice<'a>]) -> usize
Available on crate feature std only.§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])
§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 moreSized,§impl FromIterator<u8> for Bytes
§impl FromIterator<u8> for Bytes
§impl<S> FromRequest<S> for Bytes
§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 Hwhere
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>
§fn in_current_span(self) -> Instrumented<Self>
source§impl<T, U> Into<U> for Twhere
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
sourcepub fn into_0rtt(self) -> Result<(Connection, ZeroRttAccepted), Self>
Convert into a 0-RTT or 0.5-RTT connection at the cost of weakened security.
-sourcepub async fn handshake_data(&mut self) -> Result<Box<dyn Any>, ConnectionError>
Parameters negotiated during the handshake
-sourcepub fn local_ip(&self) -> Option<IpAddr>
The local IP address which was used when the peer established the connection.
-sourcepub fn remote_address(&self) -> SocketAddr
The peer’s UDP address.
-Trait Implementations§
source§impl Debug for Connecting
source§impl Future for Connecting
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for Connectingwhere
+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
sourcepub fn into_0rtt(self) -> Result<(Connection, ZeroRttAccepted), Self>
Convert into a 0-RTT or 0.5-RTT connection at the cost of weakened security.
+sourcepub async fn handshake_data(&mut self) -> Result<Box<dyn Any>, ConnectionError>
Parameters negotiated during the handshake
+sourcepub fn local_ip(&self) -> Option<IpAddr>
The local IP address which was used when the peer established the connection.
+sourcepub fn remote_address(&self) -> SocketAddr
The peer’s UDP address.
+Trait Implementations§
source§impl Debug for Connecting
source§impl Future for Connecting
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for Connectingwhere
PinnedFieldsOf<__Connecting<'pin>>: Unpin,
Auto Trait Implementations§
§impl Freeze for Connecting
§impl !RefUnwindSafe for Connecting
§impl Send for Connecting
§impl Sync for Connecting
§impl !UnwindSafe for Connecting
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§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§impl<S> StreamExt for Swhere
+ 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§impl<S> StreamExt for Swhere
S: Stream + ?Sized,
Sized,
S: Stream<Item = Self::Item>,
§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§impl<S1> StreamExt for S1where
+ 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 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 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 moreRead 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§impl<T> StreamExt for Twhere
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, ()>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>
) -> FlatMapUnordered<Self, U, F>
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 moreRuns 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 moreSized,
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 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>>
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>>
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>
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>
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>,
Available on crate features sink and alloc only.§fn inspect<F>(self, f: F) -> Inspect<Self, F>
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: SocketAddrThe address.
§typ: DirectAddrTypeThe origin of this direct address.
-Trait Implementations§
source§impl Clone for DirectAddr
source§fn clone(&self) -> DirectAddr
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddr
source§impl Hash for DirectAddr
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddr
source§impl Hash for DirectAddr
source§impl Ord for DirectAddr
source§impl Ord for DirectAddr
source§fn cmp(&self, other: &DirectAddr) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read moresource§impl PartialEq for DirectAddr
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 ==.source§impl PartialOrd for DirectAddr
source§impl PartialOrd for DirectAddr
source§fn partial_cmp(&self, other: &DirectAddr) -> Option<Ordering>
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 moresource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§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§impl Stream for DirectAddrsStream
Sized,
S: Stream<Item = Self::Item>,§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
§impl<S> StreamExt for Swhere
+ 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§impl<S> StreamExt for Swhere
S: Stream + ?Sized,
Sized,
S: Stream<Item = Self::Item>,§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§impl<S1> StreamExt for S1where
+ 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 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 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 moreRead 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
§impl<T> StreamExt for Twhere
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, ()>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>
) -> FlatMapUnordered<Self, U, F>
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 moreRuns 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 moreSized,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 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>>
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>>
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>
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>
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>,
Available on crate features sink and alloc only.§fn inspect<F>(self, f: F) -> Inspect<Self, F>
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 pub struct Endpoint { /* private fields */ }
Expand description
Controls an iroh node, establishing connections with other nodes.
+Endpoint in iroh::endpoint - Rust 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
sourcepub fn builder() -> Builder
Returns the builder for an Endpoint, with a production configuration.
-sourcepub fn set_alpns(&self, alpns: Vec<Vec<u8>>) -> Result<()>
Sets the list of accepted ALPN protocols.
+Implementations§
source§impl Endpoint
sourcepub fn builder() -> Builder
Returns the builder for an Endpoint, with a production configuration.
+sourcepub 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.
-
sourcepub 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.
-sourcepub fn add_node_addr(&self, node_addr: NodeAddr) -> Result<()>
Informs this Endpoint about addresses of the iroh node.
+sourcepub 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.
-sourcepub fn add_node_addr_with_source(
+
sourcepub fn secret_key(&self) -> &SecretKey
Returns the secret_key of this endpoint.
-sourcepub fn secret_key(&self) -> &SecretKey
Returns the secret_key of this endpoint.
+sourcepub 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.
-sourcepub async fn node_addr(&self) -> Result<NodeAddr>
Returns the current NodeAddr for this endpoint.
+sourcepub 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.
-sourcepub fn home_relay(&self) -> Option<RelayUrl>
Returns the RelayUrl of the Relay server used as home relay.
+sourcepub 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.
-sourcepub fn watch_home_relay(&self) -> impl Stream<Item = RelayUrl>
Watches for changes to the home relay.
+sourcepub 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.
-sourcepub fn direct_addresses(&self) -> DirectAddrsStream
Returns the direct addresses of this Endpoint.
+sourcepub 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;
-sourcepub fn bound_sockets(&self) -> (SocketAddr, Option<SocketAddr>)
Returns the local socket addresses on which the underlying sockets are bound.
+sourcepub 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.
-sourcepub fn remote_info(&self, node_id: NodeId) -> Option<RemoteInfo>
Returns information about the remote node identified by a NodeId.
+sourcepub 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.
-sourcepub fn remote_info_iter(&self) -> impl Iterator<Item = RemoteInfo>
Returns information about all the remote nodes this Endpoint knows about.
+sourcepub 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.
-sourcepub fn conn_type_stream(&self, node_id: NodeId) -> Result<ConnectionTypeStream>
Returns a stream that reports connection type changes for the remote node.
+sourcepub 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.
-sourcepub fn dns_resolver(&self) -> &DnsResolver
Returns the DNS resolver used in this Endpoint.
+sourcepub fn dns_resolver(&self) -> &DnsResolver
Returns the DNS resolver used in this Endpoint.
See Builder::discovery.
-sourcepub fn discovery(&self) -> Option<&dyn Discovery>
Returns the discovery mechanism, if configured.
+sourcepub fn discovery(&self) -> Option<&dyn Discovery>
Returns the discovery mechanism, if configured.
-sourcepub async fn network_change(&self)
Notifies the system of potential network changes.
+sourcepub 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.
-sourcepub 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.
-Trait Implementations§
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§
Trait Implementations§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 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 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
sourcepub fn accept(self) -> Result<Connecting, ConnectionError>
Attempts to accept this incoming connection (an error may still occur).
+Implementations§
source§impl Incoming
sourcepub 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.
-sourcepub fn accept_with(
+
sourcepub fn accept_with(
self,
server_config: Arc<ServerConfig>
) -> Result<Connecting, ConnectionError>
Accepts this incoming connection using a custom configuration.
See accept() for more details.
-sourcepub fn retry(self) -> Result<(), RetryError>
Responds with a retry packet.
+sourcepub 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.
-sourcepub fn ignore(self)
Ignores this incoming connection attempt, not sending any packet in response.
-sourcepub fn local_ip(&self) -> Option<IpAddr>
Returns the local IP address which was used when the peer established the
+
sourcepub fn ignore(self)
Ignores this incoming connection attempt, not sending any packet in response.
+sourcepub fn local_ip(&self) -> Option<IpAddr>
Returns the local IP address which was used when the peer established the
connection.
-sourcepub fn remote_address(&self) -> SocketAddr
Returns the peer’s UDP address.
-sourcepub fn remote_address_validated(&self) -> bool
Whether the socket address that is initiating this connection has been validated.
+sourcepub fn remote_address(&self) -> SocketAddr
Returns the peer’s UDP address.
+sourcepub 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 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 moreAuto Trait Implementations§
§impl !Freeze for Incoming
§impl !RefUnwindSafe for Incoming
§impl Send for Incoming
§impl Sync for Incoming
§impl Unpin for Incoming
§impl !UnwindSafe for Incoming
Blanket Implementations§
Trait Implementations§
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 moreAuto Trait Implementations§
§impl !Freeze for Incoming
§impl !RefUnwindSafe for Incoming
§impl Send for Incoming
§impl Sync for Incoming
§impl Unpin for Incoming
§impl !UnwindSafe for Incoming
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§impl Future for IncomingFuture
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for IncomingFuturewhere
+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§impl Future for IncomingFuture
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for IncomingFuturewhere
PinnedFieldsOf<__IncomingFuture<'pin>>: Unpin,
Auto Trait Implementations§
§impl !Freeze for IncomingFuture
§impl !RefUnwindSafe for IncomingFuture
§impl Send for IncomingFuture
§impl Sync for IncomingFuture
§impl !UnwindSafe for IncomingFuture
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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
§fn poll_write(
+
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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 Expand description
The blake3 hash used in Iroh.
+iroh::hash - Rust
\ 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 moresource§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
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more1.21.0 · source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more1.50.0 · source§fn clamp(self, min: Self, max: Self) -> Selfwhere
@@ -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 widthsource§fn from_bytes<'a>(data: &'a [u8]) -> <Hash as Value>::SelfType<'a>where
+ S: Serializer,
Serialize this value into the given Serde serializer. Read moresource§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 widthsource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: HashThe hash
§format: BlobFormatThe format
-Implementations§
source§impl HashAndFormat
sourcepub fn new(hash: Hash, format: BlobFormat) -> HashAndFormat
Create a new hash and format pair.
-sourcepub fn raw(hash: Hash) -> HashAndFormat
Create a new hash and format pair, using the default (raw) format.
-sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for HashAndFormat
source§impl<'de> Deserialize<'de> for HashAndFormat
source§fn deserialize<D>(
+
Implementations§
source§impl HashAndFormat
sourcepub fn new(hash: Hash, format: BlobFormat) -> HashAndFormat
Create a new hash and format pair.
+sourcepub fn raw(hash: Hash) -> HashAndFormat
Create a new hash and format pair, using the default (raw) format.
+sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for HashAndFormat
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 moresource§impl Display for HashAndFormat
source§impl FromStr for HashAndFormat
source§impl Hash for HashAndFormat
source§impl Display for HashAndFormat
source§impl FromStr for HashAndFormat
source§impl Hash for HashAndFormat
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.source§impl PartialOrd for HashAndFormat
source§fn partial_cmp(&self, other: &HashAndFormat) -> Option<Ordering>
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 moresource§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 moresource§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 widthsource§fn from_bytes<'a>(data: &'a [u8]) -> <HashAndFormat as Value>::SelfType<'a>where
+ S: Serializer,
Serialize this value into the given Serde serializer. Read moresource§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 widthsource§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 typesource§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§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
Peer-to-peer QUIC connections.
+iroh - Rust 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§
pub use endpoint::Endpoint;pub use endpoint::RelayMode;pub use iroh_relay as relay;
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_utils
test or test-utilsInternal 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§
- Options to configure what is included in a
NodeAddr.
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-utilsInternal 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§
- Options to configure what is included in a
NodeAddr.
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 Expand description
Cryptographic key handling for iroh.
+iroh::key - Rust
\ 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.
Trait Implementations§
§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 Copy for Signature
§impl Eq for Signature
§impl StructuralPartialEq for Signature
Auto Trait Implementations§
§impl Freeze for Signature
§impl RefUnwindSafe for Signature
§impl Send for Signature
§impl Sync for Signature
§impl Unpin for Signature
§impl UnwindSafe for Signature
Blanket Implementations§
source§impl<T> Any for Twhere
+ S: Serializer,
Serialize this value into the given Serde serializer. Read more§impl SignatureEncoding for Signature
§impl Copy for Signature
§impl Eq for Signature
§impl StructuralPartialEq for Signature
Auto Trait Implementations§
§impl Freeze for Signature
§impl RefUnwindSafe for Signature
§impl Send for Signature
§impl Sync for Signature
§impl Unpin for Signature
§impl UnwindSafe for Signature
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
Co-locating all of the iroh metrics structs
+iroh::metrics - Rust Expand description
Co-locating all of the iroh metrics structs
Structs§
- Enum of metrics for the module
- Enum of metrics for the module
- Enum of metrics for the module
- RelayMetrics
test-utilsMetrics tracked for the relay server
\ 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: CounterNumber of nodes we have managed to contact directly.
§connection_handshake_success: CounterNumber of connections with a successful handshake.
§connection_became_direct: CounterNumber of connections with a successful handshake that became direct.
-Trait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
Access to this metrics group to record a metric.
+Trait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterTrait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
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: CounterTrait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterTrait Implementations§
§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
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: CounterTrait Implementations§
§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterNumber of unique client keys per day
§websocket_accepts: CounterNumber of accepted websocket connections
§derp_accepts: CounterNumber of accepted ‘iroh derp http’ connection upgrades
-Trait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
Access to this metrics group to record a metric.
+Trait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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().
sourcepub 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.
-sourcepub fn to_file_path(&self) -> Result<PathBuf, ()>
Assuming the URL is in the file scheme or similar,
+
sourcepub 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.
\ 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.
\ 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§
- A drop guard to clean up test infrastructure.
- Handle and drop guard for test DNS and Pkarr servers.
Functions§
- Create a DNS resolver with a single nameserver.
- Runs a relay server with STUN and QUIC enabled suitable for tests.
- Runs a relay server.
- Runs a relay server with STUN enabled suitable for tests.
\ 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§
Auto Trait Implementations§
§impl Freeze for CleanupDropGuard
§impl !RefUnwindSafe for CleanupDropGuard
§impl Send for CleanupDropGuard
§impl Sync for CleanupDropGuard
§impl Unpin for CleanupDropGuard
§impl !UnwindSafe for CleanupDropGuard
Blanket Implementations§
source§impl<T> Any for Twhere
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: StringThe node origin domain.
§nameserver: SocketAddrThe 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
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for DiscoveryItem
§impl RefUnwindSafe for DiscoveryItem
§impl Send for DiscoveryItem
§impl Sync for DiscoveryItem
§impl Unpin for DiscoveryItem
§impl UnwindSafe for DiscoveryItem
Blanket Implementations§
source§impl<T> Any for Twhere
+Trait Implementations§
source§impl Clone for DiscoveryItem
source§fn clone(&self) -> DiscoveryItem
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto Trait Implementations§
§impl Freeze for DiscoveryItem
§impl RefUnwindSafe for DiscoveryItem
§impl Send for DiscoveryItem
§impl Sync for DiscoveryItem
§impl Unpin for DiscoveryItem
§impl UnwindSafe for DiscoveryItem
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 pub trait Discovery: Debug + Send + Sync {
+Discovery in iroh::discovery - Rust 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§
sourcefn publish(&self, _url: Option<&RelayUrl>, _addrs: &BTreeSet<SocketAddr>)
Publishes the given RelayUrl and direct addreesses to the discovery mechanism.
+Provided Methods§
sourcefn 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.
-sourcefn 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.
-sourcefn subscribe(&self) -> Option<BoxStream<DiscoveryItem>>
Subscribe to all addresses that get passively discovered.
+sourcefn 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddrType
source§impl Display for DirectAddrType
source§impl Hash for DirectAddrType
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddrType
source§impl Display for DirectAddrType
source§impl Hash for DirectAddrType
source§impl Ord for DirectAddrType
source§impl Ord for DirectAddrType
source§fn cmp(&self, other: &DirectAddrType) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read moresource§impl PartialEq for DirectAddrType
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 ==.source§impl PartialOrd for DirectAddrType
source§impl PartialOrd for DirectAddrType
source§fn partial_cmp(&self, other: &DirectAddrType) -> Option<Ordering>
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 moresource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 pub enum RelayMode {
+RelayMode in iroh::endpoint - Rust 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§
Trait Implementations§
source§impl PartialEq for RelayMode
Implementations§
Trait Implementations§
source§impl PartialEq for RelayMode
source§impl Eq for RelayMode
source§impl StructuralPartialEq for RelayMode
Auto Trait Implementations§
§impl Freeze for RelayMode
§impl RefUnwindSafe for RelayMode
§impl Send for RelayMode
§impl Sync for RelayMode
§impl Unpin for RelayMode
§impl UnwindSafe for RelayMode
Blanket Implementations§
source§impl Eq for RelayMode
source§impl StructuralPartialEq for RelayMode
Auto Trait Implementations§
§impl Freeze for RelayMode
§impl RefUnwindSafe for RelayMode
§impl Send for RelayMode
§impl Sync for RelayMode
§impl Unpin for RelayMode
§impl UnwindSafe for RelayMode
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
The Endpoint allows establishing connections to other iroh nodes.
+iroh::endpoint - Rust 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§
- Future produced by
Endpoint::accept. - Future produced by
Connection::accept_bi - Future produced by
Connection::accept_uni - Parameters for controlling the peer’s acknowledgement frequency
- Reason given by an application for closing the connection
- Builder for
Endpoint. - A cheaply cloneable and sliceable chunk of contiguous memory.
- A chunk of data from the receive stream
- Error indicating that a stream has not been opened or has already been finished or reset
- In-progress connection attempt future
- A QUIC connection.
- Reason given by the transport for closing the connection
- Connection statistics
- Stream returning
ConnectionTypes - Generic crypto errors
- A direct address on which an iroh-node might be contactable.
- Information about a direct address.
- Stream returning local endpoints as they change.
- Controls an iroh node, establishing connections with other nodes.
- Error returned by [Session::export_keying_material].
- Number of frames transmitted of each frame type
- An incoming connection for which the server has not yet begun its parts of the
handshake.
- Parameters governing MTU discovery.
- Network-level addressing information for an iroh node.
- Future produced by
Connection::open_bi - Future produced by
Connection::open_uni - Statistics related to a transmission path
- Future produced by
Connection::read_datagram - A stream that can only be used to receive data
- Details about a remote iroh node which is known to this node.
- Error for attempting to retry an [
Incoming] which already bears an address
validation token from a previous retry - A stream that can only be used to send data
- Parameters governing incoming connections
- Identifier for a stream within a particular connection
- Parameters governing the core QUIC state machine
- Transport-level errors occur when a peer violates the protocol specification
- Transport-level error code
- Statistics about UDP datagrams transmitted or received on a connection
- Error indicating that the specified QUIC version is not supported
- An integer less than 2^62
- A handle to some connection internals, use with care.
- Indicates how many bytes and chunks had been transferred in a write operation
- Future that completes when a connection is fully established
Enums§
- Options to configure what is included in a
NodeAddr. - Reasons why a connection might be lost
- The type of connection we have to the endpoint.
- The type of control message we have received.
- The type of direct address.
- Errors that arise from reading from a stream.
- Errors that arise from reading from a stream.
- Errors from
RecvStream::read_to_end - Configuration of the relay servers for an
Endpoint. - Errors that arise while waiting for a stream to be reset
- Errors that can arise when sending a datagram
- The origin or source through which an address associated with a remote node
-was discovered.
- Errors that arise while monitoring for a send stream stop from the peer
- Errors that arise from writing to a stream
Constants§
- ENV_FORCE_STAGING_RELAYSNon-
testEnvironment variable to force the use of staging relays.
Traits§
- A key for sealing data with AEAD-based algorithms
- Common interface for different congestion controllers
- Constructs controllers on demand
- Server-side configuration for the crypto protocol
- A pseudo random key for HKDF
Functions§
- Returns the default relay mode.
- Returns
true if the use of staging relays is forced. - Extract the
PublicKey from the peer’s TLS certificate. - Creates a
ServerConfig with the given secret key and limits.
\ 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§
- Environment variable to force the use of staging relays.
Traits§
- A key for sealing data with AEAD-based algorithms
- Common interface for different congestion controllers
- Constructs controllers on demand
- Server-side configuration for the crypto protocol
- A pseudo random key for HKDF
Functions§
- Returns the default relay mode.
- Returns
true if the use of staging relays is forced. - Extract the
PublicKey from the peer’s TLS certificate. - Creates a
ServerConfig with the given secret key and limits.
\ 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 pub struct Accept<'a> { /* private fields */ }
Expand description
Future produced by Endpoint::accept.
-Trait Implementations§
source§impl<'pin, 'a> Unpin for Accept<'a>where
+Accept in iroh::endpoint - Rust pub struct Accept<'a> { /* private fields */ }
Expand description
Future produced by Endpoint::accept.
+Trait Implementations§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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>,§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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 pub struct Builder { /* private fields */ }
Expand description
Builder for Endpoint.
+Builder in iroh::endpoint - Rust 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
sourcepub fn bind_addr_v4(self, addr: SocketAddrV4) -> Self
Sets the IPv4 bind address.
+Implementations§
source§impl Builder
sourcepub 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.
-sourcepub fn bind_addr_v6(self, addr: SocketAddrV6) -> Self
Sets the IPv6 bind address.
+sourcepub 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.
-sourcepub fn secret_key(self, secret_key: SecretKey) -> Self
Sets a secret key to authenticate with other peers.
+sourcepub fn secret_key(self, secret_key: SecretKey) -> Self
sourcepub fn alpns(self, alpn_protocols: Vec<Vec<u8>>) -> Self
Sets the ALPN protocols that this endpoint will accept on incoming connections.
+sourcepub fn relay_mode(self, relay_mode: RelayMode) -> Self
Sets the relay servers to assist in establishing connectivity.
+sourcepub 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.
-sourcepub fn clear_discovery(self) -> Self
Removes all discovery services from the builder.
-sourcepub fn discovery(self, discovery: Box<dyn Discovery>) -> Self
Optionally sets a discovery mechanism for this endpoint.
+sourcepub fn clear_discovery(self) -> Self
Removes all discovery services from the builder.
+sourcepub 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.
-sourcepub fn add_discovery<F, D>(self, discovery: F) -> Selfwhere
+
sourcepub fn add_discovery<F, D>(self, discovery: F) -> Self
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.
-sourcepub fn discovery_n0(self) -> Self
Configures the endpoint to use the default n0 DNS discovery service.
+sourcepub 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.
-sourcepub 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.
+sourcepub 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.
-sourcepub fn discovery_local_network(self) -> Self
Available on crate feature discovery-local-network only.
Configures the endpoint to also use local network discovery.
+sourcepub 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.
-sourcepub fn known_nodes(self, nodes: Vec<NodeAddr>) -> Self
Optionally set a list of known nodes.
-sourcepub fn transport_config(self, transport_config: TransportConfig) -> Self
Sets a custom quinn::TransportConfig for this endpoint.
+sourcepub fn known_nodes(self, nodes: Vec<NodeAddr>) -> Self
Optionally set a list of known nodes.
+sourcepub 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.
-sourcepub fn dns_resolver(self, dns_resolver: DnsResolver) -> Self
Optionally sets a custom DNS resolver to use for this endpoint.
+sourcepub 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.
-sourcepub fn proxy_url(self, url: Url) -> Self
Sets an explicit proxy url to proxy all HTTP(S) traffic through.
-sourcepub fn proxy_from_env(self) -> Self
Sets the proxy url from the environment, in this order:
+sourcepub fn proxy_url(self, url: Url) -> Self
Sets an explicit proxy url to proxy all HTTP(S) traffic through.
+sourcepub fn proxy_from_env(self) -> Self
Sets the proxy url from the environment, in this order:
HTTP_PROXY
http_proxy
HTTPS_PROXY
https_proxy
-sourcepub fn keylog(self, keylog: bool) -> Self
Enables saving the TLS pre-master key for connections.
+sourcepub 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.
-sourcepub 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
+sourcepub 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§
Auto Trait Implementations§
§impl !Freeze for Builder
§impl !RefUnwindSafe for Builder
§impl Send for Builder
§impl Sync for Builder
§impl Unpin for Builder
§impl !UnwindSafe for Builder
Blanket Implementations§
Trait Implementations§
Auto Trait Implementations§
§impl !Freeze for Builder
§impl !RefUnwindSafe for Builder
§impl Send for Builder
§impl Sync for Builder
§impl Unpin for Builder
§impl !UnwindSafe for Builder
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§
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 · sourcepub fn to_ascii_uppercase(&self) -> Vec<u8> ⓘ
Returns a vector containing a copy of this slice where each byte
+
1.23.0 · sourcepub 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 · sourcepub fn to_ascii_lowercase(&self) -> Vec<u8> ⓘ
Returns a vector containing a copy of this slice where each byte
+
1.23.0 · sourcepub 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 · sourcepub 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.
sourcepub fn to_vec_in<A>(&self, alloc: A) -> Vec<T, A>
🔬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 · sourcepub 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.§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 copy_to_bytes(&mut self, len: usize) -> Bytes
§fn chunks_vectored<'a>(&'a self, dst: &mut [IoSlice<'a>]) -> usize
§fn chunks_vectored<'a>(&'a self, dst: &mut [IoSlice<'a>]) -> usize
Available on crate feature std only.§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])
§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 moreSized,§impl FromIterator<u8> for Bytes
§impl FromIterator<u8> for Bytes
§impl<S> FromRequest<S> for Bytes
§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 Hwhere
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>
§fn in_current_span(self) -> Instrumented<Self>
source§impl<T, U> Into<U> for Twhere
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
sourcepub fn into_0rtt(self) -> Result<(Connection, ZeroRttAccepted), Self>
Convert into a 0-RTT or 0.5-RTT connection at the cost of weakened security.
-sourcepub async fn handshake_data(&mut self) -> Result<Box<dyn Any>, ConnectionError>
Parameters negotiated during the handshake
-sourcepub fn local_ip(&self) -> Option<IpAddr>
The local IP address which was used when the peer established the connection.
-sourcepub fn remote_address(&self) -> SocketAddr
The peer’s UDP address.
-Trait Implementations§
source§impl Debug for Connecting
source§impl Future for Connecting
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for Connectingwhere
+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
sourcepub fn into_0rtt(self) -> Result<(Connection, ZeroRttAccepted), Self>
Convert into a 0-RTT or 0.5-RTT connection at the cost of weakened security.
+sourcepub async fn handshake_data(&mut self) -> Result<Box<dyn Any>, ConnectionError>
Parameters negotiated during the handshake
+sourcepub fn local_ip(&self) -> Option<IpAddr>
The local IP address which was used when the peer established the connection.
+sourcepub fn remote_address(&self) -> SocketAddr
The peer’s UDP address.
+Trait Implementations§
source§impl Debug for Connecting
source§impl Future for Connecting
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for Connectingwhere
PinnedFieldsOf<__Connecting<'pin>>: Unpin,
Auto Trait Implementations§
§impl Freeze for Connecting
§impl !RefUnwindSafe for Connecting
§impl Send for Connecting
§impl Sync for Connecting
§impl !UnwindSafe for Connecting
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§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§impl<S> StreamExt for Swhere
+ 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§impl<S> StreamExt for Swhere
S: Stream + ?Sized,
Sized,
S: Stream<Item = Self::Item>,
§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§impl<S1> StreamExt for S1where
+ 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 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 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 moreRead 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§impl<T> StreamExt for Twhere
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, ()>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>
) -> FlatMapUnordered<Self, U, F>
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 moreRuns 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 moreSized,
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 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>>
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>>
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>
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>
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>,
Available on crate features sink and alloc only.§fn inspect<F>(self, f: F) -> Inspect<Self, F>
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: SocketAddrThe address.
§typ: DirectAddrTypeThe origin of this direct address.
-Trait Implementations§
source§impl Clone for DirectAddr
source§fn clone(&self) -> DirectAddr
Returns a copy of the value. Read more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddr
source§impl Hash for DirectAddr
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for DirectAddr
source§impl Hash for DirectAddr
source§impl Ord for DirectAddr
source§impl Ord for DirectAddr
source§fn cmp(&self, other: &DirectAddr) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read moresource§impl PartialEq for DirectAddr
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 ==.source§impl PartialOrd for DirectAddr
source§impl PartialOrd for DirectAddr
source§fn partial_cmp(&self, other: &DirectAddr) -> Option<Ordering>
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 moresource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§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§impl Stream for DirectAddrsStream
Sized,
S: Stream<Item = Self::Item>,§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
§impl<S> StreamExt for Swhere
+ 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§impl<S> StreamExt for Swhere
S: Stream + ?Sized,
Sized,
S: Stream<Item = Self::Item>,§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§impl<S1> StreamExt for S1where
+ 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 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 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 moreRead 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
§impl<T> StreamExt for Twhere
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, ()>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>
) -> FlatMapUnordered<Self, U, F>
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 moreRuns 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 moreSized,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 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>>
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>>
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>
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>
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>,
Available on crate features sink and alloc only.§fn inspect<F>(self, f: F) -> Inspect<Self, F>
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 pub struct Endpoint { /* private fields */ }
Expand description
Controls an iroh node, establishing connections with other nodes.
+Endpoint in iroh::endpoint - Rust 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
sourcepub fn builder() -> Builder
Returns the builder for an Endpoint, with a production configuration.
-sourcepub fn set_alpns(&self, alpns: Vec<Vec<u8>>) -> Result<()>
Sets the list of accepted ALPN protocols.
+Implementations§
source§impl Endpoint
sourcepub fn builder() -> Builder
Returns the builder for an Endpoint, with a production configuration.
+sourcepub 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.
-
sourcepub 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.
-sourcepub fn add_node_addr(&self, node_addr: NodeAddr) -> Result<()>
Informs this Endpoint about addresses of the iroh node.
+sourcepub 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.
-sourcepub fn add_node_addr_with_source(
+
sourcepub fn secret_key(&self) -> &SecretKey
Returns the secret_key of this endpoint.
-sourcepub fn secret_key(&self) -> &SecretKey
Returns the secret_key of this endpoint.
+sourcepub 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.
-sourcepub async fn node_addr(&self) -> Result<NodeAddr>
Returns the current NodeAddr for this endpoint.
+sourcepub 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.
-sourcepub fn home_relay(&self) -> Option<RelayUrl>
Returns the RelayUrl of the Relay server used as home relay.
+sourcepub 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.
-sourcepub fn watch_home_relay(&self) -> impl Stream<Item = RelayUrl>
Watches for changes to the home relay.
+sourcepub 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.
-sourcepub fn direct_addresses(&self) -> DirectAddrsStream
Returns the direct addresses of this Endpoint.
+sourcepub 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;
-sourcepub fn bound_sockets(&self) -> (SocketAddr, Option<SocketAddr>)
Returns the local socket addresses on which the underlying sockets are bound.
+sourcepub 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.
-sourcepub fn remote_info(&self, node_id: NodeId) -> Option<RemoteInfo>
Returns information about the remote node identified by a NodeId.
+sourcepub 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.
-sourcepub fn remote_info_iter(&self) -> impl Iterator<Item = RemoteInfo>
Returns information about all the remote nodes this Endpoint knows about.
+sourcepub 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.
-sourcepub fn conn_type_stream(&self, node_id: NodeId) -> Result<ConnectionTypeStream>
Returns a stream that reports connection type changes for the remote node.
+sourcepub 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.
-sourcepub fn dns_resolver(&self) -> &DnsResolver
Returns the DNS resolver used in this Endpoint.
+sourcepub fn dns_resolver(&self) -> &DnsResolver
Returns the DNS resolver used in this Endpoint.
See Builder::discovery.
-sourcepub fn discovery(&self) -> Option<&dyn Discovery>
Returns the discovery mechanism, if configured.
+sourcepub fn discovery(&self) -> Option<&dyn Discovery>
Returns the discovery mechanism, if configured.
-sourcepub async fn network_change(&self)
Notifies the system of potential network changes.
+sourcepub 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.
-sourcepub 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.
-Trait Implementations§
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§
Trait Implementations§
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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 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 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
sourcepub fn accept(self) -> Result<Connecting, ConnectionError>
Attempts to accept this incoming connection (an error may still occur).
+Implementations§
source§impl Incoming
sourcepub 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.
-sourcepub fn accept_with(
+
sourcepub fn accept_with(
self,
server_config: Arc<ServerConfig>
) -> Result<Connecting, ConnectionError>
Accepts this incoming connection using a custom configuration.
See accept() for more details.
-sourcepub fn retry(self) -> Result<(), RetryError>
Responds with a retry packet.
+sourcepub 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.
-sourcepub fn ignore(self)
Ignores this incoming connection attempt, not sending any packet in response.
-sourcepub fn local_ip(&self) -> Option<IpAddr>
Returns the local IP address which was used when the peer established the
+
sourcepub fn ignore(self)
Ignores this incoming connection attempt, not sending any packet in response.
+sourcepub fn local_ip(&self) -> Option<IpAddr>
Returns the local IP address which was used when the peer established the
connection.
-sourcepub fn remote_address(&self) -> SocketAddr
Returns the peer’s UDP address.
-sourcepub fn remote_address_validated(&self) -> bool
Whether the socket address that is initiating this connection has been validated.
+sourcepub fn remote_address(&self) -> SocketAddr
Returns the peer’s UDP address.
+sourcepub 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 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 moreAuto Trait Implementations§
§impl !Freeze for Incoming
§impl !RefUnwindSafe for Incoming
§impl Send for Incoming
§impl Sync for Incoming
§impl Unpin for Incoming
§impl !UnwindSafe for Incoming
Blanket Implementations§
Trait Implementations§
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 moreAuto Trait Implementations§
§impl !Freeze for Incoming
§impl !RefUnwindSafe for Incoming
§impl Send for Incoming
§impl Sync for Incoming
§impl Unpin for Incoming
§impl !UnwindSafe for Incoming
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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§impl Future for IncomingFuture
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for IncomingFuturewhere
+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§impl Future for IncomingFuture
§type Output = Result<Connection, ConnectionError>
The type of value produced on completion.source§impl<'pin> Unpin for IncomingFuturewhere
PinnedFieldsOf<__IncomingFuture<'pin>>: Unpin,
Auto Trait Implementations§
§impl !Freeze for IncomingFuture
§impl !RefUnwindSafe for IncomingFuture
§impl Send for IncomingFuture
§impl Sync for IncomingFuture
§impl !UnwindSafe for IncomingFuture
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for T
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more
§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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,§impl<Fut> TryFutureExt for Futwhere
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>
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
§fn poll_write(
+
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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moreAuto 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
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>,
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F> FutureExt for F
Available on crate features std and race only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F> FutureExt for F
§fn catch_unwind(self) -> CatchUnwind<Self>where
- Self: Sized + UnwindSafe,
Catches panics while polling the future. Read more§impl<F1> FutureExt for F1
Available on crate feature std only.§fn catch_unwind(self) -> CatchUnwind<Self>where
+ Self: Sized + UnwindSafe,
Available on crate feature std only.Catches panics while polling the future. Read more§impl<F1> FutureExt for F1where
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>
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
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>>
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>
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,
Turns a Future<Output = T> into a
TryFuture<Ok = T, Error = ()>.§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 Expand description
The blake3 hash used in Iroh.
+iroh::hash - Rust
\ 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 moresource§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
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more1.21.0 · source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more1.50.0 · source§fn clamp(self, min: Self, max: Self) -> Selfwhere
@@ -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 widthsource§fn from_bytes<'a>(data: &'a [u8]) -> <Hash as Value>::SelfType<'a>where
+ S: Serializer,
Serialize this value into the given Serde serializer. Read moresource§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 widthsource§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: HashThe hash
§format: BlobFormatThe format
-Implementations§
source§impl HashAndFormat
sourcepub fn new(hash: Hash, format: BlobFormat) -> HashAndFormat
Create a new hash and format pair.
-sourcepub fn raw(hash: Hash) -> HashAndFormat
Create a new hash and format pair, using the default (raw) format.
-sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for HashAndFormat
source§impl<'de> Deserialize<'de> for HashAndFormat
source§fn deserialize<D>(
+
Implementations§
source§impl HashAndFormat
sourcepub fn new(hash: Hash, format: BlobFormat) -> HashAndFormat
Create a new hash and format pair.
+sourcepub fn raw(hash: Hash) -> HashAndFormat
Create a new hash and format pair, using the default (raw) format.
+sourcepub 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 more1.0.0 · source§fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read moresource§impl Debug for HashAndFormat
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 moresource§impl Display for HashAndFormat
source§impl FromStr for HashAndFormat
source§impl Hash for HashAndFormat
source§impl Display for HashAndFormat
source§impl FromStr for HashAndFormat
source§impl Hash for HashAndFormat
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.source§impl PartialOrd for HashAndFormat
source§fn partial_cmp(&self, other: &HashAndFormat) -> Option<Ordering>
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 moresource§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 moresource§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 widthsource§fn from_bytes<'a>(data: &'a [u8]) -> <HashAndFormat as Value>::SelfType<'a>where
+ S: Serializer,
Serialize this value into the given Serde serializer. Read moresource§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 widthsource§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 typesource§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§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 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§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
Peer-to-peer QUIC connections.
+iroh - Rust 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§
pub use endpoint::Endpoint;pub use endpoint::RelayMode;pub use iroh_relay as relay;
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_utils
test or test-utilsInternal 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§
- Options to configure what is included in a
NodeAddr.
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-utilsInternal 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§
- Options to configure what is included in a
NodeAddr.
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 Expand description
Cryptographic key handling for iroh.
+iroh::key - Rust
\ 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.
Trait Implementations§
§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 Copy for Signature
§impl Eq for Signature
§impl StructuralPartialEq for Signature
Auto Trait Implementations§
§impl Freeze for Signature
§impl RefUnwindSafe for Signature
§impl Send for Signature
§impl Sync for Signature
§impl Unpin for Signature
§impl UnwindSafe for Signature
Blanket Implementations§
source§impl<T> Any for Twhere
+ S: Serializer,
Serialize this value into the given Serde serializer. Read more§impl SignatureEncoding for Signature
§impl Copy for Signature
§impl Eq for Signature
§impl StructuralPartialEq for Signature
Auto Trait Implementations§
§impl Freeze for Signature
§impl RefUnwindSafe for Signature
§impl Send for Signature
§impl Sync for Signature
§impl Unpin for Signature
§impl UnwindSafe for Signature
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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 Expand description
Co-locating all of the iroh metrics structs
+iroh::metrics - Rust Expand description
Co-locating all of the iroh metrics structs
Structs§
- Enum of metrics for the module
- Enum of metrics for the module
- Enum of metrics for the module
- RelayMetrics
test-utilsMetrics tracked for the relay server
\ 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: CounterNumber of nodes we have managed to contact directly.
§connection_handshake_success: CounterNumber of connections with a successful handshake.
§connection_became_direct: CounterNumber of connections with a successful handshake that became direct.
-Trait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
Access to this metrics group to record a metric.
+Trait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterTrait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
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: CounterTrait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterTrait Implementations§
§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
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: CounterTrait Implementations§
§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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: CounterNumber of unique client keys per day
§websocket_accepts: CounterNumber of accepted websocket connections
§derp_accepts: CounterNumber of accepted ‘iroh derp http’ connection upgrades
-Trait Implementations§
source§impl Metric for Metrics
§fn with_metric<T, F>(f: F)
Access to this metrics group to record a metric.
+Trait Implementations§
source§impl Metric for Metrics
§fn new(registry: &mut Registry) -> Self
Available on crate feature metrics only.Initializes this metric group.§fn with_metric<T, F>(f: F)
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§
§impl Freeze for Metrics
§impl RefUnwindSafe for Metrics
§impl Send for Metrics
§impl Sync for Metrics
§impl Unpin for Metrics
§impl UnwindSafe for Metrics
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
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().
sourcepub 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.
-sourcepub fn to_file_path(&self) -> Result<PathBuf, ()>
Assuming the URL is in the file scheme or similar,
+
sourcepub 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.
\ 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.
\ 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§
- A drop guard to clean up test infrastructure.
- Handle and drop guard for test DNS and Pkarr servers.
Functions§
- Create a DNS resolver with a single nameserver.
- Runs a relay server with STUN and QUIC enabled suitable for tests.
- Runs a relay server.
- Runs a relay server with STUN enabled suitable for tests.
\ 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§
Auto Trait Implementations§
§impl Freeze for CleanupDropGuard
§impl !RefUnwindSafe for CleanupDropGuard
§impl Send for CleanupDropGuard
§impl Sync for CleanupDropGuard
§impl Unpin for CleanupDropGuard
§impl !UnwindSafe for CleanupDropGuard
Blanket Implementations§
source§impl<T> Any for Twhere
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: StringThe node origin domain.
§nameserver: SocketAddrThe 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