Documentation
¶
Index ¶
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
}
FileStorage 文件日志存储实现
func NewFileStorage ¶
func NewFileStorage(filePath string) (*FileStorage, error)
NewFileStorage 创建新的文件存储实例
type KeyRecord ¶
type KeyRecord struct {
ID uint `gorm:"primaryKey"`
CreatedAt time.Time `gorm:"autoCreateTime;index"`
KeyCode int `gorm:"index"`
KeyName string `gorm:"index;size:50"`
IsDown bool
ModifierFlags int
}
KeyRecord 数据库记录模型
type SQLiteStorage ¶
type SQLiteStorage struct {
// contains filtered or unexported fields
}
SQLiteStorage SQLite存储实现
func NewSQLiteStorage ¶
func NewSQLiteStorage(dbPath string) (*SQLiteStorage, error)
NewSQLiteStorage 创建新的SQLite存储实例
func (*SQLiteStorage) Save ¶
func (s *SQLiteStorage) Save(event KeyEvent) error
Save 保存键盘事件到数据库(只保存按下事件)
Click to show internal directories.
Click to hide internal directories.