Documentation ¶
Index ¶
- func IsNewDay(oldTime int64, nowT int64) bool
- type BlockDataProcessor
- type BlockSmith
- type CratosProcessingService
- func (proc CratosProcessingService) ApplyAmendment(countAmendmentVote map[string]uint64, newCratos *model.Cratos, ...)
- func (proc CratosProcessingService) ApplyDelta(t int64, oldBlock model.Block, updatedCratosCid chan string, ...)
- func (proc CratosProcessingService) ApplyVariableValueChange(newCratos *model.Cratos, demos model.Demos, evidences chan model.Evidence)
- func (proc CratosProcessingService) DeserializeFromCratos(block model.Cratos)
- func (proc CratosProcessingService) IsAuthorized(role string, perm string) bool
- func (proc CratosProcessingService) SerializeForCratos() model.Roles
- type CurrencyProcessorService
- type DemosProcessingService
- type NotaryProcessorService
- type PolitikojjError
- type PowProcessorService
- type TemporaryPool
- func (pool *TemporaryPool) Add(cid string, data interface{})
- func (pool *TemporaryPool) Attach(docsChan chan model.Wrapper)
- func (pool *TemporaryPool) CountVotes() map[string]map[string]uint64
- func (pool *TemporaryPool) Exists(cid string) bool
- func (pool *TemporaryPool) GetTxs() map[string]model.Transaction
- func (pool *TemporaryPool) GetVotes() map[string]model.OpenBallot
- func (pool *TemporaryPool) Remove(cid string)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type BlockDataProcessor ¶
type BlockSmith ¶
type BlockSmith struct { Key crypto.Keypair CratosP CratosProcessingService Pools *TemporaryPool Chain *chain.BlockChainService // contains filtered or unexported fields }
func NewBlockSmith ¶
func NewBlockSmith(ch *chain.BlockChainService, pair crypto.Keypair, powCores int) *BlockSmith
func (BlockSmith) CalculatePow ¶
func (smith BlockSmith) CalculatePow(block model.Block) model.Block
func (BlockSmith) CheckForkOrChain ¶
func (smith BlockSmith) CheckForkOrChain(block model.Block) error
func (BlockSmith) GenerateBlock ¶
func (BlockSmith) RunBlockSmith ¶
func (smith BlockSmith) RunBlockSmith()
type CratosProcessingService ¶
type CratosProcessingService struct { Pools *TemporaryPool // contains filtered or unexported fields }
func (CratosProcessingService) ApplyAmendment ¶
func (CratosProcessingService) ApplyDelta ¶
func (CratosProcessingService) ApplyVariableValueChange ¶
func (CratosProcessingService) DeserializeFromCratos ¶
func (proc CratosProcessingService) DeserializeFromCratos(block model.Cratos)
func (CratosProcessingService) IsAuthorized ¶
func (proc CratosProcessingService) IsAuthorized(role string, perm string) bool
func (CratosProcessingService) SerializeForCratos ¶
func (proc CratosProcessingService) SerializeForCratos() model.Roles
type CurrencyProcessorService ¶
type CurrencyProcessorService struct { Pools *TemporaryPool // contains filtered or unexported fields }
type DemosProcessingService ¶
type DemosProcessingService struct { Pools *TemporaryPool // contains filtered or unexported fields }
func (DemosProcessingService) ApplyDelta ¶
func (DemosProcessingService) FindNewCitizens ¶
func (proc DemosProcessingService) FindNewCitizens(demos *model.Demos, evidences chan model.Evidence)
type NotaryProcessorService ¶
type NotaryProcessorService struct { Pools *TemporaryPool // contains filtered or unexported fields }
type PolitikojjError ¶
type PolitikojjError string
func (PolitikojjError) Error ¶
func (e PolitikojjError) Error() string
type PowProcessorService ¶
type PowProcessorService struct {
// contains filtered or unexported fields
}
type TemporaryPool ¶
type TemporaryPool struct { Claims map[string]model.Claim ApprovedClaims map[string]model.ApprovedClaim Votes map[string]model.OpenBallot Transactions map[string]model.Transaction Amendments map[string]model.Amendment sync.RWMutex // contains filtered or unexported fields }
==================== Pools ====================
func NewPool ¶
func NewPool() *TemporaryPool
func (*TemporaryPool) Add ¶
func (pool *TemporaryPool) Add(cid string, data interface{})
func (*TemporaryPool) Attach ¶
func (pool *TemporaryPool) Attach(docsChan chan model.Wrapper)
func (*TemporaryPool) CountVotes ¶
func (pool *TemporaryPool) CountVotes() map[string]map[string]uint64
func (*TemporaryPool) Exists ¶
func (pool *TemporaryPool) Exists(cid string) bool
func (*TemporaryPool) GetTxs ¶
func (pool *TemporaryPool) GetTxs() map[string]model.Transaction
func (*TemporaryPool) GetVotes ¶
func (pool *TemporaryPool) GetVotes() map[string]model.OpenBallot
func (*TemporaryPool) Remove ¶
func (pool *TemporaryPool) Remove(cid string)
Click to show internal directories.
Click to hide internal directories.