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
|
|
|
|
}
|
|
|
|
|
2024-08-09 17:26:13 +00:00
|
|
|
var _dataDataJson = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\xbd\x5b\x73\xa4\xb8\x9a\xef\x7d\xbf\x3e\x05\xe1\x7d\xd1\xef\x3b\x51\xa4\xf3\xec\x43\xc4\x5c\x54\xdb\xd5\xd5\x8e\xae\x72\x79\xec\xea\x9e\xbd\x62\xbc\xc2\x81\x41\x99\x66\x99\x04\x1a\x48\x57\xb9\x6b\xfa\xbb\xef\x90\x38\x83\x20\x25\x20\xd3\x79\xf8\x7b\x22\x66\x75\x25\x92\x10\x42\x3c\xff\x9f\x1e\x49\x8f\x7e\xfc\x43\x39\xfa\xed\xd4\xff\x83\x78\xbe\xe9\xd8\x77\xc4\x7b\x31\x75\xf2\xc5\x0d\x4c\xc7\xf6\x8f\xce\x95\x1f\xff\x50\x94\xa3\x97\x41\x6f\xd0\x8f\xfe\xa1\x1c\x91\x40\x37\x8e\xce\x15\x7b\x69\x59\xef\xd8\x0f\xcf\xcb\x47\xa2\xb9\x66\x9c\x40\x39\xd2\x2c\xcb\xf9\xa6\xba\x9e\xf9\x62\x5a\x64\x4e\x68\xea\xa3\xc0\x5b\x92\xa3\x77\xd1\x75\xdb\xb1\x5f\x17\xce\xd2\x57\xb5\x65\xf0\x44\xaf\xce\x34\xcb\x4f\x2e\x3f\x9a\xb6\xa1\x6a\x86\xe1\x11\x9f\x56\xe1\xa8\xdf\x63\xff\x17\x5f\x26\xb6\xf6\x68\x11\x55\x33\x16\xa6\x4f\xeb\xac\xba\xd6\x72\x6e\xb2\xda\x1e\x5d\x6b\x0b\xe2\xbb\x9a\x4e\x3e\x99\x33\xa2\xbf\xea\x16\x79\xf7\xc9\x5c\x98\xc1\xad\x66\xcf\x89\xf7\x2e\x7a\xbc\xf7\xba\xee\x2c\xed\xe0\xdd\x25\x99\x69\x4b\x2b\xb8\x0b\x1c\x4f\x9b\x93\x0b\x4b\xf3\xfd\xf8\xb7\xaf\x8e\x45\x3c\x2d\x60\x4d\xa2\x3b\xb6\xe1\xbf\xfb\xbc\x0c\xb4\xc0\xb4\xe7\xef\xe3\xfb\xfe\x37\x79\x7c\x72\x9c\xe7\x77\x7f\x68\x96\x69\xf0\x2f\xdd\x12\xdf\x59\x7a\x3a\xf9\xaf\xa5\x13\x68\xef\xae\x1d\x83\xdc\x12\x3f\xf0\x4c\x9d\x16\x1c\x3f\x8f\x69\xfb\x44\x5f\x7a\x44\x75\x1d\x2f\x60\xcf\x1b\x5f\xa1\x0d\x6b\x91\x40\x75\x3d\x32\x23\x9e\x47\x92\x56\x51\x83\x57\x97\xb0\x07\xbe\xb2\x03\xe2\xd9\x9a\x75\x75\xf3\xee\xc3\xf7\xe4\x3f\x7f\x75\xfc\xc0\xd6\x16\x49\x8b\xba\x9e\x33\x33\x2d\xd3\x9e\x97\xda\xda\x23\x7f\x2e\x89\x1f\x3c\x11\xcd\x20\x9e\x4a\xbe\x07\x9e\xa6\x86\xff\xf0\xd9\x6d\xcd\xef\x34\xcb\xff\x55\x6f\xc9\xc2\x09\x88\xfa\x81\x25\xe0\x67\x9e\x7b\xce\xd2\x8d\x33\xe7\x72\x7d\xa4\x57\xf8\x99\x96\x3e\xad\xf3\x82\x70\xf3\xfd\xee\x13\x2f\xc9\xb6\xb4\x03\x73\x41\x54\xdd\xb1\x67\x26\x7b\x0e\xda\x77\x1c\xcf\xfc\x8b\xbd\xa5\xde\xf3\xa9\xdf\x33\x9d\xe3\x97\xc1\x23\x09\xb4\xc1\x7f\x66\xbb\x5b\xa1\x79\xa7\xe3\xf1\x28\xbd\xc4\x3a\x84\xaa\x85\x3d\x42\xb5\x1c\xe7\x79\xe9\x16\xfb\xab\x1f\x76\x10\xf5\x51\xd3\x9f\x89\xcd\xba\x33\xfd\x08\x92\x52\x02\xcb\x57\x75\xd3\x7d\x22\x9e\xea\x2f\xcd\x20\x7c\x33\x5f\x3f\xdd\x3d\x7c\xb8\xb8\xfc\xf5\x03\xfd\xff\x77\xef\x1f\xfe\xfb\xea\xeb\xaf\x0f\xef\x3f\xdc\x3d\x0c\x86\xa7\x0f\x1f\x2f\x3e\x3f\xdc\xfd\xfa\x7e\x38\x99\xbe\xab\x4c\x37\x9c\x4c\xe3\x74\xa3\xd3\x31\x3f\xdd\xc5\xaf\xef\x2f\x7e\x7d\x3f\xec\x3f\xdc\x7c\xf9\xf4\xcf\xc1\xa8\x3f\xc9\x24\xbb\x15\xba\xe9\xad\xd0\x2d\x6f\x2b\x6f\x78\x44\x9b\xe0\xef\xd4\x10\x58\x24\xc8\x18\x82\xca\x8f\xb8\xa5\x89\xa0\x3f\x12\x3b\x30\x75\xf6\xf2\xd5\xc0\x79\x26\xb6\xfa\x2d\xfc\xea\x4a\x45\x65\xfb\x89\xba\x70\x0c\x42\x53\x44\x9f\x68\x9c\x48\x67\xbd\xd7\x57\x5d\xe2\xa9\x7f\x3a\xe1\x0b\xcc\x94\xa1\xdb\xa6\xfa\x68\xda\xaa\x61\x7a\xf4\xd2\xb1\xe3\x06\xc7\xba\x6d\x1e\x3f\x9a\x76\x36\x09\xed\x9c\x49\x1a\x12\xe8\x2c\x8d\x4d\x82\x9e\x91\x1a\xaf\x99\xe3\xe9\x44\xb5\x1d\x83\xa8\xb4\x11\x74\x2d\xa0\xe6\x8c\xe6\x48\xd2\xbc\x10\x3b\x50\xff\x74\xfd\x9c\x31\x58\x68\xcf\x44\x35\x5d\x96\xda\x57\x97\x81\x69\xa9\xfa\x93\x16\xd9\xbd\xec\xf3\xda\x24\xf8\xe6\x78\xcf\x91\x59\xa4\x57\x75\xdb\x4c\xbf\x3e\xcd\x50\x1d\xdb\x7a\x2d\x5b\x1b\x8f\xf8\x8e\xf5\xc2\x9e\x21\xa9\x7f\xf8\x5b\x8f\xfd\x96\x7c\x0c\x1e\xd1\x16\xa6\x3d\xa7\x29\x6d\xc2\x4c\x99\x6a\x1a\x16\x51\xe9\xf7\xe9\x2c\x59\xa1\xa3\xfe\x02\x1f\x47\x7f\x12\xb7\xc1\x0b\x7d\xe6\x61\xf2\x2f\xc7\x5a\x2e\x48\xf4\x7e\x92\xee\xf2\xa2\x79\xc7\x96\xf9\x78\x1c\x7d\x44\xc7\x61\xaa\x58\xdb\x0a\x5f\x99\xeb\x39\xdf\x5f\xd3\xef\xec\x89\x68\x56\xf0\xf4\x97\x5a\x54\xce\xc1\xf0\x84\x7d\x76\x83\x42\x45\x0a\xa5\x5d\x38\x76\xe0\x39\x96\x45\x3c\xd1\x4f\x57\xd7\x82\xa8\x0f\xeb\xa6\xe1\x95\xba\x60\xf8\x75\x2f\xed\x40\x9b\xcf\x89\xa1\xea\x96\xb3\x2c\x7d\xe1\xa1\x21\xa7\x86\x99\x5d\x56\x3d\x67\x19\x75\x8e\xdc\x97\x1e\xa9\xfd\x93\xe3\x07\xae\x16\x3c\xa9\xae\xe7\xbc\x98\x54\x63\x59\x65\xf3\x69\xad\x48\xc5\x2c\xa2\x07\xa5\xaf\x82\x56\x76\xe1\xd8\x66\xe0\x50\xa9\xd2\x74\x42\xbf\x75\xd3\x61\xf5\x1a\xf7\xfd\x44\x2a\x1d\x43\x25\x2f\xa1\x42\x67\x7b\xf4\x64\x91\x49\x53\x29\xa
|
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
|
|
|
|
}
|
|
|
|
|
2024-08-09 17:26:13 +00:00
|
|
|
info := bindataFileInfo{name: "data/data.json", size: 8038221, 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, "/")...)...)
|
|
|
|
}
|