pub struct CustomProtocol;Expand description
Register custom protocol for ArkWeb
You can register multi custom protocol at once
You need to call CustomProtocol::register to register to web before web init.
ⓘ
CustomProtocol::register("custom", CustomProtocolOption::Standard);
CustomProtocol::register("custom2", CustomProtocolOption::Standard);
CustomProtocol::register_to_web();Implementations§
Source§impl CustomProtocol
impl CustomProtocol
Sourcepub fn add_protocol(protocol: &str)
pub fn add_protocol(protocol: &str)
Sourcepub fn add_protocol_with_option(protocol: &str, option: CustomProtocolOption)
pub fn add_protocol_with_option(protocol: &str, option: CustomProtocolOption)
Add a custom protocol to the list.
§Arguments
protocol- The protocol to add.option- The option for the protocol.
Sourcepub fn is_protocol_registered(protocol: &str) -> bool
pub fn is_protocol_registered(protocol: &str) -> bool
Auto Trait Implementations§
impl Forget for CustomProtocol
impl Freeze for CustomProtocol
impl Move for CustomProtocol
impl RefUnwindSafe for CustomProtocol
impl Send for CustomProtocol
impl Sync for CustomProtocol
impl Unpin for CustomProtocol
impl UnsafeUnpin for CustomProtocol
impl UnwindSafe for CustomProtocol
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