Documentation
¶
Index ¶
- func Country(s string) func(*ListOpts)
- func Create(ctx context.Context, mg *db.MongoDB, feed *feedsv2.Feed) (*feedsv2.Feed, error)
- func Delete(ctx context.Context, mg *db.MongoDB, feed *feedsv2.Feed) error
- func EnsureIndex(ctx context.Context, dbConn *db.MongoDB) error
- func Get(ctx context.Context, mg *db.MongoDB, optionsList ...func(*ListOpts)) (*feedsv2.Feed, error)
- func GetByHostname(ctx context.Context, mg *db.MongoDB, hostname string) (*feedsv2.Feed, error)
- func GetByUserName(ctx context.Context, mg *db.MongoDB, username string) (*feedsv2.Feed, error)
- func GetFeedsStreamList(ctx context.Context, mg *db.MongoDB, optionsList ...func(*ListOpts)) ([]*feedsv2.Feed, error)
- func Hostname(i string) func(*ListOpts)
- func Id(i string) func(*ListOpts)
- func Lang(s string) func(*ListOpts)
- func Limit(i int) func(*ListOpts)
- func List(ctx context.Context, mg *db.MongoDB, optionsList ...func(*ListOpts)) (*feedsv2.FeedList, error)
- func NewListOpts() []func(*ListOpts)
- func Offset(i int) func(*ListOpts)
- func Q(i string) func(*ListOpts)
- func SortKey(i string) func(*ListOpts)
- func SortOrder(s int) func(*ListOpts)
- func StreamStatus(s int) func(*ListOpts)
- func StreamType(s int) func(*ListOpts)
- func Update(ctx context.Context, mg *db.MongoDB, feed *feedsv2.Feed) error
- func UserName(i string) func(*ListOpts)
- type ListOpts
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EnsureIndex ¶
EnsureIndex in mongodb.
func Get ¶
func Get(ctx context.Context, mg *db.MongoDB, optionsList ...func(*ListOpts)) (*feedsv2.Feed, error)
Get returns a single feed by feed query.
func GetByHostname ¶
GetByHostname returns a feed with a specific hostname.
func GetByUserName ¶
GetByUserName returns a feed with a specific user_name.
func GetFeedsStreamList ¶
func GetFeedsStreamList(ctx context.Context, mg *db.MongoDB, optionsList ...func(*ListOpts)) ([]*feedsv2.Feed, error)
GetFeedsStreamList returns a list of all active streams by feed query.
func List ¶
func List(ctx context.Context, mg *db.MongoDB, optionsList ...func(*ListOpts)) (*feedsv2.FeedList, error)
List returns a list of feeds by feed query.
func NewListOpts ¶
func NewListOpts() []func(*ListOpts)
func StreamStatus ¶
func StreamType ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.