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