store

package
v0.0.25 Latest Latest
Warning

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

Go to latest
Published: Nov 5, 2019 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package store contains everything storage related for MVDS.

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrMessageNotFound = errors.New("message not found")
)

Functions

func NewMemoryMessageStore added in v0.0.25

func NewMemoryMessageStore() *memoryMessageStore

func NewPersistentMessageStore added in v0.0.21

func NewPersistentMessageStore(db *sql.DB) *persistentMessageStore

Types

type MessageStore

type MessageStore interface {
	Has(id state.MessageID) (bool, error)
	Get(id state.MessageID) (*protobuf.Message, error)
	Add(message *protobuf.Message) error
	GetMessagesWithoutChildren(id state.GroupID) ([]state.MessageID, error)
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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