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