storage

package
v0.0.0-...-6dc70a1 Latest Latest
Warning

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

Go to latest
Published: Aug 18, 2021 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CodeLinkField = "code"
	URLLinkField  = "url"
)

...

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

Client ...

func NewClient

func NewClient(uri string, database string, collection string) (Client, error)

NewClient ...

func (Client) Collection

func (client Client) Collection() *mongo.Collection

Collection ...

type LinkGetter

type LinkGetter struct {
	Client   Client
	KeyField string
}

LinkGetter ...

func (getter LinkGetter) GetLink(query string) (entities.Link, error)

GetLink ...

type LinkSetter

type LinkSetter struct {
	Client Client
}

LinkSetter ...

func (setter LinkSetter) SetLink(link entities.Link) error

SetLink ...

Jump to

Keyboard shortcuts

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