blockli

package module
v0.0.0-...-e9d4b7a Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 5, 2019 License: MIT Imports: 7 Imported by: 0

README

blockli

Go Report Card Build Status Coverage Status

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Block

type Block struct {
	PreviousHash string `json:"previousHash"`
	Data         string `json:"data"`
	Timestamp    int64  `json:"timestamp"`
	Hash         string `json:"hash"`
}

Block asd

func (Block) GetData

func (b Block) GetData() string

GetData sdsd

func (Block) GetHash

func (b Block) GetHash() string

GetHash adssd

func (Block) GetPreviousHash

func (b Block) GetPreviousHash() string

GetPreviousHash sds

func (Block) GetTimestamp

func (b Block) GetTimestamp() int64

GetTimestamp sdd

type BlockCache

type BlockCache struct {
	// contains filtered or unexported fields
}

BlockCache asdadasda

func NewBlockCache

func NewBlockCache(savePath string) *BlockCache

NewBlockCache sdadadaddasd

func (*BlockCache) Read

func (db *BlockCache) Read(key string) *Block

func (*BlockCache) Write

func (db *BlockCache) Write(value *Block) string

type BlockStore

type BlockStore struct {
	// contains filtered or unexported fields
}

BlockStore sdad

func NewBlockStore

func NewBlockStore(path string) *BlockStore

NewBlockStore sdssdd

func (*BlockStore) Retrieve

func (BlockStore *BlockStore) Retrieve(key string) *Block

Retrieve sdsds

func (*BlockStore) Save

func (BlockStore *BlockStore) Save(key string, value *Block)

Save sdsdsd

type Blockli

type Blockli struct {
	// contains filtered or unexported fields
}

Blockli sds

func NewBlockli

func NewBlockli() *Blockli

NewBlockli asdad

func (*Blockli) AddBlock

func (bc *Blockli) AddBlock(data string) string

AddBlock sds

func (*Blockli) GetGenesisHash

func (bc *Blockli) GetGenesisHash() string

GetGenesisHash dfd

func (*Blockli) Init

func (bc *Blockli) Init() string

Init sdsd

func (*Blockli) ShowBlock

func (bc *Blockli) ShowBlock(hash string) string

ShowBlock sd

func (*Blockli) ValidateBlock

func (bc *Blockli) ValidateBlock(hash string) bool

ValidateBlock sdsds

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL