provider

package
v0.2.12 Latest Latest
Warning

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

Go to latest
Published: Nov 5, 2024 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Azure

type Azure struct {
	model.OssConfig
}

func (*Azure) Auth

func (o *Azure) Auth() error

func (*Azure) Close

func (o *Azure) Close() error

func (*Azure) GetObject

func (o *Azure) GetObject(objName string) (io.ReadCloser, error)

func (*Azure) GetOssConfigID

func (o *Azure) GetOssConfigID() uint64

func (*Azure) PutObject

func (o *Azure) PutObject(objName string, reader io.Reader) error

type KS3

type KS3 struct {
	model.OssConfig
}

func (*KS3) Auth

func (o *KS3) Auth() error

func (*KS3) Close

func (o *KS3) Close() error

func (*KS3) GetObject

func (o *KS3) GetObject(objName string) (io.ReadCloser, error)

func (*KS3) GetOssConfigID

func (o *KS3) GetOssConfigID() uint64

func (*KS3) PutObject

func (o *KS3) PutObject(objName string, reader io.Reader) error

type Minio

type Minio struct {
	model.OssConfig
	Client *minio.Client
}

func (*Minio) Auth

func (o *Minio) Auth() error

func (*Minio) Close

func (o *Minio) Close() error

func (*Minio) GetObject

func (o *Minio) GetObject(objName string) (io.ReadCloser, error)

func (*Minio) GetOssConfigID

func (o *Minio) GetOssConfigID() uint64

func (*Minio) PutObject

func (o *Minio) PutObject(objName string, reader io.Reader) error

type OBS

type OBS struct {
	model.OssConfig
	Client *obs.ObsClient
}

func (*OBS) Auth

func (o *OBS) Auth() error

func (*OBS) Close

func (o *OBS) Close() error

func (*OBS) GetObject

func (o *OBS) GetObject(objName string) (io.ReadCloser, error)

func (*OBS) GetOssConfigID

func (o *OBS) GetOssConfigID() uint64

func (*OBS) PutObject

func (o *OBS) PutObject(objName string, reader io.Reader) error

type OSS

type OSS struct {
	model.OssConfig
	Client *oss.Client
	Bucket *oss.Bucket
}

func (*OSS) Auth

func (o *OSS) Auth() error

func (*OSS) Close

func (o *OSS) Close() error

func (*OSS) GetObject

func (o *OSS) GetObject(objName string) (io.ReadCloser, error)

func (*OSS) GetOssConfigID

func (o *OSS) GetOssConfigID() uint64

func (*OSS) PutObject

func (o *OSS) PutObject(objName string, reader io.Reader) error

type OsManager

type OsManager interface {
	Auth() error
	Close() error
	PutObject(objName string, reader io.Reader) error
	GetObject(objName string) (io.ReadCloser, error)
	GetOssConfigID() uint64
}

func GetProvider

func GetProvider(c *model.OssConfig) (m OsManager)

Jump to

Keyboard shortcuts

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