forked from Keelrleek/SoulStream
19 lines
954 B
Rust
19 lines
954 B
Rust
use tokio::sync::Mutex;
|
|
|
|
#[derive(Default)]
|
|
pub struct AppState {
|
|
pub client: Mutex<Option<soulseek_client::Client>>,
|
|
pub connected_as: Mutex<Option<String>>,
|
|
/// Server-distributed excluded search phrases (message 160). A query
|
|
/// containing one returns ZERO responses network-wide — the server simply
|
|
/// never routes it — so the resolver strips these terms up front instead
|
|
/// of discovering the silence by timeout. Lowercased on receipt.
|
|
pub excluded_search_phrases: Mutex<Vec<String>>,
|
|
/// The experimental Freenet layer's one handle (default: disabled, inert).
|
|
/// The privilege boundary: node operations never leave the Rust side.
|
|
pub freenet: freenet_adapter::FreenetAdapter,
|
|
/// The local Freenet peer THIS app launched (freenet.rs), if any. A node
|
|
/// started by hand is not here — the adapter finds it all the same.
|
|
pub freenet_node: std::sync::Mutex<Option<std::process::Child>>,
|
|
}
|