16 lines
411 B
Go
Raw Permalink Normal View History

2024-04-10 22:10:09 +08:00
package interfaces
import (
"context"
"io"
2024-04-10 22:10:09 +08:00
"nf-repo/internal/model"
"nf-repo/internal/tool/rerr"
2024-04-10 22:10:09 +08:00
)
type UploadHandler interface {
UploadId() string
Write(ctx context.Context, id string, reader io.ReadCloser, start, end int) (int, *rerr.RepositoryError)
Done(ctx context.Context, bh BlobHandler, id string, closer io.ReadCloser, contentLength int, repo string, hash model.Hash) *rerr.RepositoryError
}