pub struct HostEntityChannel { /* private fields */ }Expand description
Outbound state machine for a single host-owned entity, tracking its component set and authority sub-channel.
Implementations§
Source§impl HostEntityChannel
impl HostEntityChannel
Sourcepub fn new(host_type: HostType) -> Self
pub fn new(host_type: HostType) -> Self
Creates a fresh HostEntityChannel with no components and default auth state for host_type.
Sourcepub fn send_command(&mut self, command: EntityCommand)
pub fn send_command(&mut self, command: EntityCommand)
Validates and routes command to the component set or authority sub-channel, queuing it for outbound delivery.
Sourcepub fn extract_outgoing_commands(&mut self) -> Vec<EntityCommand>
pub fn extract_outgoing_commands(&mut self) -> Vec<EntityCommand>
Drains and returns all queued outbound EntityCommands.
Sourcepub fn local_enable_delegation(&mut self)
pub fn local_enable_delegation(&mut self)
Force-enable delegation on this channel (client-side only) This is called when the client originates an EnableDelegation message, to ensure the local channel is in the correct state to receive MigrateResponse
Sourcepub fn is_delegated(&self) -> bool
pub fn is_delegated(&self) -> bool
Returns true if this channel’s authority sub-channel is in the Delegated state.
Sourcepub fn auth_channel_state(&self) -> EntityAuthChannelState
pub fn auth_channel_state(&self) -> EntityAuthChannelState
Returns the current publication/delegation state of this channel’s authority sub-channel.
Auto Trait Implementations§
impl Freeze for HostEntityChannel
impl RefUnwindSafe for HostEntityChannel
impl Send for HostEntityChannel
impl Sync for HostEntityChannel
impl Unpin for HostEntityChannel
impl UnsafeUnpin for HostEntityChannel
impl UnwindSafe for HostEntityChannel
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more