Update generated go code

This commit is contained in:
Tobie Morgan Hitchcock 2019-10-03 19:15:50 +01:00
parent 0ea0942378
commit f646d47e24
4 changed files with 926 additions and 1154 deletions

View file

@ -11,23 +11,23 @@ import (
const (
// ----- content types ----
codecSelferCcUTF8830 = 1
codecSelferCcRAW830 = 255
codecSelferCcUTF87751 = 1
codecSelferCcRAW7751 = 255
// ----- value types used ----
codecSelferValueTypeArray830 = 10
codecSelferValueTypeMap830 = 9
codecSelferValueTypeString830 = 6
codecSelferValueTypeInt830 = 2
codecSelferValueTypeUint830 = 3
codecSelferValueTypeFloat830 = 4
codecSelferBitsize830 = uint8(32 << (^uint(0) >> 63))
codecSelferValueTypeArray7751 = 10
codecSelferValueTypeMap7751 = 9
codecSelferValueTypeString7751 = 6
codecSelferValueTypeInt7751 = 2
codecSelferValueTypeUint7751 = 3
codecSelferValueTypeFloat7751 = 4
codecSelferBitsize7751 = uint8(32 << (^uint(0) >> 63))
)
var (
errCodecSelferOnlyMapOrArrayEncodeToStruct830 = errors.New(`only encoded map or array can be decoded into a struct`)
errCodecSelferOnlyMapOrArrayEncodeToStruct7751 = errors.New(`only encoded map or array can be decoded into a struct`)
)
type codecSelfer830 struct{}
type codecSelfer7751 struct{}
func init() {
if codec1978.GenVersion != 10 {
@ -40,7 +40,7 @@ func init() {
}
func (x *Response) CodecEncodeSelf(e *codec1978.Encoder) {
var h codecSelfer830
var h codecSelfer7751
z, r := codec1978.GenHelperEncoder(e)
_, _, _ = h, z, r
if x == nil {
@ -78,18 +78,10 @@ func (x *Response) CodecEncodeSelf(e *codec1978.Encoder) {
if yyq2[0] {
if false {
} else {
if z.EncBasicHandle().StringToRaw {
r.EncodeStringBytesRaw(z.BytesView(string(x.Time)))
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, string(x.Time))
}
r.EncodeStringEnc(codecSelferCcUTF87751, string(x.Time))
}
} else {
if z.EncBasicHandle().StringToRaw {
r.EncodeStringBytesRaw([]byte{})
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, "")
}
r.EncodeStringEnc(codecSelferCcUTF87751, "")
}
} else {
if yyq2[0] {
@ -97,16 +89,12 @@ func (x *Response) CodecEncodeSelf(e *codec1978.Encoder) {
if z.IsJSONHandle() {
z.WriteStr("\"time\"")
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, `time`)
r.EncodeStringEnc(codecSelferCcUTF87751, `time`)
}
r.WriteMapElemValue()
if false {
} else {
if z.EncBasicHandle().StringToRaw {
r.EncodeStringBytesRaw(z.BytesView(string(x.Time)))
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, string(x.Time))
}
r.EncodeStringEnc(codecSelferCcUTF87751, string(x.Time))
}
}
}
@ -115,18 +103,10 @@ func (x *Response) CodecEncodeSelf(e *codec1978.Encoder) {
if yyq2[1] {
if false {
} else {
if z.EncBasicHandle().StringToRaw {
r.EncodeStringBytesRaw(z.BytesView(string(x.Status)))
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, string(x.Status))
}
r.EncodeStringEnc(codecSelferCcUTF87751, string(x.Status))
}
} else {
if z.EncBasicHandle().StringToRaw {
r.EncodeStringBytesRaw([]byte{})
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, "")
}
r.EncodeStringEnc(codecSelferCcUTF87751, "")
}
} else {
if yyq2[1] {
@ -134,16 +114,12 @@ func (x *Response) CodecEncodeSelf(e *codec1978.Encoder) {
if z.IsJSONHandle() {
z.WriteStr("\"status\"")
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, `status`)
r.EncodeStringEnc(codecSelferCcUTF87751, `status`)
}
r.WriteMapElemValue()
if false {
} else {
if z.EncBasicHandle().StringToRaw {
r.EncodeStringBytesRaw(z.BytesView(string(x.Status)))
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, string(x.Status))
}
r.EncodeStringEnc(codecSelferCcUTF87751, string(x.Status))
}
}
}
@ -152,18 +128,10 @@ func (x *Response) CodecEncodeSelf(e *codec1978.Encoder) {
if yyq2[2] {
if false {
} else {
if z.EncBasicHandle().StringToRaw {
r.EncodeStringBytesRaw(z.BytesView(string(x.Detail)))
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, string(x.Detail))
}
r.EncodeStringEnc(codecSelferCcUTF87751, string(x.Detail))
}
} else {
if z.EncBasicHandle().StringToRaw {
r.EncodeStringBytesRaw([]byte{})
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, "")
}
r.EncodeStringEnc(codecSelferCcUTF87751, "")
}
} else {
if yyq2[2] {
@ -171,16 +139,12 @@ func (x *Response) CodecEncodeSelf(e *codec1978.Encoder) {
if z.IsJSONHandle() {
z.WriteStr("\"detail\"")
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, `detail`)
r.EncodeStringEnc(codecSelferCcUTF87751, `detail`)
}
r.WriteMapElemValue()
if false {
} else {
if z.EncBasicHandle().StringToRaw {
r.EncodeStringBytesRaw(z.BytesView(string(x.Detail)))
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, string(x.Detail))
}
r.EncodeStringEnc(codecSelferCcUTF87751, string(x.Detail))
}
}
}
@ -204,7 +168,7 @@ func (x *Response) CodecEncodeSelf(e *codec1978.Encoder) {
if z.IsJSONHandle() {
z.WriteStr("\"result\"")
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, `result`)
r.EncodeStringEnc(codecSelferCcUTF87751, `result`)
}
r.WriteMapElemValue()
if x.Result == nil {
@ -227,7 +191,7 @@ func (x *Response) CodecEncodeSelf(e *codec1978.Encoder) {
}
func (x *Response) CodecDecodeSelf(d *codec1978.Decoder) {
var h codecSelfer830
var h codecSelfer7751
z, r := codec1978.GenHelperDecoder(d)
_, _, _ = h, z, r
if false {
@ -235,14 +199,14 @@ func (x *Response) CodecDecodeSelf(d *codec1978.Decoder) {
z.DecExtension(x, yyxt1)
} else {
yyct2 := r.ContainerType()
if yyct2 == codecSelferValueTypeMap830 {
if yyct2 == codecSelferValueTypeMap7751 {
yyl2 := r.ReadMapStart()
if yyl2 == 0 {
r.ReadMapEnd()
} else {
x.codecDecodeSelfFromMap(yyl2, d)
}
} else if yyct2 == codecSelferValueTypeArray830 {
} else if yyct2 == codecSelferValueTypeArray7751 {
yyl2 := r.ReadArrayStart()
if yyl2 == 0 {
r.ReadArrayEnd()
@ -250,13 +214,13 @@ func (x *Response) CodecDecodeSelf(d *codec1978.Decoder) {
x.codecDecodeSelfFromArray(yyl2, d)
}
} else {
panic(errCodecSelferOnlyMapOrArrayEncodeToStruct830)
panic(errCodecSelferOnlyMapOrArrayEncodeToStruct7751)
}
}
}
func (x *Response) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
var h codecSelfer830
var h codecSelfer7751
z, r := codec1978.GenHelperDecoder(d)
_, _, _ = h, z, r
var yyhl3 bool = l >= 0
@ -309,7 +273,7 @@ func (x *Response) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
}
func (x *Response) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
var h codecSelfer830
var h codecSelfer7751
z, r := codec1978.GenHelperDecoder(d)
_, _, _ = h, z, r
var yyj9 int
@ -399,7 +363,7 @@ func (x *Response) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
}
func (x *Dispatch) CodecEncodeSelf(e *codec1978.Encoder) {
var h codecSelfer830
var h codecSelfer7751
z, r := codec1978.GenHelperEncoder(e)
_, _, _ = h, z, r
if x == nil {
@ -436,18 +400,10 @@ func (x *Dispatch) CodecEncodeSelf(e *codec1978.Encoder) {
if yyq2[0] {
if false {
} else {
if z.EncBasicHandle().StringToRaw {
r.EncodeStringBytesRaw(z.BytesView(string(x.Query)))
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, string(x.Query))
}
r.EncodeStringEnc(codecSelferCcUTF87751, string(x.Query))
}
} else {
if z.EncBasicHandle().StringToRaw {
r.EncodeStringBytesRaw([]byte{})
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, "")
}
r.EncodeStringEnc(codecSelferCcUTF87751, "")
}
} else {
if yyq2[0] {
@ -455,16 +411,12 @@ func (x *Dispatch) CodecEncodeSelf(e *codec1978.Encoder) {
if z.IsJSONHandle() {
z.WriteStr("\"query\"")
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, `query`)
r.EncodeStringEnc(codecSelferCcUTF87751, `query`)
}
r.WriteMapElemValue()
if false {
} else {
if z.EncBasicHandle().StringToRaw {
r.EncodeStringBytesRaw(z.BytesView(string(x.Query)))
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, string(x.Query))
}
r.EncodeStringEnc(codecSelferCcUTF87751, string(x.Query))
}
}
}
@ -473,18 +425,10 @@ func (x *Dispatch) CodecEncodeSelf(e *codec1978.Encoder) {
if yyq2[1] {
if false {
} else {
if z.EncBasicHandle().StringToRaw {
r.EncodeStringBytesRaw(z.BytesView(string(x.Action)))
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, string(x.Action))
}
r.EncodeStringEnc(codecSelferCcUTF87751, string(x.Action))
}
} else {
if z.EncBasicHandle().StringToRaw {
r.EncodeStringBytesRaw([]byte{})
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, "")
}
r.EncodeStringEnc(codecSelferCcUTF87751, "")
}
} else {
if yyq2[1] {
@ -492,16 +436,12 @@ func (x *Dispatch) CodecEncodeSelf(e *codec1978.Encoder) {
if z.IsJSONHandle() {
z.WriteStr("\"action\"")
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, `action`)
r.EncodeStringEnc(codecSelferCcUTF87751, `action`)
}
r.WriteMapElemValue()
if false {
} else {
if z.EncBasicHandle().StringToRaw {
r.EncodeStringBytesRaw(z.BytesView(string(x.Action)))
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, string(x.Action))
}
r.EncodeStringEnc(codecSelferCcUTF87751, string(x.Action))
}
}
}
@ -525,7 +465,7 @@ func (x *Dispatch) CodecEncodeSelf(e *codec1978.Encoder) {
if z.IsJSONHandle() {
z.WriteStr("\"result\"")
} else {
r.EncodeStringEnc(codecSelferCcUTF8830, `result`)
r.EncodeStringEnc(codecSelferCcUTF87751, `result`)
}
r.WriteMapElemValue()
if x.Result == nil {
@ -548,7 +488,7 @@ func (x *Dispatch) CodecEncodeSelf(e *codec1978.Encoder) {
}
func (x *Dispatch) CodecDecodeSelf(d *codec1978.Decoder) {
var h codecSelfer830
var h codecSelfer7751
z, r := codec1978.GenHelperDecoder(d)
_, _, _ = h, z, r
if false {
@ -556,14 +496,14 @@ func (x *Dispatch) CodecDecodeSelf(d *codec1978.Decoder) {
z.DecExtension(x, yyxt1)
} else {
yyct2 := r.ContainerType()
if yyct2 == codecSelferValueTypeMap830 {
if yyct2 == codecSelferValueTypeMap7751 {
yyl2 := r.ReadMapStart()
if yyl2 == 0 {
r.ReadMapEnd()
} else {
x.codecDecodeSelfFromMap(yyl2, d)
}
} else if yyct2 == codecSelferValueTypeArray830 {
} else if yyct2 == codecSelferValueTypeArray7751 {
yyl2 := r.ReadArrayStart()
if yyl2 == 0 {
r.ReadArrayEnd()
@ -571,13 +511,13 @@ func (x *Dispatch) CodecDecodeSelf(d *codec1978.Decoder) {
x.codecDecodeSelfFromArray(yyl2, d)
}
} else {
panic(errCodecSelferOnlyMapOrArrayEncodeToStruct830)
panic(errCodecSelferOnlyMapOrArrayEncodeToStruct7751)
}
}
}
func (x *Dispatch) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
var h codecSelfer830
var h codecSelfer7751
z, r := codec1978.GenHelperDecoder(d)
_, _, _ = h, z, r
var yyhl3 bool = l >= 0
@ -624,7 +564,7 @@ func (x *Dispatch) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) {
}
func (x *Dispatch) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
var h codecSelfer830
var h codecSelfer7751
z, r := codec1978.GenHelperDecoder(d)
_, _, _ = h, z, r
var yyj8 int

4
go.mod
View file

@ -7,6 +7,7 @@ require (
github.com/abcum/cork v0.0.0-20190929093632-f45e788b8f1b
github.com/abcum/fibre v0.0.0-20191003170635-45f18bd55f9a
github.com/abcum/rixxdb v0.0.0-20191003170549-44f889db956a
github.com/abcum/tmpl v0.0.0-20190929092451-4b08f6027ed1 // indirect
github.com/dgrijalva/jwt-go v3.2.0+incompatible
github.com/elithrar/simple-scrypt v1.3.0
github.com/gorilla/websocket v1.4.1
@ -21,8 +22,9 @@ require (
github.com/sirupsen/logrus v1.4.2
github.com/smartystreets/goconvey v0.0.0-20190731233626-505e41936337
github.com/spf13/cobra v0.0.5
github.com/ugorji/go/codec v1.1.7
github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8
golang.org/x/crypto v0.0.0-20191002192127-34f69633bfdc
golang.org/x/net v0.0.0-20191002035440-2ec189313ef0
golang.org/x/text v0.3.2
golang.org/x/tools v0.0.0-20191003162220-c56b4b191e2d // indirect
)

14
go.sum
View file

@ -7,6 +7,8 @@ github.com/abcum/fibre v0.0.0-20191003170635-45f18bd55f9a h1:w7vwArRjHlY/Kvi4f86
github.com/abcum/fibre v0.0.0-20191003170635-45f18bd55f9a/go.mod h1:CPo8U5dmWBEajd6U7ozAQRp0b1zbuRkaAyZJneBZ63g=
github.com/abcum/rixxdb v0.0.0-20191003170549-44f889db956a h1:J/GpT8OmcVuKW+SBYMRx+pZrjaFIUQlBRTx7I07bk84=
github.com/abcum/rixxdb v0.0.0-20191003170549-44f889db956a/go.mod h1:6lIALuvT453ADA/5AFRXGLDNcc3sqIvt4ISaKyPeTLg=
github.com/abcum/tmpl v0.0.0-20190929092451-4b08f6027ed1 h1:hRp2bOK7p4HTCCFl4v0apR309NuN1qpKnWnX21JSCHQ=
github.com/abcum/tmpl v0.0.0-20190929092451-4b08f6027ed1/go.mod h1:T/xXRVJ6YMMHqf+MiKW6KELsEmb2n4eNMsaNQ6lI5M8=
github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8=
github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE=
github.com/coreos/go-etcd v2.0.0+incompatible/go.mod h1:Jez6KQU2B/sWsbdaef3ED8NzMklzPG4d5KIOhIy30Tk=
@ -80,11 +82,9 @@ github.com/spf13/viper v1.3.2/go.mod h1:ZiWeW+zYFKm7srdB9IoDzzZXaJaI5eL9QjNiN/DM
github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/testify v1.2.2 h1:bSDNvY7ZPG5RlJ8otE/7V6gMiyenm9RtJ7IUVIAoJ1w=
github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs=
github.com/ugorji/go v1.1.7 h1:/68gy2h+1mWMrwZFeD1kQialdSzAb432dtpeJ42ovdo=
github.com/ugorji/go v1.1.7/go.mod h1:kZn38zHttfInRq0xu/PH0az30d+z6vm202qpg1oXVMw=
github.com/ugorji/go v0.0.0-20181204163529-d75b2dcb6bc8 h1:Kcv6ck5PWsaDifMwDDgexKfbmP1k63r3tcVppPa+FyM=
github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8 h1:3SVOIvH7Ae1KRYyQWRjXWJEA9sS/c/pjvH++55Gr648=
github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8/go.mod h1:VFNgLljTbGfSG7qAOspJ7OScBnGdDN/yBr0sguwnwf0=
github.com/ugorji/go/codec v1.1.7 h1:2SvQaVZ1ouYrrKKwoSk2pzd4A9evlKJb9oTL+OaLUSs=
github.com/ugorji/go/codec v1.1.7/go.mod h1:Ax+UKWsSmolVDwsd+7N3ZtXu+yMGCf907BLYF3GoBXY=
github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q=
golang.org/x/crypto v0.0.0-20181203042331-505ab145d0a9/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
@ -92,9 +92,11 @@ golang.org/x/crypto v0.0.0-20191002192127-34f69633bfdc h1:c0o/qxkaO2LF5t6fQrT4b5
golang.org/x/crypto v0.0.0-20191002192127-34f69633bfdc/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
golang.org/x/net v0.0.0-20190926025831-c00fd9afed17/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
golang.org/x/net v0.0.0-20191002035440-2ec189313ef0 h1:2mqDk8w/o6UmeUCu5Qiq2y7iMf6anbx+YA8d1JFoFrs=
golang.org/x/net v0.0.0-20191002035440-2ec189313ef0/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sys v0.0.0-20181205085412-a5c9d58dba9a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
@ -105,7 +107,11 @@ golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
golang.org/x/text v0.3.2 h1:tW2bmiBqwgJj/UpqtC8EpXEZVYOwU0yG4iWbprSVAcs=
golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk=
golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
golang.org/x/tools v0.0.0-20190328211700-ab21143f2384 h1:TFlARGu6Czu1z7q93HTxcP1P+/ZFC/IKythI5RzrnRg=
golang.org/x/tools v0.0.0-20190328211700-ab21143f2384/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
golang.org/x/tools v0.0.0-20191003162220-c56b4b191e2d h1:xzbfnqkhzcf2qHVgbBaXlaj+JlFOxT6P/oe2+yVuwBE=
golang.org/x/tools v0.0.0-20191003162220-c56b4b191e2d/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 h1:YR8cESwS4TdDjEe65xsg0ogRM/Nc3DYOhEAlW+xobZo=
gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=

File diff suppressed because it is too large Load diff