Documentation
¶
Index ¶
- type ApplicationMock
- type AssemblerMock
- type Batcher
- type CommMock
- type Decider
- type FailureDetector
- type HeartbeatEventHandler
- type LeaderMonitor
- func (_m *LeaderMonitor) ChangeRole(role bft.Role, view uint64, leaderID uint64)
- func (_m *LeaderMonitor) Close()
- func (_m *LeaderMonitor) HeartbeatWasSent()
- func (_m *LeaderMonitor) InjectArtificialHeartbeat(sender uint64, msg *smartbftprotos.Message)
- func (_m *LeaderMonitor) ProcessMsg(sender uint64, msg *smartbftprotos.Message)
- type MembershipNotifierMock
- type ProposerBuilder
- type Pruner
- type RequestPool
- func (_m *RequestPool) Close()
- func (_m *RequestPool) NextRequests(maxCount int, maxSizeBytes uint64, check bool) ([][]byte, bool)
- func (_m *RequestPool) Prune(predicate func([]byte) error)
- func (_m *RequestPool) RemoveRequest(request types.RequestInfo) error
- func (_m *RequestPool) RestartTimers()
- func (_m *RequestPool) Size() int
- func (_m *RequestPool) StopTimers()
- func (_m *RequestPool) Submit(request []byte) error
- type RequestTimeoutHandler
- type RequestsTimer
- type SignerMock
- type State
- type Synchronizer
- type SynchronizerMock
- type VerifierMock
- func (_m *VerifierMock) AuxiliaryData(_a0 []byte) []byte
- func (_m *VerifierMock) RequestsFromProposal(proposal types.Proposal) []types.RequestInfo
- func (_m *VerifierMock) VerificationSequence() uint64
- func (_m *VerifierMock) VerifyConsenterSig(signature types.Signature, prop types.Proposal) ([]byte, error)
- func (_m *VerifierMock) VerifyProposal(proposal types.Proposal) ([]types.RequestInfo, error)
- func (_m *VerifierMock) VerifyRequest(val []byte) (types.RequestInfo, error)
- func (_m *VerifierMock) VerifySignature(signature types.Signature) error
- type ViewController
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ApplicationMock ¶
ApplicationMock is an autogenerated mock type for the ApplicationMock type
type AssemblerMock ¶
AssemblerMock is an autogenerated mock type for the AssemblerMock type
func (*AssemblerMock) AssembleProposal ¶
func (_m *AssemblerMock) AssembleProposal(metadata []byte, requests [][]byte) types.Proposal
AssembleProposal provides a mock function with given fields: metadata, requests
type Batcher ¶
Batcher is an autogenerated mock type for the Batcher type
func (*Batcher) Close ¶
func (_m *Batcher) Close()
Close provides a mock function with given fields:
type CommMock ¶
CommMock is an autogenerated mock type for the CommMock type
func (*CommMock) BroadcastConsensus ¶
func (_m *CommMock) BroadcastConsensus(m *smartbftprotos.Message)
BroadcastConsensus provides a mock function with given fields: m
func (*CommMock) SendConsensus ¶
func (_m *CommMock) SendConsensus(targetID uint64, m *smartbftprotos.Message)
SendConsensus provides a mock function with given fields: targetID, m
func (*CommMock) SendTransaction ¶
SendTransaction provides a mock function with given fields: targetID, request
type FailureDetector ¶
FailureDetector is an autogenerated mock type for the FailureDetector type
func (*FailureDetector) Complain ¶
func (_m *FailureDetector) Complain(viewNum uint64, stopView bool)
Complain provides a mock function with given fields: viewNum, stopView
type HeartbeatEventHandler ¶
HeartbeatEventHandler is an autogenerated mock type for the HeartbeatEventHandler type
func (*HeartbeatEventHandler) OnHeartbeatTimeout ¶
func (_m *HeartbeatEventHandler) OnHeartbeatTimeout(view uint64, leaderID uint64)
OnHeartbeatTimeout provides a mock function with given fields: view, leaderID
func (*HeartbeatEventHandler) Sync ¶
func (_m *HeartbeatEventHandler) Sync()
Sync provides a mock function with given fields:
type LeaderMonitor ¶
LeaderMonitor is an autogenerated mock type for the LeaderMonitor type
func (*LeaderMonitor) ChangeRole ¶
func (_m *LeaderMonitor) ChangeRole(role bft.Role, view uint64, leaderID uint64)
ChangeRole provides a mock function with given fields: role, view, leaderID
func (*LeaderMonitor) Close ¶
func (_m *LeaderMonitor) Close()
Close provides a mock function with given fields:
func (*LeaderMonitor) HeartbeatWasSent ¶
func (_m *LeaderMonitor) HeartbeatWasSent()
HeartbeatWasSent provides a mock function with given fields:
func (*LeaderMonitor) InjectArtificialHeartbeat ¶
func (_m *LeaderMonitor) InjectArtificialHeartbeat(sender uint64, msg *smartbftprotos.Message)
InjectArtificialHeartbeat provides a mock function with given fields: sender, msg
func (*LeaderMonitor) ProcessMsg ¶
func (_m *LeaderMonitor) ProcessMsg(sender uint64, msg *smartbftprotos.Message)
ProcessMsg provides a mock function with given fields: sender, msg
type MembershipNotifierMock ¶
MembershipNotifierMock is an autogenerated mock type for the MembershipNotifierMock type
func (*MembershipNotifierMock) MembershipChange ¶
func (_m *MembershipNotifierMock) MembershipChange() bool
MembershipChange provides a mock function with given fields:
type ProposerBuilder ¶
ProposerBuilder is an autogenerated mock type for the ProposerBuilder type
func (*ProposerBuilder) NewProposer ¶
func (_m *ProposerBuilder) NewProposer(leader uint64, proposalSequence uint64, viewNum uint64, decisionsInView uint64, quorumSize int) bft.Proposer
NewProposer provides a mock function with given fields: leader, proposalSequence, viewNum, decisionsInView, quorumSize
type Pruner ¶
Pruner is an autogenerated mock type for the Pruner type
func (*Pruner) MaybePruneRevokedRequests ¶
func (_m *Pruner) MaybePruneRevokedRequests()
MaybePruneRevokedRequests provides a mock function with given fields:
type RequestPool ¶
RequestPool is an autogenerated mock type for the RequestPool type
func (*RequestPool) Close ¶
func (_m *RequestPool) Close()
Close provides a mock function with given fields:
func (*RequestPool) NextRequests ¶
NextRequests provides a mock function with given fields: maxCount, maxSizeBytes, check
func (*RequestPool) Prune ¶
func (_m *RequestPool) Prune(predicate func([]byte) error)
Prune provides a mock function with given fields: predicate
func (*RequestPool) RemoveRequest ¶
func (_m *RequestPool) RemoveRequest(request types.RequestInfo) error
RemoveRequest provides a mock function with given fields: request
func (*RequestPool) RestartTimers ¶
func (_m *RequestPool) RestartTimers()
RestartTimers provides a mock function with given fields:
func (*RequestPool) Size ¶
func (_m *RequestPool) Size() int
Size provides a mock function with given fields:
func (*RequestPool) StopTimers ¶
func (_m *RequestPool) StopTimers()
StopTimers provides a mock function with given fields:
func (*RequestPool) Submit ¶
func (_m *RequestPool) Submit(request []byte) error
Submit provides a mock function with given fields: request
type RequestTimeoutHandler ¶
RequestTimeoutHandler is an autogenerated mock type for the RequestTimeoutHandler type
func (*RequestTimeoutHandler) OnAutoRemoveTimeout ¶
func (_m *RequestTimeoutHandler) OnAutoRemoveTimeout(requestInfo types.RequestInfo)
OnAutoRemoveTimeout provides a mock function with given fields: requestInfo
func (*RequestTimeoutHandler) OnLeaderFwdRequestTimeout ¶
func (_m *RequestTimeoutHandler) OnLeaderFwdRequestTimeout(request []byte, requestInfo types.RequestInfo)
OnLeaderFwdRequestTimeout provides a mock function with given fields: request, requestInfo
func (*RequestTimeoutHandler) OnRequestTimeout ¶
func (_m *RequestTimeoutHandler) OnRequestTimeout(request []byte, requestInfo types.RequestInfo)
OnRequestTimeout provides a mock function with given fields: request, requestInfo
type RequestsTimer ¶
RequestsTimer is an autogenerated mock type for the RequestsTimer type
func (*RequestsTimer) RemoveRequest ¶
func (_m *RequestsTimer) RemoveRequest(request types.RequestInfo) error
RemoveRequest provides a mock function with given fields: request
func (*RequestsTimer) RestartTimers ¶
func (_m *RequestsTimer) RestartTimers()
RestartTimers provides a mock function with given fields:
func (*RequestsTimer) StopTimers ¶
func (_m *RequestsTimer) StopTimers()
StopTimers provides a mock function with given fields:
type SignerMock ¶
SignerMock is an autogenerated mock type for the SignerMock type
func (*SignerMock) Sign ¶
func (_m *SignerMock) Sign(_a0 []byte) []byte
Sign provides a mock function with given fields: _a0
func (*SignerMock) SignProposal ¶
SignProposal provides a mock function with given fields: proposal, auxiliaryInput
type State ¶
State is an autogenerated mock type for the State type
func (*State) Save ¶
func (_m *State) Save(message *smartbftprotos.SavedMessage) error
Save provides a mock function with given fields: message
type Synchronizer ¶
Synchronizer is an autogenerated mock type for the Synchronizer type
func (*Synchronizer) Sync ¶
func (_m *Synchronizer) Sync()
Sync provides a mock function with given fields:
type SynchronizerMock ¶
SynchronizerMock is an autogenerated mock type for the SynchronizerMock type
func (*SynchronizerMock) Sync ¶
func (_m *SynchronizerMock) Sync() types.SyncResponse
Sync provides a mock function with given fields:
type VerifierMock ¶
VerifierMock is an autogenerated mock type for the VerifierMock type
func (*VerifierMock) AuxiliaryData ¶
func (_m *VerifierMock) AuxiliaryData(_a0 []byte) []byte
AuxiliaryData provides a mock function with given fields: _a0
func (*VerifierMock) RequestsFromProposal ¶
func (_m *VerifierMock) RequestsFromProposal(proposal types.Proposal) []types.RequestInfo
RequestsFromProposal provides a mock function with given fields: proposal
func (*VerifierMock) VerificationSequence ¶
func (_m *VerifierMock) VerificationSequence() uint64
VerificationSequence provides a mock function with given fields:
func (*VerifierMock) VerifyConsenterSig ¶
func (_m *VerifierMock) VerifyConsenterSig(signature types.Signature, prop types.Proposal) ([]byte, error)
VerifyConsenterSig provides a mock function with given fields: signature, prop
func (*VerifierMock) VerifyProposal ¶
func (_m *VerifierMock) VerifyProposal(proposal types.Proposal) ([]types.RequestInfo, error)
VerifyProposal provides a mock function with given fields: proposal
func (*VerifierMock) VerifyRequest ¶
func (_m *VerifierMock) VerifyRequest(val []byte) (types.RequestInfo, error)
VerifyRequest provides a mock function with given fields: val
func (*VerifierMock) VerifySignature ¶
func (_m *VerifierMock) VerifySignature(signature types.Signature) error
VerifySignature provides a mock function with given fields: signature
type ViewController ¶
ViewController is an autogenerated mock type for the ViewController type
func (*ViewController) AbortView ¶
func (_m *ViewController) AbortView(view uint64)
AbortView provides a mock function with given fields: view
func (*ViewController) ViewChanged ¶
func (_m *ViewController) ViewChanged(newViewNumber uint64, newProposalSequence uint64)
ViewChanged provides a mock function with given fields: newViewNumber, newProposalSequence
Source Files
¶
- application_mock.go
- assembler_mock.go
- batcher.go
- comm_mock.go
- decider.go
- failure_detector.go
- heartbeat_event_handler.go
- leader_monitor.go
- membership_notifier_mock.go
- proposer_builder.go
- pruner.go
- request_pool.go
- request_timeout_handler.go
- requests_timer.go
- signer_mock.go
- state.go
- synchronizer.go
- synchronizer_mock.go
- verifier_mock.go
- view_controller.go