-
Notifications
You must be signed in to change notification settings - Fork 2
/
result.go
25 lines (21 loc) · 924 Bytes
/
result.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
package bigo
// OMeasure is a single capture of the O value.
type OMeasure struct {
// ResultValue may be used to store result values of the tested logic.
// It is not used by this library, it's intention is debugging:
// If those are deterministic they could be used to cross check that the tested code worked as expected.
ResultValue interface{} `json:"V"`
// O represents the number of operations used by the tested program.
// Determining this value could be from tricky to impossible.
// For a per machine comparison this could also be the duration of the logic under test.
O float64 `json:"O"`
}
// OMeasures contains multiple instances of OMeasure.
type OMeasures []OMeasure
// Result is used by the library to accumulate OMeasure results per N.
type Result struct {
N float64 `json:"N"`
OMeasures OMeasures `json:"M"`
}
// Results contains multiple instances of Result.
type Results []Result