Documentation
¶
Overview ¶
Package for_sqlite stores types in categories package in a sqlite database.
Index ¶
- type Cache
- func (c *Cache) AccountAdd(t db.Transaction, name string) (cds categories.CatDetailStore, newId int64, err error)
- func (c *Cache) AccountRemove(t db.Transaction, id int64) (cds categories.CatDetailStore, err error)
- func (c *Cache) AccountRename(t db.Transaction, id int64, name string) (cds categories.CatDetailStore, err error)
- func (c *Cache) Add(t db.Transaction, name string) (cds categories.CatDetailStore, newId fin.Cat, err error)
- func (c *Cache) Get(t db.Transaction) (cds categories.CatDetailStore, err error)
- func (c *Cache) Invalidate(t db.Transaction) error
- func (c *Cache) Purge(t db.Transaction, cats fin.CatSet) error
- func (c *Cache) Remove(t db.Transaction, id fin.Cat) (cds categories.CatDetailStore, err error)
- func (c *Cache) Rename(t db.Transaction, id fin.Cat, newName string) (cds categories.CatDetailStore, err error)
- type ReadOnlyCache
- func (c ReadOnlyCache) AccountAdd(t db.Transaction, name string) (cds categories.CatDetailStore, newId int64, err error)
- func (c ReadOnlyCache) AccountRemove(t db.Transaction, id int64) (cds categories.CatDetailStore, err error)
- func (c ReadOnlyCache) AccountRename(t db.Transaction, id int64, name string) (cds categories.CatDetailStore, err error)
- func (c ReadOnlyCache) Add(t db.Transaction, name string) (cds categories.CatDetailStore, newId fin.Cat, err error)
- func (c ReadOnlyCache) Get(t db.Transaction) (cds categories.CatDetailStore, err error)
- func (c ReadOnlyCache) Remove(t db.Transaction, id fin.Cat) (cds categories.CatDetailStore, err error)
- func (c ReadOnlyCache) Rename(t db.Transaction, id fin.Cat, newName string) (cds categories.CatDetailStore, err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Cache ¶
type Cache struct {
// contains filtered or unexported fields
}
func New ¶
func New(db *sqlite3_db.Db) *Cache
func (*Cache) AccountAdd ¶
func (c *Cache) AccountAdd(t db.Transaction, name string) ( cds categories.CatDetailStore, newId int64, err error)
func (*Cache) AccountRemove ¶
func (c *Cache) AccountRemove(t db.Transaction, id int64) ( cds categories.CatDetailStore, err error)
func (*Cache) AccountRename ¶
func (c *Cache) AccountRename(t db.Transaction, id int64, name string) ( cds categories.CatDetailStore, err error)
func (*Cache) Add ¶
func (c *Cache) Add(t db.Transaction, name string) ( cds categories.CatDetailStore, newId fin.Cat, err error)
func (*Cache) Get ¶
func (c *Cache) Get(t db.Transaction) ( cds categories.CatDetailStore, err error)
func (*Cache) Invalidate ¶
func (c *Cache) Invalidate(t db.Transaction) error
func (*Cache) Remove ¶
func (c *Cache) Remove(t db.Transaction, id fin.Cat) ( cds categories.CatDetailStore, err error)
func (*Cache) Rename ¶
func (c *Cache) Rename(t db.Transaction, id fin.Cat, newName string) ( cds categories.CatDetailStore, err error)
type ReadOnlyCache ¶
type ReadOnlyCache struct { categoriesdb.NoPermissionCache // contains filtered or unexported fields }
The writing methods of ReadOnlyCache merely return categoriesdb.NoPermission error along with the contents of the cache. If nothing is in the cache, they read from the database.
func ReadOnlyWrapper ¶
func ReadOnlyWrapper(c *Cache) ReadOnlyCache
func (ReadOnlyCache) AccountAdd ¶
func (c ReadOnlyCache) AccountAdd(t db.Transaction, name string) ( cds categories.CatDetailStore, newId int64, err error)
func (ReadOnlyCache) AccountRemove ¶
func (c ReadOnlyCache) AccountRemove(t db.Transaction, id int64) ( cds categories.CatDetailStore, err error)
func (ReadOnlyCache) AccountRename ¶
func (c ReadOnlyCache) AccountRename(t db.Transaction, id int64, name string) ( cds categories.CatDetailStore, err error)
func (ReadOnlyCache) Add ¶
func (c ReadOnlyCache) Add(t db.Transaction, name string) ( cds categories.CatDetailStore, newId fin.Cat, err error)
func (ReadOnlyCache) Get ¶
func (c ReadOnlyCache) Get(t db.Transaction) ( cds categories.CatDetailStore, err error)
func (ReadOnlyCache) Remove ¶
func (c ReadOnlyCache) Remove(t db.Transaction, id fin.Cat) ( cds categories.CatDetailStore, err error)
func (ReadOnlyCache) Rename ¶
func (c ReadOnlyCache) Rename( t db.Transaction, id fin.Cat, newName string) ( cds categories.CatDetailStore, err error)
Click to show internal directories.
Click to hide internal directories.