result

package
v0.6.0-3 Latest Latest
Warning

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

Go to latest
Published: Jun 2, 2022 License: BSD-3-Clause Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetResultService

func GetResultService(s *models.Spider, opts ...Option) (svc interfaces.ResultService, err error)

func GetResultServiceRegistry

func GetResultServiceRegistry() (r interfaces.ResultServiceRegistry)

func NewResultService

func NewResultService(registryKey string, s *models.Spider) (svc2 interfaces.ResultService, err error)

func NewResultServiceMongo

func NewResultServiceMongo(colId primitive.ObjectID, _ primitive.ObjectID) (svc2 interfaces.ResultService, err error)

func NewResultServiceRegistry

func NewResultServiceRegistry() (r interfaces.ResultServiceRegistry)

Types

type Option

type Option func(opts *Options)

func WithRegistryKey

func WithRegistryKey(key string) Option

type Options

type Options struct {
	SpiderId primitive.ObjectID // data source id
	// contains filtered or unexported fields
}

type ServiceMongo

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

func (*ServiceMongo) Count

func (svc *ServiceMongo) Count(query generic.ListQuery) (n int, err error)

func (*ServiceMongo) Insert

func (svc *ServiceMongo) Insert(docs ...interface{}) (err error)

func (*ServiceMongo) List

func (svc *ServiceMongo) List(query generic.ListQuery, opts *generic.ListOptions) (results []interface{}, err error)

type ServiceRegistry

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

func (*ServiceRegistry) Get

func (*ServiceRegistry) Register

func (*ServiceRegistry) Unregister

func (r *ServiceRegistry) Unregister(key string)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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