Remove Create() everywhere

This commit is contained in:
Alexander Neumann
2016-01-24 20:23:50 +01:00
parent ea29ad6f96
commit 1547d3b656
13 changed files with 25 additions and 401 deletions
-17
View File
@@ -1,7 +1,5 @@
package backend
import "io"
// Type is the type of a Blob.
type Type string
@@ -21,10 +19,6 @@ type Backend interface {
// repository.
Location() string
// Create creates a new Blob. The data is available only after Finalize()
// has been called on the returned Blob.
Create() (Blob, error)
// Test a boolean value whether a Blob with the name and type exists.
Test(t Type, name string) (bool, error)
@@ -65,14 +59,3 @@ type Deleter interface {
type BlobInfo struct {
Size int64
}
// Blob is old.
type Blob interface {
io.Writer
// Finalize moves the data blob to the final location for type and name.
Finalize(t Type, name string) error
// Size returns the number of bytes written to the backend so far.
Size() uint
}