pub struct CredentialResponse {
pub result: CredentialResult,
pub one_time_secret: OneTimeSecret,
pub account: Option<String>,
pub metadata: Option<String>,
}Expand description
The WALLET’s response, delivered as plaintext JSON or sealed in a
Blob.
This is the parsed, validated form; CredentialResponseWire is the JSON.
Fields§
§result: CredentialResult§one_time_secret: OneTimeSecretThe request’s one_time_secret, echoed back.
account: Option<String>The request’s account, echoed back if set.
metadata: Option<String>The request’s metadata, echoed back if set.
Implementations§
Source§impl CredentialResponse
impl CredentialResponse
Sourcepub fn from_json(json: &[u8]) -> Result<Self, ResponseError>
pub fn from_json(json: &[u8]) -> Result<Self, ResponseError>
Parse the response JSON, plaintext or freshly opened.
pub fn try_from_wire( wire: CredentialResponseWire, ) -> Result<Self, ResponseError>
Trait Implementations§
Source§impl Clone for CredentialResponse
impl Clone for CredentialResponse
Source§impl Debug for CredentialResponse
impl Debug for CredentialResponse
impl Eq for CredentialResponse
Source§impl From<CredentialResponse> for CredentialResponseWire
impl From<CredentialResponse> for CredentialResponseWire
Source§fn from(response: CredentialResponse) -> Self
fn from(response: CredentialResponse) -> Self
Converts to this type from the input type.
Source§impl PartialEq for CredentialResponse
impl PartialEq for CredentialResponse
impl StructuralPartialEq for CredentialResponse
Auto Trait Implementations§
impl Freeze for CredentialResponse
impl RefUnwindSafe for CredentialResponse
impl Send for CredentialResponse
impl Sync for CredentialResponse
impl Unpin for CredentialResponse
impl UnsafeUnpin for CredentialResponse
impl UnwindSafe for CredentialResponse
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.