api/payload_easyjson.go
// Code generated by easyjson for marshaling/unmarshaling. DO NOT EDIT.
package api
import (
json "encoding/json"
easyjson "github.com/mailru/easyjson"
jlexer "github.com/mailru/easyjson/jlexer"
jwriter "github.com/mailru/easyjson/jwriter"
)
// suppress unused package warning
var (
_ *json.RawMessage
_ *jlexer.Lexer
_ *jwriter.Writer
_ easyjson.Marshaler
)
func easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi(in *jlexer.Lexer, out *Validation) {
isTopLevel := in.IsStart()
if in.IsNull() {
if isTopLevel {
in.Consumed()
}
in.Skip()
return
}
in.Delim('{')
for !in.IsDelim('}') {
key := in.UnsafeFieldName(false)
in.WantColon()
if in.IsNull() {
in.Skip()
in.WantComma()
continue
}
switch key {
default:
in.SkipRecursive()
}
in.WantComma()
}
in.Delim('}')
if isTopLevel {
in.Consumed()
}
}
func easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi(out *jwriter.Writer, in Validation) {
out.RawByte('{')
first := true
_ = first
out.RawByte('}')
}
// MarshalEasyJSON supports easyjson.Marshaler interface
func (v Validation) MarshalEasyJSON(w *jwriter.Writer) {
easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi(w, v)
}
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (v *Validation) UnmarshalEasyJSON(l *jlexer.Lexer) {
easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi(l, v)
}
func easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi1(in *jlexer.Lexer, out *UpdatePlayerPayload) {
isTopLevel := in.IsStart()
if in.IsNull() {
if isTopLevel {
in.Consumed()
}
in.Skip()
return
}
in.Delim('{')
for !in.IsDelim('}') {
key := in.UnsafeFieldName(false)
in.WantColon()
if in.IsNull() {
in.Skip()
in.WantComma()
continue
}
switch key {
case "name":
out.Name = string(in.String())
case "metadata":
if in.IsNull() {
in.Skip()
} else {
in.Delim('{')
out.Metadata = make(map[string]interface{})
for !in.IsDelim('}') {
key := string(in.String())
in.WantColon()
var v1 interface{}
if m, ok := v1.(easyjson.Unmarshaler); ok {
m.UnmarshalEasyJSON(in)
} else if m, ok := v1.(json.Unmarshaler); ok {
_ = m.UnmarshalJSON(in.Raw())
} else {
v1 = in.Interface()
}
(out.Metadata)[key] = v1
in.WantComma()
}
in.Delim('}')
}
default:
in.SkipRecursive()
}
in.WantComma()
}
in.Delim('}')
if isTopLevel {
in.Consumed()
}
}
func easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi1(out *jwriter.Writer, in UpdatePlayerPayload) {
out.RawByte('{')
first := true
_ = first
{
const prefix string = ",\"name\":"
out.RawString(prefix[1:])
out.String(string(in.Name))
}
{
const prefix string = ",\"metadata\":"
out.RawString(prefix)
if in.Metadata == nil && (out.Flags&jwriter.NilMapAsEmpty) == 0 {
out.RawString(`null`)
} else {
out.RawByte('{')
v2First := true
for v2Name, v2Value := range in.Metadata {
if v2First {
v2First = false
} else {
out.RawByte(',')
}
out.String(string(v2Name))
out.RawByte(':')
if m, ok := v2Value.(easyjson.Marshaler); ok {
m.MarshalEasyJSON(out)
} else if m, ok := v2Value.(json.Marshaler); ok {
out.Raw(m.MarshalJSON())
} else {
out.Raw(json.Marshal(v2Value))
}
}
out.RawByte('}')
}
}
out.RawByte('}')
}
// MarshalEasyJSON supports easyjson.Marshaler interface
func (v UpdatePlayerPayload) MarshalEasyJSON(w *jwriter.Writer) {
easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi1(w, v)
}
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (v *UpdatePlayerPayload) UnmarshalEasyJSON(l *jlexer.Lexer) {
easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi1(l, v)
}
func easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi2(in *jlexer.Lexer, out *UpdateGamePayload) {
isTopLevel := in.IsStart()
if in.IsNull() {
if isTopLevel {
in.Consumed()
}
in.Skip()
return
}
in.Delim('{')
for !in.IsDelim('}') {
key := in.UnsafeFieldName(false)
in.WantColon()
if in.IsNull() {
in.Skip()
in.WantComma()
continue
}
switch key {
case "name":
out.Name = string(in.String())
case "membershipLevels":
if in.IsNull() {
in.Skip()
} else {
in.Delim('{')
out.MembershipLevels = make(map[string]interface{})
for !in.IsDelim('}') {
key := string(in.String())
in.WantColon()
var v3 interface{}
if m, ok := v3.(easyjson.Unmarshaler); ok {
m.UnmarshalEasyJSON(in)
} else if m, ok := v3.(json.Unmarshaler); ok {
_ = m.UnmarshalJSON(in.Raw())
} else {
v3 = in.Interface()
}
(out.MembershipLevels)[key] = v3
in.WantComma()
}
in.Delim('}')
}
case "metadata":
if in.IsNull() {
in.Skip()
} else {
in.Delim('{')
out.Metadata = make(map[string]interface{})
for !in.IsDelim('}') {
key := string(in.String())
in.WantColon()
var v4 interface{}
if m, ok := v4.(easyjson.Unmarshaler); ok {
m.UnmarshalEasyJSON(in)
} else if m, ok := v4.(json.Unmarshaler); ok {
_ = m.UnmarshalJSON(in.Raw())
} else {
v4 = in.Interface()
}
(out.Metadata)[key] = v4
in.WantComma()
}
in.Delim('}')
}
case "minLevelToAcceptApplication":
out.MinLevelToAcceptApplication = int(in.Int())
case "minLevelToCreateInvitation":
out.MinLevelToCreateInvitation = int(in.Int())
case "minLevelToRemoveMember":
out.MinLevelToRemoveMember = int(in.Int())
case "minLevelOffsetToRemoveMember":
out.MinLevelOffsetToRemoveMember = int(in.Int())
case "minLevelOffsetToPromoteMember":
out.MinLevelOffsetToPromoteMember = int(in.Int())
case "minLevelOffsetToDemoteMember":
out.MinLevelOffsetToDemoteMember = int(in.Int())
case "maxMembers":
out.MaxMembers = int(in.Int())
case "maxClansPerPlayer":
out.MaxClansPerPlayer = int(in.Int())
case "cooldownAfterDeny":
out.CooldownAfterDeny = int(in.Int())
case "cooldownAfterDelete":
out.CooldownAfterDelete = int(in.Int())
default:
in.SkipRecursive()
}
in.WantComma()
}
in.Delim('}')
if isTopLevel {
in.Consumed()
}
}
func easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi2(out *jwriter.Writer, in UpdateGamePayload) {
out.RawByte('{')
first := true
_ = first
{
const prefix string = ",\"name\":"
out.RawString(prefix[1:])
out.String(string(in.Name))
}
{
const prefix string = ",\"membershipLevels\":"
out.RawString(prefix)
if in.MembershipLevels == nil && (out.Flags&jwriter.NilMapAsEmpty) == 0 {
out.RawString(`null`)
} else {
out.RawByte('{')
v5First := true
for v5Name, v5Value := range in.MembershipLevels {
if v5First {
v5First = false
} else {
out.RawByte(',')
}
out.String(string(v5Name))
out.RawByte(':')
if m, ok := v5Value.(easyjson.Marshaler); ok {
m.MarshalEasyJSON(out)
} else if m, ok := v5Value.(json.Marshaler); ok {
out.Raw(m.MarshalJSON())
} else {
out.Raw(json.Marshal(v5Value))
}
}
out.RawByte('}')
}
}
{
const prefix string = ",\"metadata\":"
out.RawString(prefix)
if in.Metadata == nil && (out.Flags&jwriter.NilMapAsEmpty) == 0 {
out.RawString(`null`)
} else {
out.RawByte('{')
v6First := true
for v6Name, v6Value := range in.Metadata {
if v6First {
v6First = false
} else {
out.RawByte(',')
}
out.String(string(v6Name))
out.RawByte(':')
if m, ok := v6Value.(easyjson.Marshaler); ok {
m.MarshalEasyJSON(out)
} else if m, ok := v6Value.(json.Marshaler); ok {
out.Raw(m.MarshalJSON())
} else {
out.Raw(json.Marshal(v6Value))
}
}
out.RawByte('}')
}
}
{
const prefix string = ",\"minLevelToAcceptApplication\":"
out.RawString(prefix)
out.Int(int(in.MinLevelToAcceptApplication))
}
{
const prefix string = ",\"minLevelToCreateInvitation\":"
out.RawString(prefix)
out.Int(int(in.MinLevelToCreateInvitation))
}
{
const prefix string = ",\"minLevelToRemoveMember\":"
out.RawString(prefix)
out.Int(int(in.MinLevelToRemoveMember))
}
{
const prefix string = ",\"minLevelOffsetToRemoveMember\":"
out.RawString(prefix)
out.Int(int(in.MinLevelOffsetToRemoveMember))
}
{
const prefix string = ",\"minLevelOffsetToPromoteMember\":"
out.RawString(prefix)
out.Int(int(in.MinLevelOffsetToPromoteMember))
}
{
const prefix string = ",\"minLevelOffsetToDemoteMember\":"
out.RawString(prefix)
out.Int(int(in.MinLevelOffsetToDemoteMember))
}
{
const prefix string = ",\"maxMembers\":"
out.RawString(prefix)
out.Int(int(in.MaxMembers))
}
{
const prefix string = ",\"maxClansPerPlayer\":"
out.RawString(prefix)
out.Int(int(in.MaxClansPerPlayer))
}
{
const prefix string = ",\"cooldownAfterDeny\":"
out.RawString(prefix)
out.Int(int(in.CooldownAfterDeny))
}
{
const prefix string = ",\"cooldownAfterDelete\":"
out.RawString(prefix)
out.Int(int(in.CooldownAfterDelete))
}
out.RawByte('}')
}
// MarshalEasyJSON supports easyjson.Marshaler interface
func (v UpdateGamePayload) MarshalEasyJSON(w *jwriter.Writer) {
easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi2(w, v)
}
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (v *UpdateGamePayload) UnmarshalEasyJSON(l *jlexer.Lexer) {
easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi2(l, v)
}
func easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi3(in *jlexer.Lexer, out *UpdateClanPayload) {
isTopLevel := in.IsStart()
if in.IsNull() {
if isTopLevel {
in.Consumed()
}
in.Skip()
return
}
in.Delim('{')
for !in.IsDelim('}') {
key := in.UnsafeFieldName(false)
in.WantColon()
if in.IsNull() {
in.Skip()
in.WantComma()
continue
}
switch key {
case "name":
out.Name = string(in.String())
case "ownerPublicID":
out.OwnerPublicID = string(in.String())
case "metadata":
if in.IsNull() {
in.Skip()
} else {
in.Delim('{')
out.Metadata = make(map[string]interface{})
for !in.IsDelim('}') {
key := string(in.String())
in.WantColon()
var v7 interface{}
if m, ok := v7.(easyjson.Unmarshaler); ok {
m.UnmarshalEasyJSON(in)
} else if m, ok := v7.(json.Unmarshaler); ok {
_ = m.UnmarshalJSON(in.Raw())
} else {
v7 = in.Interface()
}
(out.Metadata)[key] = v7
in.WantComma()
}
in.Delim('}')
}
case "allowApplication":
out.AllowApplication = bool(in.Bool())
case "autoJoin":
out.AutoJoin = bool(in.Bool())
default:
in.SkipRecursive()
}
in.WantComma()
}
in.Delim('}')
if isTopLevel {
in.Consumed()
}
}
func easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi3(out *jwriter.Writer, in UpdateClanPayload) {
out.RawByte('{')
first := true
_ = first
{
const prefix string = ",\"name\":"
out.RawString(prefix[1:])
out.String(string(in.Name))
}
{
const prefix string = ",\"ownerPublicID\":"
out.RawString(prefix)
out.String(string(in.OwnerPublicID))
}
{
const prefix string = ",\"metadata\":"
out.RawString(prefix)
if in.Metadata == nil && (out.Flags&jwriter.NilMapAsEmpty) == 0 {
out.RawString(`null`)
} else {
out.RawByte('{')
v8First := true
for v8Name, v8Value := range in.Metadata {
if v8First {
v8First = false
} else {
out.RawByte(',')
}
out.String(string(v8Name))
out.RawByte(':')
if m, ok := v8Value.(easyjson.Marshaler); ok {
m.MarshalEasyJSON(out)
} else if m, ok := v8Value.(json.Marshaler); ok {
out.Raw(m.MarshalJSON())
} else {
out.Raw(json.Marshal(v8Value))
}
}
out.RawByte('}')
}
}
{
const prefix string = ",\"allowApplication\":"
out.RawString(prefix)
out.Bool(bool(in.AllowApplication))
}
{
const prefix string = ",\"autoJoin\":"
out.RawString(prefix)
out.Bool(bool(in.AutoJoin))
}
out.RawByte('}')
}
// MarshalEasyJSON supports easyjson.Marshaler interface
func (v UpdateClanPayload) MarshalEasyJSON(w *jwriter.Writer) {
easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi3(w, v)
}
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (v *UpdateClanPayload) UnmarshalEasyJSON(l *jlexer.Lexer) {
easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi3(l, v)
}
func easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi4(in *jlexer.Lexer, out *TransferClanOwnershipPayload) {
isTopLevel := in.IsStart()
if in.IsNull() {
if isTopLevel {
in.Consumed()
}
in.Skip()
return
}
in.Delim('{')
for !in.IsDelim('}') {
key := in.UnsafeFieldName(false)
in.WantColon()
if in.IsNull() {
in.Skip()
in.WantComma()
continue
}
switch key {
case "playerPublicID":
out.PlayerPublicID = string(in.String())
default:
in.SkipRecursive()
}
in.WantComma()
}
in.Delim('}')
if isTopLevel {
in.Consumed()
}
}
func easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi4(out *jwriter.Writer, in TransferClanOwnershipPayload) {
out.RawByte('{')
first := true
_ = first
{
const prefix string = ",\"playerPublicID\":"
out.RawString(prefix[1:])
out.String(string(in.PlayerPublicID))
}
out.RawByte('}')
}
// MarshalEasyJSON supports easyjson.Marshaler interface
func (v TransferClanOwnershipPayload) MarshalEasyJSON(w *jwriter.Writer) {
easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi4(w, v)
}
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (v *TransferClanOwnershipPayload) UnmarshalEasyJSON(l *jlexer.Lexer) {
easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi4(l, v)
}
func easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi5(in *jlexer.Lexer, out *InviteForMembershipPayload) {
isTopLevel := in.IsStart()
if in.IsNull() {
if isTopLevel {
in.Consumed()
}
in.Skip()
return
}
in.Delim('{')
for !in.IsDelim('}') {
key := in.UnsafeFieldName(false)
in.WantColon()
if in.IsNull() {
in.Skip()
in.WantComma()
continue
}
switch key {
case "level":
out.Level = string(in.String())
case "playerPublicID":
out.PlayerPublicID = string(in.String())
case "requestorPublicID":
out.RequestorPublicID = string(in.String())
default:
in.SkipRecursive()
}
in.WantComma()
}
in.Delim('}')
if isTopLevel {
in.Consumed()
}
}
func easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi5(out *jwriter.Writer, in InviteForMembershipPayload) {
out.RawByte('{')
first := true
_ = first
{
const prefix string = ",\"level\":"
out.RawString(prefix[1:])
out.String(string(in.Level))
}
{
const prefix string = ",\"playerPublicID\":"
out.RawString(prefix)
out.String(string(in.PlayerPublicID))
}
{
const prefix string = ",\"requestorPublicID\":"
out.RawString(prefix)
out.String(string(in.RequestorPublicID))
}
out.RawByte('}')
}
// MarshalEasyJSON supports easyjson.Marshaler interface
func (v InviteForMembershipPayload) MarshalEasyJSON(w *jwriter.Writer) {
easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi5(w, v)
}
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (v *InviteForMembershipPayload) UnmarshalEasyJSON(l *jlexer.Lexer) {
easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi5(l, v)
}
func easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi6(in *jlexer.Lexer, out *HookPayload) {
isTopLevel := in.IsStart()
if in.IsNull() {
if isTopLevel {
in.Consumed()
}
in.Skip()
return
}
in.Delim('{')
for !in.IsDelim('}') {
key := in.UnsafeFieldName(false)
in.WantColon()
if in.IsNull() {
in.Skip()
in.WantComma()
continue
}
switch key {
case "type":
out.Type = int(in.Int())
case "hookURL":
out.HookURL = string(in.String())
default:
in.SkipRecursive()
}
in.WantComma()
}
in.Delim('}')
if isTopLevel {
in.Consumed()
}
}
func easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi6(out *jwriter.Writer, in HookPayload) {
out.RawByte('{')
first := true
_ = first
{
const prefix string = ",\"type\":"
out.RawString(prefix[1:])
out.Int(int(in.Type))
}
{
const prefix string = ",\"hookURL\":"
out.RawString(prefix)
out.String(string(in.HookURL))
}
out.RawByte('}')
}
// MarshalEasyJSON supports easyjson.Marshaler interface
func (v HookPayload) MarshalEasyJSON(w *jwriter.Writer) {
easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi6(w, v)
}
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (v *HookPayload) UnmarshalEasyJSON(l *jlexer.Lexer) {
easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi6(l, v)
}
func easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi7(in *jlexer.Lexer, out *CreatePlayerPayload) {
isTopLevel := in.IsStart()
if in.IsNull() {
if isTopLevel {
in.Consumed()
}
in.Skip()
return
}
in.Delim('{')
for !in.IsDelim('}') {
key := in.UnsafeFieldName(false)
in.WantColon()
if in.IsNull() {
in.Skip()
in.WantComma()
continue
}
switch key {
case "publicID":
out.PublicID = string(in.String())
case "name":
out.Name = string(in.String())
case "metadata":
if in.IsNull() {
in.Skip()
} else {
in.Delim('{')
out.Metadata = make(map[string]interface{})
for !in.IsDelim('}') {
key := string(in.String())
in.WantColon()
var v9 interface{}
if m, ok := v9.(easyjson.Unmarshaler); ok {
m.UnmarshalEasyJSON(in)
} else if m, ok := v9.(json.Unmarshaler); ok {
_ = m.UnmarshalJSON(in.Raw())
} else {
v9 = in.Interface()
}
(out.Metadata)[key] = v9
in.WantComma()
}
in.Delim('}')
}
default:
in.SkipRecursive()
}
in.WantComma()
}
in.Delim('}')
if isTopLevel {
in.Consumed()
}
}
func easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi7(out *jwriter.Writer, in CreatePlayerPayload) {
out.RawByte('{')
first := true
_ = first
{
const prefix string = ",\"publicID\":"
out.RawString(prefix[1:])
out.String(string(in.PublicID))
}
{
const prefix string = ",\"name\":"
out.RawString(prefix)
out.String(string(in.Name))
}
{
const prefix string = ",\"metadata\":"
out.RawString(prefix)
if in.Metadata == nil && (out.Flags&jwriter.NilMapAsEmpty) == 0 {
out.RawString(`null`)
} else {
out.RawByte('{')
v10First := true
for v10Name, v10Value := range in.Metadata {
if v10First {
v10First = false
} else {
out.RawByte(',')
}
out.String(string(v10Name))
out.RawByte(':')
if m, ok := v10Value.(easyjson.Marshaler); ok {
m.MarshalEasyJSON(out)
} else if m, ok := v10Value.(json.Marshaler); ok {
out.Raw(m.MarshalJSON())
} else {
out.Raw(json.Marshal(v10Value))
}
}
out.RawByte('}')
}
}
out.RawByte('}')
}
// MarshalEasyJSON supports easyjson.Marshaler interface
func (v CreatePlayerPayload) MarshalEasyJSON(w *jwriter.Writer) {
easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi7(w, v)
}
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (v *CreatePlayerPayload) UnmarshalEasyJSON(l *jlexer.Lexer) {
easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi7(l, v)
}
func easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi8(in *jlexer.Lexer, out *CreateGamePayload) {
isTopLevel := in.IsStart()
if in.IsNull() {
if isTopLevel {
in.Consumed()
}
in.Skip()
return
}
in.Delim('{')
for !in.IsDelim('}') {
key := in.UnsafeFieldName(false)
in.WantColon()
if in.IsNull() {
in.Skip()
in.WantComma()
continue
}
switch key {
case "publicID":
out.PublicID = string(in.String())
case "name":
out.Name = string(in.String())
case "membershipLevels":
if in.IsNull() {
in.Skip()
} else {
in.Delim('{')
out.MembershipLevels = make(map[string]interface{})
for !in.IsDelim('}') {
key := string(in.String())
in.WantColon()
var v11 interface{}
if m, ok := v11.(easyjson.Unmarshaler); ok {
m.UnmarshalEasyJSON(in)
} else if m, ok := v11.(json.Unmarshaler); ok {
_ = m.UnmarshalJSON(in.Raw())
} else {
v11 = in.Interface()
}
(out.MembershipLevels)[key] = v11
in.WantComma()
}
in.Delim('}')
}
case "metadata":
if in.IsNull() {
in.Skip()
} else {
in.Delim('{')
out.Metadata = make(map[string]interface{})
for !in.IsDelim('}') {
key := string(in.String())
in.WantColon()
var v12 interface{}
if m, ok := v12.(easyjson.Unmarshaler); ok {
m.UnmarshalEasyJSON(in)
} else if m, ok := v12.(json.Unmarshaler); ok {
_ = m.UnmarshalJSON(in.Raw())
} else {
v12 = in.Interface()
}
(out.Metadata)[key] = v12
in.WantComma()
}
in.Delim('}')
}
case "minLevelToAcceptApplication":
out.MinLevelToAcceptApplication = int(in.Int())
case "minLevelToCreateInvitation":
out.MinLevelToCreateInvitation = int(in.Int())
case "minLevelToRemoveMember":
out.MinLevelToRemoveMember = int(in.Int())
case "minLevelOffsetToRemoveMember":
out.MinLevelOffsetToRemoveMember = int(in.Int())
case "minLevelOffsetToPromoteMember":
out.MinLevelOffsetToPromoteMember = int(in.Int())
case "minLevelOffsetToDemoteMember":
out.MinLevelOffsetToDemoteMember = int(in.Int())
case "maxMembers":
out.MaxMembers = int(in.Int())
case "maxClansPerPlayer":
out.MaxClansPerPlayer = int(in.Int())
case "cooldownAfterDeny":
out.CooldownAfterDeny = int(in.Int())
case "cooldownAfterDelete":
out.CooldownAfterDelete = int(in.Int())
default:
in.SkipRecursive()
}
in.WantComma()
}
in.Delim('}')
if isTopLevel {
in.Consumed()
}
}
func easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi8(out *jwriter.Writer, in CreateGamePayload) {
out.RawByte('{')
first := true
_ = first
{
const prefix string = ",\"publicID\":"
out.RawString(prefix[1:])
out.String(string(in.PublicID))
}
{
const prefix string = ",\"name\":"
out.RawString(prefix)
out.String(string(in.Name))
}
{
const prefix string = ",\"membershipLevels\":"
out.RawString(prefix)
if in.MembershipLevels == nil && (out.Flags&jwriter.NilMapAsEmpty) == 0 {
out.RawString(`null`)
} else {
out.RawByte('{')
v13First := true
for v13Name, v13Value := range in.MembershipLevels {
if v13First {
v13First = false
} else {
out.RawByte(',')
}
out.String(string(v13Name))
out.RawByte(':')
if m, ok := v13Value.(easyjson.Marshaler); ok {
m.MarshalEasyJSON(out)
} else if m, ok := v13Value.(json.Marshaler); ok {
out.Raw(m.MarshalJSON())
} else {
out.Raw(json.Marshal(v13Value))
}
}
out.RawByte('}')
}
}
{
const prefix string = ",\"metadata\":"
out.RawString(prefix)
if in.Metadata == nil && (out.Flags&jwriter.NilMapAsEmpty) == 0 {
out.RawString(`null`)
} else {
out.RawByte('{')
v14First := true
for v14Name, v14Value := range in.Metadata {
if v14First {
v14First = false
} else {
out.RawByte(',')
}
out.String(string(v14Name))
out.RawByte(':')
if m, ok := v14Value.(easyjson.Marshaler); ok {
m.MarshalEasyJSON(out)
} else if m, ok := v14Value.(json.Marshaler); ok {
out.Raw(m.MarshalJSON())
} else {
out.Raw(json.Marshal(v14Value))
}
}
out.RawByte('}')
}
}
{
const prefix string = ",\"minLevelToAcceptApplication\":"
out.RawString(prefix)
out.Int(int(in.MinLevelToAcceptApplication))
}
{
const prefix string = ",\"minLevelToCreateInvitation\":"
out.RawString(prefix)
out.Int(int(in.MinLevelToCreateInvitation))
}
{
const prefix string = ",\"minLevelToRemoveMember\":"
out.RawString(prefix)
out.Int(int(in.MinLevelToRemoveMember))
}
{
const prefix string = ",\"minLevelOffsetToRemoveMember\":"
out.RawString(prefix)
out.Int(int(in.MinLevelOffsetToRemoveMember))
}
{
const prefix string = ",\"minLevelOffsetToPromoteMember\":"
out.RawString(prefix)
out.Int(int(in.MinLevelOffsetToPromoteMember))
}
{
const prefix string = ",\"minLevelOffsetToDemoteMember\":"
out.RawString(prefix)
out.Int(int(in.MinLevelOffsetToDemoteMember))
}
{
const prefix string = ",\"maxMembers\":"
out.RawString(prefix)
out.Int(int(in.MaxMembers))
}
{
const prefix string = ",\"maxClansPerPlayer\":"
out.RawString(prefix)
out.Int(int(in.MaxClansPerPlayer))
}
{
const prefix string = ",\"cooldownAfterDeny\":"
out.RawString(prefix)
out.Int(int(in.CooldownAfterDeny))
}
{
const prefix string = ",\"cooldownAfterDelete\":"
out.RawString(prefix)
out.Int(int(in.CooldownAfterDelete))
}
out.RawByte('}')
}
// MarshalEasyJSON supports easyjson.Marshaler interface
func (v CreateGamePayload) MarshalEasyJSON(w *jwriter.Writer) {
easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi8(w, v)
}
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (v *CreateGamePayload) UnmarshalEasyJSON(l *jlexer.Lexer) {
easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi8(l, v)
}
func easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi9(in *jlexer.Lexer, out *CreateClanPayload) {
isTopLevel := in.IsStart()
if in.IsNull() {
if isTopLevel {
in.Consumed()
}
in.Skip()
return
}
in.Delim('{')
for !in.IsDelim('}') {
key := in.UnsafeFieldName(false)
in.WantColon()
if in.IsNull() {
in.Skip()
in.WantComma()
continue
}
switch key {
case "publicID":
out.PublicID = string(in.String())
case "name":
out.Name = string(in.String())
case "ownerPublicID":
out.OwnerPublicID = string(in.String())
case "metadata":
if in.IsNull() {
in.Skip()
} else {
in.Delim('{')
out.Metadata = make(map[string]interface{})
for !in.IsDelim('}') {
key := string(in.String())
in.WantColon()
var v15 interface{}
if m, ok := v15.(easyjson.Unmarshaler); ok {
m.UnmarshalEasyJSON(in)
} else if m, ok := v15.(json.Unmarshaler); ok {
_ = m.UnmarshalJSON(in.Raw())
} else {
v15 = in.Interface()
}
(out.Metadata)[key] = v15
in.WantComma()
}
in.Delim('}')
}
case "allowApplication":
out.AllowApplication = bool(in.Bool())
case "autoJoin":
out.AutoJoin = bool(in.Bool())
default:
in.SkipRecursive()
}
in.WantComma()
}
in.Delim('}')
if isTopLevel {
in.Consumed()
}
}
func easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi9(out *jwriter.Writer, in CreateClanPayload) {
out.RawByte('{')
first := true
_ = first
{
const prefix string = ",\"publicID\":"
out.RawString(prefix[1:])
out.String(string(in.PublicID))
}
{
const prefix string = ",\"name\":"
out.RawString(prefix)
out.String(string(in.Name))
}
{
const prefix string = ",\"ownerPublicID\":"
out.RawString(prefix)
out.String(string(in.OwnerPublicID))
}
{
const prefix string = ",\"metadata\":"
out.RawString(prefix)
if in.Metadata == nil && (out.Flags&jwriter.NilMapAsEmpty) == 0 {
out.RawString(`null`)
} else {
out.RawByte('{')
v16First := true
for v16Name, v16Value := range in.Metadata {
if v16First {
v16First = false
} else {
out.RawByte(',')
}
out.String(string(v16Name))
out.RawByte(':')
if m, ok := v16Value.(easyjson.Marshaler); ok {
m.MarshalEasyJSON(out)
} else if m, ok := v16Value.(json.Marshaler); ok {
out.Raw(m.MarshalJSON())
} else {
out.Raw(json.Marshal(v16Value))
}
}
out.RawByte('}')
}
}
{
const prefix string = ",\"allowApplication\":"
out.RawString(prefix)
out.Bool(bool(in.AllowApplication))
}
{
const prefix string = ",\"autoJoin\":"
out.RawString(prefix)
out.Bool(bool(in.AutoJoin))
}
out.RawByte('}')
}
// MarshalEasyJSON supports easyjson.Marshaler interface
func (v CreateClanPayload) MarshalEasyJSON(w *jwriter.Writer) {
easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi9(w, v)
}
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (v *CreateClanPayload) UnmarshalEasyJSON(l *jlexer.Lexer) {
easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi9(l, v)
}
func easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi10(in *jlexer.Lexer, out *BasePayloadWithRequestorAndPlayerPublicIDs) {
isTopLevel := in.IsStart()
if in.IsNull() {
if isTopLevel {
in.Consumed()
}
in.Skip()
return
}
in.Delim('{')
for !in.IsDelim('}') {
key := in.UnsafeFieldName(false)
in.WantColon()
if in.IsNull() {
in.Skip()
in.WantComma()
continue
}
switch key {
case "playerPublicID":
out.PlayerPublicID = string(in.String())
case "requestorPublicID":
out.RequestorPublicID = string(in.String())
default:
in.SkipRecursive()
}
in.WantComma()
}
in.Delim('}')
if isTopLevel {
in.Consumed()
}
}
func easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi10(out *jwriter.Writer, in BasePayloadWithRequestorAndPlayerPublicIDs) {
out.RawByte('{')
first := true
_ = first
{
const prefix string = ",\"playerPublicID\":"
out.RawString(prefix[1:])
out.String(string(in.PlayerPublicID))
}
{
const prefix string = ",\"requestorPublicID\":"
out.RawString(prefix)
out.String(string(in.RequestorPublicID))
}
out.RawByte('}')
}
// MarshalEasyJSON supports easyjson.Marshaler interface
func (v BasePayloadWithRequestorAndPlayerPublicIDs) MarshalEasyJSON(w *jwriter.Writer) {
easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi10(w, v)
}
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (v *BasePayloadWithRequestorAndPlayerPublicIDs) UnmarshalEasyJSON(l *jlexer.Lexer) {
easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi10(l, v)
}
func easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi11(in *jlexer.Lexer, out *ApproveOrDenyMembershipInvitationPayload) {
isTopLevel := in.IsStart()
if in.IsNull() {
if isTopLevel {
in.Consumed()
}
in.Skip()
return
}
in.Delim('{')
for !in.IsDelim('}') {
key := in.UnsafeFieldName(false)
in.WantColon()
if in.IsNull() {
in.Skip()
in.WantComma()
continue
}
switch key {
case "playerPublicID":
out.PlayerPublicID = string(in.String())
default:
in.SkipRecursive()
}
in.WantComma()
}
in.Delim('}')
if isTopLevel {
in.Consumed()
}
}
func easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi11(out *jwriter.Writer, in ApproveOrDenyMembershipInvitationPayload) {
out.RawByte('{')
first := true
_ = first
{
const prefix string = ",\"playerPublicID\":"
out.RawString(prefix[1:])
out.String(string(in.PlayerPublicID))
}
out.RawByte('}')
}
// MarshalEasyJSON supports easyjson.Marshaler interface
func (v ApproveOrDenyMembershipInvitationPayload) MarshalEasyJSON(w *jwriter.Writer) {
easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi11(w, v)
}
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (v *ApproveOrDenyMembershipInvitationPayload) UnmarshalEasyJSON(l *jlexer.Lexer) {
easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi11(l, v)
}
func easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi12(in *jlexer.Lexer, out *ApplyForMembershipPayload) {
isTopLevel := in.IsStart()
if in.IsNull() {
if isTopLevel {
in.Consumed()
}
in.Skip()
return
}
in.Delim('{')
for !in.IsDelim('}') {
key := in.UnsafeFieldName(false)
in.WantColon()
if in.IsNull() {
in.Skip()
in.WantComma()
continue
}
switch key {
case "level":
out.Level = string(in.String())
case "playerPublicID":
out.PlayerPublicID = string(in.String())
default:
in.SkipRecursive()
}
in.WantComma()
}
in.Delim('}')
if isTopLevel {
in.Consumed()
}
}
func easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi12(out *jwriter.Writer, in ApplyForMembershipPayload) {
out.RawByte('{')
first := true
_ = first
{
const prefix string = ",\"level\":"
out.RawString(prefix[1:])
out.String(string(in.Level))
}
{
const prefix string = ",\"playerPublicID\":"
out.RawString(prefix)
out.String(string(in.PlayerPublicID))
}
out.RawByte('}')
}
// MarshalEasyJSON supports easyjson.Marshaler interface
func (v ApplyForMembershipPayload) MarshalEasyJSON(w *jwriter.Writer) {
easyjsonA8a797f8EncodeGithubComTopfreegamesKhanApi12(w, v)
}
// UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (v *ApplyForMembershipPayload) UnmarshalEasyJSON(l *jlexer.Lexer) {
easyjsonA8a797f8DecodeGithubComTopfreegamesKhanApi12(l, v)
}