Documentation ¶
Index ¶
Constants ¶
View Source
const ( Stopped timerState = iota Started Paused )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MultiPartSetter ¶
type MultiPartSetter struct {
// contains filtered or unexported fields
}
A setter that can have distinct part or sections. By using a MultiPartSetter one can time distinct sections of code and have their individuals times summed to form a total timed value.
func NewMultiPartSetter ¶
func NewMultiPartSetter(setter Setter) *MultiPartSetter
func (*MultiPartSetter) NewPart ¶
func (mp *MultiPartSetter) NewPart() Setter
Add a new distinct part. As new timings are set for this part they will contribute to the total time.
func (*MultiPartSetter) Stop ¶
func (mp *MultiPartSetter) Stop()
type Setter ¶
type Setter interface {
Set(int64)
}
A variable that is settable. The use of this interface allows for control on how the averaged timed value accessed.
Click to show internal directories.
Click to hide internal directories.