Documentation ¶
Index ¶
- func BoolToInt(b bool) (int64, error)
- func IntToBool(i int64) (bool, error)
- func MakeDomainToRepositoryEntityConverter[TIn any, TOut any](ctx context.Context, ...) func(entity *TIn) (*TOut, error)
- func MakeDomainToRepositoryEntityConverterGeneric[TIn any, TOut any](ctx context.Context, ...) func(entity *TIn) (*TOut, error)
- func NullStrToOptionalTime(time_ null.String) (optional.Optional[time.Time], error)
- func NullStringToOptionalString(str null.String) (optional.Optional[string], error)
- func NullTimeToOptionalTime(time_ null.Time) (optional.Optional[time.Time], error)
- func OptionalStringToNullString(str optional.Optional[string]) (null.String, error)
- func OptionalTimeToNullStr(time optional.Optional[time.Time]) (null.String, error)
- func OptionalTimeToNullTime(time optional.Optional[time.Time]) (null.Time, error)
- func StrToTime(time_ string) (time.Time, error)
- func TimeToStr(time time.Time) (string, error)
- type BookmarkRepository
- type DocumentContent
- type DocumentContentRepository
- type DocumentRepository
- type ReferenceToNonExistentDependencyError
- type TagRepository
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MakeDomainToRepositoryEntityConverterGeneric ¶ added in v0.6.0
func NullStrToOptionalTime ¶
func NullTimeToOptionalTime ¶
func OptionalTimeToNullStr ¶
func OptionalTimeToNullTime ¶
Types ¶
type BookmarkRepository ¶
type BookmarkRepository interface { New(args any) (BookmarkRepository, error) Add(ctx context.Context, domainModels []*domain.Bookmark) error Replace(ctx context.Context, domainModels []*domain.Bookmark) error Upsert(ctx context.Context, domainModels []*domain.Bookmark) error Update(ctx context.Context, domainModels []*domain.Bookmark, domainUpdaters *domain.BookmarkUpdater) error UpdateWhere(ctx context.Context, domainFilter *domain.BookmarkFilter, domainUpdaters *domain.BookmarkUpdater) (numAffectedRecords int64, err error) Delete(ctx context.Context, domainModels []*domain.Bookmark) error DeleteWhere(ctx context.Context, domainFilter *domain.BookmarkFilter) (numAffectedRecords int64, err error) CountWhere(ctx context.Context, domainFilter *domain.BookmarkFilter) (numRecords int64, err error) CountAll(ctx context.Context) (numRecords int64, err error) DoesExist(ctx context.Context, domainModel *domain.Bookmark) (doesExist bool, err error) DoesExistWhere(ctx context.Context, domainFilter *domain.BookmarkFilter) (doesExist bool, err error) GetWhere(ctx context.Context, domainFilter *domain.BookmarkFilter) (records []*domain.Bookmark, err error) GetFirstWhere(ctx context.Context, domainFilter *domain.BookmarkFilter) (record *domain.Bookmark, err error) GetAll(ctx context.Context) (records []*domain.Bookmark, err error) GetFromIDs(ctx context.Context, ids []int64) (records []*domain.Bookmark, err error) AddType(ctx context.Context, types []string) error DeleteType(ctx context.Context, types []string) error UpdateType(ctx context.Context, oldType string, newType string) error GetAllTypes(ctx context.Context) ([]string, error) GetTagRepository() TagRepository BookmarkRepositoryToDomainModel(ctx context.Context, repositoryModel any) (domainModel *domain.Bookmark, err error) BookmarkDomainToRepositoryModel(ctx context.Context, domainModel *domain.Bookmark) (repositoryModel any, err error) BookmarkDomainToRepositoryFilter(ctx context.Context, domainFilter *domain.BookmarkFilter) (repositoryFilter any, err error) BookmarkDomainToRepositoryUpdater(ctx context.Context, domainUpdater *domain.BookmarkUpdater) (repositoryUpdater any, err error) }
type DocumentContent ¶
type DocumentContentRepository ¶
type DocumentContentRepository interface { New(args any) (DocumentContentRepository, error) Add(ctx context.Context, pathContents []tuple.T2[string, string]) error Update(ctx context.Context, pathContents []tuple.T2[string, string]) error Move(ctx context.Context, pathChanges []tuple.T2[string, string]) error Delete(ctx context.Context, paths []string) error Get(ctx context.Context, paths []string) (contents []string, err error) }
type DocumentRepository ¶
type DocumentRepository interface { New(args any) (DocumentRepository, error) Add(ctx context.Context, domainModels []*domain.Document) error Replace(ctx context.Context, domainModels []*domain.Document) error Upsert(ctx context.Context, domainModels []*domain.Document) error Update(ctx context.Context, domainModels []*domain.Document, domainUpdaters *domain.DocumentUpdater) error UpdateWhere(ctx context.Context, domainFilter *domain.DocumentFilter, domainUpdaters *domain.DocumentUpdater) (numAffectedRecords int64, err error) Delete(ctx context.Context, domainModels []*domain.Document) error DeleteWhere(ctx context.Context, domainFilter *domain.DocumentFilter) (numAffectedRecords int64, err error) CountWhere(ctx context.Context, domainFilter *domain.DocumentFilter) (numRecords int64, err error) CountAll(ctx context.Context) (numRecords int64, err error) DoesExist(ctx context.Context, domainModel *domain.Document) (doesExist bool, err error) DoesExistWhere(ctx context.Context, domainFilter *domain.DocumentFilter) (doesExist bool, err error) GetWhere(ctx context.Context, domainFilter *domain.DocumentFilter) (records []*domain.Document, err error) GetFirstWhere(ctx context.Context, domainFilter *domain.DocumentFilter) (record *domain.Document, err error) GetAll(ctx context.Context) (records []*domain.Document, err error) GetFromIDs(ctx context.Context, ids []int64) (records []*domain.Document, err error) AddType(ctx context.Context, types []string) error DeleteType(ctx context.Context, types []string) error UpdateType(ctx context.Context, oldType string, newType string) error GetAllTypes(ctx context.Context) ([]string, error) GetTagRepository() TagRepository DocumentRepositoryToDomainModel(ctx context.Context, repositoryModel any) (domainModel *domain.Document, err error) DocumentDomainToRepositoryModel(ctx context.Context, domainModel *domain.Document) (repositoryModel any, err error) DocumentDomainToRepositoryFilter(ctx context.Context, domainFilter *domain.DocumentFilter) (repositoryFilter any, err error) DocumentDomainToRepositoryUpdater(ctx context.Context, domainUpdater *domain.DocumentUpdater) (repositoryUpdater any, err error) }
type ReferenceToNonExistentDependencyError ¶ added in v0.6.0
type ReferenceToNonExistentDependencyError struct {
Inner error
}
func (ReferenceToNonExistentDependencyError) As ¶ added in v0.6.0
func (err ReferenceToNonExistentDependencyError) As(target any) bool
func (ReferenceToNonExistentDependencyError) Error ¶ added in v0.6.0
func (err ReferenceToNonExistentDependencyError) Error() string
func (ReferenceToNonExistentDependencyError) Is ¶ added in v0.6.0
func (err ReferenceToNonExistentDependencyError) Is(other error) bool
func (ReferenceToNonExistentDependencyError) Unwrap ¶ added in v0.6.0
func (err ReferenceToNonExistentDependencyError) Unwrap() error
type TagRepository ¶
type TagRepository interface { New(args any) (TagRepository, error) Add(ctx context.Context, domainModels []*domain.Tag) error Replace(ctx context.Context, domainModels []*domain.Tag) error Upsert(ctx context.Context, domainModels []*domain.Tag) error Update(ctx context.Context, domainModels []*domain.Tag, domainUpdaters *domain.TagUpdater) error UpdateWhere(ctx context.Context, domainFilter *domain.TagFilter, domainUpdaters *domain.TagUpdater) (numAffectedRecords int64, err error) Delete(ctx context.Context, domainModels []*domain.Tag) error DeleteWhere(ctx context.Context, domainFilter *domain.TagFilter) (numAffectedRecords int64, err error) CountWhere(ctx context.Context, domainFilter *domain.TagFilter) (numRecords int64, err error) CountAll(ctx context.Context) (numRecords int64, err error) DoesExist(ctx context.Context, domainModel *domain.Tag) (doesExist bool, err error) DoesExistWhere(ctx context.Context, domainFilter *domain.TagFilter) (doesExist bool, err error) GetWhere(ctx context.Context, domainFilter *domain.TagFilter) (records []*domain.Tag, err error) GetFirstWhere(ctx context.Context, domainFilter *domain.TagFilter) (record *domain.Tag, err error) GetAll(ctx context.Context) (records []*domain.Tag, err error) GetFromIDs(ctx context.Context, ids []int64) (records []*domain.Tag, err error) TagRepositoryToDomainModel(ctx context.Context, repositoryModel any) (domainModel *domain.Tag, err error) TagDomainToRepositoryModel(ctx context.Context, domainModel *domain.Tag) (repositoryModel any, err error) TagDomainToRepositoryFilter(ctx context.Context, domainFilter *domain.TagFilter) (repositoryFilter any, err error) TagDomainToRepositoryUpdater(ctx context.Context, domainUpdater *domain.TagUpdater) (repositoryUpdater any, err error) }
Source Files ¶
Click to show internal directories.
Click to hide internal directories.