Skip to main content

Crate clasp_transport

Crate clasp_transport 

Source
Expand description

CLASP Transport Layer

This crate provides transport implementations for CLASP. The protocol is transport-agnostic - any byte transport works.

Available transports:

  • WebSocket (recommended baseline for interoperability)
    • Native: tokio-tungstenite (client + server)
    • WASM: web-sys (client only)
  • UDP (LAN, low-latency, broadcast) - native only
  • QUIC (modern native apps, connection migration) - native only
  • Serial (direct hardware, lowest latency) - native only
  • BLE (Bluetooth Low Energy, wireless controllers) - native only
  • WebRTC (P2P, NAT traversal, low-latency)

Re-exports§

pub use error::Result;
pub use error::TransportError;
pub use traits::Transport;
pub use traits::TransportEvent;
pub use traits::TransportReceiver;
pub use traits::TransportSender;
pub use traits::TransportServer;
pub use websocket::WebSocketConfig;
pub use websocket::WebSocketServer;
pub use websocket::WebSocketTransport;
pub use tcp::TcpConfig;
pub use tcp::TcpServer;
pub use tcp::TcpTransport;
pub use udp::UdpConfig;
pub use udp::UdpTransport;
pub use quic::QuicConfig;
pub use quic::QuicConnection;
pub use quic::QuicTransport;

Modules§

error
Transport error types
quic
QUIC transport implementation
tcp
TCP transport implementation
traits
Transport trait definitions
udp
UDP transport implementation
websocket
WebSocket transport implementation