pub struct NativePersonalSession { /* private fields */ }Expand description
One generic app session with at most one personal call. It is not Clone and never auto-renews authentication, redials, fabricates a callee Join for caller context, or retries an uncertain action. Callers persist state.cookie changes even when subsequent app parsing fails.
Implementations§
Source§impl NativePersonalSession
impl NativePersonalSession
Sourcepub fn authenticate(
client: &impl PersonalTransport,
state: &mut AccountState,
authority: AppAuthority,
host_task: u32,
device32: [u8; 32],
parameters: VoiceParameters,
) -> Result<Self>
pub fn authenticate( client: &impl PersonalTransport, state: &mut AccountState, authority: AppAuthority, host_task: u32, device32: [u8; 32], parameters: VoiceParameters, ) -> Result<Self>
Perform exactly one generic7994 request after the host has journaled its
original intent. device32 is fresh own app identity from a secure RNG.
pub fn phase(&self) -> PersonalPhase
Sourcepub fn peer_microphone_muted(&self) -> Option<bool>
pub fn peer_microphone_muted(&self) -> Option<bool>
Current authenticated remote microphone state while joined. This is independent of membership, codec selection and whether media is audible.
Sourcepub fn has_allocated_control(&self) -> bool
pub fn has_allocated_control(&self) -> bool
Allocated control identity survives a later media-admission failure. It does not by itself authorize Cancel or Exit; the current phase still must prove pending versus joined membership.
pub fn media_ready( &self, state: &AccountState, current: AppAuthority, ) -> Result<bool>
pub fn invite( &mut self, client: &impl PersonalTransport, state: &mut AccountState, current: AppAuthority, peer: &str, invite_id: u64, tasks: TaskIds, ) -> Result<()>
Sourcepub fn poll(
&mut self,
client: &impl PersonalTransport,
state: &mut AccountState,
current: AppAuthority,
tasks: TaskIds,
) -> Result<SyncProgress>
pub fn poll( &mut self, client: &impl PersonalTransport, state: &mut AccountState, current: AppAuthority, tasks: TaskIds, ) -> Result<SyncProgress>
One caller LiveSync with source-selected timeout. Install all supported effects atomically, then cookies. Unknown or post-media reconfiguration stops with the old cursor retained and no automatic next poll.
Sourcepub fn take_media(
&mut self,
state: &AccountState,
current: AppAuthority,
connection_index: usize,
udp_index: usize,
) -> Result<NegotiatedMedia>
pub fn take_media( &mut self, state: &AccountState, current: AppAuthority, connection_index: usize, udp_index: usize, ) -> Result<NegotiatedMedia>
Move one admitted media context out only after current roster/capability/AV state agrees. This never constructs a synthetic callee Join response.
Sourcepub fn cancel(
&mut self,
client: &impl PersonalTransport,
state: &mut AccountState,
current: AppAuthority,
tasks: TaskIds,
) -> Result<()>
pub fn cancel( &mut self, client: &impl PersonalTransport, state: &mut AccountState, current: AppAuthority, tasks: TaskIds, ) -> Result<()>
Cancel the original unanswered personal invitation once. This selected client owns one original pending peer; no unrelated recipients are added.
Sourcepub fn finish_remote(
&mut self,
client: &impl PersonalTransport,
state: &mut AccountState,
current: AppAuthority,
tasks: TaskIds,
talk_success: bool,
) -> Result<()>
pub fn finish_remote( &mut self, client: &impl PersonalTransport, state: &mut AccountState, current: AppAuthority, tasks: TaskIds, talk_success: bool, ) -> Result<()>
Complete one source-classified remote termination. This is separate from local Hangup: the peer may already be absent or nonjoined. The embedding owner must stop media before calling. Failed replies remain uncertain.
Sourcepub fn exit(
&mut self,
client: &impl PersonalTransport,
state: &mut AccountState,
current: AppAuthority,
tasks: TaskIds,
talk_success: bool,
) -> Result<()>
pub fn exit( &mut self, client: &impl PersonalTransport, state: &mut AccountState, current: AppAuthority, tasks: TaskIds, talk_success: bool, ) -> Result<()>
Submit joined Exit once. talk_success is the independently established
source predicate, not inferred here from a phone timer. Reliable peer
notice and canonical history remain distinct from accepted server Exit.