Help us shape the future of Go! Take the 2026 Go Developer Survey

author

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Nov 2, 2025 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Author

type Author struct {
	Id        string
	Name      *string
	ColorId   int
	PadIDs    map[string]struct{}
	Timestamp int64
}

type Manager

type Manager struct {
	Db db.DataStore
}

func NewManager

func NewManager() Manager

func (*Manager) AddPad

func (m *Manager) AddPad(authorId string, padId string)

func (*Manager) CreateAuthor

func (m *Manager) CreateAuthor(name *string) Author

func (*Manager) GetAuthor

func (m *Manager) GetAuthor(authorId string) (*Author, error)

func (*Manager) GetAuthor4Token

func (m *Manager) GetAuthor4Token(token string) *Author

func (*Manager) GetAuthorId

func (m *Manager) GetAuthorId(token string) *Author

func (*Manager) GetAuthorName

func (m *Manager) GetAuthorName(authorId string) string

*

  • Returns the name of the author
  • @param {String} author The id of the author

func (*Manager) ListPadsOfAuthor

func (m *Manager) ListPadsOfAuthor(authorId string) ([]string, error)

*

  • Returns an array of all pads this author contributed to
  • @param {String} authorID The id of the author

func (*Manager) SetAuthorColor

func (m *Manager) SetAuthorColor(author string, colorId int)

func (*Manager) SetAuthorName

func (m *Manager) SetAuthorName(authorId string, authorName string)

Jump to

Keyboard shortcuts

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