cityuni-webserver/pageHandler/utils/counting-writer.go
Captain ALM 11deb796e8
All checks were successful
continuous-integration/drone Build is passing
Begin adding page handling system, add utils for the pageHandler system.
2022-07-14 23:25:43 +01:00

11 lines
172 B
Go

package utils
type CountingWriter struct {
Length int64
}
func (c *CountingWriter) Write(p []byte) (n int, err error) {
c.Length += int64(len(p))
return len(p), nil
}