Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Exporter ¶
type Exporter struct {
// contains filtered or unexported fields
}
Exporter collects stats from the Tankerkoenig API and exports them using the prometheus client library.
func NewForLocation ¶
func NewForLocation(logger *log.Logger, apiClient *client.Client, location string, radius int) (*Exporter, error)
NewForLocation returns a new, initialized Tankerkoenig API exporter for the stations that are in the given radius around the given location.
func NewForStations ¶
func NewForStations(logger *log.Logger, apiClient *client.Client, apiStations []string) (*Exporter, error)
NewForStations returns a new, initialized Tankerkoenig API exporter for the given stations.
func (*Exporter) Collect ¶
func (e *Exporter) Collect(ch chan<- prometheus.Metric)
Collect the stats from the Tankerkoenig API. Implements prometheus.Collector.
func (*Exporter) Describe ¶
func (e *Exporter) Describe(ch chan<- *prometheus.Desc)
Describe all the metrics collected by the Tankerkoenig exporter. Implements prometheus.Collector.
Click to show internal directories.
Click to hide internal directories.