2018-04-06 20:04:40 +03:00
|
|
|
// Code generated by codecgen - DO NOT EDIT.
|
2015-08-17 03:41:14 +03:00
|
|
|
|
|
|
|
package client
|
|
|
|
|
|
|
|
import (
|
|
|
|
"errors"
|
2018-04-06 20:04:40 +03:00
|
|
|
"runtime"
|
|
|
|
"strconv"
|
|
|
|
"time"
|
2018-04-09 19:58:04 +03:00
|
|
|
|
|
|
|
codec1978 "github.com/ugorji/go/codec"
|
2015-08-17 03:41:14 +03:00
|
|
|
)
|
|
|
|
|
|
|
|
const (
|
2015-11-02 14:03:40 +03:00
|
|
|
// ----- content types ----
|
2019-02-25 07:07:40 +03:00
|
|
|
codecSelferCcUTF89381 = 1
|
|
|
|
codecSelferCcRAW9381 = 255
|
2015-11-02 14:03:40 +03:00
|
|
|
// ----- value types used ----
|
2019-02-25 07:07:40 +03:00
|
|
|
codecSelferValueTypeArray9381 = 10
|
|
|
|
codecSelferValueTypeMap9381 = 9
|
|
|
|
codecSelferValueTypeString9381 = 6
|
|
|
|
codecSelferValueTypeInt9381 = 2
|
|
|
|
codecSelferValueTypeUint9381 = 3
|
|
|
|
codecSelferValueTypeFloat9381 = 4
|
|
|
|
codecSelferBitsize9381 = uint8(32 << (^uint(0) >> 63))
|
2015-08-17 03:41:14 +03:00
|
|
|
)
|
|
|
|
|
|
|
|
var (
|
2019-02-25 07:07:40 +03:00
|
|
|
errCodecSelferOnlyMapOrArrayEncodeToStruct9381 = errors.New(`only encoded map or array can be decoded into a struct`)
|
2015-08-17 03:41:14 +03:00
|
|
|
)
|
|
|
|
|
2019-02-25 07:07:40 +03:00
|
|
|
type codecSelfer9381 struct{}
|
2015-08-17 03:41:14 +03:00
|
|
|
|
|
|
|
func init() {
|
2019-02-25 07:07:40 +03:00
|
|
|
if codec1978.GenVersion != 10 {
|
2015-08-17 03:41:14 +03:00
|
|
|
_, file, _, _ := runtime.Caller(0)
|
2019-02-25 07:07:40 +03:00
|
|
|
panic("codecgen version mismatch: current: 10, need " + strconv.FormatInt(int64(codec1978.GenVersion), 10) + ". Re-generate file: " + file)
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2019-02-25 07:07:40 +03:00
|
|
|
if false {
|
|
|
|
var _ byte = 0 // reference the types, but skip this branch at build/run time
|
2017-10-20 08:14:43 +03:00
|
|
|
var v0 time.Duration
|
2015-08-17 03:41:14 +03:00
|
|
|
_ = v0
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-10-20 08:14:43 +03:00
|
|
|
func (x *Error) CodecEncodeSelf(e *codec1978.Encoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2015-08-17 03:41:14 +03:00
|
|
|
z, r := codec1978.GenHelperEncoder(e)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if x == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
2015-10-08 12:27:00 +03:00
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.EncExtension(x, yyxt1)
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2015-10-08 12:27:00 +03:00
|
|
|
yysep2 := !z.EncBinary()
|
|
|
|
yy2arr2 := z.EncBasicHandle().StructToArray
|
2017-10-20 08:14:43 +03:00
|
|
|
_, _ = yysep2, yy2arr2
|
2018-04-06 20:04:40 +03:00
|
|
|
const yyr2 bool = false // struct tag has 'toArray'
|
2015-10-08 12:27:00 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteArrayStart(4)
|
2015-10-08 12:27:00 +03:00
|
|
|
} else {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapStart(4)
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2015-10-08 12:27:00 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteArrayElem()
|
2015-10-08 12:27:00 +03:00
|
|
|
if false {
|
|
|
|
} else {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.EncodeInt(int64(x.Code))
|
2015-10-08 12:27:00 +03:00
|
|
|
}
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"errorCode\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `errorCode`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
2015-10-08 12:27:00 +03:00
|
|
|
if false {
|
|
|
|
} else {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.EncodeInt(int64(x.Code))
|
2015-10-08 12:27:00 +03:00
|
|
|
}
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2015-10-08 12:27:00 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
2015-10-08 12:27:00 +03:00
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Message))
|
2015-10-08 12:27:00 +03:00
|
|
|
}
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"message\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `message`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
2015-10-08 12:27:00 +03:00
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Message))
|
2015-10-08 12:27:00 +03:00
|
|
|
}
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2015-10-08 12:27:00 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
2015-10-08 12:27:00 +03:00
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Cause))
|
2015-10-08 12:27:00 +03:00
|
|
|
}
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"cause\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `cause`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Cause))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeUint(uint64(x.Index))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"index\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `index`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
2015-10-08 12:27:00 +03:00
|
|
|
} else {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.EncodeUint(uint64(x.Index))
|
2015-10-08 12:27:00 +03:00
|
|
|
}
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2015-11-02 14:03:40 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteArrayEnd()
|
2015-11-02 14:03:40 +03:00
|
|
|
} else {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapEnd()
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-10-20 08:14:43 +03:00
|
|
|
func (x *Error) CodecDecodeSelf(d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2015-08-17 03:41:14 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
2015-10-08 12:27:00 +03:00
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.DecExtension(x, yyxt1)
|
2015-10-08 12:27:00 +03:00
|
|
|
} else {
|
2016-12-05 19:06:42 +03:00
|
|
|
yyct2 := r.ContainerType()
|
2019-02-25 07:07:40 +03:00
|
|
|
if yyct2 == codecSelferValueTypeMap9381 {
|
2016-12-05 19:06:42 +03:00
|
|
|
yyl2 := r.ReadMapStart()
|
|
|
|
if yyl2 == 0 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadMapEnd()
|
2015-10-08 12:27:00 +03:00
|
|
|
} else {
|
2016-12-05 19:06:42 +03:00
|
|
|
x.codecDecodeSelfFromMap(yyl2, d)
|
2015-10-08 12:27:00 +03:00
|
|
|
}
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if yyct2 == codecSelferValueTypeArray9381 {
|
2016-12-05 19:06:42 +03:00
|
|
|
yyl2 := r.ReadArrayStart()
|
|
|
|
if yyl2 == 0 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
2015-10-08 12:27:00 +03:00
|
|
|
} else {
|
2016-12-05 19:06:42 +03:00
|
|
|
x.codecDecodeSelfFromArray(yyl2, d)
|
2015-10-08 12:27:00 +03:00
|
|
|
}
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
panic(errCodecSelferOnlyMapOrArrayEncodeToStruct9381)
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-10-20 08:14:43 +03:00
|
|
|
func (x *Error) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2015-08-17 03:41:14 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
2016-12-05 19:06:42 +03:00
|
|
|
var yyhl3 bool = l >= 0
|
|
|
|
for yyj3 := 0; ; yyj3++ {
|
|
|
|
if yyhl3 {
|
|
|
|
if yyj3 >= l {
|
2015-08-17 03:41:14 +03:00
|
|
|
break
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if r.CheckBreak() {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadMapElemKey()
|
2018-04-06 20:04:40 +03:00
|
|
|
yys3 := z.StringView(r.DecodeStringAsBytes())
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadMapElemValue()
|
2016-12-05 19:06:42 +03:00
|
|
|
switch yys3 {
|
2017-10-20 08:14:43 +03:00
|
|
|
case "errorCode":
|
2015-08-17 03:41:14 +03:00
|
|
|
if r.TryDecodeAsNil() {
|
2017-10-20 08:14:43 +03:00
|
|
|
x.Code = 0
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
x.Code = (int)(z.C.IntV(r.DecodeInt64(), codecSelferBitsize9381))
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
case "message":
|
2015-08-17 03:41:14 +03:00
|
|
|
if r.TryDecodeAsNil() {
|
2017-10-20 08:14:43 +03:00
|
|
|
x.Message = ""
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Message = (string)(r.DecodeString())
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
case "cause":
|
2015-08-17 03:41:14 +03:00
|
|
|
if r.TryDecodeAsNil() {
|
2017-10-20 08:14:43 +03:00
|
|
|
x.Cause = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Cause = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "index":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Index = 0
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Index = (uint64)(r.DecodeUint64())
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
|
|
|
default:
|
2016-12-05 19:06:42 +03:00
|
|
|
z.DecStructFieldNotFound(-1, yys3)
|
|
|
|
} // end switch yys3
|
|
|
|
} // end for yyj3
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadMapEnd()
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
|
|
|
|
2017-10-20 08:14:43 +03:00
|
|
|
func (x *Error) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2015-08-17 03:41:14 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
2018-04-06 20:04:40 +03:00
|
|
|
var yyj8 int
|
|
|
|
var yyb8 bool
|
|
|
|
var yyhl8 bool = l >= 0
|
|
|
|
yyj8++
|
|
|
|
if yyhl8 {
|
|
|
|
yyb8 = yyj8 > l
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb8 = r.CheckBreak()
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb8 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
2015-08-17 03:41:14 +03:00
|
|
|
return
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayElem()
|
2015-08-17 03:41:14 +03:00
|
|
|
if r.TryDecodeAsNil() {
|
2017-10-20 08:14:43 +03:00
|
|
|
x.Code = 0
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
x.Code = (int)(z.C.IntV(r.DecodeInt64(), codecSelferBitsize9381))
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj8++
|
|
|
|
if yyhl8 {
|
|
|
|
yyb8 = yyj8 > l
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb8 = r.CheckBreak()
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb8 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
2015-08-17 03:41:14 +03:00
|
|
|
return
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayElem()
|
2015-08-17 03:41:14 +03:00
|
|
|
if r.TryDecodeAsNil() {
|
2017-10-20 08:14:43 +03:00
|
|
|
x.Message = ""
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Message = (string)(r.DecodeString())
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj8++
|
|
|
|
if yyhl8 {
|
|
|
|
yyb8 = yyj8 > l
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb8 = r.CheckBreak()
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb8 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
2015-08-17 03:41:14 +03:00
|
|
|
return
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayElem()
|
2015-08-17 03:41:14 +03:00
|
|
|
if r.TryDecodeAsNil() {
|
2017-10-20 08:14:43 +03:00
|
|
|
x.Cause = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Cause = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj8++
|
|
|
|
if yyhl8 {
|
|
|
|
yyb8 = yyj8 > l
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb8 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb8 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Index = 0
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Index = (uint64)(r.DecodeUint64())
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
|
|
|
for {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj8++
|
|
|
|
if yyhl8 {
|
|
|
|
yyb8 = yyj8 > l
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb8 = r.CheckBreak()
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb8 {
|
2015-08-17 03:41:14 +03:00
|
|
|
break
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayElem()
|
2018-04-06 20:04:40 +03:00
|
|
|
z.DecStructFieldNotFound(yyj8-1, "")
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
|
|
|
|
2017-10-20 08:14:43 +03:00
|
|
|
func (x PrevExistType) CodecEncodeSelf(e *codec1978.Encoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperEncoder(e)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.EncExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *PrevExistType) CodecDecodeSelf(d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.DecExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
*x = (PrevExistType)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *WatcherOptions) CodecEncodeSelf(e *codec1978.Encoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2015-08-17 03:41:14 +03:00
|
|
|
z, r := codec1978.GenHelperEncoder(e)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if x == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
2015-10-08 12:27:00 +03:00
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.EncExtension(x, yyxt1)
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2016-12-05 19:06:42 +03:00
|
|
|
yysep2 := !z.EncBinary()
|
|
|
|
yy2arr2 := z.EncBasicHandle().StructToArray
|
2017-10-20 08:14:43 +03:00
|
|
|
_, _ = yysep2, yy2arr2
|
2018-04-06 20:04:40 +03:00
|
|
|
const yyr2 bool = false // struct tag has 'toArray'
|
2016-12-05 19:06:42 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteArrayStart(2)
|
2015-10-08 12:27:00 +03:00
|
|
|
} else {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapStart(2)
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2016-12-05 19:06:42 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteArrayElem()
|
2015-10-08 12:27:00 +03:00
|
|
|
if false {
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.EncodeUint(uint64(x.AfterIndex))
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
|
|
|
} else {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"AfterIndex\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `AfterIndex`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
2015-10-08 12:27:00 +03:00
|
|
|
if false {
|
|
|
|
} else {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.EncodeUint(uint64(x.AfterIndex))
|
2015-10-08 12:27:00 +03:00
|
|
|
}
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2016-12-05 19:06:42 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteArrayElem()
|
2015-10-08 12:27:00 +03:00
|
|
|
if false {
|
|
|
|
} else {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.EncodeBool(bool(x.Recursive))
|
2015-10-08 12:27:00 +03:00
|
|
|
}
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Recursive\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Recursive`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
2015-10-08 12:27:00 +03:00
|
|
|
if false {
|
|
|
|
} else {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.EncodeBool(bool(x.Recursive))
|
2015-10-08 12:27:00 +03:00
|
|
|
}
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2016-12-05 19:06:42 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteArrayEnd()
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapEnd()
|
2015-10-08 12:27:00 +03:00
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *WatcherOptions) CodecDecodeSelf(d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.DecExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yyct2 := r.ContainerType()
|
2019-02-25 07:07:40 +03:00
|
|
|
if yyct2 == codecSelferValueTypeMap9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadMapStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadMapEnd()
|
2015-10-08 12:27:00 +03:00
|
|
|
} else {
|
2017-10-20 08:14:43 +03:00
|
|
|
x.codecDecodeSelfFromMap(yyl2, d)
|
|
|
|
}
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if yyct2 == codecSelferValueTypeArray9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadArrayStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromArray(yyl2, d)
|
|
|
|
}
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
panic(errCodecSelferOnlyMapOrArrayEncodeToStruct9381)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *WatcherOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
var yyhl3 bool = l >= 0
|
|
|
|
for yyj3 := 0; ; yyj3++ {
|
|
|
|
if yyhl3 {
|
|
|
|
if yyj3 >= l {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if r.CheckBreak() {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
}
|
|
|
|
r.ReadMapElemKey()
|
2018-04-06 20:04:40 +03:00
|
|
|
yys3 := z.StringView(r.DecodeStringAsBytes())
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadMapElemValue()
|
|
|
|
switch yys3 {
|
|
|
|
case "AfterIndex":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.AfterIndex = 0
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.AfterIndex = (uint64)(r.DecodeUint64())
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
case "Recursive":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Recursive = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Recursive = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
default:
|
|
|
|
z.DecStructFieldNotFound(-1, yys3)
|
|
|
|
} // end switch yys3
|
|
|
|
} // end for yyj3
|
|
|
|
r.ReadMapEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *WatcherOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
2018-04-06 20:04:40 +03:00
|
|
|
var yyj6 int
|
|
|
|
var yyb6 bool
|
|
|
|
var yyhl6 bool = l >= 0
|
|
|
|
yyj6++
|
|
|
|
if yyhl6 {
|
|
|
|
yyb6 = yyj6 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb6 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb6 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.AfterIndex = 0
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.AfterIndex = (uint64)(r.DecodeUint64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj6++
|
|
|
|
if yyhl6 {
|
|
|
|
yyb6 = yyj6 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb6 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb6 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Recursive = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Recursive = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
for {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj6++
|
|
|
|
if yyhl6 {
|
|
|
|
yyb6 = yyj6 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb6 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb6 {
|
2017-10-20 08:14:43 +03:00
|
|
|
break
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
2018-04-06 20:04:40 +03:00
|
|
|
z.DecStructFieldNotFound(yyj6-1, "")
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *CreateInOrderOptions) CodecEncodeSelf(e *codec1978.Encoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperEncoder(e)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if x == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.EncExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yysep2 := !z.EncBinary()
|
|
|
|
yy2arr2 := z.EncBasicHandle().StructToArray
|
|
|
|
_, _ = yysep2, yy2arr2
|
2018-04-06 20:04:40 +03:00
|
|
|
const yyr2 bool = false // struct tag has 'toArray'
|
2017-10-20 08:14:43 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayStart(1)
|
|
|
|
} else {
|
|
|
|
r.WriteMapStart(1)
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt4 := z.Extension(z.I2Rtid(x.TTL)); yyxt4 != nil {
|
|
|
|
z.EncExtension(x.TTL, yyxt4)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
r.EncodeInt(int64(x.TTL))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"TTL\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `TTL`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt5 := z.Extension(z.I2Rtid(x.TTL)); yyxt5 != nil {
|
|
|
|
z.EncExtension(x.TTL, yyxt5)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
r.EncodeInt(int64(x.TTL))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayEnd()
|
|
|
|
} else {
|
|
|
|
r.WriteMapEnd()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *CreateInOrderOptions) CodecDecodeSelf(d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.DecExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yyct2 := r.ContainerType()
|
2019-02-25 07:07:40 +03:00
|
|
|
if yyct2 == codecSelferValueTypeMap9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadMapStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadMapEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromMap(yyl2, d)
|
|
|
|
}
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if yyct2 == codecSelferValueTypeArray9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadArrayStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromArray(yyl2, d)
|
|
|
|
}
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
panic(errCodecSelferOnlyMapOrArrayEncodeToStruct9381)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *CreateInOrderOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
var yyhl3 bool = l >= 0
|
|
|
|
for yyj3 := 0; ; yyj3++ {
|
|
|
|
if yyhl3 {
|
|
|
|
if yyj3 >= l {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if r.CheckBreak() {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
}
|
|
|
|
r.ReadMapElemKey()
|
2018-04-06 20:04:40 +03:00
|
|
|
yys3 := z.StringView(r.DecodeStringAsBytes())
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadMapElemValue()
|
|
|
|
switch yys3 {
|
|
|
|
case "TTL":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.TTL = 0
|
|
|
|
} else {
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt5 := z.Extension(z.I2Rtid(x.TTL)); yyxt5 != nil {
|
|
|
|
z.DecExtension(x.TTL, yyxt5)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.TTL = (time.Duration)(r.DecodeInt64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
default:
|
|
|
|
z.DecStructFieldNotFound(-1, yys3)
|
|
|
|
} // end switch yys3
|
|
|
|
} // end for yyj3
|
|
|
|
r.ReadMapEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *CreateInOrderOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
var yyj6 int
|
|
|
|
var yyb6 bool
|
|
|
|
var yyhl6 bool = l >= 0
|
|
|
|
yyj6++
|
|
|
|
if yyhl6 {
|
|
|
|
yyb6 = yyj6 > l
|
|
|
|
} else {
|
|
|
|
yyb6 = r.CheckBreak()
|
|
|
|
}
|
|
|
|
if yyb6 {
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.TTL = 0
|
|
|
|
} else {
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt8 := z.Extension(z.I2Rtid(x.TTL)); yyxt8 != nil {
|
|
|
|
z.DecExtension(x.TTL, yyxt8)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.TTL = (time.Duration)(r.DecodeInt64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
for {
|
|
|
|
yyj6++
|
|
|
|
if yyhl6 {
|
|
|
|
yyb6 = yyj6 > l
|
|
|
|
} else {
|
|
|
|
yyb6 = r.CheckBreak()
|
|
|
|
}
|
|
|
|
if yyb6 {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
z.DecStructFieldNotFound(yyj6-1, "")
|
|
|
|
}
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *SetOptions) CodecEncodeSelf(e *codec1978.Encoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperEncoder(e)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if x == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.EncExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yysep2 := !z.EncBinary()
|
|
|
|
yy2arr2 := z.EncBasicHandle().StructToArray
|
|
|
|
_, _ = yysep2, yy2arr2
|
2018-04-06 20:04:40 +03:00
|
|
|
const yyr2 bool = false // struct tag has 'toArray'
|
2017-10-20 08:14:43 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayStart(7)
|
|
|
|
} else {
|
|
|
|
r.WriteMapStart(7)
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.PrevValue))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"PrevValue\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `PrevValue`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.PrevValue))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeUint(uint64(x.PrevIndex))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"PrevIndex\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `PrevIndex`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeUint(uint64(x.PrevIndex))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
x.PrevExist.CodecEncodeSelf(e)
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"PrevExist\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `PrevExist`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
x.PrevExist.CodecEncodeSelf(e)
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt13 := z.Extension(z.I2Rtid(x.TTL)); yyxt13 != nil {
|
|
|
|
z.EncExtension(x.TTL, yyxt13)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
r.EncodeInt(int64(x.TTL))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"TTL\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `TTL`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt14 := z.Extension(z.I2Rtid(x.TTL)); yyxt14 != nil {
|
|
|
|
z.EncExtension(x.TTL, yyxt14)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
r.EncodeInt(int64(x.TTL))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Refresh))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Refresh\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Refresh`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Refresh))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Dir))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Dir\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Dir`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Dir))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.NoValueOnSuccess))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"NoValueOnSuccess\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `NoValueOnSuccess`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.NoValueOnSuccess))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayEnd()
|
|
|
|
} else {
|
|
|
|
r.WriteMapEnd()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *SetOptions) CodecDecodeSelf(d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.DecExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yyct2 := r.ContainerType()
|
2019-02-25 07:07:40 +03:00
|
|
|
if yyct2 == codecSelferValueTypeMap9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadMapStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadMapEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromMap(yyl2, d)
|
|
|
|
}
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if yyct2 == codecSelferValueTypeArray9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadArrayStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromArray(yyl2, d)
|
|
|
|
}
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
panic(errCodecSelferOnlyMapOrArrayEncodeToStruct9381)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *SetOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
var yyhl3 bool = l >= 0
|
|
|
|
for yyj3 := 0; ; yyj3++ {
|
|
|
|
if yyhl3 {
|
|
|
|
if yyj3 >= l {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if r.CheckBreak() {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
}
|
|
|
|
r.ReadMapElemKey()
|
2018-04-06 20:04:40 +03:00
|
|
|
yys3 := z.StringView(r.DecodeStringAsBytes())
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadMapElemValue()
|
|
|
|
switch yys3 {
|
|
|
|
case "PrevValue":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.PrevValue = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.PrevValue = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "PrevIndex":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.PrevIndex = 0
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.PrevIndex = (uint64)(r.DecodeUint64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "PrevExist":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.PrevExist = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.PrevExist.CodecDecodeSelf(d)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "TTL":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.TTL = 0
|
|
|
|
} else {
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt8 := z.Extension(z.I2Rtid(x.TTL)); yyxt8 != nil {
|
|
|
|
z.DecExtension(x.TTL, yyxt8)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.TTL = (time.Duration)(r.DecodeInt64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
case "Refresh":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Refresh = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Refresh = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "Dir":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Dir = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Dir = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "NoValueOnSuccess":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.NoValueOnSuccess = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.NoValueOnSuccess = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
default:
|
|
|
|
z.DecStructFieldNotFound(-1, yys3)
|
|
|
|
} // end switch yys3
|
|
|
|
} // end for yyj3
|
|
|
|
r.ReadMapEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *SetOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
2018-04-06 20:04:40 +03:00
|
|
|
var yyj12 int
|
|
|
|
var yyb12 bool
|
|
|
|
var yyhl12 bool = l >= 0
|
|
|
|
yyj12++
|
|
|
|
if yyhl12 {
|
|
|
|
yyb12 = yyj12 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb12 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb12 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.PrevValue = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.PrevValue = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj12++
|
|
|
|
if yyhl12 {
|
|
|
|
yyb12 = yyj12 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb12 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb12 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.PrevIndex = 0
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.PrevIndex = (uint64)(r.DecodeUint64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj12++
|
|
|
|
if yyhl12 {
|
|
|
|
yyb12 = yyj12 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb12 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb12 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.PrevExist = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.PrevExist.CodecDecodeSelf(d)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj12++
|
|
|
|
if yyhl12 {
|
|
|
|
yyb12 = yyj12 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb12 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb12 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.TTL = 0
|
|
|
|
} else {
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt17 := z.Extension(z.I2Rtid(x.TTL)); yyxt17 != nil {
|
|
|
|
z.DecExtension(x.TTL, yyxt17)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.TTL = (time.Duration)(r.DecodeInt64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj12++
|
|
|
|
if yyhl12 {
|
|
|
|
yyb12 = yyj12 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb12 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb12 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Refresh = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Refresh = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj12++
|
|
|
|
if yyhl12 {
|
|
|
|
yyb12 = yyj12 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb12 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb12 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Dir = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Dir = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj12++
|
|
|
|
if yyhl12 {
|
|
|
|
yyb12 = yyj12 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb12 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb12 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.NoValueOnSuccess = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.NoValueOnSuccess = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
for {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj12++
|
|
|
|
if yyhl12 {
|
|
|
|
yyb12 = yyj12 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb12 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb12 {
|
2017-10-20 08:14:43 +03:00
|
|
|
break
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
2018-04-06 20:04:40 +03:00
|
|
|
z.DecStructFieldNotFound(yyj12-1, "")
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *GetOptions) CodecEncodeSelf(e *codec1978.Encoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperEncoder(e)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if x == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.EncExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yysep2 := !z.EncBinary()
|
|
|
|
yy2arr2 := z.EncBasicHandle().StructToArray
|
|
|
|
_, _ = yysep2, yy2arr2
|
2018-04-06 20:04:40 +03:00
|
|
|
const yyr2 bool = false // struct tag has 'toArray'
|
2017-10-20 08:14:43 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayStart(3)
|
|
|
|
} else {
|
|
|
|
r.WriteMapStart(3)
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Recursive))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Recursive\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Recursive`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Recursive))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Sort))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Sort\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Sort`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Sort))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Quorum))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Quorum\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Quorum`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Quorum))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayEnd()
|
|
|
|
} else {
|
|
|
|
r.WriteMapEnd()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *GetOptions) CodecDecodeSelf(d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.DecExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yyct2 := r.ContainerType()
|
2019-02-25 07:07:40 +03:00
|
|
|
if yyct2 == codecSelferValueTypeMap9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadMapStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadMapEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromMap(yyl2, d)
|
|
|
|
}
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if yyct2 == codecSelferValueTypeArray9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadArrayStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromArray(yyl2, d)
|
|
|
|
}
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
panic(errCodecSelferOnlyMapOrArrayEncodeToStruct9381)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *GetOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
var yyhl3 bool = l >= 0
|
|
|
|
for yyj3 := 0; ; yyj3++ {
|
|
|
|
if yyhl3 {
|
|
|
|
if yyj3 >= l {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if r.CheckBreak() {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
}
|
|
|
|
r.ReadMapElemKey()
|
2018-04-06 20:04:40 +03:00
|
|
|
yys3 := z.StringView(r.DecodeStringAsBytes())
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadMapElemValue()
|
|
|
|
switch yys3 {
|
|
|
|
case "Recursive":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Recursive = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Recursive = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "Sort":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Sort = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Sort = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "Quorum":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Quorum = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Quorum = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
default:
|
|
|
|
z.DecStructFieldNotFound(-1, yys3)
|
|
|
|
} // end switch yys3
|
|
|
|
} // end for yyj3
|
|
|
|
r.ReadMapEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *GetOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
2018-04-06 20:04:40 +03:00
|
|
|
var yyj7 int
|
|
|
|
var yyb7 bool
|
|
|
|
var yyhl7 bool = l >= 0
|
|
|
|
yyj7++
|
|
|
|
if yyhl7 {
|
|
|
|
yyb7 = yyj7 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb7 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb7 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Recursive = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Recursive = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj7++
|
|
|
|
if yyhl7 {
|
|
|
|
yyb7 = yyj7 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb7 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb7 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Sort = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Sort = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj7++
|
|
|
|
if yyhl7 {
|
|
|
|
yyb7 = yyj7 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb7 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb7 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Quorum = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Quorum = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
for {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj7++
|
|
|
|
if yyhl7 {
|
|
|
|
yyb7 = yyj7 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb7 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb7 {
|
2017-10-20 08:14:43 +03:00
|
|
|
break
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
2018-04-06 20:04:40 +03:00
|
|
|
z.DecStructFieldNotFound(yyj7-1, "")
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *DeleteOptions) CodecEncodeSelf(e *codec1978.Encoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperEncoder(e)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if x == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.EncExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yysep2 := !z.EncBinary()
|
|
|
|
yy2arr2 := z.EncBasicHandle().StructToArray
|
|
|
|
_, _ = yysep2, yy2arr2
|
2018-04-06 20:04:40 +03:00
|
|
|
const yyr2 bool = false // struct tag has 'toArray'
|
2017-10-20 08:14:43 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayStart(4)
|
|
|
|
} else {
|
|
|
|
r.WriteMapStart(4)
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.PrevValue))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"PrevValue\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `PrevValue`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.PrevValue))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeUint(uint64(x.PrevIndex))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"PrevIndex\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `PrevIndex`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeUint(uint64(x.PrevIndex))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Recursive))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Recursive\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Recursive`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Recursive))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Dir))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Dir\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Dir`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Dir))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayEnd()
|
|
|
|
} else {
|
|
|
|
r.WriteMapEnd()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *DeleteOptions) CodecDecodeSelf(d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.DecExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yyct2 := r.ContainerType()
|
2019-02-25 07:07:40 +03:00
|
|
|
if yyct2 == codecSelferValueTypeMap9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadMapStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadMapEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromMap(yyl2, d)
|
|
|
|
}
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if yyct2 == codecSelferValueTypeArray9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadArrayStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromArray(yyl2, d)
|
|
|
|
}
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
panic(errCodecSelferOnlyMapOrArrayEncodeToStruct9381)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *DeleteOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
var yyhl3 bool = l >= 0
|
|
|
|
for yyj3 := 0; ; yyj3++ {
|
|
|
|
if yyhl3 {
|
|
|
|
if yyj3 >= l {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if r.CheckBreak() {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
}
|
|
|
|
r.ReadMapElemKey()
|
2018-04-06 20:04:40 +03:00
|
|
|
yys3 := z.StringView(r.DecodeStringAsBytes())
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadMapElemValue()
|
|
|
|
switch yys3 {
|
|
|
|
case "PrevValue":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.PrevValue = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.PrevValue = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "PrevIndex":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.PrevIndex = 0
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.PrevIndex = (uint64)(r.DecodeUint64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "Recursive":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Recursive = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Recursive = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "Dir":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Dir = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Dir = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
default:
|
|
|
|
z.DecStructFieldNotFound(-1, yys3)
|
|
|
|
} // end switch yys3
|
|
|
|
} // end for yyj3
|
|
|
|
r.ReadMapEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *DeleteOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
2018-04-06 20:04:40 +03:00
|
|
|
var yyj8 int
|
|
|
|
var yyb8 bool
|
|
|
|
var yyhl8 bool = l >= 0
|
|
|
|
yyj8++
|
|
|
|
if yyhl8 {
|
|
|
|
yyb8 = yyj8 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb8 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb8 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.PrevValue = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.PrevValue = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj8++
|
|
|
|
if yyhl8 {
|
|
|
|
yyb8 = yyj8 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb8 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb8 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.PrevIndex = 0
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.PrevIndex = (uint64)(r.DecodeUint64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj8++
|
|
|
|
if yyhl8 {
|
|
|
|
yyb8 = yyj8 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb8 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb8 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Recursive = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Recursive = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj8++
|
|
|
|
if yyhl8 {
|
|
|
|
yyb8 = yyj8 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb8 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb8 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Dir = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Dir = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
for {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj8++
|
|
|
|
if yyhl8 {
|
|
|
|
yyb8 = yyj8 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb8 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb8 {
|
2017-10-20 08:14:43 +03:00
|
|
|
break
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
2018-04-06 20:04:40 +03:00
|
|
|
z.DecStructFieldNotFound(yyj8-1, "")
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *Response) CodecEncodeSelf(e *codec1978.Encoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperEncoder(e)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if x == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.EncExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yysep2 := !z.EncBinary()
|
|
|
|
yy2arr2 := z.EncBasicHandle().StructToArray
|
|
|
|
_, _ = yysep2, yy2arr2
|
2018-04-06 20:04:40 +03:00
|
|
|
const yyr2 bool = false // struct tag has 'toArray'
|
2017-10-20 08:14:43 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayStart(3)
|
|
|
|
} else {
|
|
|
|
r.WriteMapStart(3)
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Action))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"action\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `action`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Action))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
var yyn6 bool
|
|
|
|
if x.Node == nil {
|
|
|
|
yyn6 = true
|
|
|
|
goto LABEL6
|
|
|
|
}
|
|
|
|
LABEL6:
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
if yyn6 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if x.Node == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
x.Node.CodecEncodeSelf(e)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"node\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `node`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if yyn6 {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
if x.Node == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
x.Node.CodecEncodeSelf(e)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
var yyn9 bool
|
|
|
|
if x.PrevNode == nil {
|
|
|
|
yyn9 = true
|
|
|
|
goto LABEL9
|
|
|
|
}
|
|
|
|
LABEL9:
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
if yyn9 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if x.PrevNode == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
x.PrevNode.CodecEncodeSelf(e)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"prevNode\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `prevNode`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if yyn9 {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
if x.PrevNode == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
x.PrevNode.CodecEncodeSelf(e)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayEnd()
|
|
|
|
} else {
|
|
|
|
r.WriteMapEnd()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *Response) CodecDecodeSelf(d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.DecExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yyct2 := r.ContainerType()
|
2019-02-25 07:07:40 +03:00
|
|
|
if yyct2 == codecSelferValueTypeMap9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadMapStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadMapEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromMap(yyl2, d)
|
|
|
|
}
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if yyct2 == codecSelferValueTypeArray9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadArrayStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromArray(yyl2, d)
|
|
|
|
}
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
panic(errCodecSelferOnlyMapOrArrayEncodeToStruct9381)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *Response) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
var yyhl3 bool = l >= 0
|
|
|
|
for yyj3 := 0; ; yyj3++ {
|
|
|
|
if yyhl3 {
|
|
|
|
if yyj3 >= l {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if r.CheckBreak() {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
}
|
|
|
|
r.ReadMapElemKey()
|
2018-04-06 20:04:40 +03:00
|
|
|
yys3 := z.StringView(r.DecodeStringAsBytes())
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadMapElemValue()
|
|
|
|
switch yys3 {
|
|
|
|
case "action":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Action = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Action = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "node":
|
|
|
|
if r.TryDecodeAsNil() {
|
2018-04-06 20:04:40 +03:00
|
|
|
if true && x.Node != nil {
|
2017-10-20 08:14:43 +03:00
|
|
|
x.Node = nil
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if x.Node == nil {
|
|
|
|
x.Node = new(Node)
|
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
|
2017-10-20 08:14:43 +03:00
|
|
|
x.Node.CodecDecodeSelf(d)
|
|
|
|
}
|
|
|
|
case "prevNode":
|
|
|
|
if r.TryDecodeAsNil() {
|
2018-04-06 20:04:40 +03:00
|
|
|
if true && x.PrevNode != nil {
|
2017-10-20 08:14:43 +03:00
|
|
|
x.PrevNode = nil
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if x.PrevNode == nil {
|
|
|
|
x.PrevNode = new(Node)
|
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
|
2017-10-20 08:14:43 +03:00
|
|
|
x.PrevNode.CodecDecodeSelf(d)
|
|
|
|
}
|
|
|
|
default:
|
|
|
|
z.DecStructFieldNotFound(-1, yys3)
|
|
|
|
} // end switch yys3
|
|
|
|
} // end for yyj3
|
|
|
|
r.ReadMapEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *Response) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
2018-04-06 20:04:40 +03:00
|
|
|
var yyj7 int
|
|
|
|
var yyb7 bool
|
|
|
|
var yyhl7 bool = l >= 0
|
|
|
|
yyj7++
|
|
|
|
if yyhl7 {
|
|
|
|
yyb7 = yyj7 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb7 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb7 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Action = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Action = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj7++
|
|
|
|
if yyhl7 {
|
|
|
|
yyb7 = yyj7 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb7 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb7 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
2018-04-06 20:04:40 +03:00
|
|
|
if true && x.Node != nil {
|
2017-10-20 08:14:43 +03:00
|
|
|
x.Node = nil
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if x.Node == nil {
|
|
|
|
x.Node = new(Node)
|
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
|
2017-10-20 08:14:43 +03:00
|
|
|
x.Node.CodecDecodeSelf(d)
|
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj7++
|
|
|
|
if yyhl7 {
|
|
|
|
yyb7 = yyj7 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb7 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb7 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
2018-04-06 20:04:40 +03:00
|
|
|
if true && x.PrevNode != nil {
|
2017-10-20 08:14:43 +03:00
|
|
|
x.PrevNode = nil
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if x.PrevNode == nil {
|
|
|
|
x.PrevNode = new(Node)
|
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
|
2017-10-20 08:14:43 +03:00
|
|
|
x.PrevNode.CodecDecodeSelf(d)
|
|
|
|
}
|
|
|
|
for {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj7++
|
|
|
|
if yyhl7 {
|
|
|
|
yyb7 = yyj7 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb7 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb7 {
|
2017-10-20 08:14:43 +03:00
|
|
|
break
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
2018-04-06 20:04:40 +03:00
|
|
|
z.DecStructFieldNotFound(yyj7-1, "")
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *Node) CodecEncodeSelf(e *codec1978.Encoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperEncoder(e)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if x == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.EncExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yysep2 := !z.EncBinary()
|
|
|
|
yy2arr2 := z.EncBasicHandle().StructToArray
|
|
|
|
_, _ = yysep2, yy2arr2
|
2018-04-06 20:04:40 +03:00
|
|
|
const yyr2 bool = false // struct tag has 'toArray'
|
|
|
|
var yyq2 = [8]bool{ // should field at this index be written?
|
|
|
|
true, // Key
|
|
|
|
x.Dir, // Dir
|
|
|
|
true, // Value
|
|
|
|
true, // Nodes
|
|
|
|
true, // CreatedIndex
|
|
|
|
true, // ModifiedIndex
|
|
|
|
x.Expiration != nil, // Expiration
|
|
|
|
x.TTL != 0, // TTL
|
|
|
|
}
|
|
|
|
_ = yyq2
|
2017-10-20 08:14:43 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayStart(8)
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
var yynn2 int
|
2017-10-20 08:14:43 +03:00
|
|
|
for _, b := range yyq2 {
|
|
|
|
if b {
|
|
|
|
yynn2++
|
|
|
|
}
|
|
|
|
}
|
|
|
|
r.WriteMapStart(yynn2)
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Key))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"key\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `key`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Key))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if yyq2[1] {
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Dir))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(false)
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if yyq2[1] {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"dir\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `dir`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Dir))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Value))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"value\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `value`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Value))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if x.Nodes == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
x.Nodes.CodecEncodeSelf(e)
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"nodes\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `nodes`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if x.Nodes == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
x.Nodes.CodecEncodeSelf(e)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeUint(uint64(x.CreatedIndex))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"createdIndex\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `createdIndex`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeUint(uint64(x.CreatedIndex))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeUint(uint64(x.ModifiedIndex))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"modifiedIndex\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `modifiedIndex`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeUint(uint64(x.ModifiedIndex))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
var yyn21 bool
|
|
|
|
if x.Expiration == nil {
|
|
|
|
yyn21 = true
|
|
|
|
goto LABEL21
|
|
|
|
}
|
|
|
|
LABEL21:
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
if yyn21 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if yyq2[6] {
|
|
|
|
if x.Expiration == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
2018-04-09 19:57:10 +03:00
|
|
|
yy22 := *x.Expiration
|
2017-10-20 08:14:43 +03:00
|
|
|
if false {
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if !z.EncBasicHandle().TimeNotBuiltin {
|
2018-04-09 19:57:10 +03:00
|
|
|
r.EncodeTime(yy22)
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if yyxt23 := z.Extension(z.I2Rtid(yy22)); yyxt23 != nil {
|
|
|
|
z.EncExtension(yy22, yyxt23)
|
|
|
|
} else if z.EncBinary() {
|
|
|
|
z.EncBinaryMarshal(yy22)
|
|
|
|
} else if !z.EncBinary() && z.IsJSONHandle() {
|
|
|
|
z.EncJSONMarshal(yy22)
|
|
|
|
} else {
|
|
|
|
z.EncFallback(yy22)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.EncodeNil()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if yyq2[6] {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"expiration\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `expiration`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if yyn21 {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
if x.Expiration == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
2018-04-09 19:57:10 +03:00
|
|
|
yy24 := *x.Expiration
|
2017-10-20 08:14:43 +03:00
|
|
|
if false {
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if !z.EncBasicHandle().TimeNotBuiltin {
|
2018-04-09 19:57:10 +03:00
|
|
|
r.EncodeTime(yy24)
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if yyxt25 := z.Extension(z.I2Rtid(yy24)); yyxt25 != nil {
|
|
|
|
z.EncExtension(yy24, yyxt25)
|
|
|
|
} else if z.EncBinary() {
|
|
|
|
z.EncBinaryMarshal(yy24)
|
|
|
|
} else if !z.EncBinary() && z.IsJSONHandle() {
|
|
|
|
z.EncJSONMarshal(yy24)
|
|
|
|
} else {
|
|
|
|
z.EncFallback(yy24)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if yyq2[7] {
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeInt(int64(x.TTL))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.EncodeInt(0)
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if yyq2[7] {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"ttl\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `ttl`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeInt(int64(x.TTL))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayEnd()
|
|
|
|
} else {
|
|
|
|
r.WriteMapEnd()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *Node) CodecDecodeSelf(d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.DecExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yyct2 := r.ContainerType()
|
2019-02-25 07:07:40 +03:00
|
|
|
if yyct2 == codecSelferValueTypeMap9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadMapStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadMapEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromMap(yyl2, d)
|
|
|
|
}
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if yyct2 == codecSelferValueTypeArray9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadArrayStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromArray(yyl2, d)
|
|
|
|
}
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
panic(errCodecSelferOnlyMapOrArrayEncodeToStruct9381)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *Node) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
var yyhl3 bool = l >= 0
|
|
|
|
for yyj3 := 0; ; yyj3++ {
|
|
|
|
if yyhl3 {
|
|
|
|
if yyj3 >= l {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if r.CheckBreak() {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
}
|
|
|
|
r.ReadMapElemKey()
|
2018-04-06 20:04:40 +03:00
|
|
|
yys3 := z.StringView(r.DecodeStringAsBytes())
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadMapElemValue()
|
|
|
|
switch yys3 {
|
|
|
|
case "key":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Key = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Key = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "dir":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Dir = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Dir = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "value":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Value = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Value = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "nodes":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Nodes = nil
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Nodes.CodecDecodeSelf(d)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "createdIndex":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.CreatedIndex = 0
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.CreatedIndex = (uint64)(r.DecodeUint64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "modifiedIndex":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.ModifiedIndex = 0
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.ModifiedIndex = (uint64)(r.DecodeUint64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "expiration":
|
|
|
|
if r.TryDecodeAsNil() {
|
2018-04-06 20:04:40 +03:00
|
|
|
if true && x.Expiration != nil {
|
2017-10-20 08:14:43 +03:00
|
|
|
x.Expiration = nil
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if x.Expiration == nil {
|
|
|
|
x.Expiration = new(time.Time)
|
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
|
2017-10-20 08:14:43 +03:00
|
|
|
if false {
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if !z.DecBasicHandle().TimeNotBuiltin {
|
2018-04-06 20:04:40 +03:00
|
|
|
*x.Expiration = r.DecodeTime()
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if yyxt11 := z.Extension(z.I2Rtid(x.Expiration)); yyxt11 != nil {
|
|
|
|
z.DecExtension(x.Expiration, yyxt11)
|
|
|
|
} else if z.DecBinary() {
|
|
|
|
z.DecBinaryUnmarshal(x.Expiration)
|
|
|
|
} else if !z.DecBinary() && z.IsJSONHandle() {
|
|
|
|
z.DecJSONUnmarshal(x.Expiration)
|
|
|
|
} else {
|
|
|
|
z.DecFallback(x.Expiration, false)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
case "ttl":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.TTL = 0
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.TTL = (int64)(r.DecodeInt64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
default:
|
|
|
|
z.DecStructFieldNotFound(-1, yys3)
|
|
|
|
} // end switch yys3
|
|
|
|
} // end for yyj3
|
|
|
|
r.ReadMapEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *Node) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
2018-04-06 20:04:40 +03:00
|
|
|
var yyj13 int
|
|
|
|
var yyb13 bool
|
|
|
|
var yyhl13 bool = l >= 0
|
|
|
|
yyj13++
|
|
|
|
if yyhl13 {
|
|
|
|
yyb13 = yyj13 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb13 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb13 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Key = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Key = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj13++
|
|
|
|
if yyhl13 {
|
|
|
|
yyb13 = yyj13 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb13 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb13 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Dir = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Dir = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj13++
|
|
|
|
if yyhl13 {
|
|
|
|
yyb13 = yyj13 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb13 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb13 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Value = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Value = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj13++
|
|
|
|
if yyhl13 {
|
|
|
|
yyb13 = yyj13 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb13 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb13 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Nodes = nil
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Nodes.CodecDecodeSelf(d)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj13++
|
|
|
|
if yyhl13 {
|
|
|
|
yyb13 = yyj13 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb13 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb13 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.CreatedIndex = 0
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.CreatedIndex = (uint64)(r.DecodeUint64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj13++
|
|
|
|
if yyhl13 {
|
|
|
|
yyb13 = yyj13 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb13 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb13 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.ModifiedIndex = 0
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.ModifiedIndex = (uint64)(r.DecodeUint64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj13++
|
|
|
|
if yyhl13 {
|
|
|
|
yyb13 = yyj13 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb13 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb13 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
2018-04-06 20:04:40 +03:00
|
|
|
if true && x.Expiration != nil {
|
2017-10-20 08:14:43 +03:00
|
|
|
x.Expiration = nil
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if x.Expiration == nil {
|
|
|
|
x.Expiration = new(time.Time)
|
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
|
2017-10-20 08:14:43 +03:00
|
|
|
if false {
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if !z.DecBasicHandle().TimeNotBuiltin {
|
2018-04-06 20:04:40 +03:00
|
|
|
*x.Expiration = r.DecodeTime()
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if yyxt21 := z.Extension(z.I2Rtid(x.Expiration)); yyxt21 != nil {
|
|
|
|
z.DecExtension(x.Expiration, yyxt21)
|
|
|
|
} else if z.DecBinary() {
|
|
|
|
z.DecBinaryUnmarshal(x.Expiration)
|
|
|
|
} else if !z.DecBinary() && z.IsJSONHandle() {
|
|
|
|
z.DecJSONUnmarshal(x.Expiration)
|
|
|
|
} else {
|
|
|
|
z.DecFallback(x.Expiration, false)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj13++
|
|
|
|
if yyhl13 {
|
|
|
|
yyb13 = yyj13 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb13 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb13 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.TTL = 0
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.TTL = (int64)(r.DecodeInt64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
for {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj13++
|
|
|
|
if yyhl13 {
|
|
|
|
yyb13 = yyj13 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb13 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb13 {
|
2017-10-20 08:14:43 +03:00
|
|
|
break
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
2018-04-06 20:04:40 +03:00
|
|
|
z.DecStructFieldNotFound(yyj13-1, "")
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x Nodes) CodecEncodeSelf(e *codec1978.Encoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperEncoder(e)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if x == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.EncExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
h.encNodes((Nodes)(x), e)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *Nodes) CodecDecodeSelf(d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.DecExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
h.decNodes((*Nodes)(x), d)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *httpKeysAPI) CodecEncodeSelf(e *codec1978.Encoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperEncoder(e)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if x == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.EncExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yysep2 := !z.EncBinary()
|
|
|
|
yy2arr2 := z.EncBasicHandle().StructToArray
|
|
|
|
_, _ = yysep2, yy2arr2
|
2018-04-06 20:04:40 +03:00
|
|
|
const yyr2 bool = false // struct tag has 'toArray'
|
2017-10-20 08:14:43 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayStart(0)
|
|
|
|
} else {
|
|
|
|
r.WriteMapStart(0)
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayEnd()
|
|
|
|
} else {
|
|
|
|
r.WriteMapEnd()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *httpKeysAPI) CodecDecodeSelf(d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.DecExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yyct2 := r.ContainerType()
|
2019-02-25 07:07:40 +03:00
|
|
|
if yyct2 == codecSelferValueTypeMap9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadMapStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadMapEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromMap(yyl2, d)
|
|
|
|
}
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if yyct2 == codecSelferValueTypeArray9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadArrayStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromArray(yyl2, d)
|
|
|
|
}
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
panic(errCodecSelferOnlyMapOrArrayEncodeToStruct9381)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *httpKeysAPI) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
var yyhl3 bool = l >= 0
|
|
|
|
for yyj3 := 0; ; yyj3++ {
|
|
|
|
if yyhl3 {
|
|
|
|
if yyj3 >= l {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if r.CheckBreak() {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
}
|
|
|
|
r.ReadMapElemKey()
|
2018-04-06 20:04:40 +03:00
|
|
|
yys3 := z.StringView(r.DecodeStringAsBytes())
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadMapElemValue()
|
|
|
|
switch yys3 {
|
|
|
|
default:
|
|
|
|
z.DecStructFieldNotFound(-1, yys3)
|
|
|
|
} // end switch yys3
|
|
|
|
} // end for yyj3
|
|
|
|
r.ReadMapEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *httpKeysAPI) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
var yyj4 int
|
|
|
|
var yyb4 bool
|
|
|
|
var yyhl4 bool = l >= 0
|
|
|
|
for {
|
|
|
|
yyj4++
|
|
|
|
if yyhl4 {
|
|
|
|
yyb4 = yyj4 > l
|
|
|
|
} else {
|
|
|
|
yyb4 = r.CheckBreak()
|
|
|
|
}
|
|
|
|
if yyb4 {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
z.DecStructFieldNotFound(yyj4-1, "")
|
|
|
|
}
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *httpWatcher) CodecEncodeSelf(e *codec1978.Encoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperEncoder(e)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if x == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.EncExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yysep2 := !z.EncBinary()
|
|
|
|
yy2arr2 := z.EncBasicHandle().StructToArray
|
|
|
|
_, _ = yysep2, yy2arr2
|
2018-04-06 20:04:40 +03:00
|
|
|
const yyr2 bool = false // struct tag has 'toArray'
|
2017-10-20 08:14:43 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayStart(0)
|
|
|
|
} else {
|
|
|
|
r.WriteMapStart(0)
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayEnd()
|
|
|
|
} else {
|
|
|
|
r.WriteMapEnd()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *httpWatcher) CodecDecodeSelf(d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.DecExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yyct2 := r.ContainerType()
|
2019-02-25 07:07:40 +03:00
|
|
|
if yyct2 == codecSelferValueTypeMap9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadMapStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadMapEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromMap(yyl2, d)
|
|
|
|
}
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if yyct2 == codecSelferValueTypeArray9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadArrayStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromArray(yyl2, d)
|
|
|
|
}
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
panic(errCodecSelferOnlyMapOrArrayEncodeToStruct9381)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *httpWatcher) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
var yyhl3 bool = l >= 0
|
|
|
|
for yyj3 := 0; ; yyj3++ {
|
|
|
|
if yyhl3 {
|
|
|
|
if yyj3 >= l {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if r.CheckBreak() {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
}
|
|
|
|
r.ReadMapElemKey()
|
2018-04-06 20:04:40 +03:00
|
|
|
yys3 := z.StringView(r.DecodeStringAsBytes())
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadMapElemValue()
|
|
|
|
switch yys3 {
|
|
|
|
default:
|
|
|
|
z.DecStructFieldNotFound(-1, yys3)
|
|
|
|
} // end switch yys3
|
|
|
|
} // end for yyj3
|
|
|
|
r.ReadMapEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *httpWatcher) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
var yyj4 int
|
|
|
|
var yyb4 bool
|
|
|
|
var yyhl4 bool = l >= 0
|
|
|
|
for {
|
|
|
|
yyj4++
|
|
|
|
if yyhl4 {
|
|
|
|
yyb4 = yyj4 > l
|
|
|
|
} else {
|
|
|
|
yyb4 = r.CheckBreak()
|
|
|
|
}
|
|
|
|
if yyb4 {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
z.DecStructFieldNotFound(yyj4-1, "")
|
|
|
|
}
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *getAction) CodecEncodeSelf(e *codec1978.Encoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperEncoder(e)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if x == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.EncExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yysep2 := !z.EncBinary()
|
|
|
|
yy2arr2 := z.EncBasicHandle().StructToArray
|
|
|
|
_, _ = yysep2, yy2arr2
|
2018-04-06 20:04:40 +03:00
|
|
|
const yyr2 bool = false // struct tag has 'toArray'
|
2017-10-20 08:14:43 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayStart(5)
|
|
|
|
} else {
|
|
|
|
r.WriteMapStart(5)
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Prefix))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Prefix\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Prefix`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Prefix))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Key))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Key\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Key`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Key))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Recursive))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Recursive\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Recursive`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Recursive))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Sorted))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Sorted\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Sorted`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Sorted))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Quorum))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Quorum\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Quorum`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Quorum))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayEnd()
|
|
|
|
} else {
|
|
|
|
r.WriteMapEnd()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *getAction) CodecDecodeSelf(d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.DecExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yyct2 := r.ContainerType()
|
2019-02-25 07:07:40 +03:00
|
|
|
if yyct2 == codecSelferValueTypeMap9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadMapStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadMapEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromMap(yyl2, d)
|
|
|
|
}
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if yyct2 == codecSelferValueTypeArray9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadArrayStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromArray(yyl2, d)
|
|
|
|
}
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
panic(errCodecSelferOnlyMapOrArrayEncodeToStruct9381)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *getAction) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
var yyhl3 bool = l >= 0
|
|
|
|
for yyj3 := 0; ; yyj3++ {
|
|
|
|
if yyhl3 {
|
|
|
|
if yyj3 >= l {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if r.CheckBreak() {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
}
|
|
|
|
r.ReadMapElemKey()
|
2018-04-06 20:04:40 +03:00
|
|
|
yys3 := z.StringView(r.DecodeStringAsBytes())
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadMapElemValue()
|
|
|
|
switch yys3 {
|
|
|
|
case "Prefix":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Prefix = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Prefix = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "Key":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Key = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Key = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "Recursive":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Recursive = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Recursive = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "Sorted":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Sorted = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Sorted = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "Quorum":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Quorum = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Quorum = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
default:
|
|
|
|
z.DecStructFieldNotFound(-1, yys3)
|
|
|
|
} // end switch yys3
|
|
|
|
} // end for yyj3
|
|
|
|
r.ReadMapEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *getAction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
2018-04-06 20:04:40 +03:00
|
|
|
var yyj9 int
|
|
|
|
var yyb9 bool
|
|
|
|
var yyhl9 bool = l >= 0
|
|
|
|
yyj9++
|
|
|
|
if yyhl9 {
|
|
|
|
yyb9 = yyj9 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb9 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb9 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Prefix = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Prefix = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj9++
|
|
|
|
if yyhl9 {
|
|
|
|
yyb9 = yyj9 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb9 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb9 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Key = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Key = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj9++
|
|
|
|
if yyhl9 {
|
|
|
|
yyb9 = yyj9 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb9 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb9 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Recursive = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Recursive = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj9++
|
|
|
|
if yyhl9 {
|
|
|
|
yyb9 = yyj9 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb9 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb9 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Sorted = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Sorted = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj9++
|
|
|
|
if yyhl9 {
|
|
|
|
yyb9 = yyj9 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb9 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb9 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Quorum = false
|
|
|
|
} else {
|
|
|
|
x.Quorum = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
for {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj9++
|
|
|
|
if yyhl9 {
|
|
|
|
yyb9 = yyj9 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb9 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb9 {
|
2017-10-20 08:14:43 +03:00
|
|
|
break
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
2018-04-06 20:04:40 +03:00
|
|
|
z.DecStructFieldNotFound(yyj9-1, "")
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *waitAction) CodecEncodeSelf(e *codec1978.Encoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperEncoder(e)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if x == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.EncExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yysep2 := !z.EncBinary()
|
|
|
|
yy2arr2 := z.EncBasicHandle().StructToArray
|
|
|
|
_, _ = yysep2, yy2arr2
|
2018-04-06 20:04:40 +03:00
|
|
|
const yyr2 bool = false // struct tag has 'toArray'
|
2017-10-20 08:14:43 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayStart(4)
|
|
|
|
} else {
|
|
|
|
r.WriteMapStart(4)
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Prefix))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Prefix\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Prefix`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Prefix))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Key))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Key\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Key`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Key))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeUint(uint64(x.WaitIndex))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"WaitIndex\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `WaitIndex`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeUint(uint64(x.WaitIndex))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Recursive))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Recursive\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Recursive`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Recursive))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayEnd()
|
|
|
|
} else {
|
|
|
|
r.WriteMapEnd()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *waitAction) CodecDecodeSelf(d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.DecExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yyct2 := r.ContainerType()
|
2019-02-25 07:07:40 +03:00
|
|
|
if yyct2 == codecSelferValueTypeMap9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadMapStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadMapEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromMap(yyl2, d)
|
|
|
|
}
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if yyct2 == codecSelferValueTypeArray9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadArrayStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromArray(yyl2, d)
|
|
|
|
}
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
panic(errCodecSelferOnlyMapOrArrayEncodeToStruct9381)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *waitAction) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
var yyhl3 bool = l >= 0
|
|
|
|
for yyj3 := 0; ; yyj3++ {
|
|
|
|
if yyhl3 {
|
|
|
|
if yyj3 >= l {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if r.CheckBreak() {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
}
|
|
|
|
r.ReadMapElemKey()
|
2018-04-06 20:04:40 +03:00
|
|
|
yys3 := z.StringView(r.DecodeStringAsBytes())
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadMapElemValue()
|
|
|
|
switch yys3 {
|
|
|
|
case "Prefix":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Prefix = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Prefix = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "Key":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Key = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Key = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "WaitIndex":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.WaitIndex = 0
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.WaitIndex = (uint64)(r.DecodeUint64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "Recursive":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Recursive = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Recursive = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
default:
|
|
|
|
z.DecStructFieldNotFound(-1, yys3)
|
|
|
|
} // end switch yys3
|
|
|
|
} // end for yyj3
|
|
|
|
r.ReadMapEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *waitAction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
2018-04-06 20:04:40 +03:00
|
|
|
var yyj8 int
|
|
|
|
var yyb8 bool
|
|
|
|
var yyhl8 bool = l >= 0
|
|
|
|
yyj8++
|
|
|
|
if yyhl8 {
|
|
|
|
yyb8 = yyj8 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb8 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb8 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Prefix = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Prefix = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj8++
|
|
|
|
if yyhl8 {
|
|
|
|
yyb8 = yyj8 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb8 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb8 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Key = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Key = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj8++
|
|
|
|
if yyhl8 {
|
|
|
|
yyb8 = yyj8 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb8 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb8 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.WaitIndex = 0
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.WaitIndex = (uint64)(r.DecodeUint64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj8++
|
|
|
|
if yyhl8 {
|
|
|
|
yyb8 = yyj8 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb8 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb8 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Recursive = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Recursive = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
for {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj8++
|
|
|
|
if yyhl8 {
|
|
|
|
yyb8 = yyj8 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb8 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb8 {
|
2017-10-20 08:14:43 +03:00
|
|
|
break
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
2018-04-06 20:04:40 +03:00
|
|
|
z.DecStructFieldNotFound(yyj8-1, "")
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *setAction) CodecEncodeSelf(e *codec1978.Encoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperEncoder(e)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if x == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.EncExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yysep2 := !z.EncBinary()
|
|
|
|
yy2arr2 := z.EncBasicHandle().StructToArray
|
|
|
|
_, _ = yysep2, yy2arr2
|
2018-04-06 20:04:40 +03:00
|
|
|
const yyr2 bool = false // struct tag has 'toArray'
|
2017-10-20 08:14:43 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayStart(10)
|
|
|
|
} else {
|
|
|
|
r.WriteMapStart(10)
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Prefix))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Prefix\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Prefix`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Prefix))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Key))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Key\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Key`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Key))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Value))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Value\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Value`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Value))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.PrevValue))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"PrevValue\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `PrevValue`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.PrevValue))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeUint(uint64(x.PrevIndex))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"PrevIndex\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `PrevIndex`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeUint(uint64(x.PrevIndex))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
x.PrevExist.CodecEncodeSelf(e)
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"PrevExist\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `PrevExist`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
x.PrevExist.CodecEncodeSelf(e)
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt22 := z.Extension(z.I2Rtid(x.TTL)); yyxt22 != nil {
|
|
|
|
z.EncExtension(x.TTL, yyxt22)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
r.EncodeInt(int64(x.TTL))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"TTL\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `TTL`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt23 := z.Extension(z.I2Rtid(x.TTL)); yyxt23 != nil {
|
|
|
|
z.EncExtension(x.TTL, yyxt23)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
r.EncodeInt(int64(x.TTL))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Refresh))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Refresh\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Refresh`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Refresh))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Dir))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Dir\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Dir`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Dir))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.NoValueOnSuccess))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"NoValueOnSuccess\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `NoValueOnSuccess`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.NoValueOnSuccess))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayEnd()
|
|
|
|
} else {
|
|
|
|
r.WriteMapEnd()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *setAction) CodecDecodeSelf(d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.DecExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yyct2 := r.ContainerType()
|
2019-02-25 07:07:40 +03:00
|
|
|
if yyct2 == codecSelferValueTypeMap9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadMapStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadMapEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromMap(yyl2, d)
|
|
|
|
}
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if yyct2 == codecSelferValueTypeArray9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadArrayStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromArray(yyl2, d)
|
|
|
|
}
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
panic(errCodecSelferOnlyMapOrArrayEncodeToStruct9381)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *setAction) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
var yyhl3 bool = l >= 0
|
|
|
|
for yyj3 := 0; ; yyj3++ {
|
|
|
|
if yyhl3 {
|
|
|
|
if yyj3 >= l {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if r.CheckBreak() {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
}
|
|
|
|
r.ReadMapElemKey()
|
2018-04-06 20:04:40 +03:00
|
|
|
yys3 := z.StringView(r.DecodeStringAsBytes())
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadMapElemValue()
|
|
|
|
switch yys3 {
|
|
|
|
case "Prefix":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Prefix = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Prefix = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "Key":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Key = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Key = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "Value":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Value = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Value = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "PrevValue":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.PrevValue = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.PrevValue = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "PrevIndex":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.PrevIndex = 0
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.PrevIndex = (uint64)(r.DecodeUint64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "PrevExist":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.PrevExist = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.PrevExist.CodecDecodeSelf(d)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "TTL":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.TTL = 0
|
|
|
|
} else {
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt11 := z.Extension(z.I2Rtid(x.TTL)); yyxt11 != nil {
|
|
|
|
z.DecExtension(x.TTL, yyxt11)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.TTL = (time.Duration)(r.DecodeInt64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
case "Refresh":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Refresh = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Refresh = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "Dir":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Dir = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Dir = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "NoValueOnSuccess":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.NoValueOnSuccess = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.NoValueOnSuccess = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
default:
|
|
|
|
z.DecStructFieldNotFound(-1, yys3)
|
|
|
|
} // end switch yys3
|
|
|
|
} // end for yyj3
|
|
|
|
r.ReadMapEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *setAction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
2018-04-06 20:04:40 +03:00
|
|
|
var yyj15 int
|
|
|
|
var yyb15 bool
|
|
|
|
var yyhl15 bool = l >= 0
|
|
|
|
yyj15++
|
|
|
|
if yyhl15 {
|
|
|
|
yyb15 = yyj15 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb15 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb15 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Prefix = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Prefix = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj15++
|
|
|
|
if yyhl15 {
|
|
|
|
yyb15 = yyj15 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb15 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb15 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Key = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Key = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj15++
|
|
|
|
if yyhl15 {
|
|
|
|
yyb15 = yyj15 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb15 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb15 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Value = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Value = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj15++
|
|
|
|
if yyhl15 {
|
|
|
|
yyb15 = yyj15 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb15 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb15 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.PrevValue = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.PrevValue = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj15++
|
|
|
|
if yyhl15 {
|
|
|
|
yyb15 = yyj15 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb15 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb15 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.PrevIndex = 0
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.PrevIndex = (uint64)(r.DecodeUint64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj15++
|
|
|
|
if yyhl15 {
|
|
|
|
yyb15 = yyj15 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb15 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb15 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.PrevExist = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.PrevExist.CodecDecodeSelf(d)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj15++
|
|
|
|
if yyhl15 {
|
|
|
|
yyb15 = yyj15 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb15 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb15 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.TTL = 0
|
|
|
|
} else {
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt23 := z.Extension(z.I2Rtid(x.TTL)); yyxt23 != nil {
|
|
|
|
z.DecExtension(x.TTL, yyxt23)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.TTL = (time.Duration)(r.DecodeInt64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj15++
|
|
|
|
if yyhl15 {
|
|
|
|
yyb15 = yyj15 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb15 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb15 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Refresh = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Refresh = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj15++
|
|
|
|
if yyhl15 {
|
|
|
|
yyb15 = yyj15 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb15 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb15 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Dir = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Dir = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj15++
|
|
|
|
if yyhl15 {
|
|
|
|
yyb15 = yyj15 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb15 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb15 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.NoValueOnSuccess = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.NoValueOnSuccess = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
for {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj15++
|
|
|
|
if yyhl15 {
|
|
|
|
yyb15 = yyj15 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb15 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb15 {
|
2017-10-20 08:14:43 +03:00
|
|
|
break
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
2018-04-06 20:04:40 +03:00
|
|
|
z.DecStructFieldNotFound(yyj15-1, "")
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *deleteAction) CodecEncodeSelf(e *codec1978.Encoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperEncoder(e)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if x == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.EncExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yysep2 := !z.EncBinary()
|
|
|
|
yy2arr2 := z.EncBasicHandle().StructToArray
|
|
|
|
_, _ = yysep2, yy2arr2
|
2018-04-06 20:04:40 +03:00
|
|
|
const yyr2 bool = false // struct tag has 'toArray'
|
2017-10-20 08:14:43 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayStart(6)
|
|
|
|
} else {
|
|
|
|
r.WriteMapStart(6)
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Prefix))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Prefix\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Prefix`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Prefix))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Key))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Key\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Key`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Key))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.PrevValue))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"PrevValue\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `PrevValue`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.PrevValue))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeUint(uint64(x.PrevIndex))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"PrevIndex\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `PrevIndex`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeUint(uint64(x.PrevIndex))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Dir))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Dir\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Dir`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Dir))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
|
|
|
r.EncodeBool(bool(x.Recursive))
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Recursive\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Recursive`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
2015-10-08 12:27:00 +03:00
|
|
|
if false {
|
|
|
|
} else {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.EncodeBool(bool(x.Recursive))
|
2015-10-08 12:27:00 +03:00
|
|
|
}
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2016-12-05 19:06:42 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteArrayEnd()
|
|
|
|
} else {
|
|
|
|
r.WriteMapEnd()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *deleteAction) CodecDecodeSelf(d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.DecExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yyct2 := r.ContainerType()
|
2019-02-25 07:07:40 +03:00
|
|
|
if yyct2 == codecSelferValueTypeMap9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadMapStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadMapEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromMap(yyl2, d)
|
|
|
|
}
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if yyct2 == codecSelferValueTypeArray9381 {
|
2017-10-20 08:14:43 +03:00
|
|
|
yyl2 := r.ReadArrayStart()
|
|
|
|
if yyl2 == 0 {
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
} else {
|
|
|
|
x.codecDecodeSelfFromArray(yyl2, d)
|
|
|
|
}
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
panic(errCodecSelferOnlyMapOrArrayEncodeToStruct9381)
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *deleteAction) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
var yyhl3 bool = l >= 0
|
|
|
|
for yyj3 := 0; ; yyj3++ {
|
|
|
|
if yyhl3 {
|
|
|
|
if yyj3 >= l {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if r.CheckBreak() {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
}
|
|
|
|
r.ReadMapElemKey()
|
2018-04-06 20:04:40 +03:00
|
|
|
yys3 := z.StringView(r.DecodeStringAsBytes())
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadMapElemValue()
|
|
|
|
switch yys3 {
|
|
|
|
case "Prefix":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Prefix = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Prefix = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "Key":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Key = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Key = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "PrevValue":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.PrevValue = ""
|
2015-10-08 12:27:00 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.PrevValue = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "PrevIndex":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.PrevIndex = 0
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.PrevIndex = (uint64)(r.DecodeUint64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "Dir":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Dir = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Dir = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
case "Recursive":
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Recursive = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Recursive = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
default:
|
|
|
|
z.DecStructFieldNotFound(-1, yys3)
|
|
|
|
} // end switch yys3
|
|
|
|
} // end for yyj3
|
|
|
|
r.ReadMapEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *deleteAction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
2018-04-06 20:04:40 +03:00
|
|
|
var yyj10 int
|
|
|
|
var yyb10 bool
|
|
|
|
var yyhl10 bool = l >= 0
|
|
|
|
yyj10++
|
|
|
|
if yyhl10 {
|
|
|
|
yyb10 = yyj10 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb10 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb10 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Prefix = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Prefix = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj10++
|
|
|
|
if yyhl10 {
|
|
|
|
yyb10 = yyj10 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb10 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb10 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Key = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Key = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj10++
|
|
|
|
if yyhl10 {
|
|
|
|
yyb10 = yyj10 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb10 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb10 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.PrevValue = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.PrevValue = (string)(r.DecodeString())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj10++
|
|
|
|
if yyhl10 {
|
|
|
|
yyb10 = yyj10 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb10 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb10 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.PrevIndex = 0
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.PrevIndex = (uint64)(r.DecodeUint64())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj10++
|
|
|
|
if yyhl10 {
|
|
|
|
yyb10 = yyj10 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb10 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb10 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Dir = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Dir = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj10++
|
|
|
|
if yyhl10 {
|
|
|
|
yyb10 = yyj10 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb10 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb10 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Recursive = false
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Recursive = (bool)(r.DecodeBool())
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
for {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj10++
|
|
|
|
if yyhl10 {
|
|
|
|
yyb10 = yyj10 > l
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb10 = r.CheckBreak()
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb10 {
|
2017-10-20 08:14:43 +03:00
|
|
|
break
|
|
|
|
}
|
|
|
|
r.ReadArrayElem()
|
2018-04-06 20:04:40 +03:00
|
|
|
z.DecStructFieldNotFound(yyj10-1, "")
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
r.ReadArrayEnd()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (x *createInOrderAction) CodecEncodeSelf(e *codec1978.Encoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2017-10-20 08:14:43 +03:00
|
|
|
z, r := codec1978.GenHelperEncoder(e)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
if x == nil {
|
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.EncExtension(x, yyxt1)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
yysep2 := !z.EncBinary()
|
|
|
|
yy2arr2 := z.EncBasicHandle().StructToArray
|
|
|
|
_, _ = yysep2, yy2arr2
|
2018-04-06 20:04:40 +03:00
|
|
|
const yyr2 bool = false // struct tag has 'toArray'
|
2017-10-20 08:14:43 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayStart(4)
|
|
|
|
} else {
|
|
|
|
r.WriteMapStart(4)
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Prefix))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Prefix\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Prefix`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Prefix))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Dir))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Dir\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Dir`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Dir))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyr2 || yy2arr2 {
|
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Value))
|
2017-10-20 08:14:43 +03:00
|
|
|
}
|
|
|
|
} else {
|
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"Value\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `Value`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, string(x.Value))
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
|
|
|
}
|
2016-12-05 19:06:42 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteArrayElem()
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt13 := z.Extension(z.I2Rtid(x.TTL)); yyxt13 != nil {
|
|
|
|
z.EncExtension(x.TTL, yyxt13)
|
2015-10-08 12:27:00 +03:00
|
|
|
} else {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.EncodeInt(int64(x.TTL))
|
2015-10-08 12:27:00 +03:00
|
|
|
}
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemKey()
|
2019-02-25 07:07:40 +03:00
|
|
|
if z.IsJSONHandle() {
|
|
|
|
z.WriteStr("\"TTL\"")
|
|
|
|
} else {
|
|
|
|
r.EncodeStringEnc(codecSelferCcUTF89381, `TTL`)
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapElemValue()
|
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt14 := z.Extension(z.I2Rtid(x.TTL)); yyxt14 != nil {
|
|
|
|
z.EncExtension(x.TTL, yyxt14)
|
2017-10-20 08:14:43 +03:00
|
|
|
} else {
|
|
|
|
r.EncodeInt(int64(x.TTL))
|
2015-10-08 12:27:00 +03:00
|
|
|
}
|
|
|
|
}
|
2016-12-05 19:06:42 +03:00
|
|
|
if yyr2 || yy2arr2 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteArrayEnd()
|
2015-11-02 14:03:40 +03:00
|
|
|
} else {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteMapEnd()
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-10-20 08:14:43 +03:00
|
|
|
func (x *createInOrderAction) CodecDecodeSelf(d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2015-08-17 03:41:14 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
2015-10-08 12:27:00 +03:00
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt1 := z.Extension(z.I2Rtid(x)); yyxt1 != nil {
|
|
|
|
z.DecExtension(x, yyxt1)
|
2015-10-08 12:27:00 +03:00
|
|
|
} else {
|
2016-12-05 19:06:42 +03:00
|
|
|
yyct2 := r.ContainerType()
|
2019-02-25 07:07:40 +03:00
|
|
|
if yyct2 == codecSelferValueTypeMap9381 {
|
2016-12-05 19:06:42 +03:00
|
|
|
yyl2 := r.ReadMapStart()
|
|
|
|
if yyl2 == 0 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadMapEnd()
|
2015-10-08 12:27:00 +03:00
|
|
|
} else {
|
2016-12-05 19:06:42 +03:00
|
|
|
x.codecDecodeSelfFromMap(yyl2, d)
|
2015-10-08 12:27:00 +03:00
|
|
|
}
|
2019-02-25 07:07:40 +03:00
|
|
|
} else if yyct2 == codecSelferValueTypeArray9381 {
|
2016-12-05 19:06:42 +03:00
|
|
|
yyl2 := r.ReadArrayStart()
|
|
|
|
if yyl2 == 0 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
2015-10-08 12:27:00 +03:00
|
|
|
} else {
|
2016-12-05 19:06:42 +03:00
|
|
|
x.codecDecodeSelfFromArray(yyl2, d)
|
2015-10-08 12:27:00 +03:00
|
|
|
}
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2019-02-25 07:07:40 +03:00
|
|
|
panic(errCodecSelferOnlyMapOrArrayEncodeToStruct9381)
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-10-20 08:14:43 +03:00
|
|
|
func (x *createInOrderAction) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2015-08-17 03:41:14 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
2016-12-05 19:06:42 +03:00
|
|
|
var yyhl3 bool = l >= 0
|
|
|
|
for yyj3 := 0; ; yyj3++ {
|
|
|
|
if yyhl3 {
|
|
|
|
if yyj3 >= l {
|
2015-08-17 03:41:14 +03:00
|
|
|
break
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
if r.CheckBreak() {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadMapElemKey()
|
2018-04-06 20:04:40 +03:00
|
|
|
yys3 := z.StringView(r.DecodeStringAsBytes())
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadMapElemValue()
|
2016-12-05 19:06:42 +03:00
|
|
|
switch yys3 {
|
2017-10-20 08:14:43 +03:00
|
|
|
case "Prefix":
|
2015-08-17 03:41:14 +03:00
|
|
|
if r.TryDecodeAsNil() {
|
2017-10-20 08:14:43 +03:00
|
|
|
x.Prefix = ""
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Prefix = (string)(r.DecodeString())
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
case "Dir":
|
2015-08-17 03:41:14 +03:00
|
|
|
if r.TryDecodeAsNil() {
|
2017-10-20 08:14:43 +03:00
|
|
|
x.Dir = ""
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Dir = (string)(r.DecodeString())
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
case "Value":
|
2015-08-17 03:41:14 +03:00
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Value = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Value = (string)(r.DecodeString())
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
case "TTL":
|
2015-08-17 03:41:14 +03:00
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.TTL = 0
|
|
|
|
} else {
|
2016-12-05 19:06:42 +03:00
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt8 := z.Extension(z.I2Rtid(x.TTL)); yyxt8 != nil {
|
|
|
|
z.DecExtension(x.TTL, yyxt8)
|
2016-12-05 19:06:42 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.TTL = (time.Duration)(r.DecodeInt64())
|
2016-12-05 19:06:42 +03:00
|
|
|
}
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
|
|
|
default:
|
2016-12-05 19:06:42 +03:00
|
|
|
z.DecStructFieldNotFound(-1, yys3)
|
|
|
|
} // end switch yys3
|
|
|
|
} // end for yyj3
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadMapEnd()
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
|
|
|
|
2017-10-20 08:14:43 +03:00
|
|
|
func (x *createInOrderAction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
|
2019-02-25 07:07:40 +03:00
|
|
|
var h codecSelfer9381
|
2015-08-17 03:41:14 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
2018-04-06 20:04:40 +03:00
|
|
|
var yyj9 int
|
|
|
|
var yyb9 bool
|
|
|
|
var yyhl9 bool = l >= 0
|
|
|
|
yyj9++
|
|
|
|
if yyhl9 {
|
|
|
|
yyb9 = yyj9 > l
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb9 = r.CheckBreak()
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb9 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
2015-08-17 03:41:14 +03:00
|
|
|
return
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayElem()
|
2015-08-17 03:41:14 +03:00
|
|
|
if r.TryDecodeAsNil() {
|
2017-10-20 08:14:43 +03:00
|
|
|
x.Prefix = ""
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Prefix = (string)(r.DecodeString())
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj9++
|
|
|
|
if yyhl9 {
|
|
|
|
yyb9 = yyj9 > l
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb9 = r.CheckBreak()
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb9 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
2015-08-17 03:41:14 +03:00
|
|
|
return
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayElem()
|
2015-08-17 03:41:14 +03:00
|
|
|
if r.TryDecodeAsNil() {
|
2017-10-20 08:14:43 +03:00
|
|
|
x.Dir = ""
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Dir = (string)(r.DecodeString())
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj9++
|
|
|
|
if yyhl9 {
|
|
|
|
yyb9 = yyj9 > l
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb9 = r.CheckBreak()
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb9 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
2015-08-17 03:41:14 +03:00
|
|
|
return
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayElem()
|
2015-08-17 03:41:14 +03:00
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.Value = ""
|
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.Value = (string)(r.DecodeString())
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj9++
|
|
|
|
if yyhl9 {
|
|
|
|
yyb9 = yyj9 > l
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb9 = r.CheckBreak()
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb9 {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
2015-08-17 03:41:14 +03:00
|
|
|
return
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayElem()
|
2015-08-17 03:41:14 +03:00
|
|
|
if r.TryDecodeAsNil() {
|
|
|
|
x.TTL = 0
|
|
|
|
} else {
|
2016-12-05 19:06:42 +03:00
|
|
|
if false {
|
2018-04-06 20:04:40 +03:00
|
|
|
} else if yyxt14 := z.Extension(z.I2Rtid(x.TTL)); yyxt14 != nil {
|
|
|
|
z.DecExtension(x.TTL, yyxt14)
|
2016-12-05 19:06:42 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
x.TTL = (time.Duration)(r.DecodeInt64())
|
2016-12-05 19:06:42 +03:00
|
|
|
}
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
|
|
|
for {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyj9++
|
|
|
|
if yyhl9 {
|
|
|
|
yyb9 = yyj9 > l
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyb9 = r.CheckBreak()
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyb9 {
|
2015-08-17 03:41:14 +03:00
|
|
|
break
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayElem()
|
2018-04-06 20:04:40 +03:00
|
|
|
z.DecStructFieldNotFound(yyj9-1, "")
|
2015-09-10 21:51:59 +03:00
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.ReadArrayEnd()
|
2015-09-10 21:51:59 +03:00
|
|
|
}
|
|
|
|
|
2019-02-25 07:07:40 +03:00
|
|
|
func (x codecSelfer9381) encNodes(v Nodes, e *codec1978.Encoder) {
|
|
|
|
var h codecSelfer9381
|
2015-08-17 03:41:14 +03:00
|
|
|
z, r := codec1978.GenHelperEncoder(e)
|
|
|
|
_, _, _ = h, z, r
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteArrayStart(len(v))
|
2016-12-05 19:06:42 +03:00
|
|
|
for _, yyv1 := range v {
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteArrayElem()
|
2016-12-05 19:06:42 +03:00
|
|
|
if yyv1 == nil {
|
2015-10-08 12:27:00 +03:00
|
|
|
r.EncodeNil()
|
|
|
|
} else {
|
2016-12-05 19:06:42 +03:00
|
|
|
yyv1.CodecEncodeSelf(e)
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
r.WriteArrayEnd()
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
|
|
|
|
2019-02-25 07:07:40 +03:00
|
|
|
func (x codecSelfer9381) decNodes(v *Nodes, d *codec1978.Decoder) {
|
|
|
|
var h codecSelfer9381
|
2015-08-17 03:41:14 +03:00
|
|
|
z, r := codec1978.GenHelperDecoder(d)
|
|
|
|
_, _, _ = h, z, r
|
|
|
|
|
2016-12-05 19:06:42 +03:00
|
|
|
yyv1 := *v
|
|
|
|
yyh1, yyl1 := z.DecSliceHelperStart()
|
|
|
|
var yyc1 bool
|
|
|
|
_ = yyc1
|
|
|
|
if yyl1 == 0 {
|
|
|
|
if yyv1 == nil {
|
|
|
|
yyv1 = []*Node{}
|
|
|
|
yyc1 = true
|
|
|
|
} else if len(yyv1) != 0 {
|
|
|
|
yyv1 = yyv1[:0]
|
|
|
|
yyc1 = true
|
|
|
|
}
|
2017-09-19 16:14:58 +03:00
|
|
|
} else {
|
|
|
|
yyhl1 := yyl1 > 0
|
|
|
|
var yyrl1 int
|
2017-10-20 08:14:43 +03:00
|
|
|
_ = yyrl1
|
2017-09-19 16:14:58 +03:00
|
|
|
if yyhl1 {
|
|
|
|
if yyl1 > cap(yyv1) {
|
|
|
|
yyrl1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8)
|
2016-12-05 19:06:42 +03:00
|
|
|
if yyrl1 <= cap(yyv1) {
|
|
|
|
yyv1 = yyv1[:yyrl1]
|
2015-11-02 14:03:40 +03:00
|
|
|
} else {
|
2016-12-05 19:06:42 +03:00
|
|
|
yyv1 = make([]*Node, yyrl1)
|
2015-11-02 14:03:40 +03:00
|
|
|
}
|
2017-09-19 16:14:58 +03:00
|
|
|
yyc1 = true
|
|
|
|
} else if yyl1 != len(yyv1) {
|
|
|
|
yyv1 = yyv1[:yyl1]
|
|
|
|
yyc1 = true
|
2015-11-02 14:03:40 +03:00
|
|
|
}
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
var yyj1 int
|
|
|
|
// var yydn1 bool
|
2019-02-25 07:07:40 +03:00
|
|
|
for yyj1 = 0; (yyhl1 && yyj1 < yyl1) || !(yyhl1 || r.CheckBreak()); yyj1++ { // bounds-check-elimination
|
2018-04-06 20:04:40 +03:00
|
|
|
if yyj1 == 0 && yyv1 == nil {
|
2017-09-19 16:14:58 +03:00
|
|
|
if yyhl1 {
|
|
|
|
yyrl1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8)
|
2015-10-08 12:27:00 +03:00
|
|
|
} else {
|
2017-09-19 16:14:58 +03:00
|
|
|
yyrl1 = 8
|
2015-10-08 12:27:00 +03:00
|
|
|
}
|
2017-09-19 16:14:58 +03:00
|
|
|
yyv1 = make([]*Node, yyrl1)
|
|
|
|
yyc1 = true
|
2015-10-08 12:27:00 +03:00
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
yyh1.ElemContainerState(yyj1)
|
|
|
|
|
2017-09-19 16:14:58 +03:00
|
|
|
var yydb1 bool
|
2016-12-05 19:06:42 +03:00
|
|
|
if yyj1 >= len(yyv1) {
|
2017-09-19 16:14:58 +03:00
|
|
|
yyv1 = append(yyv1, nil)
|
2016-12-05 19:06:42 +03:00
|
|
|
yyc1 = true
|
2017-09-19 16:14:58 +03:00
|
|
|
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2017-09-19 16:14:58 +03:00
|
|
|
if yydb1 {
|
|
|
|
z.DecSwallow()
|
|
|
|
} else {
|
2015-08-17 03:41:14 +03:00
|
|
|
if r.TryDecodeAsNil() {
|
2018-04-06 20:04:40 +03:00
|
|
|
yyv1[yyj1] = nil
|
2015-08-17 03:41:14 +03:00
|
|
|
} else {
|
2016-12-05 19:06:42 +03:00
|
|
|
if yyv1[yyj1] == nil {
|
|
|
|
yyv1[yyj1] = new(Node)
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2018-04-06 20:04:40 +03:00
|
|
|
yyv1[yyj1].CodecDecodeSelf(d)
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
}
|
2017-10-20 08:14:43 +03:00
|
|
|
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2016-12-05 19:06:42 +03:00
|
|
|
if yyj1 < len(yyv1) {
|
|
|
|
yyv1 = yyv1[:yyj1]
|
|
|
|
yyc1 = true
|
|
|
|
} else if yyj1 == 0 && yyv1 == nil {
|
2017-09-19 16:14:58 +03:00
|
|
|
yyv1 = make([]*Node, 0)
|
2016-12-05 19:06:42 +03:00
|
|
|
yyc1 = true
|
2015-11-02 14:03:40 +03:00
|
|
|
}
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
2016-12-05 19:06:42 +03:00
|
|
|
yyh1.End()
|
|
|
|
if yyc1 {
|
|
|
|
*v = yyv1
|
2015-08-17 03:41:14 +03:00
|
|
|
}
|
|
|
|
}
|