Documentation ¶
Index ¶
Constants ¶
View Source
const ( HASH_LEN = 32 BLOCKHEADER_SIZE = 150 )
View Source
const ( CONFIGTX_SIZE = 83 BLOCK_SIZE_ID = 1 DIFF_INTERVAL_ID = 2 FEE_MINIMUM_ID = 3 BLOCK_INTERVAL_ID = 4 BLOCK_REWARD_ID = 5 MIN_BLOCK_SIZE = 1000 //1KB MAX_BLOCK_SIZE = 100000000 //100MB MIN_DIFF_INTERVAL = 30 //amount in seconds MAX_DIFF_INTERVAL = 9223372036854775807 MIN_FEE_MINIMUM = 0 MAX_FEE_MINIMUM = 9223372036854775807 MIN_BLOCK_INTERVAL = 30 //30 seconds MAX_BLOCK_INTERVAL = 86400 //24 hours MIN_BLOCK_REWARD = 0 MAX_BLOCK_REWARD = 1152921504606846976 //2^60 )
View Source
const (
ACCTX_SIZE = 169
)
View Source
const (
ACC_SIZE = 76
)
View Source
const (
FUNDSTX_SIZE = 149
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AccTx ¶
func ConstrAccTx ¶
func ConstrAccTx(header byte, fee uint64, rootPrivKey *ecdsa.PrivateKey) (tx *AccTx, privKey *ecdsa.PrivateKey, err error)
type Block ¶
type Block struct { Header byte Hash [32]byte PrevHash [32]byte Nonce [8]byte Timestamp int64 MerkleRoot [32]byte Beneficiary [32]byte NrFundsTx uint16 NrAccTx uint16 NrConfigTx uint8 StateCopy map[[32]byte]*Account //won't be serialized, just keeping track of local state changes FundsTxData [][32]byte AccTxData [][32]byte ConfigTxData [][32]byte }
type ConfigTx ¶
func ConstrConfigTx ¶
type FundsTx ¶
type FundsTx struct { Header byte Amount uint64 Fee uint64 TxCnt uint32 From [32]byte To [32]byte Sig [64]byte }
func ConstrFundsTx ¶
Click to show internal directories.
Click to hide internal directories.