Skip to main content

register

Function register 

Source
pub fn register(
    kind: &str,
    connect: Option<ConnectFn>,
    listen: Option<ListenFn>,
) -> Result<()>
Expand description

Adds a custom endpoint kind, such as a transport over a device driver.

kind is lowercase ASCII letters, digits and -; built-in kinds cannot be replaced, and registering a kind again replaces the earlier one.