101 lines
5.7 KiB
Go
101 lines
5.7 KiB
Go
//------------------------------------------------------------------------------
|
|
// <auto-generated>
|
|
// This code was generated by a tool.
|
|
// Changes to this file may cause incorrect behavior and will be lost if
|
|
// the code is regenerated.
|
|
// </auto-generated>
|
|
//------------------------------------------------------------------------------
|
|
|
|
package cfg
|
|
|
|
import "errors"
|
|
|
|
type Gameitinerant_cityData struct {
|
|
Id int32
|
|
Cityticket int32
|
|
Citylvlock int32
|
|
Citymainlock []int32
|
|
Cityname string
|
|
Cityinformation string
|
|
Citytxt string
|
|
Citytype int32
|
|
Citytypenum int32
|
|
Special []int32
|
|
Specialnum int32
|
|
Exspecial []int32
|
|
Exspecialnum int32
|
|
Orspecial int32
|
|
}
|
|
|
|
const TypeId_Gameitinerant_cityData = 675778342
|
|
|
|
func (*Gameitinerant_cityData) GetTypeId() int32 {
|
|
return 675778342
|
|
}
|
|
|
|
func (_v *Gameitinerant_cityData)Deserialize(_buf map[string]interface{}) (err error) {
|
|
{ var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["id"].(float64); !_ok_ { err = errors.New("id error"); return }; _v.Id = int32(_tempNum_) }
|
|
{ var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["cityticket"].(float64); !_ok_ { err = errors.New("cityticket error"); return }; _v.Cityticket = int32(_tempNum_) }
|
|
{ var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["citylvlock"].(float64); !_ok_ { err = errors.New("citylvlock error"); return }; _v.Citylvlock = int32(_tempNum_) }
|
|
{
|
|
var _arr_ []interface{}
|
|
var _ok_ bool
|
|
if _arr_, _ok_ = _buf["citymainlock"].([]interface{}); !_ok_ { err = errors.New("citymainlock error"); return }
|
|
|
|
_v.Citymainlock = make([]int32, 0, len(_arr_))
|
|
|
|
for _, _e_ := range _arr_ {
|
|
var _list_v_ int32
|
|
{ var _ok_ bool; var _x_ float64; if _x_, _ok_ = _e_.(float64); !_ok_ { err = errors.New("_list_v_ error"); return }; _list_v_ = int32(_x_) }
|
|
_v.Citymainlock = append(_v.Citymainlock, _list_v_)
|
|
}
|
|
}
|
|
|
|
{var _ok_ bool; var __json_text__ map[string]interface{}; if __json_text__, _ok_ = _buf["cityname"].(map[string]interface{}) ; !_ok_ { err = errors.New("_v.Cityname error"); return }; { var _ok_ bool; if _, _ok_ = __json_text__["key"].(string); !_ok_ { err = errors.New("key error"); return } }; { var _ok_ bool; if _v.Cityname, _ok_ = __json_text__["text"].(string); !_ok_ { err = errors.New("text error"); return } } }
|
|
{var _ok_ bool; var __json_text__ map[string]interface{}; if __json_text__, _ok_ = _buf["cityinformation"].(map[string]interface{}) ; !_ok_ { err = errors.New("_v.Cityinformation error"); return }; { var _ok_ bool; if _, _ok_ = __json_text__["key"].(string); !_ok_ { err = errors.New("key error"); return } }; { var _ok_ bool; if _v.Cityinformation, _ok_ = __json_text__["text"].(string); !_ok_ { err = errors.New("text error"); return } } }
|
|
{var _ok_ bool; var __json_text__ map[string]interface{}; if __json_text__, _ok_ = _buf["citytxt"].(map[string]interface{}) ; !_ok_ { err = errors.New("_v.Citytxt error"); return }; { var _ok_ bool; if _, _ok_ = __json_text__["key"].(string); !_ok_ { err = errors.New("key error"); return } }; { var _ok_ bool; if _v.Citytxt, _ok_ = __json_text__["text"].(string); !_ok_ { err = errors.New("text error"); return } } }
|
|
{ var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["citytype"].(float64); !_ok_ { err = errors.New("citytype error"); return }; _v.Citytype = int32(_tempNum_) }
|
|
{ var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["citytypenum"].(float64); !_ok_ { err = errors.New("citytypenum error"); return }; _v.Citytypenum = int32(_tempNum_) }
|
|
{
|
|
var _arr_ []interface{}
|
|
var _ok_ bool
|
|
if _arr_, _ok_ = _buf["special"].([]interface{}); !_ok_ { err = errors.New("special error"); return }
|
|
|
|
_v.Special = make([]int32, 0, len(_arr_))
|
|
|
|
for _, _e_ := range _arr_ {
|
|
var _list_v_ int32
|
|
{ var _ok_ bool; var _x_ float64; if _x_, _ok_ = _e_.(float64); !_ok_ { err = errors.New("_list_v_ error"); return }; _list_v_ = int32(_x_) }
|
|
_v.Special = append(_v.Special, _list_v_)
|
|
}
|
|
}
|
|
|
|
{ var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["specialnum"].(float64); !_ok_ { err = errors.New("specialnum error"); return }; _v.Specialnum = int32(_tempNum_) }
|
|
{
|
|
var _arr_ []interface{}
|
|
var _ok_ bool
|
|
if _arr_, _ok_ = _buf["exspecial"].([]interface{}); !_ok_ { err = errors.New("exspecial error"); return }
|
|
|
|
_v.Exspecial = make([]int32, 0, len(_arr_))
|
|
|
|
for _, _e_ := range _arr_ {
|
|
var _list_v_ int32
|
|
{ var _ok_ bool; var _x_ float64; if _x_, _ok_ = _e_.(float64); !_ok_ { err = errors.New("_list_v_ error"); return }; _list_v_ = int32(_x_) }
|
|
_v.Exspecial = append(_v.Exspecial, _list_v_)
|
|
}
|
|
}
|
|
|
|
{ var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["exspecialnum"].(float64); !_ok_ { err = errors.New("exspecialnum error"); return }; _v.Exspecialnum = int32(_tempNum_) }
|
|
{ var _ok_ bool; var _tempNum_ float64; if _tempNum_, _ok_ = _buf["Orspecial"].(float64); !_ok_ { err = errors.New("Orspecial error"); return }; _v.Orspecial = int32(_tempNum_) }
|
|
return
|
|
}
|
|
|
|
func DeserializeGameitinerant_cityData(_buf map[string]interface{}) (*Gameitinerant_cityData, error) {
|
|
v := &Gameitinerant_cityData{}
|
|
if err := v.Deserialize(_buf); err == nil {
|
|
return v, nil
|
|
} else {
|
|
return nil, err
|
|
}
|
|
}
|