Files
2026-07-16 22:16:45 +07:00

18 lines
948 B
Go

package helicopterfile
import "context"
type Repository interface {
Create(ctx context.Context, row *HelicopterFile) error
Update(ctx context.Context, row *HelicopterFile) error
Delete(ctx context.Context, id []byte) error
GetByID(ctx context.Context, id []byte) (*HelicopterFile, error)
List(ctx context.Context, filter string, sort string, limit, offset int) ([]HelicopterFile, int64, error)
ListPendingAttachments(ctx context.Context, limit int) ([]HelicopterFile, error)
ListPendingAttachmentsBySourceFileID(ctx context.Context, sourceFileID []byte, limit int) ([]HelicopterFile, error)
ListByHelicopter(ctx context.Context, helicopterID []byte) ([]HelicopterFile, error)
ListByHelicopterAndSection(ctx context.Context, helicopterID []byte, section string) ([]HelicopterFile, error)
HelicopterExists(ctx context.Context, helicopterID []byte) (bool, error)
AttachmentExists(ctx context.Context, attachmentID []byte) (bool, error)
}