Documentation
¶
Index ¶
- type FileStorage
- func (s *FileStorage) Clear() error
- func (s *FileStorage) Delete(key string) error
- func (s *FileStorage) Exists(key string) bool
- func (s *FileStorage) Get(key string) (any, error)
- func (s *FileStorage) IsEmpty() bool
- func (s *FileStorage) Keys() []string
- func (s *FileStorage) Len() int
- func (s *FileStorage) Restore() error
- func (s *FileStorage) Set(key string, value any) error
- func (s *FileStorage) Store() error
- type LocalStorage
- type MixinFileStorage
- type MultiFileStorage
- type SimpleStorage
- type XFileStorage
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FileStorage ¶
type FileStorage struct {
// contains filtered or unexported fields
}
func NewFileStorage ¶
func NewFileStorage(filePath string) *FileStorage
func (*FileStorage) Clear ¶
func (s *FileStorage) Clear() error
func (*FileStorage) Delete ¶
func (s *FileStorage) Delete(key string) error
func (*FileStorage) Exists ¶
func (s *FileStorage) Exists(key string) bool
func (*FileStorage) IsEmpty ¶
func (s *FileStorage) IsEmpty() bool
func (*FileStorage) Keys ¶
func (s *FileStorage) Keys() []string
func (*FileStorage) Len ¶
func (s *FileStorage) Len() int
func (*FileStorage) Restore ¶
func (s *FileStorage) Restore() error
func (*FileStorage) Store ¶
func (s *FileStorage) Store() error
type LocalStorage ¶
type LocalStorage struct {
}
type MixinFileStorage ¶
type MixinFileStorage struct {
}
MixinFileStorage 小key统一存储到一个默认文件;大于 512 的key,存储到单独的文件中
type MultiFileStorage ¶
type MultiFileStorage struct {
}
type SimpleStorage ¶
type XFileStorage ¶
type XFileStorage struct {
}
Click to show internal directories.
Click to hide internal directories.