remote

package
v0.0.0-...-96daba7 Latest Latest
Warning

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

Go to latest
Published: Jul 28, 2019 License: GPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ApiActionGenerate = "/api/generate_work"
	ApiActionValidate = "/api/validate_work"
	ApiActionCancel   = "/api/cancel_work"
)

Variables

This section is empty.

Functions

func CancelWork

func CancelWork(dataHash []byte) error

func GenerateWork

func GenerateWork(dataHash []byte, difficulty *big.Int) (*string, error)

func InitRawUrl

func InitRawUrl(rawurl string)

func VaildateWork

func VaildateWork(dataHash []byte, threshold *big.Int, work []byte) (bool, error)

Types

type ResponseJson

type ResponseJson struct {
	Code  int         `json:"code"`
	Data  interface{} `json:"data"`
	Error string      `json:"error"`
	Msg   string      `json:"msg"`
}

Jump to

Keyboard shortcuts

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