Changeset View
Changeset View
Standalone View
Standalone View
src/avalanche/proof.h
// Copyright (c) 2020 The Bitcoin developers | // Copyright (c) 2020 The Bitcoin developers | ||||
// Distributed under the MIT software license, see the accompanying | // Distributed under the MIT software license, see the accompanying | ||||
// file COPYING or http://www.opensource.org/licenses/mit-license.php. | // file COPYING or http://www.opensource.org/licenses/mit-license.php. | ||||
#ifndef BITCOIN_AVALANCHE_PROOF_H | #ifndef BITCOIN_AVALANCHE_PROOF_H | ||||
#define BITCOIN_AVALANCHE_PROOF_H | #define BITCOIN_AVALANCHE_PROOF_H | ||||
#include <amount.h> | #include <amount.h> | ||||
#include <avalanche/proofid.h> | |||||
#include <primitives/transaction.h> | #include <primitives/transaction.h> | ||||
#include <pubkey.h> | #include <pubkey.h> | ||||
#include <serialize.h> | #include <serialize.h> | ||||
#include <uint256.h> | |||||
#include <array> | #include <array> | ||||
#include <cstdint> | #include <cstdint> | ||||
#include <vector> | #include <vector> | ||||
class CCoinsView; | class CCoinsView; | ||||
namespace avalanche { | namespace avalanche { | ||||
class ProofValidationState; | class ProofValidationState; | ||||
struct ProofId : public uint256 { | |||||
explicit ProofId() : uint256() {} | |||||
explicit ProofId(const uint256 &b) : uint256(b) {} | |||||
static ProofId fromHex(const std::string &str) { | |||||
ProofId r; | |||||
r.SetHex(str); | |||||
return r; | |||||
} | |||||
}; | |||||
class Stake { | class Stake { | ||||
COutPoint utxo; | COutPoint utxo; | ||||
Amount amount; | Amount amount; | ||||
uint32_t height; | uint32_t height; | ||||
CPubKey pubkey; | CPubKey pubkey; | ||||
public: | public: | ||||
▲ Show 20 Lines • Show All 94 Lines • Show Last 20 Lines |