filament-interfaces · manager
Source declarations, signatures and documentation for manager.
Read the current implementation boundaries before integration. This reference reproduces declarations; it omits source comments whose examples or readiness claims have not been verified.
Source: sigil/weave/filament/filament-interfaces/src/manager.rs. SHA-256: c16914f86c44e468bef4df0af7a2a209d073873a95836975b7fd51b86b46b21d.
This reference follows declared source modules, retains conditional attributes, and includes public declarations and implementation methods. Private-module re-exports and trait resolution require the compiler; this is a source reference, not a claim that every listed item is a root import. Function bodies and constant values are omitted.
manager::InterfaceManagerError
#[derive(Error, Debug)]
pub enum InterfaceManagerError {
/// Interface not found
#[error("interface not found: {0}")]
InterfaceNotFound(InterfaceId),
/// Interface already exists
#[error("interface already exists: {0}")]
InterfaceAlreadyExists(InterfaceId),
/// Interface error
#[error("interface error: {0}")]
InterfaceError(#[from] InterfaceError),
/// No interfaces available
#[error("no interfaces available")]
NoInterfaces,
}Source line: 14.
manager::PacketReceived
#[derive(Debug, Clone)]
pub struct PacketReceived {
/// Interface that received the packet
pub interface_id: InterfaceId,
/// Packet data
pub data: Vec<u8>
}Source line: 34.
manager::InterfaceManager
pub struct InterfaceManager {
}Source line: 73.
manager::InterfaceManager::new
pub fn new() -> Self;Source line: 81.
manager::InterfaceManager::add_interface
pub async fn add_interface(
&mut self,
interface: Box<dyn Interface>,
) -> Result<InterfaceId, InterfaceManagerError>;Source line: 92.
manager::InterfaceManager::remove_interface
pub async fn remove_interface(&mut self, id: InterfaceId) -> Result<(), InterfaceManagerError>;Source line: 138.
manager::InterfaceManager::get_interface
pub async fn get_interface(
&self,
id: InterfaceId,
) -> Result<SharedInterface, InterfaceManagerError>;Source line: 151.
manager::InterfaceManager::list_interfaces
pub async fn list_interfaces(&self) -> Vec<InterfaceId>;Source line: 164.
manager::InterfaceManager::interface_count
pub async fn interface_count(&self) -> usize;Source line: 170.
manager::InterfaceManager::send_to
pub async fn send_to(
&self,
interface_id: InterfaceId,
packet: &[u8],
) -> Result<(), InterfaceManagerError>;Source line: 176.
manager::InterfaceManager::broadcast
pub async fn broadcast(&self, packet: &[u8]) -> Result<usize, InterfaceManagerError>;Source line: 193.
manager::InterfaceManager::broadcast_to_mode
pub async fn broadcast_to_mode(
&self,
packet: &[u8],
mode: crate::interface::InterfaceMode,
) -> Result<usize, InterfaceManagerError>;Source line: 216.
manager::InterfaceManager::recv
pub async fn recv(&self) -> Result<PacketReceived, InterfaceManagerError>;Source line: 243.
manager::InterfaceManager::try_recv
pub async fn try_recv(&self) -> Option<PacketReceived>;Source line: 253.
manager::InterfaceManager::set_interface_enabled
pub async fn set_interface_enabled(
&self,
interface_id: InterfaceId,
enabled: bool,
) -> Result<(), InterfaceManagerError>;Source line: 259.
manager::InterfaceManager::get_all_stats
pub async fn get_all_stats(&self) -> HashMap<InterfaceId, crate::interface::InterfaceStats>;Source line: 276.
manager::InterfaceManager::total_packets_sent
pub async fn total_packets_sent(&self) -> u64;Source line: 289.
manager::InterfaceManager::total_packets_received
pub async fn total_packets_received(&self) -> u64;Source line: 295.
manager::InterfaceManager::total_bytes_sent
pub async fn total_bytes_sent(&self) -> u64;Source line: 301.
manager::InterfaceManager::total_bytes_received
pub async fn total_bytes_received(&self) -> u64;Source line: 307.
manager::InterfaceManager::shutdown
pub async fn shutdown(&mut self) -> Result<(), InterfaceManagerError>;Source line: 313.