C# Класс BitMaker.Miner.Pool

Encapsulates access to a mining pool.
Наследование: IDisposable
Показать файл Открыть проект

Открытые методы

Метод Описание
Dispose ( ) : void

Disposes of the pool and releases all resources associated with it.

GetWorkRpc ( IMiner miner, string comment ) : BitMaker.Miner.Work

Invokes the 'getwork' JSON method and parses the result into a new T:Work instance.

SubmitWorkRpc ( IMiner miner, BitMaker.Miner.Work work, string comment ) : bool

Invokes the 'getwork' JSON method, submitting the proposed work. Returns true if the service accepts the proposed work.

Приватные методы

Метод Описание
GetWorkLp ( IMiner miner, string comment ) : BitMaker.Miner.Work

Initiates a long-poll request for work.

Open ( Uri url, string method, IMiner miner, string comment ) : HttpWebRequest

Opens a web request.

OpenLp ( IMiner miner, string comment ) : HttpWebRequest

Creates a HttpWebRequest for long-polling.

OpenRpc ( IMiner miner, string comment ) : HttpWebRequest

Creates a HttpWebRequest for JSON-RPC.

ParseGetWork ( WebResponse webResponse ) : BitMaker.Miner.Work

Parses a WebResponse containing the results of a 'getwork' request.

Pool ( Uri url ) : System

Initializes a new instance.

RefreshThreadMain ( ) : void

Entry point for thread responsible for detecting changes in the current block number.

Описание методов

Dispose() публичный Метод

Disposes of the pool and releases all resources associated with it.
public Dispose ( ) : void
Результат void

GetWorkRpc() публичный Метод

Invokes the 'getwork' JSON method and parses the result into a new T:Work instance.
public GetWorkRpc ( IMiner miner, string comment ) : BitMaker.Miner.Work
miner IMiner
comment string
Результат BitMaker.Miner.Work

SubmitWorkRpc() публичный Метод

Invokes the 'getwork' JSON method, submitting the proposed work. Returns true if the service accepts the proposed work.
public SubmitWorkRpc ( IMiner miner, BitMaker.Miner.Work work, string comment ) : bool
miner IMiner
work BitMaker.Miner.Work
comment string
Результат bool