services

package
v0.0.0-...-e8836e2 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2020 License: GPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ApiLength = 5
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Count

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

func NewCount

func NewCount(sql *sql.DB) Count

func (Count) Add

func (c Count) Add(link models.Link) error

func (Count) GetCount

func (c Count) GetCount(link models.Link) (int, error)
type Link struct {
	// contains filtered or unexported fields
}
func NewLink(sql *sql.DB) Link

func (Link) Add

func (l Link) Add(link models.Link) (models.Link, error)
func (l Link) AddCountToLink(link models.Link)

func (Link) Delete

func (l Link) Delete(link models.Link) error

func (Link) GetAllFromUser

func (l Link) GetAllFromUser(user models.UserInfo) ([]models.Link, error)

func (Link) GetByApiPoint

func (l Link) GetByApiPoint(link models.Link) (models.Link, error)

func (Link) GetById

func (l Link) GetById(link models.Link) (models.Link, error)

type User

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

func NewUser

func NewUser(sql *sql.DB) User

func (User) Add

func (u User) Add(conn models.UserConn) (models.UserInfo, error)

func (User) Connection

func (u User) Connection(user models.UserConn) (models.UserInfo, bool, error)

func (User) GetById

func (u User) GetById(user models.UserInfo) (models.UserInfo, error)

func (User) IsUserExist

func (u User) IsUserExist(user models.UserInfo) bool

Jump to

Keyboard shortcuts

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