diff options
Diffstat (limited to 'vendor/github.com/aws/aws-sdk-go/aws/types.go')
-rw-r--r-- | vendor/github.com/aws/aws-sdk-go/aws/types.go | 20 |
1 files changed, 13 insertions, 7 deletions
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/types.go b/vendor/github.com/aws/aws-sdk-go/aws/types.go index 8b6f234..4550915 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/types.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/types.go | |||
@@ -7,13 +7,18 @@ import ( | |||
7 | "github.com/aws/aws-sdk-go/internal/sdkio" | 7 | "github.com/aws/aws-sdk-go/internal/sdkio" |
8 | ) | 8 | ) |
9 | 9 | ||
10 | // ReadSeekCloser wraps a io.Reader returning a ReaderSeekerCloser. Should | 10 | // ReadSeekCloser wraps a io.Reader returning a ReaderSeekerCloser. Allows the |
11 | // only be used with an io.Reader that is also an io.Seeker. Doing so may | 11 | // SDK to accept an io.Reader that is not also an io.Seeker for unsigned |
12 | // cause request signature errors, or request body's not sent for GET, HEAD | 12 | // streaming payload API operations. |
13 | // and DELETE HTTP methods. | ||
14 | // | 13 | // |
15 | // Deprecated: Should only be used with io.ReadSeeker. If using for | 14 | // A ReadSeekCloser wrapping an nonseekable io.Reader used in an API |
16 | // S3 PutObject to stream content use s3manager.Uploader instead. | 15 | // operation's input will prevent that operation being retried in the case of |
16 | // network errors, and cause operation requests to fail if the operation | ||
17 | // requires payload signing. | ||
18 | // | ||
19 | // Note: If using With S3 PutObject to stream an object upload The SDK's S3 | ||
20 | // Upload manager (s3manager.Uploader) provides support for streaming with the | ||
21 | // ability to retry network errors. | ||
17 | func ReadSeekCloser(r io.Reader) ReaderSeekerCloser { | 22 | func ReadSeekCloser(r io.Reader) ReaderSeekerCloser { |
18 | return ReaderSeekerCloser{r} | 23 | return ReaderSeekerCloser{r} |
19 | } | 24 | } |
@@ -43,7 +48,8 @@ func IsReaderSeekable(r io.Reader) bool { | |||
43 | // Read reads from the reader up to size of p. The number of bytes read, and | 48 | // Read reads from the reader up to size of p. The number of bytes read, and |
44 | // error if it occurred will be returned. | 49 | // error if it occurred will be returned. |
45 | // | 50 | // |
46 | // If the reader is not an io.Reader zero bytes read, and nil error will be returned. | 51 | // If the reader is not an io.Reader zero bytes read, and nil error will be |
52 | // returned. | ||
47 | // | 53 | // |
48 | // Performs the same functionality as io.Reader Read | 54 | // Performs the same functionality as io.Reader Read |
49 | func (r ReaderSeekerCloser) Read(p []byte) (int, error) { | 55 | func (r ReaderSeekerCloser) Read(p []byte) (int, error) { |