Documentation ¶
Index ¶
- type Bucket
- type ObjectStorage
- type ReadAndReaderAt
- type ReaderAtCloser
- type StorageFS
- func (s *StorageFS) DeleteFile(bucket Bucket, fname string) error
- func (s *StorageFS) GetBucket(name string) (Bucket, error)
- func (s *StorageFS) GetFile(bucket Bucket, fname string) (ReaderAtCloser, error)
- func (s *StorageFS) PutFile(bucket Bucket, fname string, contents ReaderAtCloser) (string, error)
- func (s *StorageFS) UpsertBucket(name string) (Bucket, error)
- type StorageMinio
- func (s *StorageMinio) DeleteFile(bucket Bucket, fname string) error
- func (s *StorageMinio) GetBucket(name string) (Bucket, error)
- func (s *StorageMinio) GetFile(bucket Bucket, fname string) (ReaderAtCloser, error)
- func (s *StorageMinio) PutFile(bucket Bucket, fname string, contents ReaderAtCloser) (string, error)
- func (s *StorageMinio) UpsertBucket(name string) (Bucket, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ObjectStorage ¶
type ReaderAtCloser ¶
type ReaderAtCloser interface { io.ReaderAt io.ReadCloser }
func NopReaderAtCloser ¶
func NopReaderAtCloser(r ReadAndReaderAt) ReaderAtCloser
type StorageFS ¶
type StorageFS struct {
Dir string
}
func NewStorageFS ¶
func (*StorageFS) GetFile ¶
func (s *StorageFS) GetFile(bucket Bucket, fname string) (ReaderAtCloser, error)
type StorageMinio ¶
type StorageMinio struct {
Client *minio.Client
}
func NewStorageMinio ¶
func NewStorageMinio(address, user, pass string) (*StorageMinio, error)
func (*StorageMinio) DeleteFile ¶
func (s *StorageMinio) DeleteFile(bucket Bucket, fname string) error
func (*StorageMinio) GetFile ¶
func (s *StorageMinio) GetFile(bucket Bucket, fname string) (ReaderAtCloser, error)
func (*StorageMinio) PutFile ¶
func (s *StorageMinio) PutFile(bucket Bucket, fname string, contents ReaderAtCloser) (string, error)
func (*StorageMinio) UpsertBucket ¶
func (s *StorageMinio) UpsertBucket(name string) (Bucket, error)
Click to show internal directories.
Click to hide internal directories.