Documentation ¶
Overview ¶
Package match provides functions for matching paths to models.
Index ¶
- func PathToGalleriesFn(ctx context.Context, name string, paths []string, ...) error
- func PathToImagesFn(ctx context.Context, name string, paths []string, ...) error
- func PathToPerformers(ctx context.Context, path string, reader models.PerformerAutoTagQueryer, ...) ([]*models.Performer, error)
- func PathToScenesFn(ctx context.Context, name string, paths []string, ...) error
- func PathToStudio(ctx context.Context, path string, reader models.StudioAutoTagQueryer, ...) (*models.Studio, error)
- func PathToTags(ctx context.Context, path string, reader models.TagAutoTagQueryer, ...) ([]*models.Tag, error)
- func ScrapedGroup(ctx context.Context, qb GroupNamesFinder, storedID *string, name *string) (matchedID *string, err error)
- func ScrapedPerformer(ctx context.Context, qb PerformerFinder, p *models.ScrapedPerformer, ...) error
- func ScrapedStudio(ctx context.Context, qb StudioFinder, s *models.ScrapedStudio, ...) error
- func ScrapedTag(ctx context.Context, qb models.TagQueryer, s *models.ScrapedTag) error
- type Cache
- type GroupNamesFinder
- type PerformerFinder
- type StudioFinder
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func PathToGalleriesFn ¶ added in v0.18.0
func PathToImagesFn ¶ added in v0.18.0
func PathToPerformers ¶
func PathToScenesFn ¶ added in v0.18.0
func PathToStudio ¶ added in v0.12.0
func PathToStudio(ctx context.Context, path string, reader models.StudioAutoTagQueryer, cache *Cache, trimExt bool) (*models.Studio, error)
PathToStudio returns the Studio that matches the given path. Where multiple matching studios are found, the one that matches the latest position in the path is returned.
func PathToTags ¶
func ScrapedGroup ¶ added in v0.27.0
func ScrapedGroup(ctx context.Context, qb GroupNamesFinder, storedID *string, name *string) (matchedID *string, err error)
ScrapedGroup matches the provided movie with the movies in the database and returns the ID field if one is found.
func ScrapedPerformer ¶
func ScrapedPerformer(ctx context.Context, qb PerformerFinder, p *models.ScrapedPerformer, stashBoxEndpoint *string) error
ScrapedPerformer matches the provided performer with the performers in the database and sets the ID field if one is found.
func ScrapedStudio ¶
func ScrapedStudio(ctx context.Context, qb StudioFinder, s *models.ScrapedStudio, stashBoxEndpoint *string) error
ScrapedStudio matches the provided studio with the studios in the database and sets the ID field if one is found.
func ScrapedTag ¶
func ScrapedTag(ctx context.Context, qb models.TagQueryer, s *models.ScrapedTag) error
ScrapedTag matches the provided tag with the tags in the database and sets the ID field if one is found.
Types ¶
type Cache ¶ added in v0.14.0
type Cache struct {
// contains filtered or unexported fields
}
Cache is used to cache queries that should not change across an autotag process.