Documentation
¶
Overview ¶
Package probes provides types to inspect varying numerical values safely across many goroutines.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Probe ¶
type Probe struct {
// The maximum length of the probe's internal signal history.
MaximumSignalLength int
// The length of the input channel's buffer.
InputBufferLength int
// The probe's input channel.
C chan float64
// contains filtered or unexported fields
}
Probe types collect floating point values and expose those values safely.
func (*Probe) Activate ¶
func (p *Probe) Activate()
Activate activates the probe and begins waiting for signal values over its input channel.
func (*Probe) ClearSignal ¶
func (p *Probe) ClearSignal()
ClearSignal removes all elements from the probe's signal.
func (*Probe) Deactivate ¶
func (p *Probe) Deactivate()
Deactivate deactivates the probe and returns the signal it collected.
func (*Probe) Push ¶
Push appends a value to the probe's signal after, optionally, flushing any values in the probe's input channel buffer.
func (*Probe) RecentValue ¶
RecentValue retrieves the most recent value collected by the probe, or 0.0 if a value has not been collected.
Click to show internal directories.
Click to hide internal directories.