memory

package
v1.1.5 Latest Latest
Warning

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

Go to latest
Published: Oct 18, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Memory

type Memory struct {
	sync.RWMutex

	DB *memdb.MemDB
	// contains filtered or unexported fields
}

Memory - Structure for in memory db

func New

func New(schema *memdb.DBSchema) (*Memory, error)

New - Creates new database schema in memory

func (*Memory) AttributeID added in v1.0.2

func (m *Memory) AttributeID() (id uint64)

func (*Memory) Close

func (m *Memory) Close() error

Close - Closing the in memory instance

func (*Memory) GetEngineType

func (m *Memory) GetEngineType() string

GetEngineType - Gets engine type, returns as string

func (*Memory) IsReady

func (m *Memory) IsReady(_ context.Context) (bool, error)

IsReady - Check if database is ready

func (*Memory) RelationTupleID added in v1.0.2

func (m *Memory) RelationTupleID() (id uint64)

type MockIMDatabase added in v0.3.8

type MockIMDatabase struct {
	mock.Mock
}

MockIMDatabase simulates the behavior of a real IMDatabase.

func (*MockIMDatabase) Close added in v0.3.8

func (m *MockIMDatabase) Close() error

func (*MockIMDatabase) GetEngineType added in v0.3.8

func (m *MockIMDatabase) GetEngineType() string

func (*MockIMDatabase) IsReady added in v0.3.8

func (m *MockIMDatabase) IsReady(ctx context.Context) (bool, error)

Jump to

Keyboard shortcuts

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