mirror of
https://git.sr.ht/~ashkeel/strimertul
synced 2024-09-30 02:40:33 +00:00
26 lines
412 B
Go
26 lines
412 B
Go
package interfaces
|
|
|
|
import "reflect"
|
|
|
|
type Enum struct {
|
|
Values []any
|
|
}
|
|
|
|
type KeyDef struct {
|
|
Description string
|
|
Type reflect.Type
|
|
Tags []KeyTag
|
|
}
|
|
|
|
type (
|
|
EnumMap map[string]Enum // Go type-system is too prehistorical to support what I need here
|
|
KeyMap map[string]KeyDef
|
|
)
|
|
|
|
type KeyTag string
|
|
|
|
const (
|
|
TagEvent KeyTag = "event"
|
|
TagRPC KeyTag = "rpc"
|
|
TagHistory KeyTag = "history"
|
|
)
|