server

package
v0.0.0-...-3cf6aa3 Latest Latest
Warning

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

Go to latest
Published: May 10, 2022 License: MPL-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrIDNotFound = fmt.Errorf("ID not found")

Functions

func NewHTTPServer

func NewHTTPServer(addr string) *http.Server

Types

type Activities

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

func (*Activities) Insert

func (c *Activities) Insert(activity Activity) uint64

func (*Activities) Retrieve

func (c *Activities) Retrieve(id uint64) (Activity, error)

type Activity

type Activity struct {
	Time        time.Time `json:"time"`
	Description string    `json:"description"`
	ID          uint64    `json:"id"`
}

type ActivityDocument

type ActivityDocument struct {
	Activity Activity `json:"activity"`
}

type IDDocument

type IDDocument struct {
	ID uint64 `json:"id"`
}

Jump to

Keyboard shortcuts

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