sebak: boscoin.io/sebak/lib/voting Index | Files

package voting

import "boscoin.io/sebak/lib/voting"

Index

Package Files

basis.go voting.go

type Basis Uses

type Basis struct {
    Round     uint64 `json:"round"`      // round sequence number
    Height    uint64 `json:"height"`     // last block height
    BlockHash string `json:"block-hash"` // hash of last block
    TotalTxs  uint64 `json:"total-txs"`
    TotalOps  uint64 `json:"total-ops"`
}

func (Basis) Index Uses

func (r Basis) Index() string

type Hole Uses

type Hole string
const (
    NOTYET Hole = "NOT-YET"
    YES    Hole = "YES"
    NO     Hole = "NO"
    EXP    Hole = "EXPIRED"
)

type ThresholdPolicy Uses

type ThresholdPolicy interface {
    Threshold() int
    Validators() int
    // Set the number of validators required for consensus
    // The parameter must be a strictly positive integer
    SetValidators(int)
    Connected() int
    // Set the number of currently connected nodes
    // The parameter must be a strictly positive integer
    SetConnected(int)
}

Package voting imports 1 packages (graph) and is imported by 18 packages. Updated 2019-01-03. Refresh now. Tools for package owners.