blob

package
v0.0.0-...-423d19e Latest Latest
Warning

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

Go to latest
Published: Nov 18, 2020 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GCSClient

type GCSClient struct {
	Client     *storage.Client
	BucketName string
}

GCSClient is a client for writing new objects to a GCS bucket.

func (*GCSClient) AllowPublicAccess

func (g *GCSClient) AllowPublicAccess(ctx context.Context, fileName string) error

AllowPublicAccess sets the ACL on the specified file to be public. The object must already exist.

func (*GCSClient) NewObject

func (g *GCSClient) NewObject(ctx context.Context, fileName string) io.WriteCloser

NewObject creates a new object with the specified file name in the bucket for this GCS client and returns a writer for the object.

Jump to

Keyboard shortcuts

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