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