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