package model

type ServerStatic struct {
	Count int64 `json:"count"`
}

// 声明一个全局变量map
var serverStaticMap = make(map[string]*ServerStatic)

func Incr(key string) {
	if _, ok := serverStaticMap[key]; !ok {
		serverStaticMap[key] = &ServerStatic{
			Count: 0,
		}
	}
	serverStaticMap[key].Count++
}

func GetServerStatic() map[string]*ServerStatic {
	return serverStaticMap
}
