pub struct ProofInfo {
pub proof: Proof,
pub y: PublicKey,
pub mint_url: MintUrl,
pub state: State,
pub spending_condition: Option<SpendingConditions>,
pub unit: CurrencyUnit,
}
Expand description
Prooinfo
Fields§
§proof: Proof
Proof
y: PublicKey
y
mint_url: MintUrl
Mint Url
state: State
Proof State
spending_condition: Option<SpendingConditions>
Proof Spending Conditions
unit: CurrencyUnit
Unit
Implementations§
Source§impl ProofInfo
impl ProofInfo
Sourcepub fn new(
proof: Proof,
mint_url: MintUrl,
state: State,
unit: CurrencyUnit,
) -> Result<Self, Error>
pub fn new( proof: Proof, mint_url: MintUrl, state: State, unit: CurrencyUnit, ) -> Result<Self, Error>
Create new ProofInfo
Sourcepub fn matches_conditions(
&self,
mint_url: &Option<MintUrl>,
unit: &Option<CurrencyUnit>,
state: &Option<Vec<State>>,
spending_conditions: &Option<Vec<SpendingConditions>>,
) -> bool
pub fn matches_conditions( &self, mint_url: &Option<MintUrl>, unit: &Option<CurrencyUnit>, state: &Option<Vec<State>>, spending_conditions: &Option<Vec<SpendingConditions>>, ) -> bool
Check if Proof
matches conditions
Trait Implementations§
Source§impl<'de> Deserialize<'de> for ProofInfo
impl<'de> Deserialize<'de> for ProofInfo
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for ProofInfo
impl StructuralPartialEq for ProofInfo
Auto Trait Implementations§
impl Freeze for ProofInfo
impl RefUnwindSafe for ProofInfo
impl Send for ProofInfo
impl Sync for ProofInfo
impl Unpin for ProofInfo
impl UnwindSafe for ProofInfo
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