Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Handler ¶
type Handler struct {
// contains filtered or unexported fields
}
Handler handles PoW requests of the node and tunnels them to powsrv.io or uses local PoW if no API key was specified or the connection failed.
func (*Handler) DoPoW ¶
func (h *Handler) DoPoW(trytes trinary.Trytes, mwm int, parallelism ...int) (nonce string, err error)
DoPoW calculates the PoW Either with the fastest available local PoW function or with the help of powsrv.io (optional, POWSRV_API_KEY env var must be available)
func (*Handler) GetPoWType ¶
GetPoWType returns the fastest available PoW type which gets used for PoW requests
Click to show internal directories.
Click to hide internal directories.