v0.1.6 Latest Latest

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

Go to latest
Published: Jul 30, 2018 License: Apache-2.0 Imports: 15 Imported by: 0




This section is empty.


This section is empty.


func Exists

func Exists(typeName string, entityID common.EntityID, callback ExistsCallbackFunc)

Exists checks if entity of specified ID exists in storage

func Initialize

func Initialize()

Initialize is called by engine to initialize storage module

func ListEntityIDs

func ListEntityIDs(typeName string, callback ListCallbackFunc)

ListEntityIDs returns all entity IDs in storage

Return values can be large for common entity types

func Load

func Load(typeName string, entityID common.EntityID, callback LoadCallbackFunc)

Load loads entity data from storage

func Save

func Save(typeName string, entityID common.EntityID, data interface{}, callback SaveCallbackFunc)

Save saves entity data to storage

func Shutdown

func Shutdown()

Shutdown storage module


type ExistsCallbackFunc

type ExistsCallbackFunc func(exists bool, err error)

ExistsCallbackFunc is the callback type of storage Exists

type ListCallbackFunc

type ListCallbackFunc func([]common.EntityID, error)

ListCallbackFunc is the callback type of storage List

type LoadCallbackFunc

type LoadCallbackFunc func(data interface{}, err error)

LoadCallbackFunc is the callback type of storage Load

type SaveCallbackFunc

type SaveCallbackFunc func()

SaveCallbackFunc is the callback type of storage Save


Path Synopsis

Jump to

Keyboard shortcuts

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