pub struct Hello {
pub protocol_version: u32,
pub client_name: String,
pub client_version: String,
pub platform: Platform,
pub device_name: Option<String>,
pub capabilities: Option<ClientCapabilities>,
pub experimental: Vec<String>,
pub features: Features,
pub language: Option<String>,
}Expand description
The client introduces itself. Every field is required. Each
string is cut to MAX_HELLO_TEXT characters.
Fields§
§protocol_version: u32§client_name: Stringe.g. spoolframe-linux.
client_version: String§platform: PlatformWhat kind of client this is: the server keeps it for the device, for
its device and session lists. Not taken from client_name, which
one app may share across platforms.
device_name: Option<String>What the device calls itself (a hostname, “Living room TV”); shown
in session lists. None when it has no name to give.
capabilities: Option<ClientCapabilities>What this device can play. None: every playback plan is
Unsupported.
experimental: Vec<String>The experimental features this client wants, by name
(crate::experimental); the server’s answer names those it
turned on. Left out when empty, so a client that wants none sends
what an older one did; an older server ignores it.
features: FeaturesThe regular features this client handles (crate::features);
the server’s answer names those of them it has. Left out when
empty, as an older client does; an older server ignores it.
language: Option<String>The device’s language, as BCP 47 (en-US): what a saved device
in track preferences stands for. It chooses nothing by itself.
Left out when the app says nothing, as an older client does; an
older server ignores it.
Implementations§
Source§impl Hello
impl Hello
Sourcepub fn within_bounds(self) -> Self
pub fn within_bounds(self) -> Self
This Hello with each string cut to MAX_HELLO_TEXT characters:
what a server keeps of it.