Files
learngo/interfaces/log-parser/oop/result.go

17 lines
229 B
Go
Raw Normal View History

2019-08-17 15:55:25 +03:00
package main
2019-08-19 20:00:27 +03:00
const fieldsLength = 4
2019-08-17 15:55:25 +03:00
type result struct {
domain string
page string
visits int
uniques int
}
func (r result) add(other result) result {
r.visits += other.visits
r.uniques += other.uniques
return r
}