Files
go-nkode/core/model/keypad_size.go
2024-08-23 10:18:39 -05:00

20 lines
351 B
Go

package model
type KeypadSize struct {
AttrsPerKey int `json:"attrs_per_key"`
NumbOfKeys int `json:"numb_of_keys"`
}
func (kp *KeypadSize) TotalAttrs() int {
return kp.AttrsPerKey * kp.NumbOfKeys
}
func (kp *KeypadSize) IsDispersable() bool {
return kp.AttrsPerKey <= kp.NumbOfKeys
}
type EncipheredNKode struct {
Code string
Mask string
}