Documentation
¶
Index ¶
- type Server
- type UserStat
- type UserStats
- func (us *UserStats) GetRecentUsers(excludeUser string, limit int) []*UserStat
- func (us *UserStats) GetUserStat(username string) (*UserStat, bool)
- func (us *UserStats) IsFirstTime(username string) bool
- func (us *UserStats) Load() error
- func (us *UserStats) RecordConnection(username string)
- func (us *UserStats) Save() error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server represents the SSH hypervisor server
type UserStat ¶
type UserStat struct { Username string `json:"username"` ConnectCount int `json:"connect_count"` LastConnected time.Time `json:"last_connected"` }
UserStat represents connection statistics for a single user
type UserStats ¶
type UserStats struct {
// contains filtered or unexported fields
}
UserStats manages user connection statistics
func NewUserStats ¶
NewUserStats creates a new UserStats manager
func (*UserStats) GetRecentUsers ¶
GetRecentUsers returns the most recent users (excluding the current user)
func (*UserStats) GetUserStat ¶
GetUserStat returns statistics for a specific user
func (*UserStats) IsFirstTime ¶
IsFirstTime returns true if this is the user's first connection
func (*UserStats) RecordConnection ¶
RecordConnection records a user connection
Click to show internal directories.
Click to hide internal directories.