2025-02-07 22:58:01 +08:00

17 lines
358 B
Go

package dto
import "time"
type File struct {
BasePath string `json:"basePath"`
Url string `json:"url"`
Path string `json:"path"`
Name string `json:"name"`
StartTime time.Time `json:"startTime"`
EndTime time.Time `json:"endTime"`
}
func (f *File) GetDiffMs() int64 {
return f.EndTime.Sub(f.StartTime).Milliseconds()
}