Documentation ¶
Index ¶
- Constants
- type Block
- type MockSigner
- func (m *MockSigner) Algorithm() crypto.Algorithm
- func (m *MockSigner) InitSigner(privateKey []byte) error
- func (m *MockSigner) RecoverPublicKey(data []byte, signature *crypto.Signature) (publicKey []byte, err error)
- func (m *MockSigner) Sign(data []byte) (signature *crypto.Signature, err error)
- func (m *MockSigner) Verify(publicKey []byte, data []byte, signature *crypto.Signature) bool
- type Node
- func (n *Node) AddressFromPublicKey(publicKey []byte) ([]byte, error)
- func (n *Node) BroadcastTransactions(rps uint, num uint)
- func (n *Node) GetPrivateKeyOfDefaultAccount() ([]byte, error)
- func (n *Node) GetSigner() crypto.Signer
- func (n *Node) Running() bool
- func (n *Node) Start(wg *sync.WaitGroup) error
- func (n *Node) Stop() error
- type State
Constants ¶
View Source
const AccountNumber = 10000
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MockSigner ¶
type MockSigner struct {
// contains filtered or unexported fields
}
func NewMockSigner ¶
func NewMockSigner() *MockSigner
func (*MockSigner) Algorithm ¶
func (m *MockSigner) Algorithm() crypto.Algorithm
func (*MockSigner) InitSigner ¶
func (m *MockSigner) InitSigner(privateKey []byte) error
func (*MockSigner) RecoverPublicKey ¶
type Node ¶
type Node struct { Tetris *tetris2.Tetris Report chan bool States map[uint]*State Blockchain []Block // contains filtered or unexported fields }
func (*Node) AddressFromPublicKey ¶
func (*Node) BroadcastTransactions ¶
func (*Node) GetPrivateKeyOfDefaultAccount ¶
Click to show internal directories.
Click to hide internal directories.