Esempio n. 1
0
func easyjson_decode_github_com_buger_jsonparser_benchmark_MediumPayload(in *jlexer.Lexer, out *MediumPayload) {
	in.Delim('{')
	for !in.IsDelim('}') {
		key := in.UnsafeString()
		in.WantColon()
		if in.IsNull() {
			in.Skip()
			in.WantComma()
			continue
		}
		switch key {
		case "person":
			if in.IsNull() {
				in.Skip()
				out.Person = nil
			} else {
				out.Person = new(CBPerson)
				(*out.Person).UnmarshalEasyJSON(in)
			}
		case "company":
			in.Delim('{')
			if !in.IsDelim('}') {
				out.Company = make(map[string]interface{})
			} else {
				out.Company = nil
			}
			for !in.IsDelim('}') {
				key := in.String()
				in.WantColon()
				var v7 interface{}
				v7 = in.Interface()
				(out.Company)[key] = v7
				in.WantComma()
			}
			in.Delim('}')
		default:
			in.SkipRecursive()
		}
		in.WantComma()
	}
	in.Delim('}')
}
func easyjson7f5ba663DecodeGithubComSergeiSvistunovGorpcDebug(in *jlexer.Lexer, out *debug.Debug) {
	if in.IsNull() {
		in.Skip()
		return
	}
	in.Delim('{')
	for !in.IsDelim('}') {
		key := in.UnsafeString()
		in.WantColon()
		if in.IsNull() {
			in.Skip()
			in.WantComma()
			continue
		}
		switch key {
		case "modules":
			if in.IsNull() {
				in.Skip()
			} else {
				in.Delim('{')
				if !in.IsDelim('}') {
					out.Modules = make(map[string]interface{})
				} else {
					out.Modules = nil
				}
				for !in.IsDelim('}') {
					key := string(in.String())
					in.WantColon()
					var v1 interface{}
					v1 = in.Interface()
					(out.Modules)[key] = v1
					in.WantComma()
				}
				in.Delim('}')
			}
		default:
			in.SkipRecursive()
		}
		in.WantComma()
	}
	in.Delim('}')
}
func easyjson7f5ba663DecodeGithubComSergeiSvistunovGorpcTransportHttpJson(in *jlexer.Lexer, out *httpSessionResponse) {
	if in.IsNull() {
		in.Skip()
		return
	}
	in.Delim('{')
	for !in.IsDelim('}') {
		key := in.UnsafeString()
		in.WantColon()
		if in.IsNull() {
			in.Skip()
			in.WantComma()
			continue
		}
		switch key {
		case "result":
			out.Result = string(in.String())
		case "data":
			out.Data = in.Interface()
		case "error":
			out.Error = string(in.String())
		case "debug":
			if in.IsNull() {
				in.Skip()
				out.Debug = nil
			} else {
				if out.Debug == nil {
					out.Debug = new(debug.Debug)
				}
				easyjson7f5ba663DecodeGithubComSergeiSvistunovGorpcDebug(in, &*out.Debug)
			}
		default:
			in.SkipRecursive()
		}
		in.WantComma()
	}
	in.Delim('}')
}