Changeset View
Changeset View
Standalone View
Standalone View
src/consensus/validation.h
// Copyright (c) 2009-2010 Satoshi Nakamoto | // Copyright (c) 2009-2010 Satoshi Nakamoto | ||||
// Copyright (c) 2009-2016 The Bitcoin Core developers | // Copyright (c) 2009-2016 The Bitcoin Core 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_CONSENSUS_VALIDATION_H | #ifndef BITCOIN_CONSENSUS_VALIDATION_H | ||||
#define BITCOIN_CONSENSUS_VALIDATION_H | #define BITCOIN_CONSENSUS_VALIDATION_H | ||||
#include <string> | #include <string> | ||||
/** "reject" message codes */ | /** "reject" message codes */ | ||||
static const uint8_t REJECT_MALFORMED = 0x01; | static const uint8_t REJECT_MALFORMED = 0x01; | ||||
static const uint8_t REJECT_INVALID = 0x10; | static const uint8_t REJECT_INVALID = 0x10; | ||||
static const uint8_t REJECT_OBSOLETE = 0x11; | static const uint8_t REJECT_OBSOLETE = 0x11; | ||||
static const uint8_t REJECT_DUPLICATE = 0x12; | static const uint8_t REJECT_DUPLICATE = 0x12; | ||||
static const uint8_t REJECT_NONSTANDARD = 0x40; | static const uint8_t REJECT_NONSTANDARD = 0x40; | ||||
static const uint8_t REJECT_DUST = 0x41; | |||||
static const uint8_t REJECT_INSUFFICIENTFEE = 0x42; | static const uint8_t REJECT_INSUFFICIENTFEE = 0x42; | ||||
static const uint8_t REJECT_CHECKPOINT = 0x43; | static const uint8_t REJECT_CHECKPOINT = 0x43; | ||||
/** Capture information about block/transaction validation */ | /** Capture information about block/transaction validation */ | ||||
class CValidationState { | class CValidationState { | ||||
private: | private: | ||||
enum mode_state { | enum mode_state { | ||||
MODE_VALID, //!< everything ok | MODE_VALID, //!< everything ok | ||||
▲ Show 20 Lines • Show All 64 Lines • Show Last 20 Lines |