mstlystcdata

package
v0.9.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 24, 2024 License: Apache-2.0 Imports: 33 Imported by: 0

Documentation

Index

Constants

View Source
const (
	NotAvailablePlaceholder = "N/A"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Cache

type Cache struct {
	// contains filtered or unexported fields
}

func NewCache

func NewCache(p Params) (*Cache, error)

func (*Cache) GetHighestJobGrade

func (c *Cache) GetHighestJobGrade(job string) *users.JobGrade

func (*Cache) GetLawBooks

func (c *Cache) GetLawBooks() []*laws.LawBook

func (*Cache) GetSearcher

func (c *Cache) GetSearcher() *Searcher

func (*Cache) RefreshLaws

func (c *Cache) RefreshLaws(ctx context.Context, lawBookId uint64) error

type Enricher

type Enricher struct {
	// contains filtered or unexported fields
}

func NewEnricher

func NewEnricher(cache *Cache, appCfg appconfig.IConfig) *Enricher

func (*Enricher) EnrichCategory

func (e *Enricher) EnrichCategory(doc common.ICategory)

func (*Enricher) EnrichJobInfo

func (e *Enricher) EnrichJobInfo(usr common.IJobInfo)

func (*Enricher) EnrichJobName

func (e *Enricher) EnrichJobName(usr common.IJobName)

func (*Enricher) GetJobByName

func (e *Enricher) GetJobByName(job string) *users.Job

func (*Enricher) GetJobGrade

func (e *Enricher) GetJobGrade(job string, grade int32) (*users.Job, *users.JobGrade)

type Params

type Params struct {
	fx.In

	LC fx.Lifecycle

	Logger *zap.Logger
	TP     *tracesdk.TracerProvider
	DB     *sql.DB
	JS     *events.JSWrapper
	Config *config.Config

	Cron         croner.ICron
	CronHandlers *croner.Handlers
}

type Searcher

type Searcher struct {
	// contains filtered or unexported fields
}

func NewSearcher

func NewSearcher(cache *Cache) (*Searcher, error)

func (*Searcher) SearchJobs

func (s *Searcher) SearchJobs(ctx context.Context, search string, exactMatch bool) ([]*users.Job, error)

type UserAwareEnricher

type UserAwareEnricher struct {
	*Enricher
	// contains filtered or unexported fields
}

func NewUserAwareEnricher

func NewUserAwareEnricher(enricher *Enricher, ps perms.Permissions) *UserAwareEnricher

func (*UserAwareEnricher) EnrichJobInfoSafe

func (e *UserAwareEnricher) EnrichJobInfoSafe(userInfo *userinfo.UserInfo, usrs ...common.IJobInfo)

func (*UserAwareEnricher) EnrichJobInfoSafeFunc

func (e *UserAwareEnricher) EnrichJobInfoSafeFunc(userInfo *userinfo.UserInfo) func(usr common.IJobInfo)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL