结构调整、kcp支持

This commit is contained in:
刘河
2019-02-09 17:07:47 +08:00
parent 2e8af6f120
commit 59d789d253
60 changed files with 11097 additions and 783 deletions

19
lib/file/csv.go Normal file
View File

@@ -0,0 +1,19 @@
package file
import (
"github.com/cnlh/nps/lib/common"
"sync"
)
var (
CsvDb *Csv
once sync.Once
)
//init csv from file
func GetCsvDb() *Csv {
once.Do(func() {
CsvDb = NewCsv(common.GetRunPath())
CsvDb.Init()
})
return CsvDb
}