Files
VoelinClient/crates/voelin-observer/src/lib.rs
T
Claude d4a178b079 relay: post under the author's own nickname
A relay (and the gateway's lookup session, for server chat) takes the
author's nickname for each post, sends the text as written and takes its
own name back, so messages read as written by the user in TeamSpeak.
While someone has the nickname it uses Nick1 to Nick3, as TeamSpeak names
a second client of the same name; relay.format ([Nick] text) is only the
fallback when it can take none of them. Posts through one session are
serialized, since each borrows a nickname.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VZBWxxMsxUzp4PSTKVzbZN
2026-10-04 21:00:38 +00:00

18 lines
757 B
Rust

//! Invisible presence and channel-chat relays over ServerQuery.
//!
//! Query clients do not show up in normal clients' channel trees. The
//! [`Observer`] keeps a live [`Presence`](voelin_model::Presence) of a server
//! from one query session. A [`RelayPool`] puts one query session into each
//! channel whose chat someone wants to read or write without joining it.
//!
//! Used by the gateway (`tsgw`) for all of its users and by the client for
//! users who have their own query credentials.
mod convert;
mod observer;
mod relay;
pub use convert::{channel_from_row, client_from_row, delta_from_notification, is_text_message};
pub use observer::{Observer, ObserverConfig, ObserverEvent};
pub use relay::{RelayConfig, RelayEvent, RelayPool, post_as};