Documentation ¶
Index ¶
- func AddImage(qb models.GalleryReaderWriter, galleryID int, imageID int) error
- func AddPerformer(qb models.GalleryReaderWriter, id int, performerID int) (bool, error)
- func AddTag(qb models.GalleryReaderWriter, id int, tagID int) (bool, error)
- func CountByPerformerID(r models.GalleryReader, id int) (int, error)
- func CountByStudioID(r models.GalleryReader, id int) (int, error)
- func CountByTagID(r models.GalleryReader, id int) (int, error)
- func FileScanner(hasher file.Hasher) file.Scanner
- func GetChecksums(galleries []*models.Gallery) []string
- func GetIDs(galleries []*models.Gallery) []int
- func GetStudioName(reader models.StudioReader, gallery *models.Gallery) (string, error)
- func PathsFilter(paths []string) *models.GalleryFilterType
- func ToBasicJSON(gallery *models.Gallery) (*jsonschema.Gallery, error)
- func UpdateFileModTime(qb models.GalleryWriter, id int, modTime models.NullSQLiteTimestamp) (*models.Gallery, error)
- type Importer
- type Scanner
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddImage ¶ added in v0.5.0
func AddImage(qb models.GalleryReaderWriter, galleryID int, imageID int) error
func AddPerformer ¶ added in v0.7.0
func CountByPerformerID ¶ added in v0.7.0
func CountByPerformerID(r models.GalleryReader, id int) (int, error)
func CountByStudioID ¶ added in v0.7.0
func CountByStudioID(r models.GalleryReader, id int) (int, error)
func CountByTagID ¶ added in v0.7.0
func CountByTagID(r models.GalleryReader, id int) (int, error)
func GetChecksums ¶ added in v0.5.0
func GetStudioName ¶
GetStudioName returns the name of the provided gallery's studio. It returns an empty string if there is no studio assigned to the gallery.
func PathsFilter ¶ added in v0.12.0
func PathsFilter(paths []string) *models.GalleryFilterType
func ToBasicJSON ¶
func ToBasicJSON(gallery *models.Gallery) (*jsonschema.Gallery, error)
ToBasicJSON converts a gallery object into its JSON object equivalent. It does not convert the relationships to other objects.
func UpdateFileModTime ¶ added in v0.5.0
func UpdateFileModTime(qb models.GalleryWriter, id int, modTime models.NullSQLiteTimestamp) (*models.Gallery, error)
Types ¶
type Importer ¶
type Importer struct { ReaderWriter models.GalleryReaderWriter StudioWriter models.StudioReaderWriter PerformerWriter models.PerformerReaderWriter TagWriter models.TagReaderWriter Input jsonschema.Gallery MissingRefBehaviour models.ImportMissingRefEnum // contains filtered or unexported fields }
func (*Importer) FindExistingID ¶
func (*Importer) PostImport ¶
type Scanner ¶ added in v0.11.0
type Scanner struct { file.Scanner ImageExtensions []string StripFileExtension bool CaseSensitiveFs bool TxnManager models.TransactionManager Paths *paths.Paths PluginCache *plugin.Cache MutexManager *utils.MutexManager }
func (*Scanner) ScanExisting ¶ added in v0.11.0
Click to show internal directories.
Click to hide internal directories.