INNER CODE UNIT · Go

newDownloadStream

256dpi/lungo · bucket.go:1120

func newDownloadStream(ctx context.Context, bucket *Bucket, id interface{}, name string, revision int) *DownloadStream {
	return &DownloadStream{
		context:  ctx,
		bucket:   bucket,
		id:       id,
		name:     name,
		revision: revision,
	}
}

// GetFile will return the file that is stream is downloading from.
func (s *DownloadStream) GetFile() *BucketFile {
	return s.file
}

// Skip will advance the read head by the specified amount of bytes.
func (s *DownloadStream) Skip(skip int64) (int64, error) {
	return s.Seek(skip, io.SeekCurrent)

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…