gcs

package
v0.0.0-...-f3846c7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 5, 2020 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewGcsFileReader

func NewGcsFileReader(ctx context.Context, projectId string, bucketName string, name string) (source.ParquetFile, error)

func NewGcsFileReaderWithClient

func NewGcsFileReaderWithClient(ctx context.Context, client *storage.Client, projectId string, bucketName string, name string) (source.ParquetFile, error)

func NewGcsFileWriter

func NewGcsFileWriter(ctx context.Context, projectId string, bucketName string, name string) (source.ParquetFile, error)

func NewGcsFileWriterWithClient

func NewGcsFileWriterWithClient(ctx context.Context, client *storage.Client, projectId string, bucketName string, name string) (source.ParquetFile, error)

Types

type GcsFile

type GcsFile struct {
	ProjectId  string
	BucketName string
	Ctx        context.Context

	Client *storage.Client

	Bucket     *storage.BucketHandle
	FilePath   string
	FileReader *storage.Reader
	FileWriter *storage.Writer
	// contains filtered or unexported fields
}

func (*GcsFile) Close

func (self *GcsFile) Close() error

func (*GcsFile) Create

func (self *GcsFile) Create(name string) (source.ParquetFile, error)

func (*GcsFile) Open

func (self *GcsFile) Open(name string) (source.ParquetFile, error)

func (*GcsFile) Read

func (self *GcsFile) Read(b []byte) (cnt int, err error)

func (*GcsFile) Seek

func (self *GcsFile) Seek(offset int64, pos int) (int64, error)

func (*GcsFile) Write

func (self *GcsFile) Write(b []byte) (n int, err error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL