[−][src]Struct cryptouri::CryptoUri
CryptoUri
: URI-based format for encoding cryptographic objects
Methods
impl CryptoUri
[src]
pub fn parse_uri(uri: &str) -> Result<Self, Error>
[src]
Parse a CryptoUri
pub fn parse_dasherized(token: &str) -> Result<Self, Error>
[src]
Parse a CryptoUri
in URI-embeddable (a.k.a. "dasherized") encoding
pub fn kind(&self) -> &CryptoUriKind
[src]
Return the CryptoUriKind
for this URI
pub fn secret_key(&self) -> Option<&SecretKey>
[src]
Return a SecretKey
if the underlying URI is a crypto:secret:key:
pub fn is_secret_key(&self) -> bool
[src]
Is this CryptoUri
a crypto:secret:key:
?
pub fn public_key(&self) -> Option<&PublicKey>
[src]
Return a PublicKey
if the underlying URI is a crypto:public:key:
pub fn is_public_key(&self) -> bool
[src]
Is this CryptoUri a crypto:public:key:
?
pub fn digest(&self) -> Option<&Digest>
[src]
Return a Digest
if the underlying URI is a crypto:public:digest:
pub fn is_digest(&self) -> bool
[src]
Is this CryptoUri a crypto:public:digest:
?
pub fn signature(&self) -> Option<&Signature>
[src]
Return a Signature
if the underlying URI is a crypto:public:signature:
pub fn is_signature(&self) -> bool
[src]
Is this CryptoUri a crypto:public:signature:
?
pub fn fragment(&self) -> Option<&str>
[src]
Obtain the fragment for this URI (i.e. everything after #
)
Trait Implementations
impl Encodable for CryptoUri
[src]
fn to_uri_string(&self) -> String
[src]
Serialize this CryptoUri
as a URI-encoded String
fn to_dasherized_string(&self) -> String
[src]
Serialize this CryptoUri
as a "dasherized" String
Auto Trait Implementations
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Same<T> for T
type Output = T
Should always be Self