storage

package
v0.0.0-...-080725f Latest Latest
Warning

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

Go to latest
Published: Sep 6, 2023 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Endpoint

type Endpoint struct {
	ID        string `gorm:"primaryKey"`
	Path      string
	Payload   string
	CreatedAt time.Time
	UpdatedAt *time.Time
}

type Manager

type Manager interface {
	Create(path string) (Endpoint, error)
	List() ([]Endpoint, error)
	Update(endpoint Endpoint) error
	Delete(endpoint Endpoint) error
}

func NewManager

func NewManager(appDirectory string, client fieldglass.FieldGlass) Manager

type ManagerImpl

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

func (*ManagerImpl) Create

func (m *ManagerImpl) Create(path string) (Endpoint, error)

func (ManagerImpl) Delete

func (e ManagerImpl) Delete(endpoint Endpoint) error

func (ManagerImpl) List

func (e ManagerImpl) List() ([]Endpoint, error)

func (ManagerImpl) Store

func (e ManagerImpl) Store(path, payload string) (Endpoint, error)

func (*ManagerImpl) Update

func (m *ManagerImpl) Update(endpoint Endpoint) error

Jump to

Keyboard shortcuts

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