tinnitus

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

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

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

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ShouldExitGracefully = func() bool {
	shouldExit := len(ctrlC) > 0

	if shouldExit {
		Logger.Info("Shutting down gracefully.")
	}

	return shouldExit
}

Functions

func InitConfig

func InitConfig()

func InitFlags

func InitFlags()

func InitLogger

func InitLogger()

func InitRPC

func InitRPC()

func InitSuperCollider

func InitSuperCollider()

func Initialize

func Initialize(tinnitusMode TinnitusMode)

func PackagePath

func PackagePath() string

Types

type ClippedTransaction

type ClippedTransaction struct {
	Time     time.Time
	Controls map[string]float32
}

type GetBitcoinBlockVerboseResult

type GetBitcoinBlockVerboseResult struct {
	*btcjson.GetBlockVerboseResult
	Tx []btcjson.TxRawResult `json:"tx,omitempty"`
}

type GetZcashBlockVerboseResult

type GetZcashBlockVerboseResult struct {
	Hash          string                `json:"hash"`
	Confirmations int64                 `json:"confirmations"`
	StrippedSize  int32                 `json:"strippedsize"`
	Size          int32                 `json:"size"`
	Weight        int32                 `json:"weight"`
	Height        int64                 `json:"height"`
	Version       int32                 `json:"version"`
	VersionHex    string                `json:"versionHex"`
	MerkleRoot    string                `json:"merkleroot"`
	Tx            []btcjson.TxRawResult `json:"tx,omitempty"`
	Time          int64                 `json:"time"`
	Nonce         string                `json:"nonce"`
	Bits          string                `json:"bits"`
	Difficulty    float64               `json:"difficulty"`
	PreviousHash  string                `json:"previousblockhash"`
	NextHash      string                `json:"nextblockhash,omitempty"`
}

type RPCClient

type RPCClient struct {
	*rpcclient.Client
}
var RPC *RPCClient

func (*RPCClient) GetBitcoinBlockVerboseTx

func (client *RPCClient) GetBitcoinBlockVerboseTx(blockHash *chainhash.Hash) (*GetBitcoinBlockVerboseResult, error)

func (*RPCClient) GetZcashBlockVerboseTx

func (client *RPCClient) GetZcashBlockVerboseTx(blockHeight int64) (*GetZcashBlockVerboseResult, error)

type RPCConfig

type RPCConfig struct {
	Host     string `yaml:"host"`
	User     string `yaml:"user"`
	Password string `yaml:"password"`
}

type SCClient

type SCClient struct {
	*sc.Client
	// contains filtered or unexported fields
}
var SC *SCClient

type SCConfig

type SCConfig struct {
	Host    string        `yaml:"host"`
	Timeout time.Duration `yaml:"timeout"`
}

type Tinnitus

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

func NewTinnitus

func NewTinnitus() *Tinnitus

func (*Tinnitus) Run

func (tinnitus *Tinnitus) Run() error

func (*Tinnitus) Sandbox

func (tinnitus *Tinnitus) Sandbox() error

type TinnitusConfig

type TinnitusConfig struct {
	SC            SCConfig      `yaml:"sc"`
	RPC           RPCConfig     `yaml:"rpc"`
	Logger        zap.Config    `yaml:"logger"`
	SleepDuration time.Duration `yaml:"sleep_duration"`
}
var Config *TinnitusConfig = &TinnitusConfig{}

type TinnitusFlags

type TinnitusFlags struct {
	Verbose *bool
	Debug   *bool
	Version *bool
	Log     *string
	Config  *string
	Live    *bool
	From    *int64
	To      *int64
}
var Flags TinnitusFlags

type TinnitusMode

type TinnitusMode int
const (
	DefaultTinnitusMode TinnitusMode = iota
	TestingTinnitusMode
)
var Mode TinnitusMode

Directories

Path Synopsis
cmd

Jump to

Keyboard shortcuts

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