2020-02-13 22:55:19 +00:00
|
|
|
// Code generated for package data by go-bindata DO NOT EDIT. (@generated)
|
|
|
|
// sources:
|
|
|
|
// data/data.json
|
|
|
|
package data
|
|
|
|
|
|
|
|
import (
|
|
|
|
"bytes"
|
|
|
|
"compress/gzip"
|
|
|
|
"fmt"
|
|
|
|
"io"
|
|
|
|
"io/ioutil"
|
|
|
|
"os"
|
|
|
|
"path/filepath"
|
|
|
|
"strings"
|
|
|
|
"time"
|
|
|
|
)
|
|
|
|
|
|
|
|
func bindataRead(data []byte, name string) ([]byte, error) {
|
|
|
|
gz, err := gzip.NewReader(bytes.NewBuffer(data))
|
|
|
|
if err != nil {
|
|
|
|
return nil, fmt.Errorf("Read %q: %v", name, err)
|
|
|
|
}
|
|
|
|
|
|
|
|
var buf bytes.Buffer
|
|
|
|
_, err = io.Copy(&buf, gz)
|
|
|
|
clErr := gz.Close()
|
|
|
|
|
|
|
|
if err != nil {
|
|
|
|
return nil, fmt.Errorf("Read %q: %v", name, err)
|
|
|
|
}
|
|
|
|
if clErr != nil {
|
|
|
|
return nil, err
|
|
|
|
}
|
|
|
|
|
|
|
|
return buf.Bytes(), nil
|
|
|
|
}
|
|
|
|
|
|
|
|
type asset struct {
|
|
|
|
bytes []byte
|
|
|
|
info os.FileInfo
|
|
|
|
}
|
|
|
|
|
|
|
|
type bindataFileInfo struct {
|
|
|
|
name string
|
|
|
|
size int64
|
|
|
|
mode os.FileMode
|
|
|
|
modTime time.Time
|
|
|
|
}
|
|
|
|
|
|
|
|
// Name return file name
|
|
|
|
func (fi bindataFileInfo) Name() string {
|
|
|
|
return fi.name
|
|
|
|
}
|
|
|
|
|
|
|
|
// Size return file size
|
|
|
|
func (fi bindataFileInfo) Size() int64 {
|
|
|
|
return fi.size
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mode return file mode
|
|
|
|
func (fi bindataFileInfo) Mode() os.FileMode {
|
|
|
|
return fi.mode
|
|
|
|
}
|
|
|
|
|
|
|
|
// Mode return file modify time
|
|
|
|
func (fi bindataFileInfo) ModTime() time.Time {
|
|
|
|
return fi.modTime
|
|
|
|
}
|
|
|
|
|
|
|
|
// IsDir return file whether a directory
|
|
|
|
func (fi bindataFileInfo) IsDir() bool {
|
|
|
|
return fi.mode&os.ModeDir != 0
|
|
|
|
}
|
|
|
|
|
|
|
|
// Sys return file is sys mode
|
|
|
|
func (fi bindataFileInfo) Sys() interface{} {
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
2022-03-17 19:07:10 +00:00
|
|
|
var _dataDataJson = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\xbd\xeb\x52\xe4\x48\x9a\x2d\xfa\xbf\x9f\xc2\x8d\x1c\xb3\xde\xd3\x27\x15\x10\x01\x11\x5c\xc6\xe6\x07\x09\x64\x26\x56\x99\xc0\x06\x2a\x6b\xda\x9a\x39\xb4\x90\x9c\x40\x83\x42\xae\x92\x14\x64\x52\xd9\xb5\xed\xbc\xc6\x79\xbd\xf3\x24\xc7\xdc\x5d\x77\xb9\x14\x92\xe2\x42\x5c\x16\x63\x36\x5d\x19\xf2\xfb\xe5\x5b\xcb\x3f\x77\x5f\xfe\xf3\x2f\x64\xeb\x97\x03\xff\x1b\xf5\x7c\x8b\x39\x37\xd4\x7b\xb1\x0c\x7a\xe9\x06\x16\x73\xfc\xad\x23\xf2\xf3\x2f\x84\x6c\xbd\x74\x3b\xdd\x9d\xf0\x1f\x64\x8b\x06\x86\xb9\x75\x44\x9c\xb1\x6d\xbf\x17\x3f\x3c\x8f\x1f\xa8\xee\x5a\x51\x00\xb2\xa5\xdb\x36\xfb\xae\xb9\x9e\xf5\x62\xd9\x74\x48\x79\xe8\xad\xc0\x1b\xd3\xad\xf7\xe1\x77\x87\x39\xaf\x23\x36\xf6\x35\x7d\x1c\x3c\xf1\xaf\x8f\xba\xed\xc7\x9f\x1f\x2c\xc7\xd4\x74\xd3\xf4\xa8\xcf\x8b\xb0\xb5\xd3\x11\xff\x17\x7d\xa6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\x5f\xba\x0f\x34\xd0\xbb\xff\x99\x1e\x6e\xb9\xe6\x1d\xec\xed\xed\x26\x9f\xc4\x80\xd0\x74\x39\x22\x34\x9b\xb1\xe7\xb1\x9b\x1f\xaf\xbe\x1c\x20\xda\x83\x6e\x3c\x53\x47\x0c\x67\x3e\x09\xe2\x54\x02\xdb\xd7\x0c\xcb\x7d\xa2\x9e\xe6\x8f\xad\x40\xf6\xcc\xed\x97\x9b\xfb\xb3\x93\xd3\xcf\x67\xfc\xff\xdf\x1c\xdf\xff\x76\x7e\xfb\xf9\xfe\xf8\xec\xe6\xbe\xdb\x3b\xb8\xff\x74\xf2\xf5\xfe\xe6\xf3\x71\xaf\x3f\x78\x5f\x1a\xae\xd7\x1f\x44\xe1\x76\x0f\xf6\xd4\xe1\x4e\x3e\x1f\x9f\x7c\x3e\xee\xed\xdc\x5f\x5d\x7e\xf9\x7b\x77\x77\xa7\x9f\x0a\x76\x5d\x2b\xd3\xeb\x5a\x59\x5e\x97\x66\xb8\xc5\x9b\xe0\xcf\xc4\x10\xd8\x34\x48\x19\x82\xd2\x49\x3c\xa5\x89\xe0\x3f\x52\x27\xb0\x0c\xd1\xf9\x5a\xc0\x9e\xa9\xa3\x7d\x97\xb3\xae\x90\x54\x7a\x9c\x68\x23\x66\x52\x1e\x22\x9c\xa2\x51\x20\x43\x8c\x5e\x5f\x73\xa9\xa7\xfd\xce\x64\x07\xa6\xd2\x30\x1c\x4b\x7b\xb0\x1c\xcd\xb4\x3c\xfe\x69\x9b\xb9\xc1\xb6\xe1\x58\xdb\x0f\x96\x93\x0e\xc2\x07\x67\x1c\x86\x06\x86\x08\xe3\xd0\xa0\x63\x26\xc6\xeb\x91\x79\x06\xd5\x1c\x66\x52\x8d\x37\x82\xa1\x07\xdc\x9c\xf1\x18\x71\x98\x17\xea\x04\xda\xef\xae\x9f\x31\x06\x23\xfd\x99\x6a\x96\x2b\x42\xfb\xda\x38\xb0\x6c\xcd\x78\xd2\x43\xbb\x97\xae\xaf\x43\x83\xef\xcc\x7b\x0e\xcd\x22\xff\x6a\x38\x56\x32\xfb\x74\x53\x63\x8e\xfd\x5a\xb4\x36\x1e\xf5\x99\xfd\x22\xea\x10\x97\x5f\xfe\xd6\x11\xbf\xc5\x93\xc1\xa3\xfa\xc8\x72\x86\x3c\xa4\x43\x85\x29\xd3\x2c\xd3\xa6\x1a\x9f\x9f\x6c\x2c\x12\xdd\xdd\x19\x61\x72\xec\xf4\xa3\x36\x78\xe1\x75\xee\xc5\xff\x62\xf6\x78\x44\xc3\xfe\x89\x87\xcb\x8b\xee\x6d\xdb\xd6\xc3\x76\x38\x89\xb6\x65\xa8\x08\xdb\x72\xb3\xcc\xf5\xd8\x8f\xd7\x64\x9e\x3d\x51\xdd\x0e\x9e\xfe\xd0\xf2\xc8\xd9\xed\xed\x8b\x69\xd7\xcd\x15\x24\x97\xda\x09\x73\x02\x8f\xd9\x36\xf5\xea\x4e\x5d\x43\x0f\xc2\x31\x6c\x58\xa6\x57\x18\x82\x72\x76\x8f\x9d\x40\x1f\x0e\xa9\xa9\x19\x36\x1b\x17\x66\xb8\x34\xe4\xdc\x30\x8b\xcf\x9a\xc7\xc6\xe1\xe0\xc8\xcc\xf4\x10\xed\x9f\x98\x1f\xb8\x7a\xf0\xa4\xb9\x1e\x7b\xb1\x38\xc6\x8a\xc2\x66\xc3\xda\x21\x8a\xd9\xd4\x08\x0a\xb3\x82\x17\x76\xc4\x1c\x2b\x60\x1c\xaa\x74\x83\xf2\xb9\x6e\x31\x51\xae\xbd\x1d\x3f\x86\x4a\x66\x6a\xf4\x45\x22\x74\x7a\x44\xf7\x47\xa9\x30\xa5\x70\x1a\x50\x6f\x64\x39\x7a\x40\x4
|
2020-02-13 22:55:19 +00:00
|
|
|
|
|
|
|
func dataDataJsonBytes() ([]byte, error) {
|
|
|
|
return bindataRead(
|
|
|
|
_dataDataJson,
|
|
|
|
"data/data.json",
|
|
|
|
)
|
|
|
|
}
|
|
|
|
|
|
|
|
func dataDataJson() (*asset, error) {
|
|
|
|
bytes, err := dataDataJsonBytes()
|
|
|
|
if err != nil {
|
|
|
|
return nil, err
|
|
|
|
}
|
|
|
|
|
2022-03-17 19:07:10 +00:00
|
|
|
info := bindataFileInfo{name: "data/data.json", size: 3332717, mode: os.FileMode(420), modTime: time.Unix(1557785965, 0)}
|
2020-02-13 22:55:19 +00:00
|
|
|
a := &asset{bytes: bytes, info: info}
|
|
|
|
return a, nil
|
|
|
|
}
|
|
|
|
|
|
|
|
// Asset loads and returns the asset for the given name.
|
|
|
|
// It returns an error if the asset could not be found or
|
|
|
|
// could not be loaded.
|
|
|
|
func Asset(name string) ([]byte, error) {
|
|
|
|
cannonicalName := strings.Replace(name, "\\", "/", -1)
|
|
|
|
if f, ok := _bindata[cannonicalName]; ok {
|
|
|
|
a, err := f()
|
|
|
|
if err != nil {
|
|
|
|
return nil, fmt.Errorf("Asset %s can't read by error: %v", name, err)
|
|
|
|
}
|
|
|
|
return a.bytes, nil
|
|
|
|
}
|
|
|
|
return nil, fmt.Errorf("Asset %s not found", name)
|
|
|
|
}
|
|
|
|
|
|
|
|
// MustAsset is like Asset but panics when Asset would return an error.
|
|
|
|
// It simplifies safe initialization of global variables.
|
|
|
|
func MustAsset(name string) []byte {
|
|
|
|
a, err := Asset(name)
|
|
|
|
if err != nil {
|
|
|
|
panic("asset: Asset(" + name + "): " + err.Error())
|
|
|
|
}
|
|
|
|
|
|
|
|
return a
|
|
|
|
}
|
|
|
|
|
|
|
|
// AssetInfo loads and returns the asset info for the given name.
|
|
|
|
// It returns an error if the asset could not be found or
|
|
|
|
// could not be loaded.
|
|
|
|
func AssetInfo(name string) (os.FileInfo, error) {
|
|
|
|
cannonicalName := strings.Replace(name, "\\", "/", -1)
|
|
|
|
if f, ok := _bindata[cannonicalName]; ok {
|
|
|
|
a, err := f()
|
|
|
|
if err != nil {
|
|
|
|
return nil, fmt.Errorf("AssetInfo %s can't read by error: %v", name, err)
|
|
|
|
}
|
|
|
|
return a.info, nil
|
|
|
|
}
|
|
|
|
return nil, fmt.Errorf("AssetInfo %s not found", name)
|
|
|
|
}
|
|
|
|
|
|
|
|
// AssetNames returns the names of the assets.
|
|
|
|
func AssetNames() []string {
|
|
|
|
names := make([]string, 0, len(_bindata))
|
|
|
|
for name := range _bindata {
|
|
|
|
names = append(names, name)
|
|
|
|
}
|
|
|
|
return names
|
|
|
|
}
|
|
|
|
|
|
|
|
// _bindata is a table, holding each asset generator, mapped to its name.
|
|
|
|
var _bindata = map[string]func() (*asset, error){
|
|
|
|
"data/data.json": dataDataJson,
|
|
|
|
}
|
|
|
|
|
|
|
|
// AssetDir returns the file names below a certain
|
|
|
|
// directory embedded in the file by go-bindata.
|
|
|
|
// For example if you run go-bindata on data/... and data contains the
|
|
|
|
// following hierarchy:
|
|
|
|
// data/
|
|
|
|
// foo.txt
|
|
|
|
// img/
|
|
|
|
// a.png
|
|
|
|
// b.png
|
|
|
|
// then AssetDir("data") would return []string{"foo.txt", "img"}
|
|
|
|
// AssetDir("data/img") would return []string{"a.png", "b.png"}
|
|
|
|
// AssetDir("foo.txt") and AssetDir("notexist") would return an error
|
|
|
|
// AssetDir("") will return []string{"data"}.
|
|
|
|
func AssetDir(name string) ([]string, error) {
|
|
|
|
node := _bintree
|
|
|
|
if len(name) != 0 {
|
|
|
|
cannonicalName := strings.Replace(name, "\\", "/", -1)
|
|
|
|
pathList := strings.Split(cannonicalName, "/")
|
|
|
|
for _, p := range pathList {
|
|
|
|
node = node.Children[p]
|
|
|
|
if node == nil {
|
|
|
|
return nil, fmt.Errorf("Asset %s not found", name)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if node.Func != nil {
|
|
|
|
return nil, fmt.Errorf("Asset %s not found", name)
|
|
|
|
}
|
|
|
|
rv := make([]string, 0, len(node.Children))
|
|
|
|
for childName := range node.Children {
|
|
|
|
rv = append(rv, childName)
|
|
|
|
}
|
|
|
|
return rv, nil
|
|
|
|
}
|
|
|
|
|
|
|
|
type bintree struct {
|
|
|
|
Func func() (*asset, error)
|
|
|
|
Children map[string]*bintree
|
|
|
|
}
|
|
|
|
|
|
|
|
var _bintree = &bintree{nil, map[string]*bintree{
|
|
|
|
"data": &bintree{nil, map[string]*bintree{
|
|
|
|
"data.json": &bintree{dataDataJson, map[string]*bintree{}},
|
|
|
|
}},
|
|
|
|
}}
|
|
|
|
|
|
|
|
// RestoreAsset restores an asset under the given directory
|
|
|
|
func RestoreAsset(dir, name string) error {
|
|
|
|
data, err := Asset(name)
|
|
|
|
if err != nil {
|
|
|
|
return err
|
|
|
|
}
|
|
|
|
info, err := AssetInfo(name)
|
|
|
|
if err != nil {
|
|
|
|
return err
|
|
|
|
}
|
|
|
|
err = os.MkdirAll(_filePath(dir, filepath.Dir(name)), os.FileMode(0755))
|
|
|
|
if err != nil {
|
|
|
|
return err
|
|
|
|
}
|
|
|
|
err = ioutil.WriteFile(_filePath(dir, name), data, info.Mode())
|
|
|
|
if err != nil {
|
|
|
|
return err
|
|
|
|
}
|
|
|
|
err = os.Chtimes(_filePath(dir, name), info.ModTime(), info.ModTime())
|
|
|
|
if err != nil {
|
|
|
|
return err
|
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
|
|
|
// RestoreAssets restores an asset under the given directory recursively
|
|
|
|
func RestoreAssets(dir, name string) error {
|
|
|
|
children, err := AssetDir(name)
|
|
|
|
// File
|
|
|
|
if err != nil {
|
|
|
|
return RestoreAsset(dir, name)
|
|
|
|
}
|
|
|
|
// Dir
|
|
|
|
for _, child := range children {
|
|
|
|
err = RestoreAssets(dir, filepath.Join(name, child))
|
|
|
|
if err != nil {
|
|
|
|
return err
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
|
|
|
func _filePath(dir, name string) string {
|
|
|
|
cannonicalName := strings.Replace(name, "\\", "/", -1)
|
|
|
|
return filepath.Join(append([]string{dir}, strings.Split(cannonicalName, "/")...)...)
|
|
|
|
}
|