updated error comment
This commit is contained in:
parent
e80d64414b
commit
fbc378067d
File diff suppressed because it is too large
Load Diff
|
@ -699,6 +699,8 @@ func (b *Bucket) Delete(ctx context.Context, key string) (err error) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// Close releases any resources used for the bucket.
|
// Close releases any resources used for the bucket.
|
||||||
|
//
|
||||||
|
// @todo Consider removing it.
|
||||||
func (b *Bucket) Close() error {
|
func (b *Bucket) Close() error {
|
||||||
b.mu.Lock()
|
b.mu.Lock()
|
||||||
prev := b.closed
|
prev := b.closed
|
||||||
|
|
|
@ -40,8 +40,7 @@ type Driver interface {
|
||||||
NormalizeError(err error) error
|
NormalizeError(err error) error
|
||||||
|
|
||||||
// Attributes returns attributes for the blob. If the specified object does
|
// Attributes returns attributes for the blob. If the specified object does
|
||||||
// not exist, Attributes must return an error for which ErrorCode returns
|
// not exist, Attributes must return an error for which ErrorCode returns ErrNotFound.
|
||||||
// gcerrors.NotFound.
|
|
||||||
// The portable type will not modify the returned Attributes.
|
// The portable type will not modify the returned Attributes.
|
||||||
Attributes(ctx context.Context, key string) (*Attributes, error)
|
Attributes(ctx context.Context, key string) (*Attributes, error)
|
||||||
|
|
||||||
|
@ -57,8 +56,7 @@ type Driver interface {
|
||||||
// NewRangeReader returns a Reader that reads part of an object, reading at
|
// NewRangeReader returns a Reader that reads part of an object, reading at
|
||||||
// most length bytes starting at the given offset. If length is negative, it
|
// most length bytes starting at the given offset. If length is negative, it
|
||||||
// will read until the end of the object. If the specified object does not
|
// will read until the end of the object. If the specified object does not
|
||||||
// exist, NewRangeReader must return an error for which ErrorCode returns
|
// exist, NewRangeReader must return an error for which ErrorCode returns ErrNotFound.
|
||||||
// gcerrors.NotFound.
|
|
||||||
// opts is guaranteed to be non-nil.
|
// opts is guaranteed to be non-nil.
|
||||||
//
|
//
|
||||||
// The returned Reader *may* also implement Downloader if the underlying
|
// The returned Reader *may* also implement Downloader if the underlying
|
||||||
|
@ -90,7 +88,7 @@ type Driver interface {
|
||||||
// Copy copies the object associated with srcKey to dstKey.
|
// Copy copies the object associated with srcKey to dstKey.
|
||||||
//
|
//
|
||||||
// If the source object does not exist, Copy must return an error for which
|
// If the source object does not exist, Copy must return an error for which
|
||||||
// ErrorCode returns gcerrors.NotFound.
|
// ErrorCode returns ErrNotFound.
|
||||||
//
|
//
|
||||||
// If the destination object already exists, it should be overwritten.
|
// If the destination object already exists, it should be overwritten.
|
||||||
//
|
//
|
||||||
|
@ -98,8 +96,7 @@ type Driver interface {
|
||||||
Copy(ctx context.Context, dstKey, srcKey string) error
|
Copy(ctx context.Context, dstKey, srcKey string) error
|
||||||
|
|
||||||
// Delete deletes the object associated with key. If the specified object does
|
// Delete deletes the object associated with key. If the specified object does
|
||||||
// not exist, Delete must return an error for which ErrorCode returns
|
// not exist, Delete must return an error for which ErrorCode returns ErrNotFound.
|
||||||
// gcerrors.NotFound.
|
|
||||||
Delete(ctx context.Context, key string) error
|
Delete(ctx context.Context, key string) error
|
||||||
|
|
||||||
// Close cleans up any resources used by the Bucket. Once Close is called,
|
// Close cleans up any resources used by the Bucket. Once Close is called,
|
||||||
|
|
Loading…
Reference in New Issue