Home Reference Source
public class | source

InterfaceBlockchainBrowserMining

WEBWORKIFY DOCUMENTATION ON https://github.com/browserify/webworkify

Method Summary

Private Methods
private

_getWorker(): *

Inherited Summary

From class InterfaceBlockchainMiningBasic
public get
public set
public get
public set
public get
public
public
public
public
public
public
private
private
private
private
private
private
private
public

async loadMinerAddress(defaultAddress: *, Wallet: *): boolean

public

async mineNextBlock(suspend: *)

public
public

async saveMinerAddress(minerAddress: *): boolean

public

async startMining()

public
private
private

_setAddress(newAddress: *, save: boolean): *

private
From class InterfaceBlockchainMining
public
public
public

block: *

public
public
public
private
public

calculateHash(nonce: *): *

public

async getNextBlock(): *

public

async mine(block: *, difficulty: *): Promise<boolean>

Simple Mining with no Workers

public

async mineBlock(block: *, difficulty: *)

Mine a specific Block

public

async mineNextBlock(suspend: *)

mine next block

private

async _mineNonces(start: *, end: *): {"result": *, "hash": *, "nonce": *}

private
From class InterfaceBlockchainMiningWorkers
public
public
public
public

block: *

public
public

end: *

public

start: *

public

workers: *

private
private

_nonce: *

private
private
public
public

async decreaseWorkers(number: *)

public

async increaseWorkers(number: *)

public

mine(block: *, difficultyTarget: *, start: *, end: *): *

public

async setWorkers(newWorkers: *)

public

async startMining()

public

async stopMining()

private

_getWorker(): {}

private

_puzzleReceived(worker: *, event: *): boolean

private

Private Methods

private _getWorker(): * source

Override:

InterfaceBlockchainMiningWorkers#_getWorker

Return:

*