Documentation ¶
Index ¶
- Variables
- type Binary
- type Service
- func (s Service) DeleteBinary(ctx context.Context, uid, id string) error
- func (s Service) GetAllBinaries(ctx context.Context, uid string) ([]Binary, error)
- func (s Service) GetBinaryByID(ctx context.Context, uid, id string) (Binary, error)
- func (s Service) StoreBinary(ctx context.Context, uid string, binary Binary) (string, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrInvalid = errors.New("passed text data is invalid") ErrNotFound = errors.New("requested binary data not found") )
Functions ¶
This section is empty.
Types ¶
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func NewService ¶
NewService returns an instance of the Service with pre-defined data microservice.
func (Service) DeleteBinary ¶
DeleteBinary removes the stored data with the unique ID. The method removes the data of the specified user only.
func (Service) GetAllBinaries ¶
GetAllBinaries returns all the user's stored binaries.
func (Service) GetBinaryByID ¶
GetBinaryByID returns the stored data by the unique ID. The method returns the data of the specified user only.
Click to show internal directories.
Click to hide internal directories.