Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BucketRepository ¶
type BucketRepository interface { CreateBucket(ctx context.Context, bucket *domain.Bucket) (*domain.Bucket, error) GetBucketByID(ctx context.Context, id uuid.UUID) (*domain.Bucket, error) GetBucketByName(ctx context.Context, name string) (*domain.Bucket, error) ListBuckets(ctx context.Context) ([]domain.Bucket, error) DeleteBucket(ctx context.Context, id uuid.UUID) error }
BucketRepository is an interface to interact with the storage layer
type BucketService ¶
type BucketService interface { CreateBucket(ctx context.Context, bucket *domain.Bucket) (*domain.Bucket, error) GetBucket(ctx context.Context, id string) (*domain.Bucket, error) ListBuckets(ctx context.Context) ([]domain.Bucket, error) DeleteBucket(ctx context.Context, id string) error }
BucketService is an interface to interact with the business logic
type FileRepository ¶
type FileRepository interface { CreateFile(ctx context.Context, file *domain.File) (*domain.File, error) GetFileByID(ctx context.Context, id uuid.UUID) (*domain.File, error) GetFileByName(ctx context.Context, name string, bucketID uuid.UUID) (*domain.File, error) GetFilesByBucketID(ctx context.Context, bucketID uuid.UUID) ([]domain.File, error) DeleteFilesByBucketID(ctx context.Context, bucketID uuid.UUID) error DeleteFile(ctx context.Context, id uuid.UUID) error }
type FileService ¶
type StorageRepository ¶
type StorageRepositoryProvider ¶
type StorageRepositoryProvider interface {
Get(storageType domain.BucketType) (StorageRepository, error)
}
Click to show internal directories.
Click to hide internal directories.