obslogapi

package
v0.0.0-...-9714d35 Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2023 License: AGPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Api

type Api struct {
	*ObsLogStore
}

func (*Api) Attached

func (sc *Api) Attached(method string) bool

func (*Api) Create

func (a *Api) Create(w http.ResponseWriter, r *http.Request, _ httprouter.Params)

func (*Api) Delete

func (a *Api) Delete(w http.ResponseWriter, r *http.Request, _ httprouter.Params)

func (*Api) List

func (a *Api) List(w http.ResponseWriter, r *http.Request, _ httprouter.Params)

func (*Api) Read

func (a *Api) Read(w http.ResponseWriter, r *http.Request, _ httprouter.Params)

func (*Api) Replace

func (a *Api) Replace(w http.ResponseWriter, r *http.Request, _ httprouter.Params)

func (*Api) Update

func (a *Api) Update(w http.ResponseWriter, r *http.Request, _ httprouter.Params)

type LogEntry

type LogEntry struct {
	Id        int64
	Source    string
	Facility  string
	User      string
	ScanId    string
	VexId     string
	PostTime  int64
	ApplyTime int64
	Type      string
	Content   string
}

type ObsLogStore

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

func NewObsLogStore

func NewObsLogStore(db *sql.DB, users *userapi.UserCache, messageSourceId string) *ObsLogStore

func (*ObsLogStore) AddLogEntry

func (s *ObsLogStore) AddLogEntry(entry *LogEntry) error

func (*ObsLogStore) GetLogEntriesByVex

func (s *ObsLogStore) GetLogEntriesByVex(vexId, facility string, lastIds map[string]int64) ([]LogEntry, error)

Jump to

Keyboard shortcuts

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