minio

package
v0.1.1-0...-4a89cbd Latest Latest
Warning

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

Go to latest
Published: May 21, 2019 License: MPL-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewConnection

func NewConnection(host, port, accessKeyID, secretAccessKey string, useSSL bool) *minio.Client

NewConnection creates a new minio Client object

Types

type MinioBucket

type MinioBucket struct {
	// contains filtered or unexported fields
}

MinioBucket stores the name and location of a bucket

func (*MinioBucket) Get

func (mb *MinioBucket) Get(name string) (io.Reader, error)

func (*MinioBucket) GetStat

func (mb *MinioBucket) GetStat(name string) (io.Reader, *MinioObjectInfo, error)

func (*MinioBucket) Put

func (mb *MinioBucket) Put(name, contentType string, size int64, object io.Reader) error

func (*MinioBucket) Remove

func (mb *MinioBucket) Remove(name string) error

func (*MinioBucket) Stat

func (mb *MinioBucket) Stat(name string) (*MinioObjectInfo, error)

type MinioObjectInfo

type MinioObjectInfo struct {
	// contains filtered or unexported fields
}

MinioObjectInfo wraps minio.ObjectInfo{}

func New

func New(mio *minio.ObjectInfo) *MinioObjectInfo

func (*MinioObjectInfo) ContentType

func (oi *MinioObjectInfo) ContentType() string

func (*MinioObjectInfo) ETag

func (oi *MinioObjectInfo) ETag() string

func (*MinioObjectInfo) LastModified

func (oi *MinioObjectInfo) LastModified() time.Time

func (*MinioObjectInfo) Size

func (oi *MinioObjectInfo) Size() int64

type MinioObjectStore

type MinioObjectStore struct {
	// contains filtered or unexported fields
}

MinioObjectStore wraps a Minio Client

func NewMinioObjStore

func NewMinioObjStore(client *minio.Client) *MinioObjectStore

func (*MinioObjectStore) DestroyBucket

func (mos *MinioObjectStore) DestroyBucket(name, location string) error

DestroyBucket destroys a bucket based on name and location

func (*MinioObjectStore) GetBucket

func (mos *MinioObjectStore) GetBucket(name, location string) (*MinioBucket, error)

GetBucket returns a bucket based on name and location strings. If a bucket does not yet exist, it will create that bucket.

Jump to

Keyboard shortcuts

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