handlers

package
v0.0.0-...-cbe46fc Latest Latest
Warning

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

Go to latest
Published: Jul 12, 2022 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CoinInfo

type CoinInfo struct {
	ID         string `json:"id,omitempty"`
	Symbol     string `json:"symbol,omitempty"`
	Name       string `json:"name,omitempty"`
	MetricDesc *prometheus.Desc
}

type Config

type Config struct {
	Coins      []*CoinInfo `json:"coins,omitempty"`
	Currencies string      `json:"currencies,omitempty"`
}

func LoadConfig

func LoadConfig() (*Config, error)

type PriceCollector

type PriceCollector struct {
	Config *Config
}

func NewPriceCollector

func NewPriceCollector() *PriceCollector

func (*PriceCollector) Collect

func (p *PriceCollector) Collect(ch chan<- prometheus.Metric)

func (*PriceCollector) Describe

func (p *PriceCollector) Describe(ch chan<- *prometheus.Desc)

Jump to

Keyboard shortcuts

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