qbtrade/pkg/types/json.go

15 lines
319 B
Go
Raw Normal View History

2024-06-27 14:42:38 +00:00
package types
type JsonStruct struct {
Key string
Json string
Type string
Value interface{}
}
type JsonArr []JsonStruct
func (a JsonArr) Len() int { return len(a) }
func (a JsonArr) Less(i, j int) bool { return a[i].Key < a[j].Key }
func (a JsonArr) Swap(i, j int) { a[i], a[j] = a[j], a[i] }