Dash Core  0.12.2.1
P2P Digital Currency
consensus.h
Go to the documentation of this file.
1 // Copyright (c) 2009-2010 Satoshi Nakamoto
2 // Copyright (c) 2009-2015 The Bitcoin Core developers
3 // Distributed under the MIT software license, see the accompanying
4 // file COPYING or http://www.opensource.org/licenses/mit-license.php.
5 
6 #ifndef BITCOIN_CONSENSUS_CONSENSUS_H
7 #define BITCOIN_CONSENSUS_CONSENSUS_H
8 
10 // static const unsigned int MAX_BLOCK_SIZE = 1000000;
11 static const unsigned int MAX_LEGACY_BLOCK_SIZE = (1 * 1000 * 1000);
12 inline unsigned int MaxBlockSize(bool fDIP0001Active /*= false */)
13 {
14  return fDIP0001Active ? MAX_LEGACY_BLOCK_SIZE * 2 : MAX_LEGACY_BLOCK_SIZE;
15 }
17 // static const unsigned int MAX_BLOCK_SIGOPS = MAX_BLOCK_SIZE/50;
18 inline unsigned int MaxBlockSigOps(bool fDIP0001Active /*= false */)
19 {
20  return MaxBlockSize(fDIP0001Active) / 50;
21 }
23 static const int COINBASE_MATURITY = 100;
24 
26 enum {
27  /* Interpret sequence numbers as relative lock-time constraints. */
29 
30  /* Use GetMedianTimePast() instead of nTime for end point timestamp. */
32 };
33 
34 #endif // BITCOIN_CONSENSUS_CONSENSUS_H
unsigned int MaxBlockSize(bool fDIP0001Active)
Definition: consensus.h:12
static const int COINBASE_MATURITY
Definition: consensus.h:23
static const unsigned int MAX_LEGACY_BLOCK_SIZE
Definition: consensus.h:11
unsigned int MaxBlockSigOps(bool fDIP0001Active)
Definition: consensus.h:18