pub struct DirectState {Show 14 fields
pub network_name: String,
pub network_secret: String,
pub topic_hash: String,
pub network_id: Uuid,
pub coordinator: bool,
pub open: bool,
pub assigned_ipv4: Ipv4Addr,
pub collision_index: u8,
pub hostname: String,
pub coordinator_endpoint_id: Option<String>,
pub doc_ticket: Option<String>,
pub namespace_id: Option<String>,
pub auto_accept_firewall: bool,
pub created_at: DateTime<Utc>,
}Expand description
Direct-mode P2P network state (no control plane).
Fields§
§network_name: String§network_secret: StringHex-encoded 32-byte network secret (PSK). In-memory only - sealed in state.enc.
topic_hash: StringHex topic id = blake3(network_name || secret).
network_id: UuidDeterministic UUID derived from topic_hash (for IPC / gossip topic helpers).
coordinator: bool§open: boolAuto-admit valid invite codes without manual approval.
assigned_ipv4: Ipv4Addr§collision_index: u8§hostname: String§coordinator_endpoint_id: Option<String>Optional coordinator endpoint id (hex) known at join time.
doc_ticket: Option<String>iroh-docs write ticket. In-memory only - sealed in state.enc.
namespace_id: Option<String>iroh-docs namespace id (hex). Network document identity.
auto_accept_firewall: boolAuto-accept coordinator firewall policy suggestions.
created_at: DateTime<Utc>Trait Implementations§
Source§impl Clone for DirectState
impl Clone for DirectState
Source§impl Debug for DirectState
impl Debug for DirectState
Source§impl<'de> Deserialize<'de> for DirectState
impl<'de> Deserialize<'de> for DirectState
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for DirectState
impl RefUnwindSafe for DirectState
impl Send for DirectState
impl Sync for DirectState
impl Unpin for DirectState
impl UnsafeUnpin for DirectState
impl UnwindSafe for DirectState
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more