gpaste/file.go

22 lines
268 B
Go
Raw Normal View History

2022-01-15 18:07:33 +00:00
package gpaste
import (
"io"
"time"
)
type File struct {
ID string
Body io.ReadCloser
MaxViews uint
ExpiresOn time.Time
}
type FileStore interface {
Store(f *File) error
Get(id string) (*File, error)
Delete(id string) error
List() ([]string, error)
}