bizyesod

package
v0.2.9 Latest Latest
Warning

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

Go to latest
Published: Mar 16, 2024 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Yesod

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

func NewYesod

func NewYesod(
	repo YesodRepo,
	supv *supervisor.Supervisor,
	cron *libcron.Cron,

	sClient *client.Searcher,
	pullFeed *libmq.Topic[modelyesod.PullFeed],
) (*Yesod, error)

func (*Yesod) CreateFeedConfig

func (y *Yesod) CreateFeedConfig(ctx context.Context, config *modelyesod.FeedConfig) (model.InternalID, *errors.Error)

func (*Yesod) GetFeedItem added in v0.0.8

func (y *Yesod) GetFeedItem(ctx context.Context, id model.InternalID) (*modelfeed.Item, *errors.Error)

func (*Yesod) GetFeedItems added in v0.0.8

func (y *Yesod) GetFeedItems(ctx context.Context, ids []model.InternalID) ([]*modelfeed.Item, *errors.Error)

func (*Yesod) GroupFeedItems added in v0.0.9

func (y *Yesod) GroupFeedItems(
	ctx context.Context,
	groupBy modelyesod.GroupFeedItemsBy,
	feedIDs []model.InternalID,
	authorIDs []model.InternalID,
	platforms []string,
	timeRange *model.TimeRange,
	groupSize int,
	categories []string,
) (map[model.TimeRange][]*modelyesod.FeedItemDigest, *errors.Error)

func (*Yesod) ListFeedCategories added in v0.1.15

func (y *Yesod) ListFeedCategories(ctx context.Context) ([]string, *errors.Error)

func (*Yesod) ListFeedItems added in v0.0.8

func (y *Yesod) ListFeedItems(
	ctx context.Context,
	paging model.Paging,
	feedIDs []model.InternalID,
	authorIDs []model.InternalID,
	platforms []string,
	timeRange *model.TimeRange,
	categories []string,
) ([]*modelyesod.FeedItemDigest, int, *errors.Error)

func (*Yesod) ListFeedPlatforms added in v0.1.15

func (y *Yesod) ListFeedPlatforms(ctx context.Context) ([]string, *errors.Error)

func (*Yesod) ListFeeds added in v0.0.8

func (y *Yesod) ListFeeds(
	ctx context.Context,
	paging model.Paging,
	ids []model.InternalID,
	authorIDs []model.InternalID,
	sources []string,
	statuses []modelyesod.FeedConfigStatus,
	categories []string,
) ([]*modelyesod.FeedWithConfig, int, *errors.Error)

func (*Yesod) PullFeeds

func (y *Yesod) PullFeeds(ctx context.Context) error

func (*Yesod) ReadFeedItem added in v0.1.15

func (y *Yesod) ReadFeedItem(ctx context.Context, id model.InternalID) *errors.Error

func (*Yesod) UpdateFeedConfig

func (y *Yesod) UpdateFeedConfig(ctx context.Context, config *modelyesod.FeedConfig) *errors.Error

Jump to

Keyboard shortcuts

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