cache

package
v0.0.0-...-686d10b Latest Latest
Warning

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

Go to latest
Published: Aug 24, 2020 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InitCache

func InitCache()

InitCache 仅用于测试

Types

type Adapter

type Adapter interface {
	// contains filtered or unexported methods
}

Adapter ...

type SchemaCache

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

SchemaCache ...

func NewSchemaCache

func NewSchemaCache(ttl int, singleCache bool) *SchemaCache

NewSchemaCache ... singleCache 默认为 false

func (*SchemaCache) Clear

func (s *SchemaCache) Clear()

Clear ...

func (*SchemaCache) GetAllClasses

func (s *SchemaCache) GetAllClasses() []types.M

GetAllClasses ...

func (*SchemaCache) GetOneSchema

func (s *SchemaCache) GetOneSchema(className string) types.M

GetOneSchema ...

func (*SchemaCache) Put

func (s *SchemaCache) Put(key string, value interface{})

Put ...

func (*SchemaCache) SetAllClasses

func (s *SchemaCache) SetAllClasses(schema []types.M)

SetAllClasses ...

func (*SchemaCache) SetOneSchema

func (s *SchemaCache) SetOneSchema(className string, schema types.M)

SetOneSchema ...

type SubCache

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

SubCache ...

var Role *SubCache

Role ...

var User *SubCache

User ...

func (*SubCache) Clear

func (c *SubCache) Clear()

Clear ...

func (*SubCache) Del

func (c *SubCache) Del(key string)

Del ...

func (*SubCache) Get

func (c *SubCache) Get(key string) interface{}

Get ...

func (*SubCache) Put

func (c *SubCache) Put(key string, value interface{}, ttl int64)

Put ...

Jump to

Keyboard shortcuts

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