Bitcoin ABC  0.24.7
P2P Digital Currency
Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | List of all members
avalanche::Proof Class Reference

#include <proof.h>

Collaboration diagram for avalanche::Proof:
[legend]

Public Member Functions

 Proof ()
 
 Proof (uint64_t sequence_, int64_t expirationTime_, CPubKey master_, std::vector< SignedStake > stakes_, const CScript &payoutScriptPubKey_, SchnorrSig signature_)
 
 SERIALIZE_METHODS (Proof, obj)
 
uint64_t getSequence () const
 
int64_t getExpirationTime () const
 
const CPubKeygetMaster () const
 
const std::vector< SignedStake > & getStakes () const
 
const CScriptgetPayoutScript () const
 
std::optional< const SchnorrSiggetSignature () const
 
const ProofIdgetId () const
 
const LimitedProofIdgetLimitedId () const
 
const StakeCommitment getStakeCommitment () const
 
uint32_t getScore () const
 
bool verify (ProofValidationState &state) const
 
bool verify (ProofValidationState &state, const CCoinsView &view) const
 

Static Public Member Functions

static bool useLegacy ()
 
static bool useLegacy (const ArgsManager &argsman)
 
static bool FromHex (Proof &proof, const std::string &hexProof, bilingual_str &errorOut)
 

Private Member Functions

void computeProofId ()
 

Private Attributes

uint64_t sequence
 
int64_t expirationTime
 
CPubKey master
 
std::vector< SignedStakestakes
 
CScript payoutScriptPubKey
 
SchnorrSig signature
 
LimitedProofId limitedProofId
 
ProofId proofid
 

Detailed Description

Definition at line 102 of file proof.h.

Constructor & Destructor Documentation

◆ Proof() [1/2]

avalanche::Proof::Proof ( )
inline

Definition at line 115 of file proof.h.

◆ Proof() [2/2]

avalanche::Proof::Proof ( uint64_t  sequence_,
int64_t  expirationTime_,
CPubKey  master_,
std::vector< SignedStake stakes_,
const CScript payoutScriptPubKey_,
SchnorrSig  signature_ 
)
inline

Definition at line 119 of file proof.h.

Here is the call graph for this function:

Member Function Documentation

◆ computeProofId()

void avalanche::Proof::computeProofId ( )
private

Definition at line 81 of file proof.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FromHex()

bool avalanche::Proof::FromHex ( Proof proof,
const std::string &  hexProof,
bilingual_str errorOut 
)
static

Definition at line 62 of file proof.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getExpirationTime()

int64_t avalanche::Proof::getExpirationTime ( ) const
inline

Definition at line 144 of file proof.h.

Here is the caller graph for this function:

◆ getId()

const ProofId& avalanche::Proof::getId ( ) const
inline

Definition at line 152 of file proof.h.

Here is the caller graph for this function:

◆ getLimitedId()

const LimitedProofId& avalanche::Proof::getLimitedId ( ) const
inline

Definition at line 153 of file proof.h.

Here is the caller graph for this function:

◆ getMaster()

const CPubKey& avalanche::Proof::getMaster ( ) const
inline

Definition at line 145 of file proof.h.

Here is the caller graph for this function:

◆ getPayoutScript()

const CScript& avalanche::Proof::getPayoutScript ( ) const
inline

Definition at line 147 of file proof.h.

Here is the caller graph for this function:

◆ getScore()

uint32_t avalanche::Proof::getScore ( ) const

Definition at line 98 of file proof.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getSequence()

uint64_t avalanche::Proof::getSequence ( ) const
inline

Definition at line 143 of file proof.h.

Here is the caller graph for this function:

◆ getSignature()

std::optional<const SchnorrSig> avalanche::Proof::getSignature ( ) const
inline

Definition at line 148 of file proof.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getStakeCommitment()

const StakeCommitment avalanche::Proof::getStakeCommitment ( ) const
inline

Definition at line 154 of file proof.h.

Here is the caller graph for this function:

◆ getStakes()

const std::vector<SignedStake>& avalanche::Proof::getStakes ( ) const
inline

Definition at line 146 of file proof.h.

Here is the caller graph for this function:

◆ SERIALIZE_METHODS()

avalanche::Proof::SERIALIZE_METHODS ( Proof  ,
obj   
)
inline

Definition at line 129 of file proof.h.

Here is the call graph for this function:

◆ useLegacy() [1/2]

bool avalanche::Proof::useLegacy ( )
static

Definition at line 53 of file proof.cpp.

Here is the caller graph for this function:

◆ useLegacy() [2/2]

bool avalanche::Proof::useLegacy ( const ArgsManager argsman)
static

Definition at line 57 of file proof.cpp.

Here is the call graph for this function:

◆ verify() [1/2]

bool avalanche::Proof::verify ( ProofValidationState state) const

Definition at line 107 of file proof.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ verify() [2/2]

bool avalanche::Proof::verify ( ProofValidationState state,
const CCoinsView view 
) const

Definition at line 164 of file proof.cpp.

Here is the call graph for this function:

Member Data Documentation

◆ expirationTime

int64_t avalanche::Proof::expirationTime
private

Definition at line 104 of file proof.h.

◆ limitedProofId

LimitedProofId avalanche::Proof::limitedProofId
private

Definition at line 110 of file proof.h.

◆ master

CPubKey avalanche::Proof::master
private

Definition at line 105 of file proof.h.

◆ payoutScriptPubKey

CScript avalanche::Proof::payoutScriptPubKey
private

Definition at line 107 of file proof.h.

◆ proofid

ProofId avalanche::Proof::proofid
private

Definition at line 111 of file proof.h.

◆ sequence

uint64_t avalanche::Proof::sequence
private

Definition at line 103 of file proof.h.

◆ signature

SchnorrSig avalanche::Proof::signature
private

Definition at line 108 of file proof.h.

◆ stakes

std::vector<SignedStake> avalanche::Proof::stakes
private

Definition at line 106 of file proof.h.


The documentation for this class was generated from the following files: