tdl/pkg/downloader/iter.go

19 lines
302 B
Go
Raw Normal View History

2022-09-04 10:48:52 +08:00
package downloader
import (
"context"
"github.com/gotd/td/tg"
)
type Iter interface {
Next(ctx context.Context) bool
Value(ctx context.Context) (*Item, error)
Total(ctx context.Context) int
}
type Item struct {
InputFileLoc tg.InputFileLocationClass
Name string
Size int64
}