diff options
Diffstat (limited to 'internal/flamegraph/counter.go')
| -rw-r--r-- | internal/flamegraph/counter.go | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/internal/flamegraph/counter.go b/internal/flamegraph/counter.go index bc30df0..96cfe06 100644 --- a/internal/flamegraph/counter.go +++ b/internal/flamegraph/counter.go @@ -1,16 +1,16 @@ package flamegraph -type counter struct { - count uint64 - duration uint64 - durationToPrev uint64 - bytes uint64 // TODO: implement +type Counter struct { + Count uint64 + Duration uint64 + DurationToPrev uint64 + Bytes uint64 // TODO: implement } -func (c counter) add(other counter) counter { - c.count += other.count - c.duration += other.duration - c.durationToPrev += other.durationToPrev - c.bytes += other.bytes +func (c Counter) add(other Counter) Counter { + c.Count += other.Count + c.Duration += other.Duration + c.DurationToPrev += other.DurationToPrev + c.Bytes += other.Bytes return c } |
