alist/internal/model/file.go

32 lines
395 B
Go
Raw Normal View History

2022-06-07 14:02:41 +00:00
package model
import "time"
type File struct {
2022-06-15 12:31:23 +00:00
ID string
2022-06-07 14:02:41 +00:00
Name string
Size uint64
Modified time.Time
IsFolder bool
}
func (f File) GetName() string {
return f.Name
}
func (f File) GetSize() uint64 {
return f.Size
}
func (f File) ModTime() time.Time {
return f.Modified
}
func (f File) IsDir() bool {
return f.IsFolder
}
2022-06-11 06:43:03 +00:00
2022-06-15 12:31:23 +00:00
func (f File) GetID() string {
return f.ID
2022-06-11 06:43:03 +00:00
}