pub enum ProtocolUsageMode {
Ignored,
Used,
UsedWithUndefinedIfEmpty,
}Expand description
How to handle the URL protocol, or the absence of it, during UrlParsing.
Description
The “Use Protocol” checkbox in PasswordMaker Pro Javascript Edition has some weird behaviour, that’s probably a bug. This enum lets you select how to hande the case that the user wants to use the Protocol, but the input string doesn’t contain one.
Variants
Ignored
The protocol part of the URI is not used in the output.
Used
The protocol part of the URI is used in the output, if it’s non-empty in the input. Otherwise it isn’t.
UsedWithUndefinedIfEmpty
The protocol part of the URI is used in the output, if it’s non-empty in the input. Otherwise the string “undefined” is used in the output. This mirrors behaviour of the PasswordMaker Pro Javascript Edition.
Trait Implementations
sourceimpl Clone for ProtocolUsageMode
impl Clone for ProtocolUsageMode
sourcefn clone(&self) -> ProtocolUsageMode
fn clone(&self) -> ProtocolUsageMode
Returns a copy of the value. Read more
1.0.0 · sourceconst fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresourceimpl Debug for ProtocolUsageMode
impl Debug for ProtocolUsageMode
impl Copy for ProtocolUsageMode
Auto Trait Implementations
impl RefUnwindSafe for ProtocolUsageMode
impl Send for ProtocolUsageMode
impl Sync for ProtocolUsageMode
impl Unpin for ProtocolUsageMode
impl UnwindSafe for ProtocolUsageMode
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more