pub struct AttachRequest {
pub short: String,
pub auth: Option<String>,
pub cols: u32,
pub rows: u32,
}Expand description
An op:'attach' request. auth is optional: a same-uid socket attach may
omit it (“legacy client, allowed via peerUid”); when the daemon control.key
is readable we present it.
Fields§
§short: String8-hex worker short id (the roster map key) – a wire value, used only here
at the control.sock boundary, never as a footnote-side identity.
auth: Option<String>Daemon control key, or None for the same-uid no-auth path.
cols: u32§rows: u32Implementations§
Source§impl AttachRequest
impl AttachRequest
Sourcepub fn new(
short: impl Into<String>,
auth: Option<String>,
cols: u32,
rows: u32,
) -> Self
pub fn new( short: impl Into<String>, auth: Option<String>, cols: u32, rows: u32, ) -> Self
Construct an attach with an explicit window size.
Sourcepub fn for_frame_stream(short: impl Into<String>, auth: Option<String>) -> Self
pub fn for_frame_stream(short: impl Into<String>, auth: Option<String>) -> Self
Attach to pull the PTY frame stream (G2 tile render). A modest default window; the daemon accepts a non-TTY attacher and streams frames.
Sourcepub fn to_json_line(&self) -> String
pub fn to_json_line(&self) -> String
Serialize to the newline-terminated JSON line the daemon reads. caps is a
REQUIRED object; we send the minimal valid shape (terminal/mux are
nullable-required, ssh required) – the finding’s colorLevel/browser
keys are NOT in the schema and are omitted. [corroborated]
Trait Implementations§
Source§impl Clone for AttachRequest
impl Clone for AttachRequest
Source§fn clone(&self) -> AttachRequest
fn clone(&self) -> AttachRequest
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more