repo

package
v0.0.0-...-0257ec7 Latest Latest
Warning

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

Go to latest
Published: Feb 17, 2021 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MongoRepo

type MongoRepo struct {
	mongo.Client
}

MongoRepo implementation

func CreateMongoClient

func CreateMongoClient(host string) (*MongoRepo, error)

CreateMongoClient - MongoRepo factory

func (*MongoRepo) AddRecord

func (r *MongoRepo) AddRecord(result *types.FuncResult) error

AddRecord does what it says

func (*MongoRepo) GetRecords

func (r *MongoRepo) GetRecords(name string, count int64) ([]*types.FuncResult, error)

GetRecords fetches last N records by name

type Results

type Results interface {
	AddRecord(result *types.FuncResult) error
	GetRecords(name string, count int64) ([]*types.FuncResult, error)
}

Results repository

Jump to

Keyboard shortcuts

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