From 57953f6110694d56906ea6a498c05421f3d6fdab Mon Sep 17 00:00:00 2001 From: Rob Genova Date: Tue, 12 Dec 2017 22:01:17 +0000 Subject: [PATCH 001/136] unbold hyperlinks --- website/source/resources.html.erb | 78 +++++++++++++++---------------- 1 file changed, 39 insertions(+), 39 deletions(-) diff --git a/website/source/resources.html.erb b/website/source/resources.html.erb index af6953134..551a73cad 100644 --- a/website/source/resources.html.erb +++ b/website/source/resources.html.erb @@ -29,68 +29,68 @@ description: |-

Blog Posts

Tools for Provisioning and Experimentation

Integrations

Other

Trusted By

    -
  • Barclays
  • -
  • Bownty.com
  • -
  • CircleCI
  • -
  • Citadel
  • -
  • Deluxe Entertainment
  • -
  • Elsevier
  • -
  • Jet.com
  • -
  • Pagerduty
  • -
  • SAP Ariba
  • -
  • SeatGeek
  • -
  • Spaceflight Industries
  • -
  • SpotInst
  • -
  • UnderArmour
  • -
  • Verizon
  • +
  • Barclays
  • +
  • Bownty.com
  • +
  • CircleCI
  • +
  • Citadel
  • +
  • Deluxe Entertainment
  • +
  • Elsevier
  • +
  • Jet.com
  • +
  • Pagerduty
  • +
  • SAP Ariba
  • +
  • SeatGeek
  • +
  • Spaceflight Industries
  • +
  • SpotInst
  • +
  • UnderArmour
  • +
  • Verizon

- If you would like to have a resource or your company name added to this page, please - submit a Pull Request. + If you would like to have a resource or your company name added to this page, please + submit a Pull Request.

From 4cb8b615e34d746ad5a5f9728bc21041b152ebc4 Mon Sep 17 00:00:00 2001 From: Rob Genova Date: Tue, 12 Dec 2017 22:11:15 +0000 Subject: [PATCH 002/136] fix minor formatting/spacing issue --- website/source/docs/drivers/docker.html.md | 1 + 1 file changed, 1 insertion(+) diff --git a/website/source/docs/drivers/docker.html.md b/website/source/docs/drivers/docker.html.md index 584e68a5b..4ea260386 100644 --- a/website/source/docs/drivers/docker.html.md +++ b/website/source/docs/drivers/docker.html.md @@ -328,6 +328,7 @@ The `docker` driver supports the following configuration in the job spec. Only ] } ``` + ### Container Name Nomad creates a container after pulling an image. Containers are named From 0c2c3568a6227d119b1b7c249c23e3b237a0c18c Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Tue, 12 Dec 2017 16:58:27 -0800 Subject: [PATCH 003/136] Skip tests that require root when not root Also skip Chown on allocdir migration on Windows and when non-root. Windows doesn't support it, and it will always fail as a non-root user. --- client/alloc_watcher.go | 12 +++++++++--- client/driver/lxc_test.go | 3 +++ client/driver/qemu_test.go | 1 + client/testutil/driver_compatible.go | 7 +++++++ 4 files changed, 20 insertions(+), 3 deletions(-) diff --git a/client/alloc_watcher.go b/client/alloc_watcher.go index 03aa948f2..99d9e9772 100644 --- a/client/alloc_watcher.go +++ b/client/alloc_watcher.go @@ -9,6 +9,7 @@ import ( "os" "path/filepath" "sync" + "syscall" "time" "github.com/hashicorp/consul/lib" @@ -517,9 +518,14 @@ func (p *remotePrevAlloc) streamAllocDir(ctx context.Context, resp io.ReadCloser f.Close() return fmt.Errorf("error chmoding file %v", err) } - if err := f.Chown(hdr.Uid, hdr.Gid); err != nil { - f.Close() - return fmt.Errorf("error chowning file %v", err) + + // Can't change owner if not root. Returns false on + // Windows as Chown always errors there. + if syscall.Geteuid() == 0 { + if err := f.Chown(hdr.Uid, hdr.Gid); err != nil { + f.Close() + return fmt.Errorf("error chowning file %v", err) + } } // We write in chunks so that we can test if the client diff --git a/client/driver/lxc_test.go b/client/driver/lxc_test.go index ddf8260fd..e9de2dab7 100644 --- a/client/driver/lxc_test.go +++ b/client/driver/lxc_test.go @@ -10,6 +10,7 @@ import ( "time" "github.com/hashicorp/nomad/client/config" + ctestutil "github.com/hashicorp/nomad/client/testutil" "github.com/hashicorp/nomad/nomad/structs" "github.com/hashicorp/nomad/testutil" lxc "gopkg.in/lxc/go-lxc.v2" @@ -61,6 +62,7 @@ func TestLxcDriver_Start_Wait(t *testing.T) { if !lxcPresent(t) { t.Skip("lxc not present") } + ctestutil.RequireRoot(t) task := &structs.Task{ Name: "foo", @@ -137,6 +139,7 @@ func TestLxcDriver_Open_Wait(t *testing.T) { if !lxcPresent(t) { t.Skip("lxc not present") } + ctestutil.RequireRoot(t) task := &structs.Task{ Name: "foo", diff --git a/client/driver/qemu_test.go b/client/driver/qemu_test.go index b0978ec9c..ebab5dae6 100644 --- a/client/driver/qemu_test.go +++ b/client/driver/qemu_test.go @@ -127,6 +127,7 @@ func TestQemuDriver_GracefulShutdown(t *testing.T) { t.Parallel() } ctestutils.QemuCompatible(t) + ctestutils.RequireRoot(t) task := &structs.Task{ Name: "linux", Driver: "qemu", diff --git a/client/testutil/driver_compatible.go b/client/testutil/driver_compatible.go index 996fca131..97f994c44 100644 --- a/client/testutil/driver_compatible.go +++ b/client/testutil/driver_compatible.go @@ -7,6 +7,13 @@ import ( "testing" ) +// RequireRoot skips tests unless running on a Unix as root. +func RequireRoot(t *testing.T) { + if syscall.Geteuid() != 0 { + t.Skip("Must run as root on Unix") + } +} + func ExecCompatible(t *testing.T) { if runtime.GOOS != "linux" || syscall.Geteuid() != 0 { t.Skip("Test only available running as root on linux") From 7cd1f55a3b592ab41dc3ed5356ae6803bf5a0851 Mon Sep 17 00:00:00 2001 From: James Rasell Date: Wed, 13 Dec 2017 10:40:22 +0000 Subject: [PATCH 004/136] Update template.html.md Vault template example The change updates the Vault example within the Environment Variables section to use the `.value` notation rather than the `.key` notation. This is because the example is calling a specific secret key and populating an env var with this; meaning the value of the secret is required over the value. --- website/source/docs/job-specification/template.html.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/website/source/docs/job-specification/template.html.md b/website/source/docs/job-specification/template.html.md index 0c7ef6021..2e3a92275 100644 --- a/website/source/docs/job-specification/template.html.md +++ b/website/source/docs/job-specification/template.html.md @@ -191,7 +191,7 @@ template { # Empty lines are also ignored LOG_LEVEL="{{key "service/geo-api/log-verbosity"}}" -API_KEY="{{with secret "secret/geo-api-key"}}{{.Data.key}}{{end}}" +API_KEY="{{with secret "secret/geo-api-key"}}{{.Data.value}}{{end}}" EOH destination = "secrets/file.env" From ad5a3f069995306233273a5d589ca3f5755eb68f Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Wed, 13 Dec 2017 11:50:12 -0800 Subject: [PATCH 005/136] Lookup euid outside of loop --- client/alloc_watcher.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/client/alloc_watcher.go b/client/alloc_watcher.go index 99d9e9772..e54e7184d 100644 --- a/client/alloc_watcher.go +++ b/client/alloc_watcher.go @@ -453,6 +453,9 @@ func (p *remotePrevAlloc) streamAllocDir(ctx context.Context, resp io.ReadCloser tr := tar.NewReader(resp) defer resp.Close() + // Cache effective uid as we only run Chown if we're root + euid := syscall.Geteuid() + canceled := func() bool { select { case <-ctx.Done(): @@ -521,7 +524,7 @@ func (p *remotePrevAlloc) streamAllocDir(ctx context.Context, resp io.ReadCloser // Can't change owner if not root. Returns false on // Windows as Chown always errors there. - if syscall.Geteuid() == 0 { + if euid == 0 { if err := f.Chown(hdr.Uid, hdr.Gid); err != nil { f.Close() return fmt.Errorf("error chowning file %v", err) From bd23d4989b308a2a03cd2b03bd6b18480c0cdd16 Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Thu, 14 Dec 2017 12:29:55 -0800 Subject: [PATCH 006/136] Lock down nodejs version The new Travis Trusty image uses node 8 (latest LTS) as the default. Node 8 is incompatible with some modules used for the UI. --- .travis.yml | 1 + scripts/travis.sh | 2 +- ui/.nvmrc | 1 + 3 files changed, 3 insertions(+), 1 deletion(-) create mode 100644 ui/.nvmrc diff --git a/.travis.yml b/.travis.yml index da9da6a13..4a40eb16a 100644 --- a/.travis.yml +++ b/.travis.yml @@ -43,6 +43,7 @@ before_install: install: - if [[ -z "$SKIP_NOMAD_TESTS" ]]; then make deps ; fi - if [[ "$RUN_STATIC_CHECKS" ]]; then make lint-deps ; fi + - if [[ "$RUN_UI_TESTS" ]]; then . $HOME/.nvm/nvm.sh && cd ui && nvm use && cd .. ; fi script: - sudo -E "PATH=$PATH" make travis diff --git a/scripts/travis.sh b/scripts/travis.sh index d17aa91e6..8e500f793 100755 --- a/scripts/travis.sh +++ b/scripts/travis.sh @@ -9,7 +9,7 @@ trap 'kill ${PING_LOOP_PID}' EXIT HUP INT QUIT TERM if [ "$RUN_STATIC_CHECKS" ]; then make check - if [ "$TRAVIS_OS_NAME" == "linux" ]; then + if [ "$TRAVIS_OS_NAME" == "linux" ]; then make checkscripts fi fi diff --git a/ui/.nvmrc b/ui/.nvmrc new file mode 100644 index 000000000..1e8b31496 --- /dev/null +++ b/ui/.nvmrc @@ -0,0 +1 @@ +6 From a7ce1543f77ec0ad879a69d0cd78e4abf0c5aa69 Mon Sep 17 00:00:00 2001 From: Rob Genova Date: Fri, 15 Dec 2017 20:35:51 +0000 Subject: [PATCH 007/136] minor formatting fixes and new resources --- website/source/resources.html.erb | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/website/source/resources.html.erb b/website/source/resources.html.erb index 551a73cad..06e43b96b 100644 --- a/website/source/resources.html.erb +++ b/website/source/resources.html.erb @@ -19,7 +19,7 @@ description: |-
  • How Jet.com uses HashiCorp Nomad on Azure to run its applications
  • End to end production Nomad at Citadel
  • HashiCorp Nomad demo and Citadel use case
  • -
  • Verizon Nelson: Multi-region Container Orchestration for Hashicorp Nomad and Lyft Envoy
  • +
  • Nelson: Multi-region Container Orchestration for Hashicorp Nomad and Lyft Envoy
  • Elsevier's Container Framework with Nomad, Terraform, and Consul
  • PagerDuty's Nomadic Journey
  • Operating jobs at scale with Nomad
  • @@ -29,8 +29,9 @@ description: |-

    Blog Posts

      +
    • Cluster Schedulers - Cindy Sridharan
    • Migrating from AWS to AWS - Gabriel Teles
    • -
    • How CircleCI Processes 4.5 Million Builds Per Monthd - Rob Zuber
    • +
    • How CircleCI Processes 4.5 Million Builds Per Month - Rob Zuber
    • Envoy with Nomad and Consul - Tim Perrett
    • Continuous Deployment with Nomad and Terraform - Nic Jackson
    • Running Apache Spark on HashiCorp Nomad - Rob Genova
    • @@ -52,10 +53,10 @@ description: |-

      Integrations

      From f12255e886802617228a9747705cb4f370bff9d2 Mon Sep 17 00:00:00 2001 From: Preetha Appan Date: Mon, 18 Dec 2017 10:03:55 -0600 Subject: [PATCH 008/136] Update eval modify index as part of plan apply. --- nomad/eval_endpoint_test.go | 67 ++++++++++++++ nomad/fsm_test.go | 61 +++++++------ nomad/job_endpoint.go | 2 + nomad/plan_apply.go | 1 + nomad/plan_apply_test.go | 149 +++++++++++++------------------- nomad/state/state_store.go | 35 ++++++++ nomad/state/state_store_test.go | 146 ++++++++++++++++--------------- nomad/structs/structs.go | 6 ++ nomad/worker_test.go | 1 + scheduler/testing.go | 1 + 10 files changed, 283 insertions(+), 186 deletions(-) diff --git a/nomad/eval_endpoint_test.go b/nomad/eval_endpoint_test.go index 6955182c5..238ee9fde 100644 --- a/nomad/eval_endpoint_test.go +++ b/nomad/eval_endpoint_test.go @@ -286,6 +286,73 @@ func TestEvalEndpoint_Dequeue_WaitIndex(t *testing.T) { } } +func TestEvalEndpoint_Dequeue_UpdateWaitIndex(t *testing.T) { + // test enqueing an eval, updating a plan result for the same eval and dequeing the eval + t.Parallel() + s1 := testServer(t, func(c *Config) { + c.NumSchedulers = 0 // Prevent automatic dequeue + }) + defer s1.Shutdown() + codec := rpcClient(t, s1) + testutil.WaitForLeader(t, s1.RPC) + + alloc := mock.Alloc() + job := alloc.Job + alloc.Job = nil + + state := s1.fsm.State() + + if err := state.UpsertJob(999, job); err != nil { + t.Fatalf("err: %v", err) + } + + eval := mock.Eval() + eval.JobID = job.ID + + // Create an eval + if err := state.UpsertEvals(1, []*structs.Evaluation{eval}); err != nil { + t.Fatalf("err: %v", err) + } + + s1.evalBroker.Enqueue(eval) + + // Create a plan result and apply it with a later index + res := structs.ApplyPlanResultsRequest{ + AllocUpdateRequest: structs.AllocUpdateRequest{ + Alloc: []*structs.Allocation{alloc}, + Job: job, + }, + EvalID: eval.ID, + } + assert := assert.New(t) + err := state.UpsertPlanResults(1000, &res) + assert.Nil(err) + + // Dequeue the eval + get := &structs.EvalDequeueRequest{ + Schedulers: defaultSched, + SchedulerVersion: scheduler.SchedulerVersion, + WriteRequest: structs.WriteRequest{Region: "global"}, + } + var resp structs.EvalDequeueResponse + if err := msgpackrpc.CallWithCodec(codec, "Eval.Dequeue", get, &resp); err != nil { + t.Fatalf("err: %v", err) + } + + // Ensure outstanding + token, ok := s1.evalBroker.Outstanding(eval.ID) + if !ok { + t.Fatalf("should be outstanding") + } + if token != resp.Token { + t.Fatalf("bad token: %#v %#v", token, resp.Token) + } + + if resp.WaitIndex != 1000 { + t.Fatalf("bad wait index; got %d; want %d", resp.WaitIndex, 1000) + } +} + func TestEvalEndpoint_Dequeue_Version_Mismatch(t *testing.T) { t.Parallel() s1 := testServer(t, func(c *Config) { diff --git a/nomad/fsm_test.go b/nomad/fsm_test.go index 4f9051add..8414cb75c 100644 --- a/nomad/fsm_test.go +++ b/nomad/fsm_test.go @@ -1213,6 +1213,10 @@ func TestFSM_ApplyPlanResults(t *testing.T) { alloc.DeploymentID = d.ID + eval := mock.Eval() + eval.JobID = job.ID + fsm.State().UpsertEvals(1, []*structs.Evaluation{eval}) + fsm.State().UpsertJobSummary(1, mock.JobSummary(alloc.JobID)) req := structs.ApplyPlanResultsRequest{ AllocUpdateRequest: structs.AllocUpdateRequest{ @@ -1220,6 +1224,7 @@ func TestFSM_ApplyPlanResults(t *testing.T) { Alloc: []*structs.Allocation{alloc}, }, Deployment: d, + EvalID: eval.ID, } buf, err := structs.Encode(structs.ApplyPlanResultsRequestType, req) if err != nil { @@ -1233,32 +1238,32 @@ func TestFSM_ApplyPlanResults(t *testing.T) { // Verify the allocation is registered ws := memdb.NewWatchSet() + assert := assert.New(t) out, err := fsm.State().AllocByID(ws, alloc.ID) - if err != nil { - t.Fatalf("err: %v", err) - } + assert.Nil(err) alloc.CreateIndex = out.CreateIndex alloc.ModifyIndex = out.ModifyIndex alloc.AllocModifyIndex = out.AllocModifyIndex // Job should be re-attached alloc.Job = job - if !reflect.DeepEqual(alloc, out) { - t.Fatalf("bad: %#v %#v", alloc, out) - } + assert.Equal(alloc, out) dout, err := fsm.State().DeploymentByID(ws, d.ID) - if err != nil { - t.Fatalf("err: %v", err) - } - if tg, ok := dout.TaskGroups[alloc.TaskGroup]; !ok || tg.PlacedAllocs != 1 { - t.Fatalf("err: %v %v", tg, err) - } + assert.Nil(err) + tg, ok := dout.TaskGroups[alloc.TaskGroup] + assert.True(ok) + assert.NotNil(tg) + assert.Equal(1, tg.PlacedAllocs) // Ensure that the original job is used evictAlloc := alloc.Copy() job = mock.Job() job.Priority = 123 + eval = mock.Eval() + eval.JobID = job.ID + + fsm.State().UpsertEvals(2, []*structs.Evaluation{eval}) evictAlloc.Job = nil evictAlloc.DesiredStatus = structs.AllocDesiredStatusEvict @@ -1267,28 +1272,28 @@ func TestFSM_ApplyPlanResults(t *testing.T) { Job: job, Alloc: []*structs.Allocation{evictAlloc}, }, + EvalID: eval.ID, } buf, err = structs.Encode(structs.ApplyPlanResultsRequestType, req2) - if err != nil { - t.Fatalf("err: %v", err) - } + assert.Nil(err) - resp = fsm.Apply(makeLog(buf)) - if resp != nil { - t.Fatalf("resp: %v", resp) - } + log := makeLog(buf) + //set the index to something other than 1 + log.Index = 25 + resp = fsm.Apply(log) + assert.Nil(resp) // Verify we are evicted out, err = fsm.State().AllocByID(ws, alloc.ID) - if err != nil { - t.Fatalf("err: %v", err) - } - if out.DesiredStatus != structs.AllocDesiredStatusEvict { - t.Fatalf("alloc found!") - } - if out.Job == nil || out.Job.Priority == 123 { - t.Fatalf("bad job") - } + assert.Nil(err) + assert.Equal(structs.AllocDesiredStatusEvict, out.DesiredStatus) + assert.NotNil(out.Job) + assert.NotEqual(123, out.Job.Priority) + + evalOut, err := fsm.State().EvalByID(ws, eval.ID) + assert.Nil(err) + assert.Equal(log.Index, evalOut.ModifyIndex) + } func TestFSM_DeploymentStatusUpdate(t *testing.T) { diff --git a/nomad/job_endpoint.go b/nomad/job_endpoint.go index 572b96b81..c85abf7c7 100644 --- a/nomad/job_endpoint.go +++ b/nomad/job_endpoint.go @@ -1088,6 +1088,8 @@ func (j *Job) Plan(args *structs.JobPlanRequest, reply *structs.JobPlanResponse) AnnotatePlan: true, } + snap.UpsertEvals(100, []*structs.Evaluation{eval}) + // Create an in-memory Planner that returns no errors and stores the // submitted plan and created evals. planner := &scheduler.Harness{ diff --git a/nomad/plan_apply.go b/nomad/plan_apply.go index 5d2c29bcf..44f78e2c8 100644 --- a/nomad/plan_apply.go +++ b/nomad/plan_apply.go @@ -135,6 +135,7 @@ func (s *Server) applyPlan(plan *structs.Plan, result *structs.PlanResult, snap }, Deployment: result.Deployment, DeploymentUpdates: result.DeploymentUpdates, + EvalID: plan.EvalID, } for _, updateList := range result.NodeUpdate { req.Alloc = append(req.Alloc, updateList...) diff --git a/nomad/plan_apply_test.go b/nomad/plan_apply_test.go index 7d3195d92..93e44e617 100644 --- a/nomad/plan_apply_test.go +++ b/nomad/plan_apply_test.go @@ -10,6 +10,7 @@ import ( "github.com/hashicorp/nomad/nomad/structs" "github.com/hashicorp/nomad/testutil" "github.com/hashicorp/raft" + "github.com/stretchr/testify/assert" ) const ( @@ -65,7 +66,7 @@ func TestPlanApply_applyPlan(t *testing.T) { defer s1.Shutdown() testutil.WaitForLeader(t, s1.RPC) - // Register ndoe + // Register node node := mock.Node() testRegisterNode(t, s1, node) @@ -91,6 +92,13 @@ func TestPlanApply_applyPlan(t *testing.T) { // Register alloc, deployment and deployment update alloc := mock.Alloc() s1.State().UpsertJobSummary(1000, mock.JobSummary(alloc.JobID)) + // Create an eval + eval := mock.Eval() + eval.JobID = alloc.JobID + if err := s1.State().UpsertEvals(1, []*structs.Evaluation{eval}); err != nil { + t.Fatalf("err: %v", err) + } + planRes := &structs.PlanResult{ NodeAllocation: map[string][]*structs.Allocation{ node.ID: {alloc}, @@ -110,73 +118,55 @@ func TestPlanApply_applyPlan(t *testing.T) { Job: alloc.Job, Deployment: dnew, DeploymentUpdates: updates, + EvalID: eval.ID, } // Apply the plan future, err := s1.applyPlan(plan, planRes, snap) - if err != nil { - t.Fatalf("err: %v", err) - } + assert := assert.New(t) + assert.Nil(err) // Verify our optimistic snapshot is updated ws := memdb.NewWatchSet() - if out, err := snap.AllocByID(ws, alloc.ID); err != nil || out == nil { - t.Fatalf("bad: %v %v", out, err) - } + allocOut, err := snap.AllocByID(ws, alloc.ID) + assert.Nil(err) + assert.NotNil(allocOut) - if out, err := snap.DeploymentByID(ws, plan.Deployment.ID); err != nil || out == nil { - t.Fatalf("bad: %v %v", out, err) - } + deploymentOut, err := snap.DeploymentByID(ws, plan.Deployment.ID) + assert.Nil(err) + assert.NotNil(deploymentOut) // Check plan does apply cleanly index, err := planWaitFuture(future) - if err != nil { - t.Fatalf("err: %v", err) - } - if index == 0 { - t.Fatalf("bad: %d", index) - } + assert.Nil(err) + assert.NotEqual(0, index) // Lookup the allocation fsmState := s1.fsm.State() - out, err := fsmState.AllocByID(ws, alloc.ID) - if err != nil { - t.Fatalf("err: %v", err) - } - if out == nil { - t.Fatalf("missing alloc") - } - - if out.CreateTime <= 0 { - t.Fatalf("invalid create time %v", out.CreateTime) - } - if out.ModifyTime <= 0 { - t.Fatalf("invalid modify time %v", out.CreateTime) - } - if out.CreateTime != out.ModifyTime { - t.Fatalf("create time %v modify time %v must be equal", out.CreateTime, out.ModifyTime) - } + allocOut, err = fsmState.AllocByID(ws, alloc.ID) + assert.Nil(err) + assert.NotNil(allocOut) + assert.True(allocOut.CreateTime > 0) + assert.True(allocOut.ModifyTime > 0) + assert.Equal(allocOut.CreateTime, allocOut.ModifyTime) // Lookup the new deployment dout, err := fsmState.DeploymentByID(ws, plan.Deployment.ID) - if err != nil { - t.Fatalf("err: %v", err) - } - if dout == nil { - t.Fatalf("missing deployment") - } + assert.Nil(err) + assert.NotNil(dout) // Lookup the updated deployment dout2, err := fsmState.DeploymentByID(ws, oldDeployment.ID) - if err != nil { - t.Fatalf("err: %v", err) - } - if dout2 == nil { - t.Fatalf("missing deployment") - } - if dout2.Status != desiredStatus || dout2.StatusDescription != desiredStatusDescription { - t.Fatalf("bad status: %#v", dout2) - } + assert.Nil(err) + assert.NotNil(dout2) + assert.Equal(desiredStatus, dout2.Status) + assert.Equal(desiredStatusDescription, dout2.StatusDescription) + + // Lookup updated eval + evalOut, err := fsmState.EvalByID(ws, eval.ID) + assert.Nil(err) + assert.NotNil(evalOut) + assert.Equal(index, evalOut.ModifyIndex) // Evict alloc, Register alloc2 allocEvict := new(structs.Allocation) @@ -197,60 +187,43 @@ func TestPlanApply_applyPlan(t *testing.T) { // Snapshot the state snap, err = s1.State().Snapshot() - if err != nil { - t.Fatalf("err: %v", err) - } + assert.Nil(err) // Apply the plan plan = &structs.Plan{ - Job: job, + Job: job, + EvalID: eval.ID, } future, err = s1.applyPlan(plan, planRes, snap) - if err != nil { - t.Fatalf("err: %v", err) - } + assert.Nil(err) // Check that our optimistic view is updated - if out, _ := snap.AllocByID(ws, allocEvict.ID); out.DesiredStatus != structs.AllocDesiredStatusEvict { - t.Fatalf("bad: %#v", out) - } + out, _ := snap.AllocByID(ws, allocEvict.ID) + assert.Equal(structs.AllocDesiredStatusEvict, out.DesiredStatus) // Verify plan applies cleanly index, err = planWaitFuture(future) - if err != nil { - t.Fatalf("err: %v", err) - } - if index == 0 { - t.Fatalf("bad: %d", index) - } + assert.Nil(err) + assert.NotEqual(0, index) // Lookup the allocation - out, err = s1.fsm.State().AllocByID(ws, alloc.ID) - if err != nil { - t.Fatalf("err: %v", err) - } - if out.DesiredStatus != structs.AllocDesiredStatusEvict { - t.Fatalf("should be evicted alloc: %#v", out) - } - if out.Job == nil { - t.Fatalf("missing job") - } - - if out.ModifyTime <= 0 { - t.Fatalf("must have valid modify time but was %v", out.ModifyTime) - } + allocOut, err = s1.fsm.State().AllocByID(ws, alloc.ID) + assert.Nil(err) + assert.Equal(structs.AllocDesiredStatusEvict, allocOut.DesiredStatus) + assert.NotNil(allocOut.Job) + assert.True(allocOut.ModifyTime > 0) // Lookup the allocation - out, err = s1.fsm.State().AllocByID(ws, alloc2.ID) - if err != nil { - t.Fatalf("err: %v", err) - } - if out == nil { - t.Fatalf("missing alloc") - } - if out.Job == nil { - t.Fatalf("missing job") - } + allocOut, err = s1.fsm.State().AllocByID(ws, alloc2.ID) + assert.Nil(err) + assert.NotNil(allocOut) + assert.NotNil(allocOut.Job) + + // Lookup updated eval + evalOut, err = fsmState.EvalByID(ws, eval.ID) + assert.Nil(err) + assert.NotNil(evalOut) + assert.Equal(index, evalOut.ModifyIndex) } func TestPlanApply_EvalPlan_Simple(t *testing.T) { diff --git a/nomad/state/state_store.go b/nomad/state/state_store.go index 0091055b3..92e9605a7 100644 --- a/nomad/state/state_store.go +++ b/nomad/state/state_store.go @@ -196,6 +196,11 @@ func (s *StateStore) UpsertPlanResults(index uint64, results *structs.ApplyPlanR return err } + // Update the modify index of the eval id + if err := s.updateEvalModifyIndex(txn, index, results.EvalID); err != nil { + return err + } + txn.Commit() return nil } @@ -1486,6 +1491,36 @@ func (s *StateStore) nestedUpsertEval(txn *memdb.Txn, index uint64, eval *struct return nil } +// updateEvalModifyIndex is used to update the modify index of an evaluation that has been +// through a scheduler pass. This is done as part of plan apply. It ensures that when a subsequent +// scheduler workers process a re-queued evaluation it sees any partial updates from the plan apply. +func (s *StateStore) updateEvalModifyIndex(txn *memdb.Txn, index uint64, evalID string) error { + // Lookup the evaluation + existing, err := txn.First("evals", "id", evalID) + if err != nil { + return fmt.Errorf("eval lookup failed: %v", err) + } + if existing == nil { + // return if there isn't an eval with this ID. + // In some cases (like snapshot restores), we process evals that are not already in the state store. + s.logger.Printf("[WARN] state_store: unable to find eval ID %v, cannot update modify index ", evalID) + return nil + } + eval := existing.(*structs.Evaluation).Copy() + // Update the indexes + eval.CreateIndex = existing.(*structs.Evaluation).CreateIndex + eval.ModifyIndex = index + + // Insert the eval + if err := txn.Insert("evals", eval); err != nil { + return fmt.Errorf("eval insert failed: %v", err) + } + if err := txn.Insert("index", &IndexEntry{"evals", index}); err != nil { + return fmt.Errorf("index update failed: %v", err) + } + return nil +} + // DeleteEval is used to delete an evaluation func (s *StateStore) DeleteEval(index uint64, evals []string, allocs []string) error { txn := s.db.Txn(true) diff --git a/nomad/state/state_store_test.go b/nomad/state/state_store_test.go index 38081ccfc..6c0a5b567 100644 --- a/nomad/state/state_store_test.go +++ b/nomad/state/state_store_test.go @@ -100,40 +100,43 @@ func TestStateStore_UpsertPlanResults_AllocationsCreated_Denormalized(t *testing t.Fatalf("err: %v", err) } + eval := mock.Eval() + eval.JobID = job.ID + + // Create an eval + if err := state.UpsertEvals(1, []*structs.Evaluation{eval}); err != nil { + t.Fatalf("err: %v", err) + } + // Create a plan result res := structs.ApplyPlanResultsRequest{ AllocUpdateRequest: structs.AllocUpdateRequest{ Alloc: []*structs.Allocation{alloc}, Job: job, }, + EvalID: eval.ID, } - + assert := assert.New(t) err := state.UpsertPlanResults(1000, &res) - if err != nil { - t.Fatalf("err: %v", err) - } + assert.Nil(err) ws := memdb.NewWatchSet() out, err := state.AllocByID(ws, alloc.ID) - if err != nil { - t.Fatalf("err: %v", err) - } - - if !reflect.DeepEqual(alloc, out) { - t.Fatalf("bad: %#v %#v", alloc, out) - } + assert.Nil(err) + assert.Equal(alloc, out) index, err := state.Index("allocs") - if err != nil { - t.Fatalf("err: %v", err) - } - if index != 1000 { - t.Fatalf("bad: %d", index) - } + assert.Nil(err) + assert.Equal(uint64(1000), index) if watchFired(ws) { t.Fatalf("bad") } + + evalOut, err := state.EvalByID(ws, eval.ID) + assert.Nil(err) + assert.NotNil(evalOut) + assert.Equal(uint64(1000), evalOut.ModifyIndex) } // This test checks that the deployment is created and allocations count towards @@ -154,6 +157,14 @@ func TestStateStore_UpsertPlanResults_Deployment(t *testing.T) { t.Fatalf("err: %v", err) } + eval := mock.Eval() + eval.JobID = job.ID + + // Create an eval + if err := state.UpsertEvals(1, []*structs.Evaluation{eval}); err != nil { + t.Fatalf("err: %v", err) + } + // Create a plan result res := structs.ApplyPlanResultsRequest{ AllocUpdateRequest: structs.AllocUpdateRequest{ @@ -161,6 +172,7 @@ func TestStateStore_UpsertPlanResults_Deployment(t *testing.T) { Job: job, }, Deployment: d, + EvalID: eval.ID, } err := state.UpsertPlanResults(1000, &res) @@ -169,31 +181,24 @@ func TestStateStore_UpsertPlanResults_Deployment(t *testing.T) { } ws := memdb.NewWatchSet() + assert := assert.New(t) out, err := state.AllocByID(ws, alloc.ID) - if err != nil { - t.Fatalf("err: %v", err) - } - - if !reflect.DeepEqual(alloc, out) { - t.Fatalf("bad: %#v %#v", alloc, out) - } + assert.Nil(err) + assert.Equal(alloc, out) dout, err := state.DeploymentByID(ws, d.ID) - if err != nil { - t.Fatalf("err: %v", err) - } - - if dout == nil { - t.Fatalf("bad: nil deployment") - } + assert.Nil(err) + assert.NotNil(dout) tg, ok := dout.TaskGroups[alloc.TaskGroup] - if !ok { - t.Fatalf("bad: nil deployment state") - } - if tg == nil || tg.PlacedAllocs != 2 { - t.Fatalf("bad: %v", dout) - } + assert.True(ok) + assert.NotNil(tg) + assert.Equal(2, tg.PlacedAllocs) + + evalOut, err := state.EvalByID(ws, eval.ID) + assert.Nil(err) + assert.NotNil(evalOut) + assert.Equal(uint64(1000), evalOut.ModifyIndex) if watchFired(ws) { t.Fatalf("bad") @@ -215,6 +220,7 @@ func TestStateStore_UpsertPlanResults_Deployment(t *testing.T) { Job: job, }, Deployment: d2, + EvalID: eval.ID, } err = state.UpsertPlanResults(1001, &res) @@ -223,21 +229,18 @@ func TestStateStore_UpsertPlanResults_Deployment(t *testing.T) { } dout, err = state.DeploymentByID(ws, d2.ID) - if err != nil { - t.Fatalf("err: %v", err) - } - - if dout == nil { - t.Fatalf("bad: nil deployment") - } + assert.Nil(err) + assert.NotNil(dout) tg, ok = dout.TaskGroups[alloc.TaskGroup] - if !ok { - t.Fatalf("bad: nil deployment state") - } - if tg == nil || tg.PlacedAllocs != 2 { - t.Fatalf("bad: %v", dout) - } + assert.True(ok) + assert.NotNil(tg) + assert.Equal(2, tg.PlacedAllocs) + + evalOut, err = state.EvalByID(ws, eval.ID) + assert.Nil(err) + assert.NotNil(evalOut) + assert.Equal(uint64(1001), evalOut.ModifyIndex) } // This test checks that deployment updates are applied correctly @@ -258,6 +261,13 @@ func TestStateStore_UpsertPlanResults_DeploymentUpdates(t *testing.T) { t.Fatalf("err: %v", err) } + eval := mock.Eval() + eval.JobID = job.ID + + // Create an eval + if err := state.UpsertEvals(1, []*structs.Evaluation{eval}); err != nil { + t.Fatalf("err: %v", err) + } alloc := mock.Alloc() alloc.Job = nil @@ -280,41 +290,37 @@ func TestStateStore_UpsertPlanResults_DeploymentUpdates(t *testing.T) { }, Deployment: dnew, DeploymentUpdates: []*structs.DeploymentStatusUpdate{update}, + EvalID: eval.ID, } err := state.UpsertPlanResults(1000, &res) if err != nil { t.Fatalf("err: %v", err) } - + assert := assert.New(t) ws := memdb.NewWatchSet() // Check the deployments are correctly updated. dout, err := state.DeploymentByID(ws, dnew.ID) - if err != nil { - t.Fatalf("err: %v", err) - } - - if dout == nil { - t.Fatalf("bad: nil deployment") - } + assert.Nil(err) + assert.NotNil(dout) tg, ok := dout.TaskGroups[alloc.TaskGroup] - if !ok { - t.Fatalf("bad: nil deployment state") - } - if tg == nil || tg.PlacedAllocs != 1 { - t.Fatalf("bad: %v", dout) - } + assert.True(ok) + assert.NotNil(tg) + assert.Equal(1, tg.PlacedAllocs) doutstandingout, err := state.DeploymentByID(ws, doutstanding.ID) - if err != nil || doutstandingout == nil { - t.Fatalf("bad: %v %v", err, doutstandingout) - } - if doutstandingout.Status != update.Status || doutstandingout.StatusDescription != update.StatusDescription || doutstandingout.ModifyIndex != 1000 { - t.Fatalf("bad: %v", doutstandingout) - } + assert.Nil(err) + assert.NotNil(doutstandingout) + assert.Equal(update.Status, doutstandingout.Status) + assert.Equal(update.StatusDescription, doutstandingout.StatusDescription) + assert.Equal(uint64(1000), doutstandingout.ModifyIndex) + evalOut, err := state.EvalByID(ws, eval.ID) + assert.Nil(err) + assert.NotNil(evalOut) + assert.Equal(uint64(1000), evalOut.ModifyIndex) if watchFired(ws) { t.Fatalf("bad") } diff --git a/nomad/structs/structs.go b/nomad/structs/structs.go index b15f38811..ea5fe5690 100644 --- a/nomad/structs/structs.go +++ b/nomad/structs/structs.go @@ -514,6 +514,12 @@ type ApplyPlanResultsRequest struct { // deployments. This allows the scheduler to cancel any unneeded deployment // because the job is stopped or the update block is removed. DeploymentUpdates []*DeploymentStatusUpdate + + // EvalID is the eval ID of the plan being applied. We also update the modify + // index of the eval ID as part of applying plan results. This is to ensure that + // other workers that are dequeing evaluations don't miss updates that can affect + // scheduling decisions. + EvalID string } // AllocUpdateRequest is used to submit changes to allocations, either diff --git a/nomad/worker_test.go b/nomad/worker_test.go index 627887e31..faa9cc104 100644 --- a/nomad/worker_test.go +++ b/nomad/worker_test.go @@ -341,6 +341,7 @@ func TestWorker_SubmitPlan(t *testing.T) { eval1 := mock.Eval() eval1.JobID = job.ID s1.fsm.State().UpsertJob(1000, job) + s1.fsm.State().UpsertEvals(1000, []*structs.Evaluation{eval1}) // Create the register request s1.evalBroker.Enqueue(eval1) diff --git a/scheduler/testing.go b/scheduler/testing.go index fb631d444..a04b99ce8 100644 --- a/scheduler/testing.go +++ b/scheduler/testing.go @@ -122,6 +122,7 @@ func (h *Harness) SubmitPlan(plan *structs.Plan) (*structs.PlanResult, State, er }, Deployment: plan.Deployment, DeploymentUpdates: plan.DeploymentUpdates, + EvalID: plan.EvalID, } // Apply the full plan From aa35b5b9f21f53b3a054d23831e1f33c3c062e61 Mon Sep 17 00:00:00 2001 From: Preetha Appan Date: Mon, 18 Dec 2017 14:55:36 -0600 Subject: [PATCH 009/136] Return an error if evaluation doesn't exist in state store at plan apply time. --- nomad/fsm.go | 4 +- nomad/state/state_store.go | 5 +- scheduler/generic_sched_test.go | 106 +++++++++++++++++++++++++++++++- scheduler/system_sched_test.go | 55 +++++++++++++++-- 4 files changed, 158 insertions(+), 12 deletions(-) diff --git a/nomad/fsm.go b/nomad/fsm.go index 7d0ef4fc4..0a004c836 100644 --- a/nomad/fsm.go +++ b/nomad/fsm.go @@ -1104,7 +1104,7 @@ func (n *nomadFSM) Restore(old io.ReadCloser) error { return nil } -// reconcileSummaries re-calculates the queued allocations for every job that we +// reconcileQueuedAllocations re-calculates the queued allocations for every job that we // created a Job Summary during the snap shot restore func (n *nomadFSM) reconcileQueuedAllocations(index uint64) error { // Get all the jobs @@ -1142,7 +1142,7 @@ func (n *nomadFSM) reconcileQueuedAllocations(index uint64) error { Status: structs.EvalStatusPending, AnnotatePlan: true, } - + snap.UpsertEvals(100, []*structs.Evaluation{eval}) // Create the scheduler and run it sched, err := scheduler.NewScheduler(eval.Type, n.logger, snap, planner) if err != nil { diff --git a/nomad/state/state_store.go b/nomad/state/state_store.go index 92e9605a7..98e1d5580 100644 --- a/nomad/state/state_store.go +++ b/nomad/state/state_store.go @@ -1501,10 +1501,7 @@ func (s *StateStore) updateEvalModifyIndex(txn *memdb.Txn, index uint64, evalID return fmt.Errorf("eval lookup failed: %v", err) } if existing == nil { - // return if there isn't an eval with this ID. - // In some cases (like snapshot restores), we process evals that are not already in the state store. - s.logger.Printf("[WARN] state_store: unable to find eval ID %v, cannot update modify index ", evalID) - return nil + return fmt.Errorf("[ERR] state_store: unable to find eval id %q", evalID) } eval := existing.(*structs.Evaluation).Copy() // Update the indexes diff --git a/scheduler/generic_sched_test.go b/scheduler/generic_sched_test.go index 02296ff76..0e88b4255 100644 --- a/scheduler/generic_sched_test.go +++ b/scheduler/generic_sched_test.go @@ -35,8 +35,11 @@ func TestServiceSched_JobRegister(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) + // Process the evaluation err := h.Process(NewServiceScheduler, eval) if err != nil { @@ -118,7 +121,9 @@ func TestServiceSched_JobRegister_StickyAllocs(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation if err := h.Process(NewServiceScheduler, eval); err != nil { @@ -149,7 +154,9 @@ func TestServiceSched_JobRegister_StickyAllocs(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerNodeUpdate, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) h1 := NewHarnessWithState(t, h.State) if err := h1.Process(NewServiceScheduler, eval); err != nil { t.Fatalf("err: %v", err) @@ -206,8 +213,11 @@ func TestServiceSched_JobRegister_DiskConstraints(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) + // Process the evaluation err := h.Process(NewServiceScheduler, eval) if err != nil { @@ -275,8 +285,11 @@ func TestServiceSched_JobRegister_DistinctHosts(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) + // Process the evaluation err := h.Process(NewServiceScheduler, eval) if err != nil { @@ -364,8 +377,11 @@ func TestServiceSched_JobRegister_DistinctProperty(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) + // Process the evaluation err := h.Process(NewServiceScheduler, eval) if err != nil { @@ -456,7 +472,9 @@ func TestServiceSched_JobRegister_DistinctProperty_TaskGroup(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) @@ -548,7 +566,9 @@ func TestServiceSched_JobRegister_DistinctProperty_TaskGroup_Incr(t *testing.T) Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation assert.Nil(h.Process(NewServiceScheduler, eval), "Process") @@ -602,7 +622,9 @@ func TestServiceSched_JobRegister_Annotate(t *testing.T) { TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, AnnotatePlan: true, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) @@ -679,7 +701,9 @@ func TestServiceSched_JobRegister_CountZero(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) @@ -720,8 +744,11 @@ func TestServiceSched_JobRegister_AllocFail(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) + // Process the evaluation err := h.Process(NewServiceScheduler, eval) if err != nil { @@ -802,8 +829,11 @@ func TestServiceSched_JobRegister_CreateBlockedEval(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) + // Process the evaluation err := h.Process(NewServiceScheduler, eval) if err != nil { @@ -899,8 +929,9 @@ func TestServiceSched_JobRegister_FeasibleAndInfeasibleTG(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } - + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) if err != nil { @@ -1016,8 +1047,11 @@ func TestServiceSched_Plan_Partial_Progress(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) + // Process the evaluation err := h.Process(NewServiceScheduler, eval) if err != nil { @@ -1245,7 +1279,9 @@ func TestServiceSched_JobModify(t *testing.T) { Priority: 50, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) @@ -1329,7 +1365,9 @@ func TestServiceSched_JobModify_IncrCount_NodeLimit(t *testing.T) { Priority: 50, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) @@ -1436,7 +1474,9 @@ func TestServiceSched_JobModify_CountZero(t *testing.T) { Priority: 50, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) @@ -1530,7 +1570,9 @@ func TestServiceSched_JobModify_Rolling(t *testing.T) { Priority: 50, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) @@ -1635,7 +1677,9 @@ func TestServiceSched_JobModify_Rolling_FullNode(t *testing.T) { Priority: 50, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) @@ -1736,7 +1780,9 @@ func TestServiceSched_JobModify_Canaries(t *testing.T) { Priority: 50, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) @@ -1844,7 +1890,9 @@ func TestServiceSched_JobModify_InPlace(t *testing.T) { Priority: 50, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) @@ -1958,7 +2006,9 @@ func TestServiceSched_JobModify_DistinctProperty(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) @@ -2044,7 +2094,9 @@ func TestServiceSched_JobDeregister_Purged(t *testing.T) { Priority: 50, TriggeredBy: structs.EvalTriggerJobDeregister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) @@ -2111,7 +2163,9 @@ func TestServiceSched_JobDeregister_Stopped(t *testing.T) { Priority: 50, TriggeredBy: structs.EvalTriggerJobDeregister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) @@ -2201,7 +2255,9 @@ func TestServiceSched_NodeDown(t *testing.T) { TriggeredBy: structs.EvalTriggerNodeUpdate, JobID: job.ID, NodeID: node.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) @@ -2267,7 +2323,9 @@ func TestServiceSched_NodeUpdate(t *testing.T) { TriggeredBy: structs.EvalTriggerNodeUpdate, JobID: job.ID, NodeID: node.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) @@ -2318,7 +2376,9 @@ func TestServiceSched_NodeDrain(t *testing.T) { TriggeredBy: structs.EvalTriggerNodeUpdate, JobID: job.ID, NodeID: node.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) @@ -2419,8 +2479,11 @@ func TestServiceSched_NodeDrain_Down(t *testing.T) { TriggeredBy: structs.EvalTriggerNodeUpdate, JobID: job.ID, NodeID: node.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) + // Process the evaluation err := h.Process(NewServiceScheduler, eval) if err != nil { @@ -2493,7 +2556,9 @@ func TestServiceSched_NodeDrain_Queued_Allocations(t *testing.T) { TriggeredBy: structs.EvalTriggerNodeUpdate, JobID: job.ID, NodeID: node.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) @@ -2550,7 +2615,9 @@ func TestServiceSched_NodeDrain_UpdateStrategy(t *testing.T) { TriggeredBy: structs.EvalTriggerNodeUpdate, JobID: job.ID, NodeID: node.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) @@ -2608,7 +2675,9 @@ func TestServiceSched_RetryLimit(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) @@ -2664,7 +2733,9 @@ func TestBatchSched_Run_CompleteAlloc(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewBatchScheduler, eval) @@ -2719,7 +2790,9 @@ func TestBatchSched_Run_FailedAlloc(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewBatchScheduler, eval) @@ -2781,7 +2854,9 @@ func TestBatchSched_Run_FailedAllocQueuedAllocations(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewBatchScheduler, eval) @@ -2841,7 +2916,9 @@ func TestBatchSched_ReRun_SuccessfullyFinishedAlloc(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewBatchScheduler, eval) @@ -2904,7 +2981,9 @@ func TestBatchSched_JobModify_InPlace_Terminal(t *testing.T) { Priority: 50, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewBatchScheduler, eval) @@ -2985,7 +3064,9 @@ func TestBatchSched_JobModify_Destructive_Terminal(t *testing.T) { Priority: 50, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewBatchScheduler, eval) @@ -3039,8 +3120,11 @@ func TestBatchSched_NodeDrain_Running_OldJob(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) + // Process the evaluation err := h.Process(NewBatchScheduler, eval) if err != nil { @@ -3102,8 +3186,11 @@ func TestBatchSched_NodeDrain_Complete(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) + // Process the evaluation err := h.Process(NewBatchScheduler, eval) if err != nil { @@ -3154,8 +3241,11 @@ func TestBatchSched_ScaleDown_SameName(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) + // Process the evaluation err := h.Process(NewBatchScheduler, eval) if err != nil { @@ -3197,7 +3287,9 @@ func TestGenericSched_ChainedAlloc(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation if err := h.Process(NewServiceScheduler, eval); err != nil { t.Fatalf("err: %v", err) @@ -3226,7 +3318,10 @@ func TestGenericSched_ChainedAlloc(t *testing.T) { Priority: job1.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job1.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval1})) + // Process the evaluation if err := h1.Process(NewServiceScheduler, eval1); err != nil { t.Fatalf("err: %v", err) @@ -3287,8 +3382,11 @@ func TestServiceSched_NodeDrain_Sticky(t *testing.T) { TriggeredBy: structs.EvalTriggerNodeUpdate, JobID: alloc.Job.ID, NodeID: node.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) + // Process the evaluation err := h.Process(NewServiceScheduler, eval) if err != nil { @@ -3344,8 +3442,11 @@ func TestServiceSched_CancelDeployment_Stopped(t *testing.T) { Priority: 50, TriggeredBy: structs.EvalTriggerJobDeregister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) + // Process the evaluation err := h.Process(NewServiceScheduler, eval) if err != nil { @@ -3413,8 +3514,11 @@ func TestServiceSched_CancelDeployment_NewerJob(t *testing.T) { Priority: 50, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) + // Process the evaluation err := h.Process(NewServiceScheduler, eval) if err != nil { diff --git a/scheduler/system_sched_test.go b/scheduler/system_sched_test.go index be43026a1..2e0535500 100644 --- a/scheduler/system_sched_test.go +++ b/scheduler/system_sched_test.go @@ -32,7 +32,9 @@ func TestSystemSched_JobRegister(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewSystemScheduler, eval) @@ -105,7 +107,9 @@ func TestSystemeSched_JobRegister_StickyAllocs(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation if err := h.Process(NewSystemScheduler, eval); err != nil { @@ -134,7 +138,9 @@ func TestSystemeSched_JobRegister_StickyAllocs(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerNodeUpdate, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) h1 := NewHarnessWithState(t, h.State) if err := h1.Process(NewSystemScheduler, eval); err != nil { t.Fatalf("err: %v", err) @@ -181,7 +187,9 @@ func TestSystemSched_JobRegister_EphemeralDiskConstraint(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation if err := h.Process(NewSystemScheduler, eval); err != nil { @@ -207,7 +215,9 @@ func TestSystemSched_JobRegister_EphemeralDiskConstraint(t *testing.T) { Priority: job1.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job1.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation if err := h1.Process(NewSystemScheduler, eval1); err != nil { @@ -241,8 +251,9 @@ func TestSystemSched_ExhaustResources(t *testing.T) { Priority: svcJob.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: svcJob.ID, + Status: structs.EvalStatusPending, } - + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) if err != nil { @@ -260,8 +271,9 @@ func TestSystemSched_ExhaustResources(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } - + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation if err := h.Process(NewSystemScheduler, eval1); err != nil { t.Fatalf("err: %v", err) @@ -307,7 +319,9 @@ func TestSystemSched_JobRegister_Annotate(t *testing.T) { TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, AnnotatePlan: true, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewSystemScheduler, eval) @@ -405,8 +419,9 @@ func TestSystemSched_JobRegister_AddNode(t *testing.T) { Priority: 50, TriggeredBy: structs.EvalTriggerNodeUpdate, JobID: job.ID, + Status: structs.EvalStatusPending, } - + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewSystemScheduler, eval) if err != nil { @@ -472,8 +487,9 @@ func TestSystemSched_JobRegister_AllocFail(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } - + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewSystemScheduler, eval) if err != nil { @@ -542,7 +558,9 @@ func TestSystemSched_JobModify(t *testing.T) { Priority: 50, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewSystemScheduler, eval) @@ -633,8 +651,9 @@ func TestSystemSched_JobModify_Rolling(t *testing.T) { Priority: 50, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } - + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewSystemScheduler, eval) if err != nil { @@ -728,7 +747,9 @@ func TestSystemSched_JobModify_InPlace(t *testing.T) { Priority: 50, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewSystemScheduler, eval) @@ -822,7 +843,9 @@ func TestSystemSched_JobDeregister_Purged(t *testing.T) { Priority: 50, TriggeredBy: structs.EvalTriggerJobDeregister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewSystemScheduler, eval) @@ -894,7 +917,9 @@ func TestSystemSched_JobDeregister_Stopped(t *testing.T) { Priority: 50, TriggeredBy: structs.EvalTriggerJobDeregister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewSystemScheduler, eval) @@ -956,7 +981,9 @@ func TestSystemSched_NodeDown(t *testing.T) { TriggeredBy: structs.EvalTriggerNodeUpdate, JobID: job.ID, NodeID: node.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewSystemScheduler, eval) @@ -1021,7 +1048,9 @@ func TestSystemSched_NodeDrain_Down(t *testing.T) { TriggeredBy: structs.EvalTriggerNodeUpdate, JobID: job.ID, NodeID: node.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewServiceScheduler, eval) @@ -1080,7 +1109,9 @@ func TestSystemSched_NodeDrain(t *testing.T) { TriggeredBy: structs.EvalTriggerNodeUpdate, JobID: job.ID, NodeID: node.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewSystemScheduler, eval) @@ -1143,7 +1174,9 @@ func TestSystemSched_NodeUpdate(t *testing.T) { TriggeredBy: structs.EvalTriggerNodeUpdate, JobID: job.ID, NodeID: node.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewSystemScheduler, eval) @@ -1180,7 +1213,9 @@ func TestSystemSched_RetryLimit(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewSystemScheduler, eval) @@ -1230,7 +1265,9 @@ func TestSystemSched_Queued_With_Constraints(t *testing.T) { TriggeredBy: structs.EvalTriggerNodeUpdate, JobID: job.ID, NodeID: node.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewSystemScheduler, eval) @@ -1264,7 +1301,9 @@ func TestSystemSched_ChainedAlloc(t *testing.T) { Priority: job.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation if err := h.Process(NewSystemScheduler, eval); err != nil { t.Fatalf("err: %v", err) @@ -1299,7 +1338,9 @@ func TestSystemSched_ChainedAlloc(t *testing.T) { Priority: job1.Priority, TriggeredBy: structs.EvalTriggerJobRegister, JobID: job1.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval1})) // Process the evaluation if err := h1.Process(NewSystemScheduler, eval1); err != nil { t.Fatalf("err: %v", err) @@ -1389,7 +1430,9 @@ func TestSystemSched_PlanWithDrainedNode(t *testing.T) { TriggeredBy: structs.EvalTriggerNodeUpdate, JobID: job.ID, NodeID: node.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewSystemScheduler, eval) @@ -1460,7 +1503,9 @@ func TestSystemSched_QueuedAllocsMultTG(t *testing.T) { TriggeredBy: structs.EvalTriggerNodeUpdate, JobID: job.ID, NodeID: node.ID, + Status: structs.EvalStatusPending, } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) // Process the evaluation err := h.Process(NewSystemScheduler, eval) From a49db955f4f273a7adc2f2a28a7fe57c21c3570f Mon Sep 17 00:00:00 2001 From: Preetha Appan Date: Mon, 18 Dec 2017 15:13:16 -0600 Subject: [PATCH 010/136] Address some code review comments --- nomad/eval_endpoint_test.go | 2 +- nomad/state/state_store.go | 1 - nomad/state/state_store_test.go | 12 ++++++------ nomad/structs/structs.go | 10 ++++++---- 4 files changed, 13 insertions(+), 12 deletions(-) diff --git a/nomad/eval_endpoint_test.go b/nomad/eval_endpoint_test.go index 238ee9fde..ea0c42a01 100644 --- a/nomad/eval_endpoint_test.go +++ b/nomad/eval_endpoint_test.go @@ -287,7 +287,7 @@ func TestEvalEndpoint_Dequeue_WaitIndex(t *testing.T) { } func TestEvalEndpoint_Dequeue_UpdateWaitIndex(t *testing.T) { - // test enqueing an eval, updating a plan result for the same eval and dequeing the eval + // test enqueueing an eval, updating a plan result for the same eval and de-queueing the eval t.Parallel() s1 := testServer(t, func(c *Config) { c.NumSchedulers = 0 // Prevent automatic dequeue diff --git a/nomad/state/state_store.go b/nomad/state/state_store.go index 98e1d5580..508d1e236 100644 --- a/nomad/state/state_store.go +++ b/nomad/state/state_store.go @@ -1505,7 +1505,6 @@ func (s *StateStore) updateEvalModifyIndex(txn *memdb.Txn, index uint64, evalID } eval := existing.(*structs.Evaluation).Copy() // Update the indexes - eval.CreateIndex = existing.(*structs.Evaluation).CreateIndex eval.ModifyIndex = index // Insert the eval diff --git a/nomad/state/state_store_test.go b/nomad/state/state_store_test.go index 6c0a5b567..08179bdfd 100644 --- a/nomad/state/state_store_test.go +++ b/nomad/state/state_store_test.go @@ -127,7 +127,7 @@ func TestStateStore_UpsertPlanResults_AllocationsCreated_Denormalized(t *testing index, err := state.Index("allocs") assert.Nil(err) - assert.Equal(uint64(1000), index) + assert.EqualValues(1000, index) if watchFired(ws) { t.Fatalf("bad") @@ -136,7 +136,7 @@ func TestStateStore_UpsertPlanResults_AllocationsCreated_Denormalized(t *testing evalOut, err := state.EvalByID(ws, eval.ID) assert.Nil(err) assert.NotNil(evalOut) - assert.Equal(uint64(1000), evalOut.ModifyIndex) + assert.EqualValues(1000, evalOut.ModifyIndex) } // This test checks that the deployment is created and allocations count towards @@ -198,7 +198,7 @@ func TestStateStore_UpsertPlanResults_Deployment(t *testing.T) { evalOut, err := state.EvalByID(ws, eval.ID) assert.Nil(err) assert.NotNil(evalOut) - assert.Equal(uint64(1000), evalOut.ModifyIndex) + assert.EqualValues(1000, evalOut.ModifyIndex) if watchFired(ws) { t.Fatalf("bad") @@ -240,7 +240,7 @@ func TestStateStore_UpsertPlanResults_Deployment(t *testing.T) { evalOut, err = state.EvalByID(ws, eval.ID) assert.Nil(err) assert.NotNil(evalOut) - assert.Equal(uint64(1001), evalOut.ModifyIndex) + assert.EqualValues(1001, evalOut.ModifyIndex) } // This test checks that deployment updates are applied correctly @@ -315,12 +315,12 @@ func TestStateStore_UpsertPlanResults_DeploymentUpdates(t *testing.T) { assert.NotNil(doutstandingout) assert.Equal(update.Status, doutstandingout.Status) assert.Equal(update.StatusDescription, doutstandingout.StatusDescription) - assert.Equal(uint64(1000), doutstandingout.ModifyIndex) + assert.EqualValues(1000, doutstandingout.ModifyIndex) evalOut, err := state.EvalByID(ws, eval.ID) assert.Nil(err) assert.NotNil(evalOut) - assert.Equal(uint64(1000), evalOut.ModifyIndex) + assert.EqualValues(1000, evalOut.ModifyIndex) if watchFired(ws) { t.Fatalf("bad") } diff --git a/nomad/structs/structs.go b/nomad/structs/structs.go index ea5fe5690..439e6a858 100644 --- a/nomad/structs/structs.go +++ b/nomad/structs/structs.go @@ -515,10 +515,12 @@ type ApplyPlanResultsRequest struct { // because the job is stopped or the update block is removed. DeploymentUpdates []*DeploymentStatusUpdate - // EvalID is the eval ID of the plan being applied. We also update the modify - // index of the eval ID as part of applying plan results. This is to ensure that - // other workers that are dequeing evaluations don't miss updates that can affect - // scheduling decisions. + // EvalID is the eval ID of the plan being applied. The modify index of the + // evaluation is updated as part of applying the plan to ensure that subsequent + // scheduling events for the same job will wait for the index that last produced + // state changes. This is necessary for blocked evaluations since they can be + // processed many times, potentially making state updates, without the state of + // the evaluation itself being updated. EvalID string } From 0401c2247b66e503e8b6242728ac1d7af75c8f21 Mon Sep 17 00:00:00 2001 From: Alex Dadgar Date: Mon, 18 Dec 2017 15:51:35 -0800 Subject: [PATCH 011/136] Handle upgrade path --- nomad/state/state_store.go | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/nomad/state/state_store.go b/nomad/state/state_store.go index 508d1e236..6dee12fee 100644 --- a/nomad/state/state_store.go +++ b/nomad/state/state_store.go @@ -196,9 +196,14 @@ func (s *StateStore) UpsertPlanResults(index uint64, results *structs.ApplyPlanR return err } - // Update the modify index of the eval id - if err := s.updateEvalModifyIndex(txn, index, results.EvalID); err != nil { - return err + // COMPAT: Nomad versions before 0.7.1 did not include the eval ID when + // applying the plan. Thus while we are upgrading, we ignore updating the + // modify index of evaluations from older plans. + if results.EvalID != "" { + // Update the modify index of the eval id + if err := s.updateEvalModifyIndex(txn, index, results.EvalID); err != nil { + return err + } } txn.Commit() From 039942f24b1ee49f1360c0f5310c68399b9f00bd Mon Sep 17 00:00:00 2001 From: Preetha Appan Date: Mon, 18 Dec 2017 17:56:12 -0600 Subject: [PATCH 012/136] Clean up error logging --- nomad/state/state_store.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/nomad/state/state_store.go b/nomad/state/state_store.go index 6dee12fee..f837a6106 100644 --- a/nomad/state/state_store.go +++ b/nomad/state/state_store.go @@ -1506,7 +1506,9 @@ func (s *StateStore) updateEvalModifyIndex(txn *memdb.Txn, index uint64, evalID return fmt.Errorf("eval lookup failed: %v", err) } if existing == nil { - return fmt.Errorf("[ERR] state_store: unable to find eval id %q", evalID) + err := fmt.Errorf("unable to find eval id %q", evalID) + s.logger.Printf("[ERR] state_store: %v", err) + return err } eval := existing.(*structs.Evaluation).Copy() // Update the indexes From a46bb22f1b6ef0b8bf52ae07434fa8e73e71583e Mon Sep 17 00:00:00 2001 From: Rob Genova Date: Tue, 19 Dec 2017 00:12:20 +0000 Subject: [PATCH 013/136] Add Spark configuration properties for ACL token and namespace. Remove spark.nomad.job property (deprecated in favor of spark.app.id). --- website/source/guides/spark/configuration.html.md | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/website/source/guides/spark/configuration.html.md b/website/source/guides/spark/configuration.html.md index e35d7623d..929861be9 100644 --- a/website/source/guides/spark/configuration.html.md +++ b/website/source/guides/spark/configuration.html.md @@ -13,6 +13,14 @@ are generally applicable to the Nomad integration. The properties listed below are specific to running Spark on Nomad. Configuration properties can be set by adding `--conf [property]=[value]` to the `spark-submit` command. +- `spark.nomad.authToken` `(string: nil)` - Specifies the secret key of the auth +token to use when accessing the API. This falls back to the NOMAD_TOKEN environment +variable. Note that if this configuration setting is set and the cluster deploy +mode is used, this setting will be propagated to the driver application in the +job spec. If it is not set and an auth token is taken from the NOMAD_TOKEN +environment variable, the token will not be propagated to the driver which will +require the driver to pick up its token from an environment variable. + - `spark.nomad.cluster.expectImmediateScheduling` `(bool: false)` - Specifies that `spark-submit` should fail if Nomad is not able to schedule the job immediately. @@ -101,12 +109,14 @@ time that Nomad should wait before retrying executor task groups upon failure. - `spark.nomad.executor.retryInterval` `(string: "1d")` - Specifies Nomad's retry interval for executor task groups. -- `spark.nomad.job` `(string: nil)` - Specifies the Nomad job name. - - `spark.nomad.job.template` `(string: nil)` - Specifies the path to a JSON file containing a Nomad job to use as a template. This can also be set with `spark-submit's --nomad-template` parameter. +- `spark.nomad.namespace` `(string: nil)` - Specifies the namespace to use. This +falls back first to the NOMAD_NAMESPACE environment variable and then to Nomad's +default namespace. + - `spark.nomad.priority` `(string: nil)` - Specifies the priority for the Nomad job. From d200f34e472c92b9ba1985605b6a6297d1ddf03f Mon Sep 17 00:00:00 2001 From: Alex Dadgar Date: Mon, 18 Dec 2017 16:14:34 -0800 Subject: [PATCH 014/136] changelog --- CHANGELOG.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 593d7e4d5..c5826fb51 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -52,6 +52,9 @@ BUG FIXES: * core: Fix issue in which restoring periodic jobs could fail when a leader election occurs [GH-3646] + * core: Fix race condition in which rapid reprocessing of a blocked evaluation + may lead to the scheduler not seeing the results of the previous scheduling + event [GH-3669] * core: Fixed an issue where the leader server could get into a state where it was no longer performing the periodic leader loop duties after a barrier timeout error [GH-3402] From a4449c84d7497493f7d8beb2796c92a6caae769b Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Mon, 18 Dec 2017 16:18:42 -0800 Subject: [PATCH 015/136] Services should not require a port Fixes #3673 --- command/agent/consul/client.go | 17 +- command/agent/consul/int_test.go | 24 ++- command/agent/consul/unit_test.go | 5 + nomad/mock/mock.go | 2 +- nomad/structs/structs.go | 14 +- nomad/structs/structs_test.go | 146 ++++++++++++++---- .../docs/job-specification/service.html.md | 9 +- 7 files changed, 164 insertions(+), 53 deletions(-) diff --git a/command/agent/consul/client.go b/command/agent/consul/client.go index c22cb8d74..b8db963ae 100644 --- a/command/agent/consul/client.go +++ b/command/agent/consul/client.go @@ -663,7 +663,7 @@ func (c *ServiceClient) checkRegs(ops *operations, allocID, serviceID string, se ip, port, err := getAddress(addrMode, portLabel, task.Resources.Networks, net) if err != nil { - return nil, fmt.Errorf("unable to get address for check %q: %v", check.Name, err) + return nil, fmt.Errorf("error getting address for check %q: %v", check.Name, err) } checkReg, err := createCheckReg(serviceID, checkID, check, ip, port) @@ -1036,6 +1036,11 @@ func createCheckReg(serviceID, checkID string, check *structs.ServiceCheck, host chkReg.Timeout = check.Timeout.String() chkReg.Interval = check.Interval.String() + // Require an address for http or tcp checks + if port == 0 && check.RequiresPort() { + return nil, fmt.Errorf("%s checks require an address", check.Type) + } + switch check.Type { case structs.ServiceCheckHTTP: proto := check.Protocol @@ -1089,9 +1094,15 @@ func isOldNomadService(id string) bool { return strings.HasPrefix(id, prefix) } -// getAddress returns the ip and port to use for a service or check. An error -// is returned if an ip and port cannot be determined. +// getAddress returns the IP and port to use for a service or check. If no port +// label is specified (an empty value), zero values are returned because no +// address could be resolved. func getAddress(addrMode, portLabel string, networks structs.Networks, driverNet *cstructs.DriverNetwork) (string, int, error) { + // No port label specified, no address can be assembled + if portLabel == "" { + return "", 0, nil + } + switch addrMode { case structs.AddressModeAuto: if driverNet.Advertise() { diff --git a/command/agent/consul/int_test.go b/command/agent/consul/int_test.go index ba9975532..ee0fff748 100644 --- a/command/agent/consul/int_test.go +++ b/command/agent/consul/int_test.go @@ -87,8 +87,17 @@ func TestConsul_Integration(t *testing.T) { task.Config = map[string]interface{}{ "run_for": "1h", } + // Choose a port that shouldn't be in use - task.Resources.Networks[0].ReservedPorts = []structs.Port{{Label: "http", Value: 3}} + netResource := &structs.NetworkResource{ + Device: "eth0", + IP: "127.0.0.1", + MBits: 50, + ReservedPorts: []structs.Port{{Label: "http", Value: 3}}, + } + alloc.Resources.Networks[0] = netResource + alloc.TaskResources["web"].Networks[0] = netResource + task.Resources.Networks[0] = netResource task.Services = []*structs.Service{ { Name: "httpd", @@ -96,13 +105,12 @@ func TestConsul_Integration(t *testing.T) { Tags: []string{"nomad", "test", "http"}, Checks: []*structs.ServiceCheck{ { - Name: "httpd-http-check", - Type: "http", - Path: "/", - Protocol: "http", - PortLabel: "http", - Interval: 9000 * time.Hour, - Timeout: 1, // fail as fast as possible + Name: "httpd-http-check", + Type: "http", + Path: "/", + Protocol: "http", + Interval: 9000 * time.Hour, + Timeout: 1, // fail as fast as possible }, { Name: "httpd-script-check", diff --git a/command/agent/consul/unit_test.go b/command/agent/consul/unit_test.go index 88acc4ee1..4d8123b88 100644 --- a/command/agent/consul/unit_test.go +++ b/command/agent/consul/unit_test.go @@ -1566,8 +1566,13 @@ func TestGetAddress(t *testing.T) { { Name: "InvalidMode", Mode: "invalid-mode", + PortLabel: "80", ErrContains: "invalid address mode", }, + { + Name: "EmptyIsOk", + Mode: structs.AddressModeHost, + }, } for _, tc := range cases { diff --git a/nomad/mock/mock.go b/nomad/mock/mock.go index d0c889b09..c4921a644 100644 --- a/nomad/mock/mock.go +++ b/nomad/mock/mock.go @@ -292,7 +292,7 @@ func Alloc() *structs.Allocation { IP: "192.168.0.100", ReservedPorts: []structs.Port{{Label: "admin", Value: 5000}}, MBits: 50, - DynamicPorts: []structs.Port{{Label: "http"}}, + DynamicPorts: []structs.Port{{Label: "http", Value: 9876}}, }, }, }, diff --git a/nomad/structs/structs.go b/nomad/structs/structs.go index 439e6a858..fa994e194 100644 --- a/nomad/structs/structs.go +++ b/nomad/structs/structs.go @@ -3131,8 +3131,8 @@ func (s *Service) Validate() error { } for _, c := range s.Checks { - if s.PortLabel == "" && c.RequiresPort() { - mErr.Errors = append(mErr.Errors, fmt.Errorf("check %s invalid: check requires a port but the service %+q has no port", c.Name, s.Name)) + if s.PortLabel == "" && c.PortLabel == "" && c.RequiresPort() { + mErr.Errors = append(mErr.Errors, fmt.Errorf("check %s invalid: check requires a port but neither check nor service %+q have a port", c.Name, s.Name)) continue } @@ -3577,8 +3577,16 @@ func validateServices(t *Task) error { } } + // Iterate over a sorted list of keys to make error listings stable + keys := make([]string, 0, len(servicePorts)) + for p := range servicePorts { + keys = append(keys, p) + } + sort.Strings(keys) + // Ensure all ports referenced in services exist. - for servicePort, services := range servicePorts { + for _, servicePort := range keys { + services := servicePorts[servicePort] _, ok := portLabels[servicePort] if !ok { names := make([]string, 0, len(services)) diff --git a/nomad/structs/structs_test.go b/nomad/structs/structs_test.go index 26b2d2a02..4897e0422 100644 --- a/nomad/structs/structs_test.go +++ b/nomad/structs/structs_test.go @@ -1235,55 +1235,93 @@ func TestTask_Validate_Service_Check(t *testing.T) { // TestTask_Validate_Service_Check_AddressMode asserts that checks do not // inherit address mode but do inherit ports. func TestTask_Validate_Service_Check_AddressMode(t *testing.T) { - task := &Task{ - Resources: &Resources{ - Networks: []*NetworkResource{ - { - DynamicPorts: []Port{ - { - Label: "http", - Value: 9999, + getTask := func(s *Service) *Task { + return &Task{ + Resources: &Resources{ + Networks: []*NetworkResource{ + { + DynamicPorts: []Port{ + { + Label: "http", + Value: 9999, + }, }, }, }, }, - }, - Services: []*Service{ - { + Services: []*Service{s}, + } + } + + cases := []struct { + Service *Service + ErrContains string + }{ + { + Service: &Service{ Name: "invalid-driver", PortLabel: "80", AddressMode: "host", }, - { - Name: "http-driver", + ErrContains: `port label "80" referenced`, + }, + { + Service: &Service{ + Name: "http-driver-fail-1", PortLabel: "80", AddressMode: "driver", Checks: []*ServiceCheck{ { - // Should fail Name: "invalid-check-1", Type: "tcp", Interval: time.Second, Timeout: time.Second, }, + }, + }, + ErrContains: `check "invalid-check-1" cannot use a numeric port`, + }, + { + Service: &Service{ + Name: "http-driver-fail-2", + PortLabel: "80", + AddressMode: "driver", + Checks: []*ServiceCheck{ { - // Should fail Name: "invalid-check-2", Type: "tcp", PortLabel: "80", Interval: time.Second, Timeout: time.Second, }, + }, + }, + ErrContains: `check "invalid-check-2" cannot use a numeric port`, + }, + { + Service: &Service{ + Name: "http-driver-fail-3", + PortLabel: "80", + AddressMode: "driver", + Checks: []*ServiceCheck{ { - // Should fail Name: "invalid-check-3", Type: "tcp", PortLabel: "missing-port-label", Interval: time.Second, Timeout: time.Second, }, + }, + }, + ErrContains: `port label "missing-port-label" referenced`, + }, + { + Service: &Service{ + Name: "http-driver-passes", + PortLabel: "80", + AddressMode: "driver", + Checks: []*ServiceCheck{ { - // Should pass Name: "valid-script-check", Type: "script", Command: "ok", @@ -1291,7 +1329,6 @@ func TestTask_Validate_Service_Check_AddressMode(t *testing.T) { Timeout: time.Second, }, { - // Should pass Name: "valid-host-check", Type: "tcp", PortLabel: "http", @@ -1299,7 +1336,6 @@ func TestTask_Validate_Service_Check_AddressMode(t *testing.T) { Timeout: time.Second, }, { - // Should pass Name: "valid-driver-check", Type: "tcp", AddressMode: "driver", @@ -1309,23 +1345,65 @@ func TestTask_Validate_Service_Check_AddressMode(t *testing.T) { }, }, }, - } - err := validateServices(task) - if err == nil { - t.Fatalf("expected errors but task validated successfully") - } - errs := err.(*multierror.Error).Errors - if expected := 4; len(errs) != expected { - for i, err := range errs { - t.Logf("errs[%d] -> %s", i, err) - } - t.Fatalf("expected %d errors but found %d", expected, len(errs)) + { + Service: &Service{ + Name: "empty-address-3673-passes-1", + Checks: []*ServiceCheck{ + { + Name: "valid-port-label", + Type: "tcp", + PortLabel: "http", + Interval: time.Second, + Timeout: time.Second, + }, + { + Name: "empty-is-ok", + Type: "script", + Command: "ok", + Interval: time.Second, + Timeout: time.Second, + }, + }, + }, + }, + { + Service: &Service{ + Name: "empty-address-3673-passes-2", + }, + }, + { + Service: &Service{ + Name: "empty-address-3673-fails", + Checks: []*ServiceCheck{ + { + Name: "empty-is-not-ok", + Type: "tcp", + Interval: time.Second, + Timeout: time.Second, + }, + }, + }, + ErrContains: `invalid: check requires a port but neither check nor service`, + }, } - assert.Contains(t, errs[0].Error(), `check "invalid-check-1" cannot use a numeric port`) - assert.Contains(t, errs[1].Error(), `check "invalid-check-2" cannot use a numeric port`) - assert.Contains(t, errs[2].Error(), `port label "80" referenced`) - assert.Contains(t, errs[3].Error(), `port label "missing-port-label" referenced`) + for _, tc := range cases { + tc := tc + task := getTask(tc.Service) + t.Run(tc.Service.Name, func(t *testing.T) { + err := validateServices(task) + if err == nil && tc.ErrContains == "" { + // Ok! + return + } + if err == nil { + t.Fatalf("no error returned. expected: %s", tc.ErrContains) + } + if !strings.Contains(err.Error(), tc.ErrContains) { + t.Fatalf("expected %q but found: %v", tc.ErrContains, err) + } + }) + } } func TestTask_Validate_Service_Check_CheckRestart(t *testing.T) { diff --git a/website/source/docs/job-specification/service.html.md b/website/source/docs/job-specification/service.html.md index 9707d8ec4..578f0c1ed 100644 --- a/website/source/docs/job-specification/service.html.md +++ b/website/source/docs/job-specification/service.html.md @@ -96,7 +96,7 @@ does not automatically enable service discovery. interpolated and revalidated. This can cause certain service names to pass validation at submit time but fail at runtime. -- `port` `(string: )` - Specifies the label of the port on which this +- `port` `(string: )` - Specifies the label of the port on which this service is running. Note this is the _label_ of the port and not the port number unless `address_mode = driver`. The port label must match one defined in the [`network`][network] stanza unless you're also using @@ -174,14 +174,15 @@ scripts. add the IP of the service and the port, so this is just the relative URL to the health check endpoint. This is required for http-based health checks. -- `port` `(string: )` - Specifies the label of the port on which the +- `port` `(string: )` - Specifies the label of the port on which the check will be performed. Note this is the _label_ of the port and not the port number unless `address_mode = driver`. The port label must match one defined in the [`network`][network] stanza. If a port value was declared on the `service`, this will inherit from that value if not supplied. If supplied, this value takes precedence over the `service.port` value. This is useful for - services which operate on multiple ports. Checks will use the host IP and - ports by default. In Nomad 0.7.1 or later numeric ports may be used if + services which operate on multiple ports. `http` and `tcp` checks require a + port while `script` checks do not. Checks will use the host IP and ports by + default. In Nomad 0.7.1 or later numeric ports may be used if `address_mode="driver"` is set on the check. - `protocol` `(string: "http")` - Specifies the protocol for the http-based From e12f0d1d2cb96a5110364df1b4c3b36a8c7bb966 Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Tue, 19 Dec 2017 16:19:40 -0800 Subject: [PATCH 016/136] Fix missing fields in json jobspec docs --- website/source/api/json-jobs.html.md | 42 ++++++++++++++++++- .../docs/job-specification/task.html.md | 3 +- 2 files changed, 42 insertions(+), 3 deletions(-) diff --git a/website/source/api/json-jobs.html.md b/website/source/api/json-jobs.html.md index 0090a7feb..1fe359af9 100644 --- a/website/source/api/json-jobs.html.md +++ b/website/source/api/json-jobs.html.md @@ -300,13 +300,17 @@ The `Task` object supports the following keys: } ``` +- `KillSignal` - Specifies a configurable kill signal for a task, where the + default is SIGINT. Note that this is only supported for drivers which accept + sending signals (currently `docker`, `exec`, `raw_exec`, and `java` drivers). + - `KillTimeout` - `KillTimeout` is a time duration in nanoseconds. It can be used to configure the time between signaling a task it will be killed and actually killing it. Drivers first sends a task the `SIGINT` signal and then sends `SIGTERM` if the task doesn't die after the `KillTimeout` duration has elapsed. The default `KillTimeout` is 5 seconds. -- `leader` - Specifies whether the task is the leader task of the task group. If +- `Leader` - Specifies whether the task is the leader task of the task group. If set to true, when the leader task completes, all other tasks within the task group will be gracefully shutdown. @@ -346,6 +350,23 @@ The `Task` object supports the following keys: defined in the resources block. This could be a label of either a dynamic or a static port. + - `AddressMode`: Specifies what address (host or driver-specific) this + service should advertise. This setting is supported in Docker since + Nomad 0.6 and rkt since Nomad 0.7. Valid options are: + + - `auto` - Allows the driver to determine whether the host or driver + address should be used. Defaults to `host` and only implemented by + Docker. If you use a Docker network plugin such as weave, Docker will + automatically use its address. + + - `driver` - Use the IP specified by the driver, and the port specified + in a port map. A numeric port may be specified since port maps aren't + required by all network plugins. Useful for advertising SDN and + overlay network addresses. Task will fail if driver network cannot be + determined. Only implemented for Docker and rkt. + + - `host` - Use the host IP and port. + - `Checks`: `Checks` is an array of check objects. A check object defines a health check associated with the service. Nomad supports the `script`, `http` and `tcp` Consul Checks. Script checks are not supported for the @@ -357,6 +378,25 @@ The `Task` object supports the following keys: - `Name`: The name of the health check. + - `AddressMode`: Same as `AddressMode` on `Service`. Unlike services, + checks do not have an `auto` address mode as there's no way for + Nomad to know which is the best address to use for checks. Consul + needs access to the address for any HTTP or TCP checks. Added in + Nomad 0.7.1. Unlike `PortLabel`, this setting is *not* inherited + from the `Service`. + + - `PortLabel`: Specifies the label of the port on which the check will + be performed. Note this is the _label_ of the port and not the port + number unless `AddressMode: "driver"`. The port label must match one + defined in the Network stanza. If a port value was declared on the + `Service`, this will inherit from that value if not supplied. If + supplied, this value takes precedence over the `Service.PortLabel` + value. This is useful for services which operate on multiple ports. + `http` and `tcp` checks require a port while `script` checks do not. + Checks will use the host IP and ports by default. In Nomad 0.7.1 or + later numeric ports may be used if `AddressMode: "driver"` is set on + the check. + - `Header`: Headers for HTTP checks. Should be an object where the values are an array of values. Headers will be written once for each value. diff --git a/website/source/docs/job-specification/task.html.md b/website/source/docs/job-specification/task.html.md index f23406297..f5bb18897 100644 --- a/website/source/docs/job-specification/task.html.md +++ b/website/source/docs/job-specification/task.html.md @@ -56,8 +56,7 @@ job "docs" { - `kill_signal` `(string)` - Specifies a configurable kill signal for a task, where the default is SIGINT. Note that this is only supported for drivers - which accept sending signals (currently Docker, exec, raw_exec, and Java - drivers). + sending signals (currently `docker`, `exec`, `raw_exec`, and `java` drivers). - `leader` `(bool: false)` - Specifies whether the task is the leader task of the task group. If set to true, when the leader task completes, all other From c5fd8b2b202cdad6dbb943a1c19a5d16eaa8fd80 Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Tue, 19 Dec 2017 16:41:35 -0800 Subject: [PATCH 017/136] Strip mocked dynamic port for fsm test --- nomad/fsm_test.go | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/nomad/fsm_test.go b/nomad/fsm_test.go index 8414cb75c..fdaf681b7 100644 --- a/nomad/fsm_test.go +++ b/nomad/fsm_test.go @@ -944,9 +944,14 @@ func TestFSM_UpsertAllocs_StrippedResources(t *testing.T) { fsm := testFSM(t) alloc := mock.Alloc() + + // Need to remove mock dynamic port from alloc as it won't be computed + // in this test + alloc.TaskResources["web"].Networks[0].DynamicPorts[0].Value = 0 + fsm.State().UpsertJobSummary(1, mock.JobSummary(alloc.JobID)) job := alloc.Job - resources := alloc.Resources + origResources := alloc.Resources alloc.Resources = nil req := structs.AllocUpdateRequest{ Job: job, @@ -973,10 +978,10 @@ func TestFSM_UpsertAllocs_StrippedResources(t *testing.T) { alloc.AllocModifyIndex = out.AllocModifyIndex // Resources should be recomputed - resources.DiskMB = alloc.Job.TaskGroups[0].EphemeralDisk.SizeMB - alloc.Resources = resources + origResources.DiskMB = alloc.Job.TaskGroups[0].EphemeralDisk.SizeMB + alloc.Resources = origResources if !reflect.DeepEqual(alloc, out) { - t.Fatalf("bad: %#v %#v", alloc, out) + t.Fatalf("not equal: % #v", pretty.Diff(alloc, out)) } } From 8332a3e315c69c846c40b6a766b798769c88d89f Mon Sep 17 00:00:00 2001 From: Alex Dadgar Date: Tue, 19 Dec 2017 16:53:59 -0800 Subject: [PATCH 018/136] bump version --- version/version.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/version/version.go b/version/version.go index d9068db05..d41e530a9 100644 --- a/version/version.go +++ b/version/version.go @@ -16,7 +16,7 @@ var ( // A pre-release marker for the version. If this is "" (empty string) // then it means that it is a final release. Otherwise, this is a pre-release // such as "dev" (in development), "beta", "rc1", etc. - VersionPrerelease = "rc1" + VersionPrerelease = "" // VersionMetadata is metadata further describing the build type. VersionMetadata = "" From 0b295d399d00199cfab4621566babd25987ba06e Mon Sep 17 00:00:00 2001 From: Alex Dadgar Date: Tue, 19 Dec 2017 16:57:34 -0800 Subject: [PATCH 019/136] generated files --- .gitignore | 1 - command/agent/fs_endpoint.generated.go | 1061 + nomad/structs/structs.generated.go | 77269 +++++++++++++++++++++++ 3 files changed, 78330 insertions(+), 1 deletion(-) create mode 100644 command/agent/fs_endpoint.generated.go create mode 100644 nomad/structs/structs.generated.go diff --git a/.gitignore b/.gitignore index e407015f6..39dc26c6f 100644 --- a/.gitignore +++ b/.gitignore @@ -52,7 +52,6 @@ nomad_linux_amd64 nomad_darwin_amd64 TODO.md codecgen-*.generated.go -*.generated.go .terraform *.tfstate* diff --git a/command/agent/fs_endpoint.generated.go b/command/agent/fs_endpoint.generated.go new file mode 100644 index 000000000..3102e636c --- /dev/null +++ b/command/agent/fs_endpoint.generated.go @@ -0,0 +1,1061 @@ +// ************************************************************ +// DO NOT EDIT. +// THIS FILE IS AUTO-GENERATED BY codecgen. +// ************************************************************ + +package agent + +import ( + "errors" + "fmt" + codec1978 "github.com/ugorji/go/codec" + io "io" + "reflect" + "runtime" +) + +const ( + // ----- content types ---- + codecSelferC_UTF8101 = 1 + codecSelferC_RAW101 = 0 + // ----- value types used ---- + codecSelferValueTypeArray101 = 10 + codecSelferValueTypeMap101 = 9 + // ----- containerStateValues ---- + codecSelfer_containerMapKey101 = 2 + codecSelfer_containerMapValue101 = 3 + codecSelfer_containerMapEnd101 = 4 + codecSelfer_containerArrayElem101 = 6 + codecSelfer_containerArrayEnd101 = 7 +) + +var ( + codecSelferBitsize101 = uint8(reflect.TypeOf(uint(0)).Bits()) + codecSelferOnlyMapOrArrayEncodeToStructErr101 = errors.New(`only encoded map or array can be decoded into a struct`) +) + +type codecSelfer101 struct{} + +func init() { + if codec1978.GenVersion != 5 { + _, file, _, _ := runtime.Caller(0) + err := fmt.Errorf("codecgen version mismatch: current: %v, need %v. Re-generate file: %v", + 5, codec1978.GenVersion, file) + panic(err) + } + if false { // reference the types, but skip this branch at build/run time + var v0 io.Reader + _ = v0 + } +} + +func (x *ReadCloserWrapper) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer101 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem101) + if x.Reader == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else if z.HasExtensions() && z.EncExt(x.Reader) { + } else { + z.EncFallback(x.Reader) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey101) + r.EncodeString(codecSelferC_UTF8101, string("Reader")) + z.EncSendContainerState(codecSelfer_containerMapValue101) + if x.Reader == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.EncExt(x.Reader) { + } else { + z.EncFallback(x.Reader) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem101) + if x.Closer == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.EncExt(x.Closer) { + } else { + z.EncFallback(x.Closer) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey101) + r.EncodeString(codecSelferC_UTF8101, string("Closer")) + z.EncSendContainerState(codecSelfer_containerMapValue101) + if x.Closer == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.EncExt(x.Closer) { + } else { + z.EncFallback(x.Closer) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd101) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd101) + } + } + } +} + +func (x *ReadCloserWrapper) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer101 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap101 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd101) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray101 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd101) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr101) + } + } +} + +func (x *ReadCloserWrapper) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer101 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey101) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue101) + switch yys3 { + case "Reader": + if r.TryDecodeAsNil() { + x.Reader = nil + } else { + yyv4 := &x.Reader + yym5 := z.DecBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.DecExt(yyv4) { + } else { + z.DecFallback(yyv4, true) + } + } + case "Closer": + if r.TryDecodeAsNil() { + x.Closer = nil + } else { + yyv6 := &x.Closer + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else { + z.DecFallback(yyv6, true) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd101) +} + +func (x *ReadCloserWrapper) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer101 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd101) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem101) + if r.TryDecodeAsNil() { + x.Reader = nil + } else { + yyv9 := &x.Reader + yym10 := z.DecBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.DecExt(yyv9) { + } else { + z.DecFallback(yyv9, true) + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd101) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem101) + if r.TryDecodeAsNil() { + x.Closer = nil + } else { + yyv11 := &x.Closer + yym12 := z.DecBinary() + _ = yym12 + if false { + } else if z.HasExtensions() && z.DecExt(yyv11) { + } else { + z.DecFallback(yyv11, true) + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem101) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd101) +} + +func (x *StreamFrame) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer101 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Offset != 0 + yyq2[1] = len(x.Data) != 0 + yyq2[2] = x.File != "" + yyq2[3] = x.FileEvent != "" + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem101) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeInt(int64(x.Offset)) + } + } else { + r.EncodeInt(0) + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey101) + r.EncodeString(codecSelferC_UTF8101, string("Offset")) + z.EncSendContainerState(codecSelfer_containerMapValue101) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeInt(int64(x.Offset)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem101) + if yyq2[1] { + if x.Data == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW101, []byte(x.Data)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey101) + r.EncodeString(codecSelferC_UTF8101, string("Data")) + z.EncSendContainerState(codecSelfer_containerMapValue101) + if x.Data == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW101, []byte(x.Data)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem101) + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8101, string(x.File)) + } + } else { + r.EncodeString(codecSelferC_UTF8101, "") + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey101) + r.EncodeString(codecSelferC_UTF8101, string("File")) + z.EncSendContainerState(codecSelfer_containerMapValue101) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8101, string(x.File)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem101) + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8101, string(x.FileEvent)) + } + } else { + r.EncodeString(codecSelferC_UTF8101, "") + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey101) + r.EncodeString(codecSelferC_UTF8101, string("FileEvent")) + z.EncSendContainerState(codecSelfer_containerMapValue101) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8101, string(x.FileEvent)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd101) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd101) + } + } + } +} + +func (x *StreamFrame) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer101 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap101 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd101) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray101 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd101) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr101) + } + } +} + +func (x *StreamFrame) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer101 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey101) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue101) + switch yys3 { + case "Offset": + if r.TryDecodeAsNil() { + x.Offset = 0 + } else { + yyv4 := &x.Offset + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int64)(yyv4)) = int64(r.DecodeInt(64)) + } + } + case "Data": + if r.TryDecodeAsNil() { + x.Data = nil + } else { + yyv6 := &x.Data + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *yyv6 = r.DecodeBytes(*(*[]byte)(yyv6), false, false) + } + } + case "File": + if r.TryDecodeAsNil() { + x.File = "" + } else { + yyv8 := &x.File + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "FileEvent": + if r.TryDecodeAsNil() { + x.FileEvent = "" + } else { + yyv10 := &x.FileEvent + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd101) +} + +func (x *StreamFrame) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer101 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd101) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem101) + if r.TryDecodeAsNil() { + x.Offset = 0 + } else { + yyv13 := &x.Offset + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*int64)(yyv13)) = int64(r.DecodeInt(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd101) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem101) + if r.TryDecodeAsNil() { + x.Data = nil + } else { + yyv15 := &x.Data + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *yyv15 = r.DecodeBytes(*(*[]byte)(yyv15), false, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd101) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem101) + if r.TryDecodeAsNil() { + x.File = "" + } else { + yyv17 := &x.File + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd101) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem101) + if r.TryDecodeAsNil() { + x.FileEvent = "" + } else { + yyv19 := &x.FileEvent + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem101) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd101) +} + +func (x *StreamFramer) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer101 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [0]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(0) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd101) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd101) + } + } + } +} + +func (x *StreamFramer) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer101 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap101 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd101) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray101 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd101) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr101) + } + } +} + +func (x *StreamFramer) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer101 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey101) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue101) + switch yys3 { + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd101) +} + +func (x *StreamFramer) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer101 + 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 + } + z.DecSendContainerState(codecSelfer_containerArrayElem101) + z.DecStructFieldNotFound(yyj4-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd101) +} + +func (x *indexTuple) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer101 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [0]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(0) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd101) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd101) + } + } + } +} + +func (x *indexTuple) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer101 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap101 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd101) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray101 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd101) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr101) + } + } +} + +func (x *indexTuple) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer101 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey101) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue101) + switch yys3 { + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd101) +} + +func (x *indexTuple) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer101 + 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 + } + z.DecSendContainerState(codecSelfer_containerArrayElem101) + z.DecStructFieldNotFound(yyj4-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd101) +} + +func (x indexTupleArray) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer101 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + h.encindexTupleArray((indexTupleArray)(x), e) + } + } +} + +func (x *indexTupleArray) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer101 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + h.decindexTupleArray((*indexTupleArray)(x), d) + } +} + +func (x codecSelfer101) encindexTupleArray(v indexTupleArray, e *codec1978.Encoder) { + var h codecSelfer101 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem101) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd101) +} + +func (x codecSelfer101) decindexTupleArray(v *indexTupleArray, d *codec1978.Decoder) { + var h codecSelfer101 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []indexTuple{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]indexTuple, yyrl1) + } + } else { + yyv1 = make([]indexTuple, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = indexTuple{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, indexTuple{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = indexTuple{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, indexTuple{}) // var yyz1 indexTuple + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = indexTuple{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []indexTuple{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} diff --git a/nomad/structs/structs.generated.go b/nomad/structs/structs.generated.go new file mode 100644 index 000000000..d6cf62887 --- /dev/null +++ b/nomad/structs/structs.generated.go @@ -0,0 +1,77269 @@ +// ************************************************************ +// DO NOT EDIT. +// THIS FILE IS AUTO-GENERATED BY codecgen. +// ************************************************************ + +package structs + +import ( + "errors" + "fmt" + codec1978 "github.com/ugorji/go/codec" + net "net" + "reflect" + "runtime" + time "time" +) + +const ( + // ----- content types ---- + codecSelferC_UTF8100 = 1 + codecSelferC_RAW100 = 0 + // ----- value types used ---- + codecSelferValueTypeArray100 = 10 + codecSelferValueTypeMap100 = 9 + // ----- containerStateValues ---- + codecSelfer_containerMapKey100 = 2 + codecSelfer_containerMapValue100 = 3 + codecSelfer_containerMapEnd100 = 4 + codecSelfer_containerArrayElem100 = 6 + codecSelfer_containerArrayEnd100 = 7 +) + +var ( + codecSelferBitsize100 = uint8(reflect.TypeOf(uint(0)).Bits()) + codecSelferOnlyMapOrArrayEncodeToStructErr100 = errors.New(`only encoded map or array can be decoded into a struct`) +) + +type codecSelfer100 struct{} + +func init() { + if codec1978.GenVersion != 5 { + _, file, _, _ := runtime.Caller(0) + err := fmt.Errorf("codecgen version mismatch: current: %v, need %v. Re-generate file: %v", + 5, codec1978.GenVersion, file) + panic(err) + } + if false { // reference the types, but skip this branch at build/run time + var v0 net.IP + var v1 time.Duration + _, _ = v0, v1 + } +} + +func (x MessageType) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeUint(uint64(x)) + } +} + +func (x *MessageType) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*uint8)(x)) = uint8(r.DecodeUint(8)) + } +} + +func (x Context) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x)) + } +} + +func (x *Context) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x *NamespacedID) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *NamespacedID) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *NamespacedID) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "ID": + if r.TryDecodeAsNil() { + x.ID = "" + } else { + yyv4 := &x.ID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv6 := &x.Namespace + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *NamespacedID) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ID = "" + } else { + yyv9 := &x.ID + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv11 := &x.Namespace + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *QueryOptions) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [7]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(7) + } else { + yynn2 = 7 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *QueryOptions) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *QueryOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv4 := &x.Region + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv6 := &x.Namespace + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv8 := &x.MinQueryIndex + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv10 := &x.MaxQueryTime + yym11 := z.DecBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.DecExt(yyv10) { + } else { + *((*int64)(yyv10)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv12 := &x.AllowStale + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*bool)(yyv12)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv14 := &x.Prefix + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv16 := &x.AuthToken + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *QueryOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj18 int + var yyb18 bool + var yyhl18 bool = l >= 0 + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv19 := &x.Region + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv21 := &x.Namespace + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv23 := &x.MinQueryIndex + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv25 := &x.MaxQueryTime + yym26 := z.DecBinary() + _ = yym26 + if false { + } else if z.HasExtensions() && z.DecExt(yyv25) { + } else { + *((*int64)(yyv25)) = int64(r.DecodeInt(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv27 := &x.AllowStale + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*bool)(yyv27)) = r.DecodeBool() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv29 := &x.Prefix + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv31 := &x.AuthToken + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } + } + for { + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj18-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *WriteRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 3 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *WriteRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *WriteRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv4 := &x.Region + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv6 := &x.Namespace + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv8 := &x.AuthToken + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *WriteRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv11 := &x.Region + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv13 := &x.Namespace + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv15 := &x.AuthToken + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *QueryMeta) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 3 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *QueryMeta) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *QueryMeta) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv4 := &x.Index + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*uint64)(yyv4)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv6 := &x.LastContact + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else { + *((*int64)(yyv6)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv8 := &x.KnownLeader + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*bool)(yyv8)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *QueryMeta) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv11 := &x.Index + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*uint64)(yyv11)) = uint64(r.DecodeUint(64)) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv13 := &x.LastContact + yym14 := z.DecBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.DecExt(yyv13) { + } else { + *((*int64)(yyv13)) = int64(r.DecodeInt(64)) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv15 := &x.KnownLeader + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*bool)(yyv15)) = r.DecodeBool() + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *WriteMeta) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(1) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *WriteMeta) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *WriteMeta) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv4 := &x.Index + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*uint64)(yyv4)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *WriteMeta) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + 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 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv7 := &x.Index + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*uint64)(yyv7)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj6-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *NodeRegisterRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Node == nil { + r.EncodeNil() + } else { + x.Node.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Node")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Node == nil { + r.EncodeNil() + } else { + x.Node.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *NodeRegisterRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *NodeRegisterRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Node": + if r.TryDecodeAsNil() { + if x.Node != nil { + x.Node = nil + } + } else { + if x.Node == nil { + x.Node = new(Node) + } + x.Node.CodecDecodeSelf(d) + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv5 := &x.Region + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv7 := &x.Namespace + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*string)(yyv7)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv9 := &x.AuthToken + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *NodeRegisterRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Node != nil { + x.Node = nil + } + } else { + if x.Node == nil { + x.Node = new(Node) + } + x.Node.CodecDecodeSelf(d) + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv13 := &x.Region + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv15 := &x.Namespace + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv17 := &x.AuthToken + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + for { + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj11-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *NodeDeregisterRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodeID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *NodeDeregisterRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *NodeDeregisterRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "NodeID": + if r.TryDecodeAsNil() { + x.NodeID = "" + } else { + yyv4 := &x.NodeID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv10 := &x.AuthToken + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *NodeDeregisterRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodeID = "" + } else { + yyv13 := &x.NodeID + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv15 := &x.Region + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv17 := &x.Namespace + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv19 := &x.AuthToken + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *NodeServerInfo) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.RPCAdvertiseAddr)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("RPCAdvertiseAddr")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.RPCAdvertiseAddr)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeInt(int64(x.RPCMajorVersion)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("RPCMajorVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeInt(int64(x.RPCMajorVersion)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeInt(int64(x.RPCMinorVersion)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("RPCMinorVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeInt(int64(x.RPCMinorVersion)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Datacenter)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Datacenter")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Datacenter)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *NodeServerInfo) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *NodeServerInfo) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "RPCAdvertiseAddr": + if r.TryDecodeAsNil() { + x.RPCAdvertiseAddr = "" + } else { + yyv4 := &x.RPCAdvertiseAddr + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "RPCMajorVersion": + if r.TryDecodeAsNil() { + x.RPCMajorVersion = 0 + } else { + yyv6 := &x.RPCMajorVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int32)(yyv6)) = int32(r.DecodeInt(32)) + } + } + case "RPCMinorVersion": + if r.TryDecodeAsNil() { + x.RPCMinorVersion = 0 + } else { + yyv8 := &x.RPCMinorVersion + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int32)(yyv8)) = int32(r.DecodeInt(32)) + } + } + case "Datacenter": + if r.TryDecodeAsNil() { + x.Datacenter = "" + } else { + yyv10 := &x.Datacenter + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *NodeServerInfo) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.RPCAdvertiseAddr = "" + } else { + yyv13 := &x.RPCAdvertiseAddr + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.RPCMajorVersion = 0 + } else { + yyv15 := &x.RPCMajorVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*int32)(yyv15)) = int32(r.DecodeInt(32)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.RPCMinorVersion = 0 + } else { + yyv17 := &x.RPCMinorVersion + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*int32)(yyv17)) = int32(r.DecodeInt(32)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Datacenter = "" + } else { + yyv19 := &x.Datacenter + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *NodeUpdateStatusRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 5 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodeID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Status)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Status")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Status)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *NodeUpdateStatusRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *NodeUpdateStatusRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "NodeID": + if r.TryDecodeAsNil() { + x.NodeID = "" + } else { + yyv4 := &x.NodeID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Status": + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv6 := &x.Status + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv8 := &x.Region + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv10 := &x.Namespace + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv12 := &x.AuthToken + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *NodeUpdateStatusRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodeID = "" + } else { + yyv15 := &x.NodeID + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv17 := &x.Status + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv19 := &x.Region + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv21 := &x.Namespace + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv23 := &x.AuthToken + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + for { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj14-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *NodeUpdateDrainRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 5 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodeID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeBool(bool(x.Drain)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Drain")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeBool(bool(x.Drain)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *NodeUpdateDrainRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *NodeUpdateDrainRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "NodeID": + if r.TryDecodeAsNil() { + x.NodeID = "" + } else { + yyv4 := &x.NodeID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Drain": + if r.TryDecodeAsNil() { + x.Drain = false + } else { + yyv6 := &x.Drain + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*bool)(yyv6)) = r.DecodeBool() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv8 := &x.Region + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv10 := &x.Namespace + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv12 := &x.AuthToken + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *NodeUpdateDrainRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodeID = "" + } else { + yyv15 := &x.NodeID + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Drain = false + } else { + yyv17 := &x.Drain + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*bool)(yyv17)) = r.DecodeBool() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv19 := &x.Region + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv21 := &x.Namespace + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv23 := &x.AuthToken + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + for { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj14-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *NodeEvaluateRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodeID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *NodeEvaluateRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *NodeEvaluateRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "NodeID": + if r.TryDecodeAsNil() { + x.NodeID = "" + } else { + yyv4 := &x.NodeID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv10 := &x.AuthToken + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *NodeEvaluateRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodeID = "" + } else { + yyv13 := &x.NodeID + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv15 := &x.Region + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv17 := &x.Namespace + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv19 := &x.AuthToken + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *NodeSpecificRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [9]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(9) + } else { + yynn2 = 9 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodeID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.SecretID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("SecretID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.SecretID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym29 := z.EncBinary() + _ = yym29 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *NodeSpecificRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *NodeSpecificRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "NodeID": + if r.TryDecodeAsNil() { + x.NodeID = "" + } else { + yyv4 := &x.NodeID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "SecretID": + if r.TryDecodeAsNil() { + x.SecretID = "" + } else { + yyv6 := &x.SecretID + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv8 := &x.Region + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv10 := &x.Namespace + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv12 := &x.MinQueryIndex + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*uint64)(yyv12)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv14 := &x.MaxQueryTime + yym15 := z.DecBinary() + _ = yym15 + if false { + } else if z.HasExtensions() && z.DecExt(yyv14) { + } else { + *((*int64)(yyv14)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv16 := &x.AllowStale + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*bool)(yyv16)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv18 := &x.Prefix + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv20 := &x.AuthToken + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*string)(yyv20)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *NodeSpecificRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj22 int + var yyb22 bool + var yyhl22 bool = l >= 0 + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodeID = "" + } else { + yyv23 := &x.NodeID + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.SecretID = "" + } else { + yyv25 := &x.SecretID + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv27 := &x.Region + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv29 := &x.Namespace + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv31 := &x.MinQueryIndex + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*uint64)(yyv31)) = uint64(r.DecodeUint(64)) + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv33 := &x.MaxQueryTime + yym34 := z.DecBinary() + _ = yym34 + if false { + } else if z.HasExtensions() && z.DecExt(yyv33) { + } else { + *((*int64)(yyv33)) = int64(r.DecodeInt(64)) + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv35 := &x.AllowStale + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*bool)(yyv35)) = r.DecodeBool() + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv37 := &x.Prefix + yym38 := z.DecBinary() + _ = yym38 + if false { + } else { + *((*string)(yyv37)) = r.DecodeString() + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv39 := &x.AuthToken + yym40 := z.DecBinary() + _ = yym40 + if false { + } else { + *((*string)(yyv39)) = r.DecodeString() + } + } + for { + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj22-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *SearchResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 5 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Matches == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encMapContextSlicestring((map[Context][]string)(x.Matches), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Matches")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Matches == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encMapContextSlicestring((map[Context][]string)(x.Matches), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Truncations == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + h.encMapContextbool((map[Context]bool)(x.Truncations), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Truncations")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Truncations == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + h.encMapContextbool((map[Context]bool)(x.Truncations), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *SearchResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *SearchResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Matches": + if r.TryDecodeAsNil() { + x.Matches = nil + } else { + yyv4 := &x.Matches + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decMapContextSlicestring((*map[Context][]string)(yyv4), d) + } + } + case "Truncations": + if r.TryDecodeAsNil() { + x.Truncations = nil + } else { + yyv6 := &x.Truncations + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + h.decMapContextbool((*map[Context]bool)(yyv6), d) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv8 := &x.Index + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv10 := &x.LastContact + yym11 := z.DecBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.DecExt(yyv10) { + } else { + *((*int64)(yyv10)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv12 := &x.KnownLeader + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*bool)(yyv12)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *SearchResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Matches = nil + } else { + yyv15 := &x.Matches + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + h.decMapContextSlicestring((*map[Context][]string)(yyv15), d) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Truncations = nil + } else { + yyv17 := &x.Truncations + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + h.decMapContextbool((*map[Context]bool)(yyv17), d) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv19 := &x.Index + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv21 := &x.LastContact + yym22 := z.DecBinary() + _ = yym22 + if false { + } else if z.HasExtensions() && z.DecExt(yyv21) { + } else { + *((*int64)(yyv21)) = int64(r.DecodeInt(64)) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv23 := &x.KnownLeader + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*bool)(yyv23)) = r.DecodeBool() + } + } + for { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj14-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *SearchRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(8) + } else { + yynn2 = 8 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + x.Context.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Context")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + x.Context.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *SearchRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *SearchRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv4 := &x.Prefix + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Context": + if r.TryDecodeAsNil() { + x.Context = "" + } else { + yyv6 := &x.Context + yyv6.CodecDecodeSelf(d) + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv7 := &x.Region + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*string)(yyv7)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv9 := &x.Namespace + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv11 := &x.MinQueryIndex + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*uint64)(yyv11)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv13 := &x.MaxQueryTime + yym14 := z.DecBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.DecExt(yyv13) { + } else { + *((*int64)(yyv13)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv15 := &x.AllowStale + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*bool)(yyv15)) = r.DecodeBool() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv17 := &x.AuthToken + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *SearchRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj19 int + var yyb19 bool + var yyhl19 bool = l >= 0 + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv20 := &x.Prefix + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*string)(yyv20)) = r.DecodeString() + } + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Context = "" + } else { + yyv22 := &x.Context + yyv22.CodecDecodeSelf(d) + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv23 := &x.Region + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv25 := &x.Namespace + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv27 := &x.MinQueryIndex + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) + } + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv29 := &x.MaxQueryTime + yym30 := z.DecBinary() + _ = yym30 + if false { + } else if z.HasExtensions() && z.DecExt(yyv29) { + } else { + *((*int64)(yyv29)) = int64(r.DecodeInt(64)) + } + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv31 := &x.AllowStale + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*bool)(yyv31)) = r.DecodeBool() + } + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv33 := &x.AuthToken + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*string)(yyv33)) = r.DecodeString() + } + } + for { + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj19-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobRegisterRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [7]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(7) + } else { + yynn2 = 7 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Job == nil { + r.EncodeNil() + } else { + x.Job.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Job")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Job == nil { + r.EncodeNil() + } else { + x.Job.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeBool(bool(x.EnforceIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EnforceIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeBool(bool(x.EnforceIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.JobModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.JobModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.PolicyOverride)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("PolicyOverride")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.PolicyOverride)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobRegisterRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobRegisterRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Job": + if r.TryDecodeAsNil() { + if x.Job != nil { + x.Job = nil + } + } else { + if x.Job == nil { + x.Job = new(Job) + } + x.Job.CodecDecodeSelf(d) + } + case "EnforceIndex": + if r.TryDecodeAsNil() { + x.EnforceIndex = false + } else { + yyv5 := &x.EnforceIndex + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*bool)(yyv5)) = r.DecodeBool() + } + } + case "JobModifyIndex": + if r.TryDecodeAsNil() { + x.JobModifyIndex = 0 + } else { + yyv7 := &x.JobModifyIndex + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*uint64)(yyv7)) = uint64(r.DecodeUint(64)) + } + } + case "PolicyOverride": + if r.TryDecodeAsNil() { + x.PolicyOverride = false + } else { + yyv9 := &x.PolicyOverride + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*bool)(yyv9)) = r.DecodeBool() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv11 := &x.Region + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv13 := &x.Namespace + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv15 := &x.AuthToken + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobRegisterRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj17 int + var yyb17 bool + var yyhl17 bool = l >= 0 + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Job != nil { + x.Job = nil + } + } else { + if x.Job == nil { + x.Job = new(Job) + } + x.Job.CodecDecodeSelf(d) + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EnforceIndex = false + } else { + yyv19 := &x.EnforceIndex + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobModifyIndex = 0 + } else { + yyv21 := &x.JobModifyIndex + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*uint64)(yyv21)) = uint64(r.DecodeUint(64)) + } + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.PolicyOverride = false + } else { + yyv23 := &x.PolicyOverride + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*bool)(yyv23)) = r.DecodeBool() + } + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv25 := &x.Region + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv27 := &x.Namespace + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv29 := &x.AuthToken + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } + } + for { + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj17-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobDeregisterRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 5 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeBool(bool(x.Purge)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Purge")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeBool(bool(x.Purge)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobDeregisterRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobDeregisterRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "JobID": + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv4 := &x.JobID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Purge": + if r.TryDecodeAsNil() { + x.Purge = false + } else { + yyv6 := &x.Purge + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*bool)(yyv6)) = r.DecodeBool() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv8 := &x.Region + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv10 := &x.Namespace + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv12 := &x.AuthToken + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobDeregisterRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv15 := &x.JobID + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Purge = false + } else { + yyv17 := &x.Purge + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*bool)(yyv17)) = r.DecodeBool() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv19 := &x.Region + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv21 := &x.Namespace + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv23 := &x.AuthToken + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + for { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj14-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobEvaluateRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobEvaluateRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobEvaluateRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "JobID": + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv4 := &x.JobID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv10 := &x.AuthToken + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobEvaluateRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv13 := &x.JobID + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv15 := &x.Region + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv17 := &x.Namespace + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv19 := &x.AuthToken + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobSpecificRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [9]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(9) + } else { + yynn2 = 9 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeBool(bool(x.AllAllocs)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllAllocs")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeBool(bool(x.AllAllocs)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym29 := z.EncBinary() + _ = yym29 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobSpecificRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobSpecificRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "JobID": + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv4 := &x.JobID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "AllAllocs": + if r.TryDecodeAsNil() { + x.AllAllocs = false + } else { + yyv6 := &x.AllAllocs + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*bool)(yyv6)) = r.DecodeBool() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv8 := &x.Region + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv10 := &x.Namespace + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv12 := &x.MinQueryIndex + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*uint64)(yyv12)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv14 := &x.MaxQueryTime + yym15 := z.DecBinary() + _ = yym15 + if false { + } else if z.HasExtensions() && z.DecExt(yyv14) { + } else { + *((*int64)(yyv14)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv16 := &x.AllowStale + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*bool)(yyv16)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv18 := &x.Prefix + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv20 := &x.AuthToken + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*string)(yyv20)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobSpecificRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj22 int + var yyb22 bool + var yyhl22 bool = l >= 0 + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv23 := &x.JobID + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllAllocs = false + } else { + yyv25 := &x.AllAllocs + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*bool)(yyv25)) = r.DecodeBool() + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv27 := &x.Region + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv29 := &x.Namespace + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv31 := &x.MinQueryIndex + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*uint64)(yyv31)) = uint64(r.DecodeUint(64)) + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv33 := &x.MaxQueryTime + yym34 := z.DecBinary() + _ = yym34 + if false { + } else if z.HasExtensions() && z.DecExt(yyv33) { + } else { + *((*int64)(yyv33)) = int64(r.DecodeInt(64)) + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv35 := &x.AllowStale + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*bool)(yyv35)) = r.DecodeBool() + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv37 := &x.Prefix + yym38 := z.DecBinary() + _ = yym38 + if false { + } else { + *((*string)(yyv37)) = r.DecodeString() + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv39 := &x.AuthToken + yym40 := z.DecBinary() + _ = yym40 + if false { + } else { + *((*string)(yyv39)) = r.DecodeString() + } + } + for { + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj22-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobListRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [7]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(7) + } else { + yynn2 = 7 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobListRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobListRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv4 := &x.Region + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv6 := &x.Namespace + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv8 := &x.MinQueryIndex + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv10 := &x.MaxQueryTime + yym11 := z.DecBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.DecExt(yyv10) { + } else { + *((*int64)(yyv10)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv12 := &x.AllowStale + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*bool)(yyv12)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv14 := &x.Prefix + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv16 := &x.AuthToken + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobListRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj18 int + var yyb18 bool + var yyhl18 bool = l >= 0 + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv19 := &x.Region + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv21 := &x.Namespace + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv23 := &x.MinQueryIndex + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv25 := &x.MaxQueryTime + yym26 := z.DecBinary() + _ = yym26 + if false { + } else if z.HasExtensions() && z.DecExt(yyv25) { + } else { + *((*int64)(yyv25)) = int64(r.DecodeInt(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv27 := &x.AllowStale + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*bool)(yyv27)) = r.DecodeBool() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv29 := &x.Prefix + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv31 := &x.AuthToken + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } + } + for { + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj18-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobPlanRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) + } else { + yynn2 = 6 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Job == nil { + r.EncodeNil() + } else { + x.Job.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Job")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Job == nil { + r.EncodeNil() + } else { + x.Job.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeBool(bool(x.Diff)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Diff")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeBool(bool(x.Diff)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeBool(bool(x.PolicyOverride)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("PolicyOverride")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeBool(bool(x.PolicyOverride)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobPlanRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobPlanRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Job": + if r.TryDecodeAsNil() { + if x.Job != nil { + x.Job = nil + } + } else { + if x.Job == nil { + x.Job = new(Job) + } + x.Job.CodecDecodeSelf(d) + } + case "Diff": + if r.TryDecodeAsNil() { + x.Diff = false + } else { + yyv5 := &x.Diff + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*bool)(yyv5)) = r.DecodeBool() + } + } + case "PolicyOverride": + if r.TryDecodeAsNil() { + x.PolicyOverride = false + } else { + yyv7 := &x.PolicyOverride + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*bool)(yyv7)) = r.DecodeBool() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv9 := &x.Region + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv11 := &x.Namespace + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv13 := &x.AuthToken + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobPlanRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj15 int + var yyb15 bool + var yyhl15 bool = l >= 0 + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Job != nil { + x.Job = nil + } + } else { + if x.Job == nil { + x.Job = new(Job) + } + x.Job.CodecDecodeSelf(d) + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Diff = false + } else { + yyv17 := &x.Diff + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*bool)(yyv17)) = r.DecodeBool() + } + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.PolicyOverride = false + } else { + yyv19 := &x.PolicyOverride + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv21 := &x.Region + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv23 := &x.Namespace + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv25 := &x.AuthToken + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + for { + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj15-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobSummaryRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(8) + } else { + yynn2 = 8 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobSummaryRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobSummaryRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "JobID": + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv4 := &x.JobID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv10 := &x.MinQueryIndex + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv12 := &x.MaxQueryTime + yym13 := z.DecBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.DecExt(yyv12) { + } else { + *((*int64)(yyv12)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv14 := &x.AllowStale + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv16 := &x.Prefix + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv18 := &x.AuthToken + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobSummaryRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj20 int + var yyb20 bool + var yyhl20 bool = l >= 0 + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv21 := &x.JobID + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv23 := &x.Region + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv25 := &x.Namespace + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv27 := &x.MinQueryIndex + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv29 := &x.MaxQueryTime + yym30 := z.DecBinary() + _ = yym30 + if false { + } else if z.HasExtensions() && z.DecExt(yyv29) { + } else { + *((*int64)(yyv29)) = int64(r.DecodeInt(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv31 := &x.AllowStale + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*bool)(yyv31)) = r.DecodeBool() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv33 := &x.Prefix + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*string)(yyv33)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv35 := &x.AuthToken + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*string)(yyv35)) = r.DecodeString() + } + } + for { + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj20-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobDispatchRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) + } else { + yynn2 = 6 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Payload == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Payload)) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Payload")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Payload == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Payload)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Meta == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + z.F.EncMapStringStringV(x.Meta, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Meta")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Meta == nil { + r.EncodeNil() + } else { + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + z.F.EncMapStringStringV(x.Meta, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobDispatchRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobDispatchRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "JobID": + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv4 := &x.JobID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Payload": + if r.TryDecodeAsNil() { + x.Payload = nil + } else { + yyv6 := &x.Payload + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *yyv6 = r.DecodeBytes(*(*[]byte)(yyv6), false, false) + } + } + case "Meta": + if r.TryDecodeAsNil() { + x.Meta = nil + } else { + yyv8 := &x.Meta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + z.F.DecMapStringStringX(yyv8, false, d) + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv10 := &x.Region + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv12 := &x.Namespace + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv14 := &x.AuthToken + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobDispatchRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj16 int + var yyb16 bool + var yyhl16 bool = l >= 0 + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv17 := &x.JobID + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Payload = nil + } else { + yyv19 := &x.Payload + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *yyv19 = r.DecodeBytes(*(*[]byte)(yyv19), false, false) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Meta = nil + } else { + yyv21 := &x.Meta + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + z.F.DecMapStringStringX(yyv21, false, d) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv23 := &x.Region + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv25 := &x.Namespace + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv27 := &x.AuthToken + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } + } + for { + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj16-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobValidateRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Job == nil { + r.EncodeNil() + } else { + x.Job.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Job")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Job == nil { + r.EncodeNil() + } else { + x.Job.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobValidateRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobValidateRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Job": + if r.TryDecodeAsNil() { + if x.Job != nil { + x.Job = nil + } + } else { + if x.Job == nil { + x.Job = new(Job) + } + x.Job.CodecDecodeSelf(d) + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv5 := &x.Region + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv7 := &x.Namespace + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*string)(yyv7)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv9 := &x.AuthToken + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobValidateRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Job != nil { + x.Job = nil + } + } else { + if x.Job == nil { + x.Job = new(Job) + } + x.Job.CodecDecodeSelf(d) + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv13 := &x.Region + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv15 := &x.Namespace + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv17 := &x.AuthToken + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + for { + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj11-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobRevertRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) + } else { + yynn2 = 6 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.JobVersion)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.JobVersion)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.EnforcePriorVersion == nil { + r.EncodeNil() + } else { + yy10 := *x.EnforcePriorVersion + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(yy10)) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EnforcePriorVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.EnforcePriorVersion == nil { + r.EncodeNil() + } else { + yy12 := *x.EnforcePriorVersion + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeUint(uint64(yy12)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym18 := z.EncBinary() + _ = yym18 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym21 := z.EncBinary() + _ = yym21 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobRevertRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobRevertRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "JobID": + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv4 := &x.JobID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "JobVersion": + if r.TryDecodeAsNil() { + x.JobVersion = 0 + } else { + yyv6 := &x.JobVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "EnforcePriorVersion": + if r.TryDecodeAsNil() { + if x.EnforcePriorVersion != nil { + x.EnforcePriorVersion = nil + } + } else { + if x.EnforcePriorVersion == nil { + x.EnforcePriorVersion = new(uint64) + } + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(x.EnforcePriorVersion)) = uint64(r.DecodeUint(64)) + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv10 := &x.Region + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv12 := &x.Namespace + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv14 := &x.AuthToken + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobRevertRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj16 int + var yyb16 bool + var yyhl16 bool = l >= 0 + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv17 := &x.JobID + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobVersion = 0 + } else { + yyv19 := &x.JobVersion + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.EnforcePriorVersion != nil { + x.EnforcePriorVersion = nil + } + } else { + if x.EnforcePriorVersion == nil { + x.EnforcePriorVersion = new(uint64) + } + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*uint64)(x.EnforcePriorVersion)) = uint64(r.DecodeUint(64)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv23 := &x.Region + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv25 := &x.Namespace + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv27 := &x.AuthToken + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } + } + for { + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj16-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobStabilityRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) + } else { + yynn2 = 6 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.JobVersion)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.JobVersion)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeBool(bool(x.Stable)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Stable")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeBool(bool(x.Stable)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobStabilityRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobStabilityRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "JobID": + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv4 := &x.JobID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "JobVersion": + if r.TryDecodeAsNil() { + x.JobVersion = 0 + } else { + yyv6 := &x.JobVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "Stable": + if r.TryDecodeAsNil() { + x.Stable = false + } else { + yyv8 := &x.Stable + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*bool)(yyv8)) = r.DecodeBool() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv10 := &x.Region + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv12 := &x.Namespace + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv14 := &x.AuthToken + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobStabilityRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj16 int + var yyb16 bool + var yyhl16 bool = l >= 0 + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv17 := &x.JobID + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobVersion = 0 + } else { + yyv19 := &x.JobVersion + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Stable = false + } else { + yyv21 := &x.Stable + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*bool)(yyv21)) = r.DecodeBool() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv23 := &x.Region + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv25 := &x.Namespace + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv27 := &x.AuthToken + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } + } + for { + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj16-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobStabilityResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(1) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobStabilityResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobStabilityResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv4 := &x.Index + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*uint64)(yyv4)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobStabilityResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + 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 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv7 := &x.Index + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*uint64)(yyv7)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj6-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *NodeListRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [7]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(7) + } else { + yynn2 = 7 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *NodeListRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *NodeListRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv4 := &x.Region + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv6 := &x.Namespace + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv8 := &x.MinQueryIndex + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv10 := &x.MaxQueryTime + yym11 := z.DecBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.DecExt(yyv10) { + } else { + *((*int64)(yyv10)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv12 := &x.AllowStale + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*bool)(yyv12)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv14 := &x.Prefix + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv16 := &x.AuthToken + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *NodeListRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj18 int + var yyb18 bool + var yyhl18 bool = l >= 0 + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv19 := &x.Region + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv21 := &x.Namespace + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv23 := &x.MinQueryIndex + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv25 := &x.MaxQueryTime + yym26 := z.DecBinary() + _ = yym26 + if false { + } else if z.HasExtensions() && z.DecExt(yyv25) { + } else { + *((*int64)(yyv25)) = int64(r.DecodeInt(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv27 := &x.AllowStale + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*bool)(yyv27)) = r.DecodeBool() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv29 := &x.Prefix + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv31 := &x.AuthToken + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } + } + for { + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj18-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *EvalUpdateRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 5 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Evals == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSlicePtrtoEvaluation(([]*Evaluation)(x.Evals), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Evals")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Evals == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSlicePtrtoEvaluation(([]*Evaluation)(x.Evals), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *EvalUpdateRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *EvalUpdateRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Evals": + if r.TryDecodeAsNil() { + x.Evals = nil + } else { + yyv4 := &x.Evals + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSlicePtrtoEvaluation((*[]*Evaluation)(yyv4), d) + } + } + case "EvalToken": + if r.TryDecodeAsNil() { + x.EvalToken = "" + } else { + yyv6 := &x.EvalToken + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv8 := &x.Region + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv10 := &x.Namespace + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv12 := &x.AuthToken + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *EvalUpdateRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Evals = nil + } else { + yyv15 := &x.Evals + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + h.decSlicePtrtoEvaluation((*[]*Evaluation)(yyv15), d) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalToken = "" + } else { + yyv17 := &x.EvalToken + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv19 := &x.Region + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv21 := &x.Namespace + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv23 := &x.AuthToken + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + for { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj14-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *EvalDeleteRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 5 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Evals == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + z.F.EncSliceStringV(x.Evals, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Evals")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Evals == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + z.F.EncSliceStringV(x.Evals, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Allocs == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + z.F.EncSliceStringV(x.Allocs, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Allocs")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Allocs == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + z.F.EncSliceStringV(x.Allocs, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *EvalDeleteRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *EvalDeleteRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Evals": + if r.TryDecodeAsNil() { + x.Evals = nil + } else { + yyv4 := &x.Evals + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + z.F.DecSliceStringX(yyv4, false, d) + } + } + case "Allocs": + if r.TryDecodeAsNil() { + x.Allocs = nil + } else { + yyv6 := &x.Allocs + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + z.F.DecSliceStringX(yyv6, false, d) + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv8 := &x.Region + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv10 := &x.Namespace + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv12 := &x.AuthToken + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *EvalDeleteRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Evals = nil + } else { + yyv15 := &x.Evals + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + z.F.DecSliceStringX(yyv15, false, d) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Allocs = nil + } else { + yyv17 := &x.Allocs + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + z.F.DecSliceStringX(yyv17, false, d) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv19 := &x.Region + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv21 := &x.Namespace + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv23 := &x.AuthToken + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + for { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj14-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *EvalSpecificRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(8) + } else { + yynn2 = 8 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *EvalSpecificRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *EvalSpecificRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "EvalID": + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv4 := &x.EvalID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv10 := &x.MinQueryIndex + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv12 := &x.MaxQueryTime + yym13 := z.DecBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.DecExt(yyv12) { + } else { + *((*int64)(yyv12)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv14 := &x.AllowStale + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv16 := &x.Prefix + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv18 := &x.AuthToken + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *EvalSpecificRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj20 int + var yyb20 bool + var yyhl20 bool = l >= 0 + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv21 := &x.EvalID + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv23 := &x.Region + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv25 := &x.Namespace + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv27 := &x.MinQueryIndex + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv29 := &x.MaxQueryTime + yym30 := z.DecBinary() + _ = yym30 + if false { + } else if z.HasExtensions() && z.DecExt(yyv29) { + } else { + *((*int64)(yyv29)) = int64(r.DecodeInt(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv31 := &x.AllowStale + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*bool)(yyv31)) = r.DecodeBool() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv33 := &x.Prefix + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*string)(yyv33)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv35 := &x.AuthToken + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*string)(yyv35)) = r.DecodeString() + } + } + for { + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj20-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *EvalAckRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 5 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Token)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Token")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Token)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *EvalAckRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *EvalAckRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "EvalID": + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv4 := &x.EvalID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Token": + if r.TryDecodeAsNil() { + x.Token = "" + } else { + yyv6 := &x.Token + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv8 := &x.Region + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv10 := &x.Namespace + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv12 := &x.AuthToken + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *EvalAckRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv15 := &x.EvalID + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Token = "" + } else { + yyv17 := &x.Token + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv19 := &x.Region + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv21 := &x.Namespace + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv23 := &x.AuthToken + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + for { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj14-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *EvalDequeueRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) + } else { + yynn2 = 6 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Schedulers == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + z.F.EncSliceStringV(x.Schedulers, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Schedulers")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Schedulers == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + z.F.EncSliceStringV(x.Schedulers, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.EncExt(x.Timeout) { + } else { + r.EncodeInt(int64(x.Timeout)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Timeout")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.EncExt(x.Timeout) { + } else { + r.EncodeInt(int64(x.Timeout)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.SchedulerVersion)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("SchedulerVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.SchedulerVersion)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *EvalDequeueRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *EvalDequeueRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Schedulers": + if r.TryDecodeAsNil() { + x.Schedulers = nil + } else { + yyv4 := &x.Schedulers + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + z.F.DecSliceStringX(yyv4, false, d) + } + } + case "Timeout": + if r.TryDecodeAsNil() { + x.Timeout = 0 + } else { + yyv6 := &x.Timeout + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else { + *((*int64)(yyv6)) = int64(r.DecodeInt(64)) + } + } + case "SchedulerVersion": + if r.TryDecodeAsNil() { + x.SchedulerVersion = 0 + } else { + yyv8 := &x.SchedulerVersion + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint16)(yyv8)) = uint16(r.DecodeUint(16)) + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv10 := &x.Region + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv12 := &x.Namespace + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv14 := &x.AuthToken + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *EvalDequeueRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj16 int + var yyb16 bool + var yyhl16 bool = l >= 0 + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Schedulers = nil + } else { + yyv17 := &x.Schedulers + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + z.F.DecSliceStringX(yyv17, false, d) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Timeout = 0 + } else { + yyv19 := &x.Timeout + yym20 := z.DecBinary() + _ = yym20 + if false { + } else if z.HasExtensions() && z.DecExt(yyv19) { + } else { + *((*int64)(yyv19)) = int64(r.DecodeInt(64)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.SchedulerVersion = 0 + } else { + yyv21 := &x.SchedulerVersion + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*uint16)(yyv21)) = uint16(r.DecodeUint(16)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv23 := &x.Region + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv25 := &x.Namespace + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv27 := &x.AuthToken + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } + } + for { + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj16-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *EvalListRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [7]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(7) + } else { + yynn2 = 7 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *EvalListRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *EvalListRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv4 := &x.Region + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv6 := &x.Namespace + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv8 := &x.MinQueryIndex + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv10 := &x.MaxQueryTime + yym11 := z.DecBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.DecExt(yyv10) { + } else { + *((*int64)(yyv10)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv12 := &x.AllowStale + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*bool)(yyv12)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv14 := &x.Prefix + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv16 := &x.AuthToken + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *EvalListRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj18 int + var yyb18 bool + var yyhl18 bool = l >= 0 + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv19 := &x.Region + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv21 := &x.Namespace + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv23 := &x.MinQueryIndex + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv25 := &x.MaxQueryTime + yym26 := z.DecBinary() + _ = yym26 + if false { + } else if z.HasExtensions() && z.DecExt(yyv25) { + } else { + *((*int64)(yyv25)) = int64(r.DecodeInt(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv27 := &x.AllowStale + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*bool)(yyv27)) = r.DecodeBool() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv29 := &x.Prefix + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv31 := &x.AuthToken + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } + } + for { + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj18-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *PlanRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Plan == nil { + r.EncodeNil() + } else { + x.Plan.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Plan")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Plan == nil { + r.EncodeNil() + } else { + x.Plan.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *PlanRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *PlanRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Plan": + if r.TryDecodeAsNil() { + if x.Plan != nil { + x.Plan = nil + } + } else { + if x.Plan == nil { + x.Plan = new(Plan) + } + x.Plan.CodecDecodeSelf(d) + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv5 := &x.Region + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv7 := &x.Namespace + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*string)(yyv7)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv9 := &x.AuthToken + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *PlanRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Plan != nil { + x.Plan = nil + } + } else { + if x.Plan == nil { + x.Plan = new(Plan) + } + x.Plan.CodecDecodeSelf(d) + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv13 := &x.Region + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv15 := &x.Namespace + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv17 := &x.AuthToken + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + for { + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj11-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ApplyPlanResultsRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(8) + } else { + yynn2 = 8 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Alloc == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSlicePtrtoAllocation(([]*Allocation)(x.Alloc), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Alloc")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Alloc == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSlicePtrtoAllocation(([]*Allocation)(x.Alloc), e) + } + } + } + var yyn6 bool + if x.AllocUpdateRequest.Job == nil { + yyn6 = true + goto LABEL6 + } + LABEL6: + if yyr2 || yy2arr2 { + if yyn6 { + r.EncodeNil() + } else { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Job == nil { + r.EncodeNil() + } else { + x.Job.CodecEncodeSelf(e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Job")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if yyn6 { + r.EncodeNil() + } else { + if x.Job == nil { + r.EncodeNil() + } else { + x.Job.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Deployment == nil { + r.EncodeNil() + } else { + x.Deployment.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Deployment")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Deployment == nil { + r.EncodeNil() + } else { + x.Deployment.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.DeploymentUpdates == nil { + r.EncodeNil() + } else { + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + h.encSlicePtrtoDeploymentStatusUpdate(([]*DeploymentStatusUpdate)(x.DeploymentUpdates), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DeploymentUpdates")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.DeploymentUpdates == nil { + r.EncodeNil() + } else { + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + h.encSlicePtrtoDeploymentStatusUpdate(([]*DeploymentStatusUpdate)(x.DeploymentUpdates), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ApplyPlanResultsRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ApplyPlanResultsRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Alloc": + if r.TryDecodeAsNil() { + x.Alloc = nil + } else { + yyv4 := &x.Alloc + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSlicePtrtoAllocation((*[]*Allocation)(yyv4), d) + } + } + case "Job": + if x.AllocUpdateRequest.Job == nil { + x.AllocUpdateRequest.Job = new(Job) + } + if r.TryDecodeAsNil() { + if x.Job != nil { + x.Job = nil + } + } else { + if x.Job == nil { + x.Job = new(Job) + } + x.Job.CodecDecodeSelf(d) + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv7 := &x.Region + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*string)(yyv7)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv9 := &x.Namespace + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv11 := &x.AuthToken + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + case "Deployment": + if r.TryDecodeAsNil() { + if x.Deployment != nil { + x.Deployment = nil + } + } else { + if x.Deployment == nil { + x.Deployment = new(Deployment) + } + x.Deployment.CodecDecodeSelf(d) + } + case "DeploymentUpdates": + if r.TryDecodeAsNil() { + x.DeploymentUpdates = nil + } else { + yyv14 := &x.DeploymentUpdates + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + h.decSlicePtrtoDeploymentStatusUpdate((*[]*DeploymentStatusUpdate)(yyv14), d) + } + } + case "EvalID": + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv16 := &x.EvalID + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ApplyPlanResultsRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj18 int + var yyb18 bool + var yyhl18 bool = l >= 0 + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Alloc = nil + } else { + yyv19 := &x.Alloc + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSlicePtrtoAllocation((*[]*Allocation)(yyv19), d) + } + } + if x.AllocUpdateRequest.Job == nil { + x.AllocUpdateRequest.Job = new(Job) + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Job != nil { + x.Job = nil + } + } else { + if x.Job == nil { + x.Job = new(Job) + } + x.Job.CodecDecodeSelf(d) + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv22 := &x.Region + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + *((*string)(yyv22)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv24 := &x.Namespace + yym25 := z.DecBinary() + _ = yym25 + if false { + } else { + *((*string)(yyv24)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv26 := &x.AuthToken + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + *((*string)(yyv26)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Deployment != nil { + x.Deployment = nil + } + } else { + if x.Deployment == nil { + x.Deployment = new(Deployment) + } + x.Deployment.CodecDecodeSelf(d) + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DeploymentUpdates = nil + } else { + yyv29 := &x.DeploymentUpdates + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + h.decSlicePtrtoDeploymentStatusUpdate((*[]*DeploymentStatusUpdate)(yyv29), d) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv31 := &x.EvalID + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } + } + for { + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj18-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *AllocUpdateRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 5 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Alloc == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSlicePtrtoAllocation(([]*Allocation)(x.Alloc), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Alloc")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Alloc == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSlicePtrtoAllocation(([]*Allocation)(x.Alloc), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Job == nil { + r.EncodeNil() + } else { + x.Job.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Job")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Job == nil { + r.EncodeNil() + } else { + x.Job.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *AllocUpdateRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *AllocUpdateRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Alloc": + if r.TryDecodeAsNil() { + x.Alloc = nil + } else { + yyv4 := &x.Alloc + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSlicePtrtoAllocation((*[]*Allocation)(yyv4), d) + } + } + case "Job": + if r.TryDecodeAsNil() { + if x.Job != nil { + x.Job = nil + } + } else { + if x.Job == nil { + x.Job = new(Job) + } + x.Job.CodecDecodeSelf(d) + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv7 := &x.Region + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*string)(yyv7)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv9 := &x.Namespace + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv11 := &x.AuthToken + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *AllocUpdateRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj13 int + var yyb13 bool + var yyhl13 bool = l >= 0 + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Alloc = nil + } else { + yyv14 := &x.Alloc + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + h.decSlicePtrtoAllocation((*[]*Allocation)(yyv14), d) + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Job != nil { + x.Job = nil + } + } else { + if x.Job == nil { + x.Job = new(Job) + } + x.Job.CodecDecodeSelf(d) + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv17 := &x.Region + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv19 := &x.Namespace + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv21 := &x.AuthToken + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + for { + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj13-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *AllocListRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [7]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(7) + } else { + yynn2 = 7 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *AllocListRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *AllocListRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv4 := &x.Region + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv6 := &x.Namespace + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv8 := &x.MinQueryIndex + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv10 := &x.MaxQueryTime + yym11 := z.DecBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.DecExt(yyv10) { + } else { + *((*int64)(yyv10)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv12 := &x.AllowStale + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*bool)(yyv12)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv14 := &x.Prefix + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv16 := &x.AuthToken + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *AllocListRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj18 int + var yyb18 bool + var yyhl18 bool = l >= 0 + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv19 := &x.Region + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv21 := &x.Namespace + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv23 := &x.MinQueryIndex + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv25 := &x.MaxQueryTime + yym26 := z.DecBinary() + _ = yym26 + if false { + } else if z.HasExtensions() && z.DecExt(yyv25) { + } else { + *((*int64)(yyv25)) = int64(r.DecodeInt(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv27 := &x.AllowStale + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*bool)(yyv27)) = r.DecodeBool() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv29 := &x.Prefix + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv31 := &x.AuthToken + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } + } + for { + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj18-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *AllocSpecificRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(8) + } else { + yynn2 = 8 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AllocID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllocID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AllocID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *AllocSpecificRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *AllocSpecificRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "AllocID": + if r.TryDecodeAsNil() { + x.AllocID = "" + } else { + yyv4 := &x.AllocID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv10 := &x.MinQueryIndex + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv12 := &x.MaxQueryTime + yym13 := z.DecBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.DecExt(yyv12) { + } else { + *((*int64)(yyv12)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv14 := &x.AllowStale + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv16 := &x.Prefix + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv18 := &x.AuthToken + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *AllocSpecificRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj20 int + var yyb20 bool + var yyhl20 bool = l >= 0 + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllocID = "" + } else { + yyv21 := &x.AllocID + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv23 := &x.Region + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv25 := &x.Namespace + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv27 := &x.MinQueryIndex + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv29 := &x.MaxQueryTime + yym30 := z.DecBinary() + _ = yym30 + if false { + } else if z.HasExtensions() && z.DecExt(yyv29) { + } else { + *((*int64)(yyv29)) = int64(r.DecodeInt(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv31 := &x.AllowStale + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*bool)(yyv31)) = r.DecodeBool() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv33 := &x.Prefix + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*string)(yyv33)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv35 := &x.AuthToken + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*string)(yyv35)) = r.DecodeString() + } + } + for { + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj20-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *AllocsGetRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(8) + } else { + yynn2 = 8 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.AllocIDs == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + z.F.EncSliceStringV(x.AllocIDs, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllocIDs")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.AllocIDs == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + z.F.EncSliceStringV(x.AllocIDs, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *AllocsGetRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *AllocsGetRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "AllocIDs": + if r.TryDecodeAsNil() { + x.AllocIDs = nil + } else { + yyv4 := &x.AllocIDs + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + z.F.DecSliceStringX(yyv4, false, d) + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv10 := &x.MinQueryIndex + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv12 := &x.MaxQueryTime + yym13 := z.DecBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.DecExt(yyv12) { + } else { + *((*int64)(yyv12)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv14 := &x.AllowStale + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv16 := &x.Prefix + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv18 := &x.AuthToken + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *AllocsGetRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj20 int + var yyb20 bool + var yyhl20 bool = l >= 0 + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllocIDs = nil + } else { + yyv21 := &x.AllocIDs + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + z.F.DecSliceStringX(yyv21, false, d) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv23 := &x.Region + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv25 := &x.Namespace + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv27 := &x.MinQueryIndex + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv29 := &x.MaxQueryTime + yym30 := z.DecBinary() + _ = yym30 + if false { + } else if z.HasExtensions() && z.DecExt(yyv29) { + } else { + *((*int64)(yyv29)) = int64(r.DecodeInt(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv31 := &x.AllowStale + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*bool)(yyv31)) = r.DecodeBool() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv33 := &x.Prefix + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*string)(yyv33)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv35 := &x.AuthToken + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*string)(yyv35)) = r.DecodeString() + } + } + for { + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj20-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *PeriodicForceRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *PeriodicForceRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *PeriodicForceRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "JobID": + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv4 := &x.JobID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv10 := &x.AuthToken + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *PeriodicForceRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv13 := &x.JobID + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv15 := &x.Region + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv17 := &x.Namespace + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv19 := &x.AuthToken + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ServerMembersResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ServerName)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ServerName")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ServerName)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ServerRegion)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ServerRegion")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ServerRegion)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ServerDC)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ServerDC")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ServerDC)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Members == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + h.encSlicePtrtoServerMember(([]*ServerMember)(x.Members), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Members")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Members == nil { + r.EncodeNil() + } else { + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + h.encSlicePtrtoServerMember(([]*ServerMember)(x.Members), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ServerMembersResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ServerMembersResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "ServerName": + if r.TryDecodeAsNil() { + x.ServerName = "" + } else { + yyv4 := &x.ServerName + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "ServerRegion": + if r.TryDecodeAsNil() { + x.ServerRegion = "" + } else { + yyv6 := &x.ServerRegion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "ServerDC": + if r.TryDecodeAsNil() { + x.ServerDC = "" + } else { + yyv8 := &x.ServerDC + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Members": + if r.TryDecodeAsNil() { + x.Members = nil + } else { + yyv10 := &x.Members + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSlicePtrtoServerMember((*[]*ServerMember)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ServerMembersResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ServerName = "" + } else { + yyv13 := &x.ServerName + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ServerRegion = "" + } else { + yyv15 := &x.ServerRegion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ServerDC = "" + } else { + yyv17 := &x.ServerDC + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Members = nil + } else { + yyv19 := &x.Members + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSlicePtrtoServerMember((*[]*ServerMember)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ServerMember) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [11]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(11) + } else { + yynn2 = 11 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Name")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Addr == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.EncExt(x.Addr) { + } else if !yym7 { + z.EncTextMarshal(x.Addr) + } else { + h.encnet_IP((net.IP)(x.Addr), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Addr")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Addr == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.EncExt(x.Addr) { + } else if !yym8 { + z.EncTextMarshal(x.Addr) + } else { + h.encnet_IP((net.IP)(x.Addr), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.Port)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Port")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.Port)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Tags == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + z.F.EncMapStringStringV(x.Tags, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Tags")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Tags == nil { + r.EncodeNil() + } else { + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + z.F.EncMapStringStringV(x.Tags, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Status)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Status")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Status)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeUint(uint64(x.ProtocolMin)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ProtocolMin")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeUint(uint64(x.ProtocolMin)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeUint(uint64(x.ProtocolMax)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ProtocolMax")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeUint(uint64(x.ProtocolMax)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeUint(uint64(x.ProtocolCur)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ProtocolCur")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeUint(uint64(x.ProtocolCur)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + r.EncodeUint(uint64(x.DelegateMin)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DelegateMin")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym29 := z.EncBinary() + _ = yym29 + if false { + } else { + r.EncodeUint(uint64(x.DelegateMin)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym31 := z.EncBinary() + _ = yym31 + if false { + } else { + r.EncodeUint(uint64(x.DelegateMax)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DelegateMax")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym32 := z.EncBinary() + _ = yym32 + if false { + } else { + r.EncodeUint(uint64(x.DelegateMax)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym34 := z.EncBinary() + _ = yym34 + if false { + } else { + r.EncodeUint(uint64(x.DelegateCur)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DelegateCur")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym35 := z.EncBinary() + _ = yym35 + if false { + } else { + r.EncodeUint(uint64(x.DelegateCur)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ServerMember) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ServerMember) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Addr": + if r.TryDecodeAsNil() { + x.Addr = nil + } else { + yyv6 := &x.Addr + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else if !yym7 { + z.DecTextUnmarshal(yyv6) + } else { + h.decnet_IP((*net.IP)(yyv6), d) + } + } + case "Port": + if r.TryDecodeAsNil() { + x.Port = 0 + } else { + yyv8 := &x.Port + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint16)(yyv8)) = uint16(r.DecodeUint(16)) + } + } + case "Tags": + if r.TryDecodeAsNil() { + x.Tags = nil + } else { + yyv10 := &x.Tags + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + z.F.DecMapStringStringX(yyv10, false, d) + } + } + case "Status": + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv12 := &x.Status + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + case "ProtocolMin": + if r.TryDecodeAsNil() { + x.ProtocolMin = 0 + } else { + yyv14 := &x.ProtocolMin + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*uint8)(yyv14)) = uint8(r.DecodeUint(8)) + } + } + case "ProtocolMax": + if r.TryDecodeAsNil() { + x.ProtocolMax = 0 + } else { + yyv16 := &x.ProtocolMax + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*uint8)(yyv16)) = uint8(r.DecodeUint(8)) + } + } + case "ProtocolCur": + if r.TryDecodeAsNil() { + x.ProtocolCur = 0 + } else { + yyv18 := &x.ProtocolCur + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*uint8)(yyv18)) = uint8(r.DecodeUint(8)) + } + } + case "DelegateMin": + if r.TryDecodeAsNil() { + x.DelegateMin = 0 + } else { + yyv20 := &x.DelegateMin + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*uint8)(yyv20)) = uint8(r.DecodeUint(8)) + } + } + case "DelegateMax": + if r.TryDecodeAsNil() { + x.DelegateMax = 0 + } else { + yyv22 := &x.DelegateMax + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + *((*uint8)(yyv22)) = uint8(r.DecodeUint(8)) + } + } + case "DelegateCur": + if r.TryDecodeAsNil() { + x.DelegateCur = 0 + } else { + yyv24 := &x.DelegateCur + yym25 := z.DecBinary() + _ = yym25 + if false { + } else { + *((*uint8)(yyv24)) = uint8(r.DecodeUint(8)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ServerMember) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj26 int + var yyb26 bool + var yyhl26 bool = l >= 0 + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv27 := &x.Name + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Addr = nil + } else { + yyv29 := &x.Addr + yym30 := z.DecBinary() + _ = yym30 + if false { + } else if z.HasExtensions() && z.DecExt(yyv29) { + } else if !yym30 { + z.DecTextUnmarshal(yyv29) + } else { + h.decnet_IP((*net.IP)(yyv29), d) + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Port = 0 + } else { + yyv31 := &x.Port + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*uint16)(yyv31)) = uint16(r.DecodeUint(16)) + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Tags = nil + } else { + yyv33 := &x.Tags + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + z.F.DecMapStringStringX(yyv33, false, d) + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv35 := &x.Status + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*string)(yyv35)) = r.DecodeString() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ProtocolMin = 0 + } else { + yyv37 := &x.ProtocolMin + yym38 := z.DecBinary() + _ = yym38 + if false { + } else { + *((*uint8)(yyv37)) = uint8(r.DecodeUint(8)) + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ProtocolMax = 0 + } else { + yyv39 := &x.ProtocolMax + yym40 := z.DecBinary() + _ = yym40 + if false { + } else { + *((*uint8)(yyv39)) = uint8(r.DecodeUint(8)) + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ProtocolCur = 0 + } else { + yyv41 := &x.ProtocolCur + yym42 := z.DecBinary() + _ = yym42 + if false { + } else { + *((*uint8)(yyv41)) = uint8(r.DecodeUint(8)) + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DelegateMin = 0 + } else { + yyv43 := &x.DelegateMin + yym44 := z.DecBinary() + _ = yym44 + if false { + } else { + *((*uint8)(yyv43)) = uint8(r.DecodeUint(8)) + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DelegateMax = 0 + } else { + yyv45 := &x.DelegateMax + yym46 := z.DecBinary() + _ = yym46 + if false { + } else { + *((*uint8)(yyv45)) = uint8(r.DecodeUint(8)) + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DelegateCur = 0 + } else { + yyv47 := &x.DelegateCur + yym48 := z.DecBinary() + _ = yym48 + if false { + } else { + *((*uint8)(yyv47)) = uint8(r.DecodeUint(8)) + } + } + for { + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj26-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *DeriveVaultTokenRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [11]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(11) + } else { + yynn2 = 11 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodeID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.SecretID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("SecretID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.SecretID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AllocID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllocID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AllocID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Tasks == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + z.F.EncSliceStringV(x.Tasks, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Tasks")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Tasks == nil { + r.EncodeNil() + } else { + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + z.F.EncSliceStringV(x.Tasks, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym29 := z.EncBinary() + _ = yym29 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym31 := z.EncBinary() + _ = yym31 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym32 := z.EncBinary() + _ = yym32 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym34 := z.EncBinary() + _ = yym34 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym35 := z.EncBinary() + _ = yym35 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *DeriveVaultTokenRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *DeriveVaultTokenRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "NodeID": + if r.TryDecodeAsNil() { + x.NodeID = "" + } else { + yyv4 := &x.NodeID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "SecretID": + if r.TryDecodeAsNil() { + x.SecretID = "" + } else { + yyv6 := &x.SecretID + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "AllocID": + if r.TryDecodeAsNil() { + x.AllocID = "" + } else { + yyv8 := &x.AllocID + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Tasks": + if r.TryDecodeAsNil() { + x.Tasks = nil + } else { + yyv10 := &x.Tasks + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + z.F.DecSliceStringX(yyv10, false, d) + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv12 := &x.Region + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv14 := &x.Namespace + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv16 := &x.MinQueryIndex + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*uint64)(yyv16)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv18 := &x.MaxQueryTime + yym19 := z.DecBinary() + _ = yym19 + if false { + } else if z.HasExtensions() && z.DecExt(yyv18) { + } else { + *((*int64)(yyv18)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv20 := &x.AllowStale + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*bool)(yyv20)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv22 := &x.Prefix + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + *((*string)(yyv22)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv24 := &x.AuthToken + yym25 := z.DecBinary() + _ = yym25 + if false { + } else { + *((*string)(yyv24)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *DeriveVaultTokenRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj26 int + var yyb26 bool + var yyhl26 bool = l >= 0 + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodeID = "" + } else { + yyv27 := &x.NodeID + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.SecretID = "" + } else { + yyv29 := &x.SecretID + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllocID = "" + } else { + yyv31 := &x.AllocID + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Tasks = nil + } else { + yyv33 := &x.Tasks + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + z.F.DecSliceStringX(yyv33, false, d) + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv35 := &x.Region + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*string)(yyv35)) = r.DecodeString() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv37 := &x.Namespace + yym38 := z.DecBinary() + _ = yym38 + if false { + } else { + *((*string)(yyv37)) = r.DecodeString() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv39 := &x.MinQueryIndex + yym40 := z.DecBinary() + _ = yym40 + if false { + } else { + *((*uint64)(yyv39)) = uint64(r.DecodeUint(64)) + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv41 := &x.MaxQueryTime + yym42 := z.DecBinary() + _ = yym42 + if false { + } else if z.HasExtensions() && z.DecExt(yyv41) { + } else { + *((*int64)(yyv41)) = int64(r.DecodeInt(64)) + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv43 := &x.AllowStale + yym44 := z.DecBinary() + _ = yym44 + if false { + } else { + *((*bool)(yyv43)) = r.DecodeBool() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv45 := &x.Prefix + yym46 := z.DecBinary() + _ = yym46 + if false { + } else { + *((*string)(yyv45)) = r.DecodeString() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv47 := &x.AuthToken + yym48 := z.DecBinary() + _ = yym48 + if false { + } else { + *((*string)(yyv47)) = r.DecodeString() + } + } + for { + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj26-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *VaultAccessorsRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(1) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Accessors == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSlicePtrtoVaultAccessor(([]*VaultAccessor)(x.Accessors), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Accessors")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Accessors == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSlicePtrtoVaultAccessor(([]*VaultAccessor)(x.Accessors), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *VaultAccessorsRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *VaultAccessorsRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Accessors": + if r.TryDecodeAsNil() { + x.Accessors = nil + } else { + yyv4 := &x.Accessors + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSlicePtrtoVaultAccessor((*[]*VaultAccessor)(yyv4), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *VaultAccessorsRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + 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 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Accessors = nil + } else { + yyv7 := &x.Accessors + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + h.decSlicePtrtoVaultAccessor((*[]*VaultAccessor)(yyv7), d) + } + } + for { + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj6-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *VaultAccessor) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) + } else { + yynn2 = 6 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AllocID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllocID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AllocID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Task)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Task")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Task)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodeID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Accessor)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Accessor")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Accessor)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeInt(int64(x.CreationTTL)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CreationTTL")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeInt(int64(x.CreationTTL)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *VaultAccessor) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *VaultAccessor) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "AllocID": + if r.TryDecodeAsNil() { + x.AllocID = "" + } else { + yyv4 := &x.AllocID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Task": + if r.TryDecodeAsNil() { + x.Task = "" + } else { + yyv6 := &x.Task + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "NodeID": + if r.TryDecodeAsNil() { + x.NodeID = "" + } else { + yyv8 := &x.NodeID + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Accessor": + if r.TryDecodeAsNil() { + x.Accessor = "" + } else { + yyv10 := &x.Accessor + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "CreationTTL": + if r.TryDecodeAsNil() { + x.CreationTTL = 0 + } else { + yyv12 := &x.CreationTTL + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*int)(yyv12)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "CreateIndex": + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv14 := &x.CreateIndex + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*uint64)(yyv14)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *VaultAccessor) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj16 int + var yyb16 bool + var yyhl16 bool = l >= 0 + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllocID = "" + } else { + yyv17 := &x.AllocID + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Task = "" + } else { + yyv19 := &x.Task + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodeID = "" + } else { + yyv21 := &x.NodeID + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Accessor = "" + } else { + yyv23 := &x.Accessor + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CreationTTL = 0 + } else { + yyv25 := &x.CreationTTL + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*int)(yyv25)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv27 := &x.CreateIndex + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj16-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *DeriveVaultTokenResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 5 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Tasks == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + z.F.EncMapStringStringV(x.Tasks, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Tasks")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Tasks == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + z.F.EncMapStringStringV(x.Tasks, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Error == nil { + r.EncodeNil() + } else { + x.Error.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Error")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Error == nil { + r.EncodeNil() + } else { + x.Error.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *DeriveVaultTokenResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *DeriveVaultTokenResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Tasks": + if r.TryDecodeAsNil() { + x.Tasks = nil + } else { + yyv4 := &x.Tasks + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + z.F.DecMapStringStringX(yyv4, false, d) + } + } + case "Error": + if r.TryDecodeAsNil() { + if x.Error != nil { + x.Error = nil + } + } else { + if x.Error == nil { + x.Error = new(RecoverableError) + } + x.Error.CodecDecodeSelf(d) + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv7 := &x.Index + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*uint64)(yyv7)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv9 := &x.LastContact + yym10 := z.DecBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.DecExt(yyv9) { + } else { + *((*int64)(yyv9)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv11 := &x.KnownLeader + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*bool)(yyv11)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *DeriveVaultTokenResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj13 int + var yyb13 bool + var yyhl13 bool = l >= 0 + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Tasks = nil + } else { + yyv14 := &x.Tasks + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + z.F.DecMapStringStringX(yyv14, false, d) + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Error != nil { + x.Error = nil + } + } else { + if x.Error == nil { + x.Error = new(RecoverableError) + } + x.Error.CodecDecodeSelf(d) + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv17 := &x.Index + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*uint64)(yyv17)) = uint64(r.DecodeUint(64)) + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv19 := &x.LastContact + yym20 := z.DecBinary() + _ = yym20 + if false { + } else if z.HasExtensions() && z.DecExt(yyv19) { + } else { + *((*int64)(yyv19)) = int64(r.DecodeInt(64)) + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv21 := &x.KnownLeader + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*bool)(yyv21)) = r.DecodeBool() + } + } + for { + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj13-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *GenericRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [7]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(7) + } else { + yynn2 = 7 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *GenericRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *GenericRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv4 := &x.Region + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv6 := &x.Namespace + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv8 := &x.MinQueryIndex + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv10 := &x.MaxQueryTime + yym11 := z.DecBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.DecExt(yyv10) { + } else { + *((*int64)(yyv10)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv12 := &x.AllowStale + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*bool)(yyv12)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv14 := &x.Prefix + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv16 := &x.AuthToken + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *GenericRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj18 int + var yyb18 bool + var yyhl18 bool = l >= 0 + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv19 := &x.Region + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv21 := &x.Namespace + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv23 := &x.MinQueryIndex + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv25 := &x.MaxQueryTime + yym26 := z.DecBinary() + _ = yym26 + if false { + } else if z.HasExtensions() && z.DecExt(yyv25) { + } else { + *((*int64)(yyv25)) = int64(r.DecodeInt(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv27 := &x.AllowStale + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*bool)(yyv27)) = r.DecodeBool() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv29 := &x.Prefix + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv31 := &x.AuthToken + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } + } + for { + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj18-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *DeploymentListRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [7]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(7) + } else { + yynn2 = 7 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *DeploymentListRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *DeploymentListRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv4 := &x.Region + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv6 := &x.Namespace + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv8 := &x.MinQueryIndex + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv10 := &x.MaxQueryTime + yym11 := z.DecBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.DecExt(yyv10) { + } else { + *((*int64)(yyv10)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv12 := &x.AllowStale + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*bool)(yyv12)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv14 := &x.Prefix + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv16 := &x.AuthToken + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *DeploymentListRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj18 int + var yyb18 bool + var yyhl18 bool = l >= 0 + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv19 := &x.Region + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv21 := &x.Namespace + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv23 := &x.MinQueryIndex + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv25 := &x.MaxQueryTime + yym26 := z.DecBinary() + _ = yym26 + if false { + } else if z.HasExtensions() && z.DecExt(yyv25) { + } else { + *((*int64)(yyv25)) = int64(r.DecodeInt(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv27 := &x.AllowStale + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*bool)(yyv27)) = r.DecodeBool() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv29 := &x.Prefix + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv31 := &x.AuthToken + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } + } + for { + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj18-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *DeploymentDeleteRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Deployments == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + z.F.EncSliceStringV(x.Deployments, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Deployments")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Deployments == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + z.F.EncSliceStringV(x.Deployments, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *DeploymentDeleteRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *DeploymentDeleteRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Deployments": + if r.TryDecodeAsNil() { + x.Deployments = nil + } else { + yyv4 := &x.Deployments + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + z.F.DecSliceStringX(yyv4, false, d) + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv10 := &x.AuthToken + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *DeploymentDeleteRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Deployments = nil + } else { + yyv13 := &x.Deployments + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + z.F.DecSliceStringX(yyv13, false, d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv15 := &x.Region + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv17 := &x.Namespace + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv19 := &x.AuthToken + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *DeploymentStatusUpdateRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 3 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Eval == nil { + r.EncodeNil() + } else { + x.Eval.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Eval")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Eval == nil { + r.EncodeNil() + } else { + x.Eval.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.DeploymentUpdate == nil { + r.EncodeNil() + } else { + x.DeploymentUpdate.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DeploymentUpdate")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.DeploymentUpdate == nil { + r.EncodeNil() + } else { + x.DeploymentUpdate.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Job == nil { + r.EncodeNil() + } else { + x.Job.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Job")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Job == nil { + r.EncodeNil() + } else { + x.Job.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *DeploymentStatusUpdateRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *DeploymentStatusUpdateRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Eval": + if r.TryDecodeAsNil() { + if x.Eval != nil { + x.Eval = nil + } + } else { + if x.Eval == nil { + x.Eval = new(Evaluation) + } + x.Eval.CodecDecodeSelf(d) + } + case "DeploymentUpdate": + if r.TryDecodeAsNil() { + if x.DeploymentUpdate != nil { + x.DeploymentUpdate = nil + } + } else { + if x.DeploymentUpdate == nil { + x.DeploymentUpdate = new(DeploymentStatusUpdate) + } + x.DeploymentUpdate.CodecDecodeSelf(d) + } + case "Job": + if r.TryDecodeAsNil() { + if x.Job != nil { + x.Job = nil + } + } else { + if x.Job == nil { + x.Job = new(Job) + } + x.Job.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *DeploymentStatusUpdateRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Eval != nil { + x.Eval = nil + } + } else { + if x.Eval == nil { + x.Eval = new(Evaluation) + } + x.Eval.CodecDecodeSelf(d) + } + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.DeploymentUpdate != nil { + x.DeploymentUpdate = nil + } + } else { + if x.DeploymentUpdate == nil { + x.DeploymentUpdate = new(DeploymentStatusUpdate) + } + x.DeploymentUpdate.CodecDecodeSelf(d) + } + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Job != nil { + x.Job = nil + } + } else { + if x.Job == nil { + x.Job = new(Job) + } + x.Job.CodecDecodeSelf(d) + } + for { + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj7-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *DeploymentAllocHealthRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) + } else { + yynn2 = 6 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DeploymentID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.HealthyAllocationIDs == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + z.F.EncSliceStringV(x.HealthyAllocationIDs, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("HealthyAllocationIDs")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.HealthyAllocationIDs == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + z.F.EncSliceStringV(x.HealthyAllocationIDs, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.UnhealthyAllocationIDs == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + z.F.EncSliceStringV(x.UnhealthyAllocationIDs, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("UnhealthyAllocationIDs")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.UnhealthyAllocationIDs == nil { + r.EncodeNil() + } else { + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + z.F.EncSliceStringV(x.UnhealthyAllocationIDs, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *DeploymentAllocHealthRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *DeploymentAllocHealthRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "DeploymentID": + if r.TryDecodeAsNil() { + x.DeploymentID = "" + } else { + yyv4 := &x.DeploymentID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "HealthyAllocationIDs": + if r.TryDecodeAsNil() { + x.HealthyAllocationIDs = nil + } else { + yyv6 := &x.HealthyAllocationIDs + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + z.F.DecSliceStringX(yyv6, false, d) + } + } + case "UnhealthyAllocationIDs": + if r.TryDecodeAsNil() { + x.UnhealthyAllocationIDs = nil + } else { + yyv8 := &x.UnhealthyAllocationIDs + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + z.F.DecSliceStringX(yyv8, false, d) + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv10 := &x.Region + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv12 := &x.Namespace + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv14 := &x.AuthToken + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *DeploymentAllocHealthRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj16 int + var yyb16 bool + var yyhl16 bool = l >= 0 + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DeploymentID = "" + } else { + yyv17 := &x.DeploymentID + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.HealthyAllocationIDs = nil + } else { + yyv19 := &x.HealthyAllocationIDs + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + z.F.DecSliceStringX(yyv19, false, d) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.UnhealthyAllocationIDs = nil + } else { + yyv21 := &x.UnhealthyAllocationIDs + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + z.F.DecSliceStringX(yyv21, false, d) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv23 := &x.Region + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv25 := &x.Namespace + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv27 := &x.AuthToken + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } + } + for { + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj16-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ApplyDeploymentAllocHealthRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [9]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(9) + } else { + yynn2 = 9 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DeploymentID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.HealthyAllocationIDs == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + z.F.EncSliceStringV(x.HealthyAllocationIDs, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("HealthyAllocationIDs")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.HealthyAllocationIDs == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + z.F.EncSliceStringV(x.HealthyAllocationIDs, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.UnhealthyAllocationIDs == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + z.F.EncSliceStringV(x.UnhealthyAllocationIDs, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("UnhealthyAllocationIDs")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.UnhealthyAllocationIDs == nil { + r.EncodeNil() + } else { + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + z.F.EncSliceStringV(x.UnhealthyAllocationIDs, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.DeploymentUpdate == nil { + r.EncodeNil() + } else { + x.DeploymentUpdate.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DeploymentUpdate")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.DeploymentUpdate == nil { + r.EncodeNil() + } else { + x.DeploymentUpdate.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Job == nil { + r.EncodeNil() + } else { + x.Job.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Job")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Job == nil { + r.EncodeNil() + } else { + x.Job.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Eval == nil { + r.EncodeNil() + } else { + x.Eval.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Eval")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Eval == nil { + r.EncodeNil() + } else { + x.Eval.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ApplyDeploymentAllocHealthRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ApplyDeploymentAllocHealthRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "DeploymentID": + if r.TryDecodeAsNil() { + x.DeploymentID = "" + } else { + yyv4 := &x.DeploymentID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "HealthyAllocationIDs": + if r.TryDecodeAsNil() { + x.HealthyAllocationIDs = nil + } else { + yyv6 := &x.HealthyAllocationIDs + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + z.F.DecSliceStringX(yyv6, false, d) + } + } + case "UnhealthyAllocationIDs": + if r.TryDecodeAsNil() { + x.UnhealthyAllocationIDs = nil + } else { + yyv8 := &x.UnhealthyAllocationIDs + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + z.F.DecSliceStringX(yyv8, false, d) + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv10 := &x.Region + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv12 := &x.Namespace + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv14 := &x.AuthToken + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + case "DeploymentUpdate": + if r.TryDecodeAsNil() { + if x.DeploymentUpdate != nil { + x.DeploymentUpdate = nil + } + } else { + if x.DeploymentUpdate == nil { + x.DeploymentUpdate = new(DeploymentStatusUpdate) + } + x.DeploymentUpdate.CodecDecodeSelf(d) + } + case "Job": + if r.TryDecodeAsNil() { + if x.Job != nil { + x.Job = nil + } + } else { + if x.Job == nil { + x.Job = new(Job) + } + x.Job.CodecDecodeSelf(d) + } + case "Eval": + if r.TryDecodeAsNil() { + if x.Eval != nil { + x.Eval = nil + } + } else { + if x.Eval == nil { + x.Eval = new(Evaluation) + } + x.Eval.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ApplyDeploymentAllocHealthRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj19 int + var yyb19 bool + var yyhl19 bool = l >= 0 + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DeploymentID = "" + } else { + yyv20 := &x.DeploymentID + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*string)(yyv20)) = r.DecodeString() + } + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.HealthyAllocationIDs = nil + } else { + yyv22 := &x.HealthyAllocationIDs + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + z.F.DecSliceStringX(yyv22, false, d) + } + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.UnhealthyAllocationIDs = nil + } else { + yyv24 := &x.UnhealthyAllocationIDs + yym25 := z.DecBinary() + _ = yym25 + if false { + } else { + z.F.DecSliceStringX(yyv24, false, d) + } + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv26 := &x.Region + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + *((*string)(yyv26)) = r.DecodeString() + } + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv28 := &x.Namespace + yym29 := z.DecBinary() + _ = yym29 + if false { + } else { + *((*string)(yyv28)) = r.DecodeString() + } + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv30 := &x.AuthToken + yym31 := z.DecBinary() + _ = yym31 + if false { + } else { + *((*string)(yyv30)) = r.DecodeString() + } + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.DeploymentUpdate != nil { + x.DeploymentUpdate = nil + } + } else { + if x.DeploymentUpdate == nil { + x.DeploymentUpdate = new(DeploymentStatusUpdate) + } + x.DeploymentUpdate.CodecDecodeSelf(d) + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Job != nil { + x.Job = nil + } + } else { + if x.Job == nil { + x.Job = new(Job) + } + x.Job.CodecDecodeSelf(d) + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Eval != nil { + x.Eval = nil + } + } else { + if x.Eval == nil { + x.Eval = new(Evaluation) + } + x.Eval.CodecDecodeSelf(d) + } + for { + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj19-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *DeploymentPromoteRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) + } else { + yynn2 = 6 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DeploymentID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeBool(bool(x.All)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("All")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeBool(bool(x.All)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Groups == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + z.F.EncSliceStringV(x.Groups, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Groups")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Groups == nil { + r.EncodeNil() + } else { + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + z.F.EncSliceStringV(x.Groups, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *DeploymentPromoteRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *DeploymentPromoteRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "DeploymentID": + if r.TryDecodeAsNil() { + x.DeploymentID = "" + } else { + yyv4 := &x.DeploymentID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "All": + if r.TryDecodeAsNil() { + x.All = false + } else { + yyv6 := &x.All + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*bool)(yyv6)) = r.DecodeBool() + } + } + case "Groups": + if r.TryDecodeAsNil() { + x.Groups = nil + } else { + yyv8 := &x.Groups + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + z.F.DecSliceStringX(yyv8, false, d) + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv10 := &x.Region + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv12 := &x.Namespace + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv14 := &x.AuthToken + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *DeploymentPromoteRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj16 int + var yyb16 bool + var yyhl16 bool = l >= 0 + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DeploymentID = "" + } else { + yyv17 := &x.DeploymentID + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.All = false + } else { + yyv19 := &x.All + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Groups = nil + } else { + yyv21 := &x.Groups + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + z.F.DecSliceStringX(yyv21, false, d) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv23 := &x.Region + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv25 := &x.Namespace + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv27 := &x.AuthToken + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } + } + for { + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj16-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ApplyDeploymentPromoteRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [7]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(7) + } else { + yynn2 = 7 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DeploymentID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeBool(bool(x.All)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("All")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeBool(bool(x.All)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Groups == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + z.F.EncSliceStringV(x.Groups, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Groups")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Groups == nil { + r.EncodeNil() + } else { + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + z.F.EncSliceStringV(x.Groups, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Eval == nil { + r.EncodeNil() + } else { + x.Eval.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Eval")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Eval == nil { + r.EncodeNil() + } else { + x.Eval.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ApplyDeploymentPromoteRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ApplyDeploymentPromoteRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "DeploymentID": + if r.TryDecodeAsNil() { + x.DeploymentID = "" + } else { + yyv4 := &x.DeploymentID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "All": + if r.TryDecodeAsNil() { + x.All = false + } else { + yyv6 := &x.All + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*bool)(yyv6)) = r.DecodeBool() + } + } + case "Groups": + if r.TryDecodeAsNil() { + x.Groups = nil + } else { + yyv8 := &x.Groups + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + z.F.DecSliceStringX(yyv8, false, d) + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv10 := &x.Region + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv12 := &x.Namespace + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv14 := &x.AuthToken + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + case "Eval": + if r.TryDecodeAsNil() { + if x.Eval != nil { + x.Eval = nil + } + } else { + if x.Eval == nil { + x.Eval = new(Evaluation) + } + x.Eval.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ApplyDeploymentPromoteRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj17 int + var yyb17 bool + var yyhl17 bool = l >= 0 + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DeploymentID = "" + } else { + yyv18 := &x.DeploymentID + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.All = false + } else { + yyv20 := &x.All + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*bool)(yyv20)) = r.DecodeBool() + } + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Groups = nil + } else { + yyv22 := &x.Groups + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + z.F.DecSliceStringX(yyv22, false, d) + } + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv24 := &x.Region + yym25 := z.DecBinary() + _ = yym25 + if false { + } else { + *((*string)(yyv24)) = r.DecodeString() + } + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv26 := &x.Namespace + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + *((*string)(yyv26)) = r.DecodeString() + } + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv28 := &x.AuthToken + yym29 := z.DecBinary() + _ = yym29 + if false { + } else { + *((*string)(yyv28)) = r.DecodeString() + } + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Eval != nil { + x.Eval = nil + } + } else { + if x.Eval == nil { + x.Eval = new(Evaluation) + } + x.Eval.CodecDecodeSelf(d) + } + for { + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj17-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *DeploymentPauseRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 5 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DeploymentID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeBool(bool(x.Pause)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Pause")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeBool(bool(x.Pause)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *DeploymentPauseRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *DeploymentPauseRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "DeploymentID": + if r.TryDecodeAsNil() { + x.DeploymentID = "" + } else { + yyv4 := &x.DeploymentID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Pause": + if r.TryDecodeAsNil() { + x.Pause = false + } else { + yyv6 := &x.Pause + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*bool)(yyv6)) = r.DecodeBool() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv8 := &x.Region + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv10 := &x.Namespace + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv12 := &x.AuthToken + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *DeploymentPauseRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DeploymentID = "" + } else { + yyv15 := &x.DeploymentID + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Pause = false + } else { + yyv17 := &x.Pause + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*bool)(yyv17)) = r.DecodeBool() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv19 := &x.Region + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv21 := &x.Namespace + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv23 := &x.AuthToken + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + for { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj14-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *DeploymentSpecificRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(8) + } else { + yynn2 = 8 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DeploymentID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *DeploymentSpecificRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *DeploymentSpecificRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "DeploymentID": + if r.TryDecodeAsNil() { + x.DeploymentID = "" + } else { + yyv4 := &x.DeploymentID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv10 := &x.MinQueryIndex + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv12 := &x.MaxQueryTime + yym13 := z.DecBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.DecExt(yyv12) { + } else { + *((*int64)(yyv12)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv14 := &x.AllowStale + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv16 := &x.Prefix + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv18 := &x.AuthToken + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *DeploymentSpecificRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj20 int + var yyb20 bool + var yyhl20 bool = l >= 0 + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DeploymentID = "" + } else { + yyv21 := &x.DeploymentID + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv23 := &x.Region + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv25 := &x.Namespace + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv27 := &x.MinQueryIndex + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv29 := &x.MaxQueryTime + yym30 := z.DecBinary() + _ = yym30 + if false { + } else if z.HasExtensions() && z.DecExt(yyv29) { + } else { + *((*int64)(yyv29)) = int64(r.DecodeInt(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv31 := &x.AllowStale + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*bool)(yyv31)) = r.DecodeBool() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv33 := &x.Prefix + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*string)(yyv33)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv35 := &x.AuthToken + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*string)(yyv35)) = r.DecodeString() + } + } + for { + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj20-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *DeploymentFailRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DeploymentID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *DeploymentFailRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *DeploymentFailRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "DeploymentID": + if r.TryDecodeAsNil() { + x.DeploymentID = "" + } else { + yyv4 := &x.DeploymentID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv10 := &x.AuthToken + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *DeploymentFailRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DeploymentID = "" + } else { + yyv13 := &x.DeploymentID + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv15 := &x.Region + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv17 := &x.Namespace + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv19 := &x.AuthToken + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *SingleDeploymentResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Deployment == nil { + r.EncodeNil() + } else { + x.Deployment.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Deployment")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Deployment == nil { + r.EncodeNil() + } else { + x.Deployment.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *SingleDeploymentResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *SingleDeploymentResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Deployment": + if r.TryDecodeAsNil() { + if x.Deployment != nil { + x.Deployment = nil + } + } else { + if x.Deployment == nil { + x.Deployment = new(Deployment) + } + x.Deployment.CodecDecodeSelf(d) + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv5 := &x.Index + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv7 := &x.LastContact + yym8 := z.DecBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.DecExt(yyv7) { + } else { + *((*int64)(yyv7)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv9 := &x.KnownLeader + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*bool)(yyv9)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *SingleDeploymentResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Deployment != nil { + x.Deployment = nil + } + } else { + if x.Deployment == nil { + x.Deployment = new(Deployment) + } + x.Deployment.CodecDecodeSelf(d) + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv13 := &x.Index + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv15 := &x.LastContact + yym16 := z.DecBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.DecExt(yyv15) { + } else { + *((*int64)(yyv15)) = int64(r.DecodeInt(64)) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv17 := &x.KnownLeader + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*bool)(yyv17)) = r.DecodeBool() + } + } + for { + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj11-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *GenericResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(1) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *GenericResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *GenericResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv4 := &x.Index + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*uint64)(yyv4)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *GenericResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + 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 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv7 := &x.Index + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*uint64)(yyv7)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj6-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *VersionResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 5 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Build)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Build")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Build)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Versions == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + z.F.EncMapStringIntV(x.Versions, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Versions")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Versions == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + z.F.EncMapStringIntV(x.Versions, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *VersionResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *VersionResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Build": + if r.TryDecodeAsNil() { + x.Build = "" + } else { + yyv4 := &x.Build + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Versions": + if r.TryDecodeAsNil() { + x.Versions = nil + } else { + yyv6 := &x.Versions + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + z.F.DecMapStringIntX(yyv6, false, d) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv8 := &x.Index + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv10 := &x.LastContact + yym11 := z.DecBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.DecExt(yyv10) { + } else { + *((*int64)(yyv10)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv12 := &x.KnownLeader + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*bool)(yyv12)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *VersionResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Build = "" + } else { + yyv15 := &x.Build + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Versions = nil + } else { + yyv17 := &x.Versions + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + z.F.DecMapStringIntX(yyv17, false, d) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv19 := &x.Index + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv21 := &x.LastContact + yym22 := z.DecBinary() + _ = yym22 + if false { + } else if z.HasExtensions() && z.DecExt(yyv21) { + } else { + *((*int64)(yyv21)) = int64(r.DecodeInt(64)) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv23 := &x.KnownLeader + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*bool)(yyv23)) = r.DecodeBool() + } + } + for { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj14-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobRegisterResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [7]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(7) + } else { + yynn2 = 7 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.EvalCreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalCreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.EvalCreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.JobModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.JobModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Warnings)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Warnings")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Warnings)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobRegisterResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobRegisterResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "EvalID": + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv4 := &x.EvalID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "EvalCreateIndex": + if r.TryDecodeAsNil() { + x.EvalCreateIndex = 0 + } else { + yyv6 := &x.EvalCreateIndex + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "JobModifyIndex": + if r.TryDecodeAsNil() { + x.JobModifyIndex = 0 + } else { + yyv8 := &x.JobModifyIndex + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) + } + } + case "Warnings": + if r.TryDecodeAsNil() { + x.Warnings = "" + } else { + yyv10 := &x.Warnings + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv12 := &x.Index + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*uint64)(yyv12)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv14 := &x.LastContact + yym15 := z.DecBinary() + _ = yym15 + if false { + } else if z.HasExtensions() && z.DecExt(yyv14) { + } else { + *((*int64)(yyv14)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv16 := &x.KnownLeader + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*bool)(yyv16)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobRegisterResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj18 int + var yyb18 bool + var yyhl18 bool = l >= 0 + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv19 := &x.EvalID + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalCreateIndex = 0 + } else { + yyv21 := &x.EvalCreateIndex + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*uint64)(yyv21)) = uint64(r.DecodeUint(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobModifyIndex = 0 + } else { + yyv23 := &x.JobModifyIndex + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Warnings = "" + } else { + yyv25 := &x.Warnings + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv27 := &x.Index + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv29 := &x.LastContact + yym30 := z.DecBinary() + _ = yym30 + if false { + } else if z.HasExtensions() && z.DecExt(yyv29) { + } else { + *((*int64)(yyv29)) = int64(r.DecodeInt(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv31 := &x.KnownLeader + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*bool)(yyv31)) = r.DecodeBool() + } + } + for { + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj18-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobDeregisterResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) + } else { + yynn2 = 6 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.EvalCreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalCreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.EvalCreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.JobModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.JobModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobDeregisterResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobDeregisterResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "EvalID": + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv4 := &x.EvalID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "EvalCreateIndex": + if r.TryDecodeAsNil() { + x.EvalCreateIndex = 0 + } else { + yyv6 := &x.EvalCreateIndex + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "JobModifyIndex": + if r.TryDecodeAsNil() { + x.JobModifyIndex = 0 + } else { + yyv8 := &x.JobModifyIndex + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv10 := &x.Index + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv12 := &x.LastContact + yym13 := z.DecBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.DecExt(yyv12) { + } else { + *((*int64)(yyv12)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv14 := &x.KnownLeader + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobDeregisterResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj16 int + var yyb16 bool + var yyhl16 bool = l >= 0 + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv17 := &x.EvalID + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalCreateIndex = 0 + } else { + yyv19 := &x.EvalCreateIndex + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobModifyIndex = 0 + } else { + yyv21 := &x.JobModifyIndex + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*uint64)(yyv21)) = uint64(r.DecodeUint(64)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv23 := &x.Index + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv25 := &x.LastContact + yym26 := z.DecBinary() + _ = yym26 + if false { + } else if z.HasExtensions() && z.DecExt(yyv25) { + } else { + *((*int64)(yyv25)) = int64(r.DecodeInt(64)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv27 := &x.KnownLeader + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*bool)(yyv27)) = r.DecodeBool() + } + } + for { + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj16-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobValidateResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeBool(bool(x.DriverConfigValidated)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DriverConfigValidated")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeBool(bool(x.DriverConfigValidated)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.ValidationErrors == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + z.F.EncSliceStringV(x.ValidationErrors, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ValidationErrors")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.ValidationErrors == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + z.F.EncSliceStringV(x.ValidationErrors, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Error)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Error")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Error)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Warnings)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Warnings")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Warnings)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobValidateResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobValidateResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "DriverConfigValidated": + if r.TryDecodeAsNil() { + x.DriverConfigValidated = false + } else { + yyv4 := &x.DriverConfigValidated + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*bool)(yyv4)) = r.DecodeBool() + } + } + case "ValidationErrors": + if r.TryDecodeAsNil() { + x.ValidationErrors = nil + } else { + yyv6 := &x.ValidationErrors + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + z.F.DecSliceStringX(yyv6, false, d) + } + } + case "Error": + if r.TryDecodeAsNil() { + x.Error = "" + } else { + yyv8 := &x.Error + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Warnings": + if r.TryDecodeAsNil() { + x.Warnings = "" + } else { + yyv10 := &x.Warnings + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobValidateResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DriverConfigValidated = false + } else { + yyv13 := &x.DriverConfigValidated + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*bool)(yyv13)) = r.DecodeBool() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ValidationErrors = nil + } else { + yyv15 := &x.ValidationErrors + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + z.F.DecSliceStringX(yyv15, false, d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Error = "" + } else { + yyv17 := &x.Error + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Warnings = "" + } else { + yyv19 := &x.Warnings + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *NodeUpdateResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [10]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(10) + } else { + yynn2 = 10 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else if z.HasExtensions() && z.EncExt(x.HeartbeatTTL) { + } else { + r.EncodeInt(int64(x.HeartbeatTTL)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("HeartbeatTTL")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.EncExt(x.HeartbeatTTL) { + } else { + r.EncodeInt(int64(x.HeartbeatTTL)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.EvalIDs == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + z.F.EncSliceStringV(x.EvalIDs, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalIDs")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.EvalIDs == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + z.F.EncSliceStringV(x.EvalIDs, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.EvalCreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalCreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.EvalCreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeUint(uint64(x.NodeModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodeModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeUint(uint64(x.NodeModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.LeaderRPCAddr)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LeaderRPCAddr")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.LeaderRPCAddr)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeInt(int64(x.NumNodes)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NumNodes")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeInt(int64(x.NumNodes)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Servers == nil { + r.EncodeNil() + } else { + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + h.encSlicePtrtoNodeServerInfo(([]*NodeServerInfo)(x.Servers), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Servers")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Servers == nil { + r.EncodeNil() + } else { + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + h.encSlicePtrtoNodeServerInfo(([]*NodeServerInfo)(x.Servers), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym28 := z.EncBinary() + _ = yym28 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym29 := z.EncBinary() + _ = yym29 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym31 := z.EncBinary() + _ = yym31 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym32 := z.EncBinary() + _ = yym32 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *NodeUpdateResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *NodeUpdateResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "HeartbeatTTL": + if r.TryDecodeAsNil() { + x.HeartbeatTTL = 0 + } else { + yyv4 := &x.HeartbeatTTL + yym5 := z.DecBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.DecExt(yyv4) { + } else { + *((*int64)(yyv4)) = int64(r.DecodeInt(64)) + } + } + case "EvalIDs": + if r.TryDecodeAsNil() { + x.EvalIDs = nil + } else { + yyv6 := &x.EvalIDs + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + z.F.DecSliceStringX(yyv6, false, d) + } + } + case "EvalCreateIndex": + if r.TryDecodeAsNil() { + x.EvalCreateIndex = 0 + } else { + yyv8 := &x.EvalCreateIndex + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) + } + } + case "NodeModifyIndex": + if r.TryDecodeAsNil() { + x.NodeModifyIndex = 0 + } else { + yyv10 := &x.NodeModifyIndex + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) + } + } + case "LeaderRPCAddr": + if r.TryDecodeAsNil() { + x.LeaderRPCAddr = "" + } else { + yyv12 := &x.LeaderRPCAddr + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + case "NumNodes": + if r.TryDecodeAsNil() { + x.NumNodes = 0 + } else { + yyv14 := &x.NumNodes + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*int32)(yyv14)) = int32(r.DecodeInt(32)) + } + } + case "Servers": + if r.TryDecodeAsNil() { + x.Servers = nil + } else { + yyv16 := &x.Servers + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + h.decSlicePtrtoNodeServerInfo((*[]*NodeServerInfo)(yyv16), d) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv18 := &x.Index + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*uint64)(yyv18)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv20 := &x.LastContact + yym21 := z.DecBinary() + _ = yym21 + if false { + } else if z.HasExtensions() && z.DecExt(yyv20) { + } else { + *((*int64)(yyv20)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv22 := &x.KnownLeader + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + *((*bool)(yyv22)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *NodeUpdateResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj24 int + var yyb24 bool + var yyhl24 bool = l >= 0 + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.HeartbeatTTL = 0 + } else { + yyv25 := &x.HeartbeatTTL + yym26 := z.DecBinary() + _ = yym26 + if false { + } else if z.HasExtensions() && z.DecExt(yyv25) { + } else { + *((*int64)(yyv25)) = int64(r.DecodeInt(64)) + } + } + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalIDs = nil + } else { + yyv27 := &x.EvalIDs + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + z.F.DecSliceStringX(yyv27, false, d) + } + } + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalCreateIndex = 0 + } else { + yyv29 := &x.EvalCreateIndex + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*uint64)(yyv29)) = uint64(r.DecodeUint(64)) + } + } + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodeModifyIndex = 0 + } else { + yyv31 := &x.NodeModifyIndex + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*uint64)(yyv31)) = uint64(r.DecodeUint(64)) + } + } + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LeaderRPCAddr = "" + } else { + yyv33 := &x.LeaderRPCAddr + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*string)(yyv33)) = r.DecodeString() + } + } + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NumNodes = 0 + } else { + yyv35 := &x.NumNodes + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*int32)(yyv35)) = int32(r.DecodeInt(32)) + } + } + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Servers = nil + } else { + yyv37 := &x.Servers + yym38 := z.DecBinary() + _ = yym38 + if false { + } else { + h.decSlicePtrtoNodeServerInfo((*[]*NodeServerInfo)(yyv37), d) + } + } + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv39 := &x.Index + yym40 := z.DecBinary() + _ = yym40 + if false { + } else { + *((*uint64)(yyv39)) = uint64(r.DecodeUint(64)) + } + } + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv41 := &x.LastContact + yym42 := z.DecBinary() + _ = yym42 + if false { + } else if z.HasExtensions() && z.DecExt(yyv41) { + } else { + *((*int64)(yyv41)) = int64(r.DecodeInt(64)) + } + } + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv43 := &x.KnownLeader + yym44 := z.DecBinary() + _ = yym44 + if false { + } else { + *((*bool)(yyv43)) = r.DecodeBool() + } + } + for { + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj24-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *NodeDrainUpdateResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) + } else { + yynn2 = 6 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.EvalIDs == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + z.F.EncSliceStringV(x.EvalIDs, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalIDs")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.EvalIDs == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + z.F.EncSliceStringV(x.EvalIDs, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.EvalCreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalCreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.EvalCreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.NodeModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodeModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.NodeModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *NodeDrainUpdateResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *NodeDrainUpdateResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "EvalIDs": + if r.TryDecodeAsNil() { + x.EvalIDs = nil + } else { + yyv4 := &x.EvalIDs + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + z.F.DecSliceStringX(yyv4, false, d) + } + } + case "EvalCreateIndex": + if r.TryDecodeAsNil() { + x.EvalCreateIndex = 0 + } else { + yyv6 := &x.EvalCreateIndex + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "NodeModifyIndex": + if r.TryDecodeAsNil() { + x.NodeModifyIndex = 0 + } else { + yyv8 := &x.NodeModifyIndex + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv10 := &x.Index + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv12 := &x.LastContact + yym13 := z.DecBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.DecExt(yyv12) { + } else { + *((*int64)(yyv12)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv14 := &x.KnownLeader + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *NodeDrainUpdateResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj16 int + var yyb16 bool + var yyhl16 bool = l >= 0 + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalIDs = nil + } else { + yyv17 := &x.EvalIDs + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + z.F.DecSliceStringX(yyv17, false, d) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalCreateIndex = 0 + } else { + yyv19 := &x.EvalCreateIndex + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodeModifyIndex = 0 + } else { + yyv21 := &x.NodeModifyIndex + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*uint64)(yyv21)) = uint64(r.DecodeUint(64)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv23 := &x.Index + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv25 := &x.LastContact + yym26 := z.DecBinary() + _ = yym26 + if false { + } else if z.HasExtensions() && z.DecExt(yyv25) { + } else { + *((*int64)(yyv25)) = int64(r.DecodeInt(64)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv27 := &x.KnownLeader + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*bool)(yyv27)) = r.DecodeBool() + } + } + for { + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj16-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *NodeAllocsResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Allocs == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSlicePtrtoAllocation(([]*Allocation)(x.Allocs), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Allocs")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Allocs == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSlicePtrtoAllocation(([]*Allocation)(x.Allocs), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *NodeAllocsResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *NodeAllocsResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Allocs": + if r.TryDecodeAsNil() { + x.Allocs = nil + } else { + yyv4 := &x.Allocs + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSlicePtrtoAllocation((*[]*Allocation)(yyv4), d) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv6 := &x.Index + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv8 := &x.LastContact + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + *((*int64)(yyv8)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv10 := &x.KnownLeader + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *NodeAllocsResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Allocs = nil + } else { + yyv13 := &x.Allocs + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decSlicePtrtoAllocation((*[]*Allocation)(yyv13), d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv15 := &x.Index + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv17 := &x.LastContact + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + *((*int64)(yyv17)) = int64(r.DecodeInt(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv19 := &x.KnownLeader + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *NodeClientAllocsResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 5 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Allocs == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + z.F.EncMapStringUint64V(x.Allocs, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Allocs")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Allocs == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + z.F.EncMapStringUint64V(x.Allocs, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.MigrateTokens == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + z.F.EncMapStringStringV(x.MigrateTokens, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MigrateTokens")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.MigrateTokens == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + z.F.EncMapStringStringV(x.MigrateTokens, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *NodeClientAllocsResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *NodeClientAllocsResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Allocs": + if r.TryDecodeAsNil() { + x.Allocs = nil + } else { + yyv4 := &x.Allocs + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + z.F.DecMapStringUint64X(yyv4, false, d) + } + } + case "MigrateTokens": + if r.TryDecodeAsNil() { + x.MigrateTokens = nil + } else { + yyv6 := &x.MigrateTokens + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + z.F.DecMapStringStringX(yyv6, false, d) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv8 := &x.Index + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv10 := &x.LastContact + yym11 := z.DecBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.DecExt(yyv10) { + } else { + *((*int64)(yyv10)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv12 := &x.KnownLeader + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*bool)(yyv12)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *NodeClientAllocsResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Allocs = nil + } else { + yyv15 := &x.Allocs + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + z.F.DecMapStringUint64X(yyv15, false, d) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MigrateTokens = nil + } else { + yyv17 := &x.MigrateTokens + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + z.F.DecMapStringStringX(yyv17, false, d) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv19 := &x.Index + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv21 := &x.LastContact + yym22 := z.DecBinary() + _ = yym22 + if false { + } else if z.HasExtensions() && z.DecExt(yyv21) { + } else { + *((*int64)(yyv21)) = int64(r.DecodeInt(64)) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv23 := &x.KnownLeader + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*bool)(yyv23)) = r.DecodeBool() + } + } + for { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj14-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *SingleNodeResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Node == nil { + r.EncodeNil() + } else { + x.Node.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Node")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Node == nil { + r.EncodeNil() + } else { + x.Node.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *SingleNodeResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *SingleNodeResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Node": + if r.TryDecodeAsNil() { + if x.Node != nil { + x.Node = nil + } + } else { + if x.Node == nil { + x.Node = new(Node) + } + x.Node.CodecDecodeSelf(d) + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv5 := &x.Index + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv7 := &x.LastContact + yym8 := z.DecBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.DecExt(yyv7) { + } else { + *((*int64)(yyv7)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv9 := &x.KnownLeader + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*bool)(yyv9)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *SingleNodeResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Node != nil { + x.Node = nil + } + } else { + if x.Node == nil { + x.Node = new(Node) + } + x.Node.CodecDecodeSelf(d) + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv13 := &x.Index + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv15 := &x.LastContact + yym16 := z.DecBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.DecExt(yyv15) { + } else { + *((*int64)(yyv15)) = int64(r.DecodeInt(64)) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv17 := &x.KnownLeader + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*bool)(yyv17)) = r.DecodeBool() + } + } + for { + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj11-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *NodeListResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Nodes == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSlicePtrtoNodeListStub(([]*NodeListStub)(x.Nodes), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Nodes")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Nodes == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSlicePtrtoNodeListStub(([]*NodeListStub)(x.Nodes), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *NodeListResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *NodeListResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Nodes": + if r.TryDecodeAsNil() { + x.Nodes = nil + } else { + yyv4 := &x.Nodes + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSlicePtrtoNodeListStub((*[]*NodeListStub)(yyv4), d) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv6 := &x.Index + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv8 := &x.LastContact + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + *((*int64)(yyv8)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv10 := &x.KnownLeader + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *NodeListResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Nodes = nil + } else { + yyv13 := &x.Nodes + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decSlicePtrtoNodeListStub((*[]*NodeListStub)(yyv13), d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv15 := &x.Index + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv17 := &x.LastContact + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + *((*int64)(yyv17)) = int64(r.DecodeInt(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv19 := &x.KnownLeader + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *SingleJobResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Job == nil { + r.EncodeNil() + } else { + x.Job.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Job")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Job == nil { + r.EncodeNil() + } else { + x.Job.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *SingleJobResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *SingleJobResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Job": + if r.TryDecodeAsNil() { + if x.Job != nil { + x.Job = nil + } + } else { + if x.Job == nil { + x.Job = new(Job) + } + x.Job.CodecDecodeSelf(d) + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv5 := &x.Index + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv7 := &x.LastContact + yym8 := z.DecBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.DecExt(yyv7) { + } else { + *((*int64)(yyv7)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv9 := &x.KnownLeader + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*bool)(yyv9)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *SingleJobResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Job != nil { + x.Job = nil + } + } else { + if x.Job == nil { + x.Job = new(Job) + } + x.Job.CodecDecodeSelf(d) + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv13 := &x.Index + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv15 := &x.LastContact + yym16 := z.DecBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.DecExt(yyv15) { + } else { + *((*int64)(yyv15)) = int64(r.DecodeInt(64)) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv17 := &x.KnownLeader + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*bool)(yyv17)) = r.DecodeBool() + } + } + for { + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj11-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobSummaryResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.JobSummary == nil { + r.EncodeNil() + } else { + x.JobSummary.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobSummary")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.JobSummary == nil { + r.EncodeNil() + } else { + x.JobSummary.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobSummaryResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobSummaryResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "JobSummary": + if r.TryDecodeAsNil() { + if x.JobSummary != nil { + x.JobSummary = nil + } + } else { + if x.JobSummary == nil { + x.JobSummary = new(JobSummary) + } + x.JobSummary.CodecDecodeSelf(d) + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv5 := &x.Index + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv7 := &x.LastContact + yym8 := z.DecBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.DecExt(yyv7) { + } else { + *((*int64)(yyv7)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv9 := &x.KnownLeader + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*bool)(yyv9)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobSummaryResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.JobSummary != nil { + x.JobSummary = nil + } + } else { + if x.JobSummary == nil { + x.JobSummary = new(JobSummary) + } + x.JobSummary.CodecDecodeSelf(d) + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv13 := &x.Index + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv15 := &x.LastContact + yym16 := z.DecBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.DecExt(yyv15) { + } else { + *((*int64)(yyv15)) = int64(r.DecodeInt(64)) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv17 := &x.KnownLeader + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*bool)(yyv17)) = r.DecodeBool() + } + } + for { + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj11-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobDispatchResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 5 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DispatchedJobID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DispatchedJobID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DispatchedJobID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.EvalCreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalCreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.EvalCreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeUint(uint64(x.JobCreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobCreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeUint(uint64(x.JobCreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobDispatchResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobDispatchResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "DispatchedJobID": + if r.TryDecodeAsNil() { + x.DispatchedJobID = "" + } else { + yyv4 := &x.DispatchedJobID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "EvalID": + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv6 := &x.EvalID + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "EvalCreateIndex": + if r.TryDecodeAsNil() { + x.EvalCreateIndex = 0 + } else { + yyv8 := &x.EvalCreateIndex + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) + } + } + case "JobCreateIndex": + if r.TryDecodeAsNil() { + x.JobCreateIndex = 0 + } else { + yyv10 := &x.JobCreateIndex + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv12 := &x.Index + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*uint64)(yyv12)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobDispatchResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DispatchedJobID = "" + } else { + yyv15 := &x.DispatchedJobID + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv17 := &x.EvalID + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalCreateIndex = 0 + } else { + yyv19 := &x.EvalCreateIndex + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobCreateIndex = 0 + } else { + yyv21 := &x.JobCreateIndex + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*uint64)(yyv21)) = uint64(r.DecodeUint(64)) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv23 := &x.Index + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj14-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobListResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Jobs == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSlicePtrtoJobListStub(([]*JobListStub)(x.Jobs), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Jobs")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Jobs == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSlicePtrtoJobListStub(([]*JobListStub)(x.Jobs), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobListResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobListResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Jobs": + if r.TryDecodeAsNil() { + x.Jobs = nil + } else { + yyv4 := &x.Jobs + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSlicePtrtoJobListStub((*[]*JobListStub)(yyv4), d) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv6 := &x.Index + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv8 := &x.LastContact + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + *((*int64)(yyv8)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv10 := &x.KnownLeader + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobListResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Jobs = nil + } else { + yyv13 := &x.Jobs + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decSlicePtrtoJobListStub((*[]*JobListStub)(yyv13), d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv15 := &x.Index + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv17 := &x.LastContact + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + *((*int64)(yyv17)) = int64(r.DecodeInt(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv19 := &x.KnownLeader + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobVersionsRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [9]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(9) + } else { + yynn2 = 9 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeBool(bool(x.Diffs)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Diffs")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeBool(bool(x.Diffs)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym29 := z.EncBinary() + _ = yym29 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobVersionsRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobVersionsRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "JobID": + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv4 := &x.JobID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Diffs": + if r.TryDecodeAsNil() { + x.Diffs = false + } else { + yyv6 := &x.Diffs + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*bool)(yyv6)) = r.DecodeBool() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv8 := &x.Region + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv10 := &x.Namespace + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv12 := &x.MinQueryIndex + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*uint64)(yyv12)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv14 := &x.MaxQueryTime + yym15 := z.DecBinary() + _ = yym15 + if false { + } else if z.HasExtensions() && z.DecExt(yyv14) { + } else { + *((*int64)(yyv14)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv16 := &x.AllowStale + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*bool)(yyv16)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv18 := &x.Prefix + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv20 := &x.AuthToken + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*string)(yyv20)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobVersionsRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj22 int + var yyb22 bool + var yyhl22 bool = l >= 0 + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv23 := &x.JobID + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Diffs = false + } else { + yyv25 := &x.Diffs + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*bool)(yyv25)) = r.DecodeBool() + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv27 := &x.Region + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv29 := &x.Namespace + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv31 := &x.MinQueryIndex + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*uint64)(yyv31)) = uint64(r.DecodeUint(64)) + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv33 := &x.MaxQueryTime + yym34 := z.DecBinary() + _ = yym34 + if false { + } else if z.HasExtensions() && z.DecExt(yyv33) { + } else { + *((*int64)(yyv33)) = int64(r.DecodeInt(64)) + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv35 := &x.AllowStale + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*bool)(yyv35)) = r.DecodeBool() + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv37 := &x.Prefix + yym38 := z.DecBinary() + _ = yym38 + if false { + } else { + *((*string)(yyv37)) = r.DecodeString() + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv39 := &x.AuthToken + yym40 := z.DecBinary() + _ = yym40 + if false { + } else { + *((*string)(yyv39)) = r.DecodeString() + } + } + for { + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj22-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobVersionsResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 5 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Versions == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSlicePtrtoJob(([]*Job)(x.Versions), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Versions")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Versions == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSlicePtrtoJob(([]*Job)(x.Versions), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Diffs == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + h.encSlicePtrtoJobDiff(([]*JobDiff)(x.Diffs), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Diffs")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Diffs == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + h.encSlicePtrtoJobDiff(([]*JobDiff)(x.Diffs), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobVersionsResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobVersionsResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Versions": + if r.TryDecodeAsNil() { + x.Versions = nil + } else { + yyv4 := &x.Versions + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSlicePtrtoJob((*[]*Job)(yyv4), d) + } + } + case "Diffs": + if r.TryDecodeAsNil() { + x.Diffs = nil + } else { + yyv6 := &x.Diffs + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + h.decSlicePtrtoJobDiff((*[]*JobDiff)(yyv6), d) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv8 := &x.Index + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv10 := &x.LastContact + yym11 := z.DecBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.DecExt(yyv10) { + } else { + *((*int64)(yyv10)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv12 := &x.KnownLeader + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*bool)(yyv12)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobVersionsResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Versions = nil + } else { + yyv15 := &x.Versions + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + h.decSlicePtrtoJob((*[]*Job)(yyv15), d) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Diffs = nil + } else { + yyv17 := &x.Diffs + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + h.decSlicePtrtoJobDiff((*[]*JobDiff)(yyv17), d) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv19 := &x.Index + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv21 := &x.LastContact + yym22 := z.DecBinary() + _ = yym22 + if false { + } else if z.HasExtensions() && z.DecExt(yyv21) { + } else { + *((*int64)(yyv21)) = int64(r.DecodeInt(64)) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv23 := &x.KnownLeader + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*bool)(yyv23)) = r.DecodeBool() + } + } + for { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj14-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobPlanResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(8) + } else { + yynn2 = 8 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Annotations == nil { + r.EncodeNil() + } else { + x.Annotations.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Annotations")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Annotations == nil { + r.EncodeNil() + } else { + x.Annotations.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.FailedTGAllocs == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + h.encMapstringPtrtoAllocMetric((map[string]*AllocMetric)(x.FailedTGAllocs), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("FailedTGAllocs")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.FailedTGAllocs == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + h.encMapstringPtrtoAllocMetric((map[string]*AllocMetric)(x.FailedTGAllocs), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.JobModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.JobModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.CreatedEvals == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + h.encSlicePtrtoEvaluation(([]*Evaluation)(x.CreatedEvals), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CreatedEvals")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.CreatedEvals == nil { + r.EncodeNil() + } else { + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + h.encSlicePtrtoEvaluation(([]*Evaluation)(x.CreatedEvals), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Diff == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(x.Diff) { + } else { + z.EncFallback(x.Diff) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Diff")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Diff == nil { + r.EncodeNil() + } else { + yym17 := z.EncBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.EncExt(x.Diff) { + } else { + z.EncFallback(x.Diff) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yy19 := &x.NextPeriodicLaunch + yym20 := z.EncBinary() + _ = yym20 + if false { + } else if yym21 := z.TimeRtidIfBinc(); yym21 != 0 { + r.EncodeBuiltin(yym21, yy19) + } else if z.HasExtensions() && z.EncExt(yy19) { + } else if yym20 { + z.EncBinaryMarshal(yy19) + } else if !yym20 && z.IsJSONHandle() { + z.EncJSONMarshal(yy19) + } else { + z.EncFallback(yy19) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NextPeriodicLaunch")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yy22 := &x.NextPeriodicLaunch + yym23 := z.EncBinary() + _ = yym23 + if false { + } else if yym24 := z.TimeRtidIfBinc(); yym24 != 0 { + r.EncodeBuiltin(yym24, yy22) + } else if z.HasExtensions() && z.EncExt(yy22) { + } else if yym23 { + z.EncBinaryMarshal(yy22) + } else if !yym23 && z.IsJSONHandle() { + z.EncJSONMarshal(yy22) + } else { + z.EncFallback(yy22) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Warnings)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Warnings")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym27 := z.EncBinary() + _ = yym27 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Warnings)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym29 := z.EncBinary() + _ = yym29 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym30 := z.EncBinary() + _ = yym30 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobPlanResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobPlanResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Annotations": + if r.TryDecodeAsNil() { + if x.Annotations != nil { + x.Annotations = nil + } + } else { + if x.Annotations == nil { + x.Annotations = new(PlanAnnotations) + } + x.Annotations.CodecDecodeSelf(d) + } + case "FailedTGAllocs": + if r.TryDecodeAsNil() { + x.FailedTGAllocs = nil + } else { + yyv5 := &x.FailedTGAllocs + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + h.decMapstringPtrtoAllocMetric((*map[string]*AllocMetric)(yyv5), d) + } + } + case "JobModifyIndex": + if r.TryDecodeAsNil() { + x.JobModifyIndex = 0 + } else { + yyv7 := &x.JobModifyIndex + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*uint64)(yyv7)) = uint64(r.DecodeUint(64)) + } + } + case "CreatedEvals": + if r.TryDecodeAsNil() { + x.CreatedEvals = nil + } else { + yyv9 := &x.CreatedEvals + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + h.decSlicePtrtoEvaluation((*[]*Evaluation)(yyv9), d) + } + } + case "Diff": + if r.TryDecodeAsNil() { + if x.Diff != nil { + x.Diff = nil + } + } else { + if x.Diff == nil { + x.Diff = new(JobDiff) + } + yym12 := z.DecBinary() + _ = yym12 + if false { + } else if z.HasExtensions() && z.DecExt(x.Diff) { + } else { + z.DecFallback(x.Diff, false) + } + } + case "NextPeriodicLaunch": + if r.TryDecodeAsNil() { + x.NextPeriodicLaunch = time.Time{} + } else { + yyv13 := &x.NextPeriodicLaunch + yym14 := z.DecBinary() + _ = yym14 + if false { + } else if yym15 := z.TimeRtidIfBinc(); yym15 != 0 { + r.DecodeBuiltin(yym15, yyv13) + } else if z.HasExtensions() && z.DecExt(yyv13) { + } else if yym14 { + z.DecBinaryUnmarshal(yyv13) + } else if !yym14 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv13) + } else { + z.DecFallback(yyv13, false) + } + } + case "Warnings": + if r.TryDecodeAsNil() { + x.Warnings = "" + } else { + yyv16 := &x.Warnings + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv18 := &x.Index + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*uint64)(yyv18)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobPlanResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj20 int + var yyb20 bool + var yyhl20 bool = l >= 0 + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Annotations != nil { + x.Annotations = nil + } + } else { + if x.Annotations == nil { + x.Annotations = new(PlanAnnotations) + } + x.Annotations.CodecDecodeSelf(d) + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.FailedTGAllocs = nil + } else { + yyv22 := &x.FailedTGAllocs + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + h.decMapstringPtrtoAllocMetric((*map[string]*AllocMetric)(yyv22), d) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobModifyIndex = 0 + } else { + yyv24 := &x.JobModifyIndex + yym25 := z.DecBinary() + _ = yym25 + if false { + } else { + *((*uint64)(yyv24)) = uint64(r.DecodeUint(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CreatedEvals = nil + } else { + yyv26 := &x.CreatedEvals + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + h.decSlicePtrtoEvaluation((*[]*Evaluation)(yyv26), d) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Diff != nil { + x.Diff = nil + } + } else { + if x.Diff == nil { + x.Diff = new(JobDiff) + } + yym29 := z.DecBinary() + _ = yym29 + if false { + } else if z.HasExtensions() && z.DecExt(x.Diff) { + } else { + z.DecFallback(x.Diff, false) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NextPeriodicLaunch = time.Time{} + } else { + yyv30 := &x.NextPeriodicLaunch + yym31 := z.DecBinary() + _ = yym31 + if false { + } else if yym32 := z.TimeRtidIfBinc(); yym32 != 0 { + r.DecodeBuiltin(yym32, yyv30) + } else if z.HasExtensions() && z.DecExt(yyv30) { + } else if yym31 { + z.DecBinaryUnmarshal(yyv30) + } else if !yym31 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv30) + } else { + z.DecFallback(yyv30, false) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Warnings = "" + } else { + yyv33 := &x.Warnings + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*string)(yyv33)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv35 := &x.Index + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*uint64)(yyv35)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj20-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *SingleAllocResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Alloc == nil { + r.EncodeNil() + } else { + x.Alloc.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Alloc")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Alloc == nil { + r.EncodeNil() + } else { + x.Alloc.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *SingleAllocResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *SingleAllocResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Alloc": + if r.TryDecodeAsNil() { + if x.Alloc != nil { + x.Alloc = nil + } + } else { + if x.Alloc == nil { + x.Alloc = new(Allocation) + } + x.Alloc.CodecDecodeSelf(d) + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv5 := &x.Index + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv7 := &x.LastContact + yym8 := z.DecBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.DecExt(yyv7) { + } else { + *((*int64)(yyv7)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv9 := &x.KnownLeader + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*bool)(yyv9)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *SingleAllocResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Alloc != nil { + x.Alloc = nil + } + } else { + if x.Alloc == nil { + x.Alloc = new(Allocation) + } + x.Alloc.CodecDecodeSelf(d) + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv13 := &x.Index + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv15 := &x.LastContact + yym16 := z.DecBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.DecExt(yyv15) { + } else { + *((*int64)(yyv15)) = int64(r.DecodeInt(64)) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv17 := &x.KnownLeader + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*bool)(yyv17)) = r.DecodeBool() + } + } + for { + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj11-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *AllocsGetResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Allocs == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSlicePtrtoAllocation(([]*Allocation)(x.Allocs), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Allocs")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Allocs == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSlicePtrtoAllocation(([]*Allocation)(x.Allocs), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *AllocsGetResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *AllocsGetResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Allocs": + if r.TryDecodeAsNil() { + x.Allocs = nil + } else { + yyv4 := &x.Allocs + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSlicePtrtoAllocation((*[]*Allocation)(yyv4), d) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv6 := &x.Index + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv8 := &x.LastContact + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + *((*int64)(yyv8)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv10 := &x.KnownLeader + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *AllocsGetResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Allocs = nil + } else { + yyv13 := &x.Allocs + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decSlicePtrtoAllocation((*[]*Allocation)(yyv13), d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv15 := &x.Index + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv17 := &x.LastContact + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + *((*int64)(yyv17)) = int64(r.DecodeInt(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv19 := &x.KnownLeader + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobAllocationsResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Allocations == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSlicePtrtoAllocListStub(([]*AllocListStub)(x.Allocations), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Allocations")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Allocations == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSlicePtrtoAllocListStub(([]*AllocListStub)(x.Allocations), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobAllocationsResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobAllocationsResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Allocations": + if r.TryDecodeAsNil() { + x.Allocations = nil + } else { + yyv4 := &x.Allocations + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSlicePtrtoAllocListStub((*[]*AllocListStub)(yyv4), d) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv6 := &x.Index + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv8 := &x.LastContact + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + *((*int64)(yyv8)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv10 := &x.KnownLeader + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobAllocationsResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Allocations = nil + } else { + yyv13 := &x.Allocations + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decSlicePtrtoAllocListStub((*[]*AllocListStub)(yyv13), d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv15 := &x.Index + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv17 := &x.LastContact + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + *((*int64)(yyv17)) = int64(r.DecodeInt(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv19 := &x.KnownLeader + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobEvaluationsResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Evaluations == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSlicePtrtoEvaluation(([]*Evaluation)(x.Evaluations), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Evaluations")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Evaluations == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSlicePtrtoEvaluation(([]*Evaluation)(x.Evaluations), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobEvaluationsResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobEvaluationsResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Evaluations": + if r.TryDecodeAsNil() { + x.Evaluations = nil + } else { + yyv4 := &x.Evaluations + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSlicePtrtoEvaluation((*[]*Evaluation)(yyv4), d) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv6 := &x.Index + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv8 := &x.LastContact + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + *((*int64)(yyv8)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv10 := &x.KnownLeader + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobEvaluationsResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Evaluations = nil + } else { + yyv13 := &x.Evaluations + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decSlicePtrtoEvaluation((*[]*Evaluation)(yyv13), d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv15 := &x.Index + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv17 := &x.LastContact + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + *((*int64)(yyv17)) = int64(r.DecodeInt(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv19 := &x.KnownLeader + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *SingleEvalResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Eval == nil { + r.EncodeNil() + } else { + x.Eval.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Eval")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Eval == nil { + r.EncodeNil() + } else { + x.Eval.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *SingleEvalResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *SingleEvalResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Eval": + if r.TryDecodeAsNil() { + if x.Eval != nil { + x.Eval = nil + } + } else { + if x.Eval == nil { + x.Eval = new(Evaluation) + } + x.Eval.CodecDecodeSelf(d) + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv5 := &x.Index + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv7 := &x.LastContact + yym8 := z.DecBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.DecExt(yyv7) { + } else { + *((*int64)(yyv7)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv9 := &x.KnownLeader + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*bool)(yyv9)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *SingleEvalResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Eval != nil { + x.Eval = nil + } + } else { + if x.Eval == nil { + x.Eval = new(Evaluation) + } + x.Eval.CodecDecodeSelf(d) + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv13 := &x.Index + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv15 := &x.LastContact + yym16 := z.DecBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.DecExt(yyv15) { + } else { + *((*int64)(yyv15)) = int64(r.DecodeInt(64)) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv17 := &x.KnownLeader + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*bool)(yyv17)) = r.DecodeBool() + } + } + for { + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj11-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *EvalDequeueResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) + } else { + yynn2 = 6 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Eval == nil { + r.EncodeNil() + } else { + x.Eval.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Eval")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Eval == nil { + r.EncodeNil() + } else { + x.Eval.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Token)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Token")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Token)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.WaitIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("WaitIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.WaitIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *EvalDequeueResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *EvalDequeueResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Eval": + if r.TryDecodeAsNil() { + if x.Eval != nil { + x.Eval = nil + } + } else { + if x.Eval == nil { + x.Eval = new(Evaluation) + } + x.Eval.CodecDecodeSelf(d) + } + case "Token": + if r.TryDecodeAsNil() { + x.Token = "" + } else { + yyv5 := &x.Token + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } + } + case "WaitIndex": + if r.TryDecodeAsNil() { + x.WaitIndex = 0 + } else { + yyv7 := &x.WaitIndex + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*uint64)(yyv7)) = uint64(r.DecodeUint(64)) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv9 := &x.Index + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*uint64)(yyv9)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv11 := &x.LastContact + yym12 := z.DecBinary() + _ = yym12 + if false { + } else if z.HasExtensions() && z.DecExt(yyv11) { + } else { + *((*int64)(yyv11)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv13 := &x.KnownLeader + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*bool)(yyv13)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *EvalDequeueResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj15 int + var yyb15 bool + var yyhl15 bool = l >= 0 + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Eval != nil { + x.Eval = nil + } + } else { + if x.Eval == nil { + x.Eval = new(Evaluation) + } + x.Eval.CodecDecodeSelf(d) + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Token = "" + } else { + yyv17 := &x.Token + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.WaitIndex = 0 + } else { + yyv19 := &x.WaitIndex + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) + } + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv21 := &x.Index + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*uint64)(yyv21)) = uint64(r.DecodeUint(64)) + } + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv23 := &x.LastContact + yym24 := z.DecBinary() + _ = yym24 + if false { + } else if z.HasExtensions() && z.DecExt(yyv23) { + } else { + *((*int64)(yyv23)) = int64(r.DecodeInt(64)) + } + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv25 := &x.KnownLeader + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*bool)(yyv25)) = r.DecodeBool() + } + } + for { + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj15-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *PlanResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Result == nil { + r.EncodeNil() + } else { + x.Result.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Result")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Result == nil { + r.EncodeNil() + } else { + x.Result.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *PlanResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *PlanResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Result": + if r.TryDecodeAsNil() { + if x.Result != nil { + x.Result = nil + } + } else { + if x.Result == nil { + x.Result = new(PlanResult) + } + x.Result.CodecDecodeSelf(d) + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv5 := &x.Index + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *PlanResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Result != nil { + x.Result = nil + } + } else { + if x.Result == nil { + x.Result = new(PlanResult) + } + x.Result.CodecDecodeSelf(d) + } + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv9 := &x.Index + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*uint64)(yyv9)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj7-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *AllocListResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Allocations == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSlicePtrtoAllocListStub(([]*AllocListStub)(x.Allocations), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Allocations")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Allocations == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSlicePtrtoAllocListStub(([]*AllocListStub)(x.Allocations), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *AllocListResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *AllocListResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Allocations": + if r.TryDecodeAsNil() { + x.Allocations = nil + } else { + yyv4 := &x.Allocations + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSlicePtrtoAllocListStub((*[]*AllocListStub)(yyv4), d) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv6 := &x.Index + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv8 := &x.LastContact + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + *((*int64)(yyv8)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv10 := &x.KnownLeader + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *AllocListResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Allocations = nil + } else { + yyv13 := &x.Allocations + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decSlicePtrtoAllocListStub((*[]*AllocListStub)(yyv13), d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv15 := &x.Index + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv17 := &x.LastContact + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + *((*int64)(yyv17)) = int64(r.DecodeInt(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv19 := &x.KnownLeader + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *DeploymentListResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Deployments == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSlicePtrtoDeployment(([]*Deployment)(x.Deployments), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Deployments")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Deployments == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSlicePtrtoDeployment(([]*Deployment)(x.Deployments), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *DeploymentListResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *DeploymentListResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Deployments": + if r.TryDecodeAsNil() { + x.Deployments = nil + } else { + yyv4 := &x.Deployments + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSlicePtrtoDeployment((*[]*Deployment)(yyv4), d) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv6 := &x.Index + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv8 := &x.LastContact + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + *((*int64)(yyv8)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv10 := &x.KnownLeader + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *DeploymentListResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Deployments = nil + } else { + yyv13 := &x.Deployments + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decSlicePtrtoDeployment((*[]*Deployment)(yyv13), d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv15 := &x.Index + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv17 := &x.LastContact + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + *((*int64)(yyv17)) = int64(r.DecodeInt(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv19 := &x.KnownLeader + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *EvalListResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Evaluations == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSlicePtrtoEvaluation(([]*Evaluation)(x.Evaluations), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Evaluations")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Evaluations == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSlicePtrtoEvaluation(([]*Evaluation)(x.Evaluations), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *EvalListResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *EvalListResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Evaluations": + if r.TryDecodeAsNil() { + x.Evaluations = nil + } else { + yyv4 := &x.Evaluations + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSlicePtrtoEvaluation((*[]*Evaluation)(yyv4), d) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv6 := &x.Index + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv8 := &x.LastContact + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + *((*int64)(yyv8)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv10 := &x.KnownLeader + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *EvalListResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Evaluations = nil + } else { + yyv13 := &x.Evaluations + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decSlicePtrtoEvaluation((*[]*Evaluation)(yyv13), d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv15 := &x.Index + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv17 := &x.LastContact + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + *((*int64)(yyv17)) = int64(r.DecodeInt(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv19 := &x.KnownLeader + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *EvalAllocationsResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Allocations == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSlicePtrtoAllocListStub(([]*AllocListStub)(x.Allocations), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Allocations")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Allocations == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSlicePtrtoAllocListStub(([]*AllocListStub)(x.Allocations), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *EvalAllocationsResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *EvalAllocationsResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Allocations": + if r.TryDecodeAsNil() { + x.Allocations = nil + } else { + yyv4 := &x.Allocations + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSlicePtrtoAllocListStub((*[]*AllocListStub)(yyv4), d) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv6 := &x.Index + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv8 := &x.LastContact + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + *((*int64)(yyv8)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv10 := &x.KnownLeader + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *EvalAllocationsResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Allocations = nil + } else { + yyv13 := &x.Allocations + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decSlicePtrtoAllocListStub((*[]*AllocListStub)(yyv13), d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv15 := &x.Index + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv17 := &x.LastContact + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + *((*int64)(yyv17)) = int64(r.DecodeInt(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv19 := &x.KnownLeader + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *PeriodicForceResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 3 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.EvalCreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalCreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.EvalCreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *PeriodicForceResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *PeriodicForceResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "EvalID": + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv4 := &x.EvalID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "EvalCreateIndex": + if r.TryDecodeAsNil() { + x.EvalCreateIndex = 0 + } else { + yyv6 := &x.EvalCreateIndex + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv8 := &x.Index + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *PeriodicForceResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv11 := &x.EvalID + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalCreateIndex = 0 + } else { + yyv13 := &x.EvalCreateIndex + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv15 := &x.Index + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *DeploymentUpdateResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 5 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.EvalCreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalCreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.EvalCreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.DeploymentModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DeploymentModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.DeploymentModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.RevertedJobVersion == nil { + r.EncodeNil() + } else { + yy13 := *x.RevertedJobVersion + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeUint(uint64(yy13)) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("RevertedJobVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.RevertedJobVersion == nil { + r.EncodeNil() + } else { + yy15 := *x.RevertedJobVersion + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeUint(uint64(yy15)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym18 := z.EncBinary() + _ = yym18 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *DeploymentUpdateResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *DeploymentUpdateResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "EvalID": + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv4 := &x.EvalID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "EvalCreateIndex": + if r.TryDecodeAsNil() { + x.EvalCreateIndex = 0 + } else { + yyv6 := &x.EvalCreateIndex + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "DeploymentModifyIndex": + if r.TryDecodeAsNil() { + x.DeploymentModifyIndex = 0 + } else { + yyv8 := &x.DeploymentModifyIndex + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) + } + } + case "RevertedJobVersion": + if r.TryDecodeAsNil() { + if x.RevertedJobVersion != nil { + x.RevertedJobVersion = nil + } + } else { + if x.RevertedJobVersion == nil { + x.RevertedJobVersion = new(uint64) + } + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*uint64)(x.RevertedJobVersion)) = uint64(r.DecodeUint(64)) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv12 := &x.Index + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*uint64)(yyv12)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *DeploymentUpdateResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv15 := &x.EvalID + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalCreateIndex = 0 + } else { + yyv17 := &x.EvalCreateIndex + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*uint64)(yyv17)) = uint64(r.DecodeUint(64)) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DeploymentModifyIndex = 0 + } else { + yyv19 := &x.DeploymentModifyIndex + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.RevertedJobVersion != nil { + x.RevertedJobVersion = nil + } + } else { + if x.RevertedJobVersion == nil { + x.RevertedJobVersion = new(uint64) + } + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*uint64)(x.RevertedJobVersion)) = uint64(r.DecodeUint(64)) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv23 := &x.Index + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj14-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *Node) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [19]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(19) + } else { + yynn2 = 19 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.SecretID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("SecretID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.SecretID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Datacenter)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Datacenter")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Datacenter)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Name")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.HTTPAddr)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("HTTPAddr")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.HTTPAddr)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeBool(bool(x.TLSEnabled)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("TLSEnabled")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeBool(bool(x.TLSEnabled)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Attributes == nil { + r.EncodeNil() + } else { + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + z.F.EncMapStringStringV(x.Attributes, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Attributes")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Attributes == nil { + r.EncodeNil() + } else { + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + z.F.EncMapStringStringV(x.Attributes, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Resources == nil { + r.EncodeNil() + } else { + x.Resources.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Resources")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Resources == nil { + r.EncodeNil() + } else { + x.Resources.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Reserved == nil { + r.EncodeNil() + } else { + x.Reserved.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Reserved")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Reserved == nil { + r.EncodeNil() + } else { + x.Reserved.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Links == nil { + r.EncodeNil() + } else { + yym31 := z.EncBinary() + _ = yym31 + if false { + } else { + z.F.EncMapStringStringV(x.Links, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Links")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Links == nil { + r.EncodeNil() + } else { + yym32 := z.EncBinary() + _ = yym32 + if false { + } else { + z.F.EncMapStringStringV(x.Links, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Meta == nil { + r.EncodeNil() + } else { + yym34 := z.EncBinary() + _ = yym34 + if false { + } else { + z.F.EncMapStringStringV(x.Meta, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Meta")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Meta == nil { + r.EncodeNil() + } else { + yym35 := z.EncBinary() + _ = yym35 + if false { + } else { + z.F.EncMapStringStringV(x.Meta, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym37 := z.EncBinary() + _ = yym37 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeClass)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodeClass")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym38 := z.EncBinary() + _ = yym38 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeClass)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym40 := z.EncBinary() + _ = yym40 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ComputedClass)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ComputedClass")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym41 := z.EncBinary() + _ = yym41 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ComputedClass)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym43 := z.EncBinary() + _ = yym43 + if false { + } else { + r.EncodeBool(bool(x.Drain)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Drain")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym44 := z.EncBinary() + _ = yym44 + if false { + } else { + r.EncodeBool(bool(x.Drain)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym46 := z.EncBinary() + _ = yym46 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Status)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Status")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym47 := z.EncBinary() + _ = yym47 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Status)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym49 := z.EncBinary() + _ = yym49 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("StatusDescription")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym50 := z.EncBinary() + _ = yym50 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym52 := z.EncBinary() + _ = yym52 + if false { + } else { + r.EncodeInt(int64(x.StatusUpdatedAt)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("StatusUpdatedAt")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym53 := z.EncBinary() + _ = yym53 + if false { + } else { + r.EncodeInt(int64(x.StatusUpdatedAt)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym55 := z.EncBinary() + _ = yym55 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym56 := z.EncBinary() + _ = yym56 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym58 := z.EncBinary() + _ = yym58 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym59 := z.EncBinary() + _ = yym59 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *Node) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *Node) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "ID": + if r.TryDecodeAsNil() { + x.ID = "" + } else { + yyv4 := &x.ID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "SecretID": + if r.TryDecodeAsNil() { + x.SecretID = "" + } else { + yyv6 := &x.SecretID + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Datacenter": + if r.TryDecodeAsNil() { + x.Datacenter = "" + } else { + yyv8 := &x.Datacenter + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv10 := &x.Name + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "HTTPAddr": + if r.TryDecodeAsNil() { + x.HTTPAddr = "" + } else { + yyv12 := &x.HTTPAddr + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + case "TLSEnabled": + if r.TryDecodeAsNil() { + x.TLSEnabled = false + } else { + yyv14 := &x.TLSEnabled + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + case "Attributes": + if r.TryDecodeAsNil() { + x.Attributes = nil + } else { + yyv16 := &x.Attributes + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + z.F.DecMapStringStringX(yyv16, false, d) + } + } + case "Resources": + if r.TryDecodeAsNil() { + if x.Resources != nil { + x.Resources = nil + } + } else { + if x.Resources == nil { + x.Resources = new(Resources) + } + x.Resources.CodecDecodeSelf(d) + } + case "Reserved": + if r.TryDecodeAsNil() { + if x.Reserved != nil { + x.Reserved = nil + } + } else { + if x.Reserved == nil { + x.Reserved = new(Resources) + } + x.Reserved.CodecDecodeSelf(d) + } + case "Links": + if r.TryDecodeAsNil() { + x.Links = nil + } else { + yyv20 := &x.Links + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + z.F.DecMapStringStringX(yyv20, false, d) + } + } + case "Meta": + if r.TryDecodeAsNil() { + x.Meta = nil + } else { + yyv22 := &x.Meta + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + z.F.DecMapStringStringX(yyv22, false, d) + } + } + case "NodeClass": + if r.TryDecodeAsNil() { + x.NodeClass = "" + } else { + yyv24 := &x.NodeClass + yym25 := z.DecBinary() + _ = yym25 + if false { + } else { + *((*string)(yyv24)) = r.DecodeString() + } + } + case "ComputedClass": + if r.TryDecodeAsNil() { + x.ComputedClass = "" + } else { + yyv26 := &x.ComputedClass + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + *((*string)(yyv26)) = r.DecodeString() + } + } + case "Drain": + if r.TryDecodeAsNil() { + x.Drain = false + } else { + yyv28 := &x.Drain + yym29 := z.DecBinary() + _ = yym29 + if false { + } else { + *((*bool)(yyv28)) = r.DecodeBool() + } + } + case "Status": + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv30 := &x.Status + yym31 := z.DecBinary() + _ = yym31 + if false { + } else { + *((*string)(yyv30)) = r.DecodeString() + } + } + case "StatusDescription": + if r.TryDecodeAsNil() { + x.StatusDescription = "" + } else { + yyv32 := &x.StatusDescription + yym33 := z.DecBinary() + _ = yym33 + if false { + } else { + *((*string)(yyv32)) = r.DecodeString() + } + } + case "StatusUpdatedAt": + if r.TryDecodeAsNil() { + x.StatusUpdatedAt = 0 + } else { + yyv34 := &x.StatusUpdatedAt + yym35 := z.DecBinary() + _ = yym35 + if false { + } else { + *((*int64)(yyv34)) = int64(r.DecodeInt(64)) + } + } + case "CreateIndex": + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv36 := &x.CreateIndex + yym37 := z.DecBinary() + _ = yym37 + if false { + } else { + *((*uint64)(yyv36)) = uint64(r.DecodeUint(64)) + } + } + case "ModifyIndex": + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv38 := &x.ModifyIndex + yym39 := z.DecBinary() + _ = yym39 + if false { + } else { + *((*uint64)(yyv38)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *Node) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj40 int + var yyb40 bool + var yyhl40 bool = l >= 0 + yyj40++ + if yyhl40 { + yyb40 = yyj40 > l + } else { + yyb40 = r.CheckBreak() + } + if yyb40 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ID = "" + } else { + yyv41 := &x.ID + yym42 := z.DecBinary() + _ = yym42 + if false { + } else { + *((*string)(yyv41)) = r.DecodeString() + } + } + yyj40++ + if yyhl40 { + yyb40 = yyj40 > l + } else { + yyb40 = r.CheckBreak() + } + if yyb40 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.SecretID = "" + } else { + yyv43 := &x.SecretID + yym44 := z.DecBinary() + _ = yym44 + if false { + } else { + *((*string)(yyv43)) = r.DecodeString() + } + } + yyj40++ + if yyhl40 { + yyb40 = yyj40 > l + } else { + yyb40 = r.CheckBreak() + } + if yyb40 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Datacenter = "" + } else { + yyv45 := &x.Datacenter + yym46 := z.DecBinary() + _ = yym46 + if false { + } else { + *((*string)(yyv45)) = r.DecodeString() + } + } + yyj40++ + if yyhl40 { + yyb40 = yyj40 > l + } else { + yyb40 = r.CheckBreak() + } + if yyb40 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv47 := &x.Name + yym48 := z.DecBinary() + _ = yym48 + if false { + } else { + *((*string)(yyv47)) = r.DecodeString() + } + } + yyj40++ + if yyhl40 { + yyb40 = yyj40 > l + } else { + yyb40 = r.CheckBreak() + } + if yyb40 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.HTTPAddr = "" + } else { + yyv49 := &x.HTTPAddr + yym50 := z.DecBinary() + _ = yym50 + if false { + } else { + *((*string)(yyv49)) = r.DecodeString() + } + } + yyj40++ + if yyhl40 { + yyb40 = yyj40 > l + } else { + yyb40 = r.CheckBreak() + } + if yyb40 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.TLSEnabled = false + } else { + yyv51 := &x.TLSEnabled + yym52 := z.DecBinary() + _ = yym52 + if false { + } else { + *((*bool)(yyv51)) = r.DecodeBool() + } + } + yyj40++ + if yyhl40 { + yyb40 = yyj40 > l + } else { + yyb40 = r.CheckBreak() + } + if yyb40 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Attributes = nil + } else { + yyv53 := &x.Attributes + yym54 := z.DecBinary() + _ = yym54 + if false { + } else { + z.F.DecMapStringStringX(yyv53, false, d) + } + } + yyj40++ + if yyhl40 { + yyb40 = yyj40 > l + } else { + yyb40 = r.CheckBreak() + } + if yyb40 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Resources != nil { + x.Resources = nil + } + } else { + if x.Resources == nil { + x.Resources = new(Resources) + } + x.Resources.CodecDecodeSelf(d) + } + yyj40++ + if yyhl40 { + yyb40 = yyj40 > l + } else { + yyb40 = r.CheckBreak() + } + if yyb40 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Reserved != nil { + x.Reserved = nil + } + } else { + if x.Reserved == nil { + x.Reserved = new(Resources) + } + x.Reserved.CodecDecodeSelf(d) + } + yyj40++ + if yyhl40 { + yyb40 = yyj40 > l + } else { + yyb40 = r.CheckBreak() + } + if yyb40 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Links = nil + } else { + yyv57 := &x.Links + yym58 := z.DecBinary() + _ = yym58 + if false { + } else { + z.F.DecMapStringStringX(yyv57, false, d) + } + } + yyj40++ + if yyhl40 { + yyb40 = yyj40 > l + } else { + yyb40 = r.CheckBreak() + } + if yyb40 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Meta = nil + } else { + yyv59 := &x.Meta + yym60 := z.DecBinary() + _ = yym60 + if false { + } else { + z.F.DecMapStringStringX(yyv59, false, d) + } + } + yyj40++ + if yyhl40 { + yyb40 = yyj40 > l + } else { + yyb40 = r.CheckBreak() + } + if yyb40 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodeClass = "" + } else { + yyv61 := &x.NodeClass + yym62 := z.DecBinary() + _ = yym62 + if false { + } else { + *((*string)(yyv61)) = r.DecodeString() + } + } + yyj40++ + if yyhl40 { + yyb40 = yyj40 > l + } else { + yyb40 = r.CheckBreak() + } + if yyb40 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ComputedClass = "" + } else { + yyv63 := &x.ComputedClass + yym64 := z.DecBinary() + _ = yym64 + if false { + } else { + *((*string)(yyv63)) = r.DecodeString() + } + } + yyj40++ + if yyhl40 { + yyb40 = yyj40 > l + } else { + yyb40 = r.CheckBreak() + } + if yyb40 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Drain = false + } else { + yyv65 := &x.Drain + yym66 := z.DecBinary() + _ = yym66 + if false { + } else { + *((*bool)(yyv65)) = r.DecodeBool() + } + } + yyj40++ + if yyhl40 { + yyb40 = yyj40 > l + } else { + yyb40 = r.CheckBreak() + } + if yyb40 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv67 := &x.Status + yym68 := z.DecBinary() + _ = yym68 + if false { + } else { + *((*string)(yyv67)) = r.DecodeString() + } + } + yyj40++ + if yyhl40 { + yyb40 = yyj40 > l + } else { + yyb40 = r.CheckBreak() + } + if yyb40 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.StatusDescription = "" + } else { + yyv69 := &x.StatusDescription + yym70 := z.DecBinary() + _ = yym70 + if false { + } else { + *((*string)(yyv69)) = r.DecodeString() + } + } + yyj40++ + if yyhl40 { + yyb40 = yyj40 > l + } else { + yyb40 = r.CheckBreak() + } + if yyb40 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.StatusUpdatedAt = 0 + } else { + yyv71 := &x.StatusUpdatedAt + yym72 := z.DecBinary() + _ = yym72 + if false { + } else { + *((*int64)(yyv71)) = int64(r.DecodeInt(64)) + } + } + yyj40++ + if yyhl40 { + yyb40 = yyj40 > l + } else { + yyb40 = r.CheckBreak() + } + if yyb40 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv73 := &x.CreateIndex + yym74 := z.DecBinary() + _ = yym74 + if false { + } else { + *((*uint64)(yyv73)) = uint64(r.DecodeUint(64)) + } + } + yyj40++ + if yyhl40 { + yyb40 = yyj40 > l + } else { + yyb40 = r.CheckBreak() + } + if yyb40 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv75 := &x.ModifyIndex + yym76 := z.DecBinary() + _ = yym76 + if false { + } else { + *((*uint64)(yyv75)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj40++ + if yyhl40 { + yyb40 = yyj40 > l + } else { + yyb40 = r.CheckBreak() + } + if yyb40 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj40-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *NodeListStub) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [10]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(10) + } else { + yynn2 = 10 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Datacenter)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Datacenter")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Datacenter)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Name")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeClass)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodeClass")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeClass)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Version)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Version")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Version)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeBool(bool(x.Drain)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Drain")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeBool(bool(x.Drain)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Status)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Status")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Status)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("StatusDescription")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym29 := z.EncBinary() + _ = yym29 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym31 := z.EncBinary() + _ = yym31 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym32 := z.EncBinary() + _ = yym32 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *NodeListStub) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *NodeListStub) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "ID": + if r.TryDecodeAsNil() { + x.ID = "" + } else { + yyv4 := &x.ID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Datacenter": + if r.TryDecodeAsNil() { + x.Datacenter = "" + } else { + yyv6 := &x.Datacenter + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv8 := &x.Name + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "NodeClass": + if r.TryDecodeAsNil() { + x.NodeClass = "" + } else { + yyv10 := &x.NodeClass + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "Version": + if r.TryDecodeAsNil() { + x.Version = "" + } else { + yyv12 := &x.Version + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + case "Drain": + if r.TryDecodeAsNil() { + x.Drain = false + } else { + yyv14 := &x.Drain + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + case "Status": + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv16 := &x.Status + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + case "StatusDescription": + if r.TryDecodeAsNil() { + x.StatusDescription = "" + } else { + yyv18 := &x.StatusDescription + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + case "CreateIndex": + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv20 := &x.CreateIndex + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*uint64)(yyv20)) = uint64(r.DecodeUint(64)) + } + } + case "ModifyIndex": + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv22 := &x.ModifyIndex + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + *((*uint64)(yyv22)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *NodeListStub) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj24 int + var yyb24 bool + var yyhl24 bool = l >= 0 + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ID = "" + } else { + yyv25 := &x.ID + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Datacenter = "" + } else { + yyv27 := &x.Datacenter + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } + } + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv29 := &x.Name + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } + } + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodeClass = "" + } else { + yyv31 := &x.NodeClass + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } + } + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Version = "" + } else { + yyv33 := &x.Version + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*string)(yyv33)) = r.DecodeString() + } + } + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Drain = false + } else { + yyv35 := &x.Drain + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*bool)(yyv35)) = r.DecodeBool() + } + } + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv37 := &x.Status + yym38 := z.DecBinary() + _ = yym38 + if false { + } else { + *((*string)(yyv37)) = r.DecodeString() + } + } + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.StatusDescription = "" + } else { + yyv39 := &x.StatusDescription + yym40 := z.DecBinary() + _ = yym40 + if false { + } else { + *((*string)(yyv39)) = r.DecodeString() + } + } + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv41 := &x.CreateIndex + yym42 := z.DecBinary() + _ = yym42 + if false { + } else { + *((*uint64)(yyv41)) = uint64(r.DecodeUint(64)) + } + } + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv43 := &x.ModifyIndex + yym44 := z.DecBinary() + _ = yym44 + if false { + } else { + *((*uint64)(yyv43)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l + } else { + yyb24 = r.CheckBreak() + } + if yyb24 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj24-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x Networks) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + h.encNetworks((Networks)(x), e) + } + } +} + +func (x *Networks) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + h.decNetworks((*Networks)(x), d) + } +} + +func (x *Resources) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 5 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeInt(int64(x.CPU)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CPU")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeInt(int64(x.CPU)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeInt(int64(x.MemoryMB)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MemoryMB")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeInt(int64(x.MemoryMB)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeInt(int64(x.DiskMB)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DiskMB")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeInt(int64(x.DiskMB)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeInt(int64(x.IOPS)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("IOPS")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeInt(int64(x.IOPS)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Networks == nil { + r.EncodeNil() + } else { + x.Networks.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Networks")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Networks == nil { + r.EncodeNil() + } else { + x.Networks.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *Resources) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *Resources) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "CPU": + if r.TryDecodeAsNil() { + x.CPU = 0 + } else { + yyv4 := &x.CPU + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int)(yyv4)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "MemoryMB": + if r.TryDecodeAsNil() { + x.MemoryMB = 0 + } else { + yyv6 := &x.MemoryMB + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int)(yyv6)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "DiskMB": + if r.TryDecodeAsNil() { + x.DiskMB = 0 + } else { + yyv8 := &x.DiskMB + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int)(yyv8)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "IOPS": + if r.TryDecodeAsNil() { + x.IOPS = 0 + } else { + yyv10 := &x.IOPS + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*int)(yyv10)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "Networks": + if r.TryDecodeAsNil() { + x.Networks = nil + } else { + yyv12 := &x.Networks + yyv12.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *Resources) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj13 int + var yyb13 bool + var yyhl13 bool = l >= 0 + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CPU = 0 + } else { + yyv14 := &x.CPU + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*int)(yyv14)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MemoryMB = 0 + } else { + yyv16 := &x.MemoryMB + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*int)(yyv16)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DiskMB = 0 + } else { + yyv18 := &x.DiskMB + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*int)(yyv18)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.IOPS = 0 + } else { + yyv20 := &x.IOPS + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*int)(yyv20)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Networks = nil + } else { + yyv22 := &x.Networks + yyv22.CodecDecodeSelf(d) + } + for { + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj13-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *Port) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Label)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Label")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Label)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeInt(int64(x.Value)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Value")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeInt(int64(x.Value)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *Port) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *Port) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Label": + if r.TryDecodeAsNil() { + x.Label = "" + } else { + yyv4 := &x.Label + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Value": + if r.TryDecodeAsNil() { + x.Value = 0 + } else { + yyv6 := &x.Value + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int)(yyv6)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *Port) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Label = "" + } else { + yyv9 := &x.Label + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Value = 0 + } else { + yyv11 := &x.Value + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*int)(yyv11)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *NetworkResource) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) + } else { + yynn2 = 6 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Device)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Device")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Device)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.CIDR)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CIDR")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.CIDR)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.IP)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("IP")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.IP)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeInt(int64(x.MBits)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MBits")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeInt(int64(x.MBits)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.ReservedPorts == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSlicePort(([]Port)(x.ReservedPorts), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ReservedPorts")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.ReservedPorts == nil { + r.EncodeNil() + } else { + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + h.encSlicePort(([]Port)(x.ReservedPorts), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.DynamicPorts == nil { + r.EncodeNil() + } else { + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + h.encSlicePort(([]Port)(x.DynamicPorts), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DynamicPorts")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.DynamicPorts == nil { + r.EncodeNil() + } else { + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + h.encSlicePort(([]Port)(x.DynamicPorts), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *NetworkResource) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *NetworkResource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Device": + if r.TryDecodeAsNil() { + x.Device = "" + } else { + yyv4 := &x.Device + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "CIDR": + if r.TryDecodeAsNil() { + x.CIDR = "" + } else { + yyv6 := &x.CIDR + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "IP": + if r.TryDecodeAsNil() { + x.IP = "" + } else { + yyv8 := &x.IP + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "MBits": + if r.TryDecodeAsNil() { + x.MBits = 0 + } else { + yyv10 := &x.MBits + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*int)(yyv10)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "ReservedPorts": + if r.TryDecodeAsNil() { + x.ReservedPorts = nil + } else { + yyv12 := &x.ReservedPorts + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + h.decSlicePort((*[]Port)(yyv12), d) + } + } + case "DynamicPorts": + if r.TryDecodeAsNil() { + x.DynamicPorts = nil + } else { + yyv14 := &x.DynamicPorts + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + h.decSlicePort((*[]Port)(yyv14), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *NetworkResource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj16 int + var yyb16 bool + var yyhl16 bool = l >= 0 + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Device = "" + } else { + yyv17 := &x.Device + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CIDR = "" + } else { + yyv19 := &x.CIDR + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.IP = "" + } else { + yyv21 := &x.IP + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MBits = 0 + } else { + yyv23 := &x.MBits + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*int)(yyv23)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ReservedPorts = nil + } else { + yyv25 := &x.ReservedPorts + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + h.decSlicePort((*[]Port)(yyv25), d) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DynamicPorts = nil + } else { + yyv27 := &x.DynamicPorts + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + h.decSlicePort((*[]Port)(yyv27), d) + } + } + for { + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj16-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *Job) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [26]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(26) + } else { + yynn2 = 26 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeBool(bool(x.Stop)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Stop")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeBool(bool(x.Stop)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ParentID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ParentID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ParentID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Name")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Type)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Type")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Type)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeInt(int64(x.Priority)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Priority")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeInt(int64(x.Priority)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + r.EncodeBool(bool(x.AllAtOnce)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllAtOnce")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym29 := z.EncBinary() + _ = yym29 + if false { + } else { + r.EncodeBool(bool(x.AllAtOnce)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Datacenters == nil { + r.EncodeNil() + } else { + yym31 := z.EncBinary() + _ = yym31 + if false { + } else { + z.F.EncSliceStringV(x.Datacenters, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Datacenters")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Datacenters == nil { + r.EncodeNil() + } else { + yym32 := z.EncBinary() + _ = yym32 + if false { + } else { + z.F.EncSliceStringV(x.Datacenters, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Constraints == nil { + r.EncodeNil() + } else { + yym34 := z.EncBinary() + _ = yym34 + if false { + } else { + h.encSlicePtrtoConstraint(([]*Constraint)(x.Constraints), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Constraints")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Constraints == nil { + r.EncodeNil() + } else { + yym35 := z.EncBinary() + _ = yym35 + if false { + } else { + h.encSlicePtrtoConstraint(([]*Constraint)(x.Constraints), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.TaskGroups == nil { + r.EncodeNil() + } else { + yym37 := z.EncBinary() + _ = yym37 + if false { + } else { + h.encSlicePtrtoTaskGroup(([]*TaskGroup)(x.TaskGroups), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("TaskGroups")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.TaskGroups == nil { + r.EncodeNil() + } else { + yym38 := z.EncBinary() + _ = yym38 + if false { + } else { + h.encSlicePtrtoTaskGroup(([]*TaskGroup)(x.TaskGroups), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yy40 := &x.Update + yy40.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Update")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yy42 := &x.Update + yy42.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Periodic == nil { + r.EncodeNil() + } else { + x.Periodic.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Periodic")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Periodic == nil { + r.EncodeNil() + } else { + x.Periodic.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.ParameterizedJob == nil { + r.EncodeNil() + } else { + x.ParameterizedJob.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ParameterizedJob")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.ParameterizedJob == nil { + r.EncodeNil() + } else { + x.ParameterizedJob.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Payload == nil { + r.EncodeNil() + } else { + yym51 := z.EncBinary() + _ = yym51 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Payload)) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Payload")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Payload == nil { + r.EncodeNil() + } else { + yym52 := z.EncBinary() + _ = yym52 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Payload)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Meta == nil { + r.EncodeNil() + } else { + yym54 := z.EncBinary() + _ = yym54 + if false { + } else { + z.F.EncMapStringStringV(x.Meta, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Meta")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Meta == nil { + r.EncodeNil() + } else { + yym55 := z.EncBinary() + _ = yym55 + if false { + } else { + z.F.EncMapStringStringV(x.Meta, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym57 := z.EncBinary() + _ = yym57 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.VaultToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("VaultToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym58 := z.EncBinary() + _ = yym58 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.VaultToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym60 := z.EncBinary() + _ = yym60 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Status)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Status")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym61 := z.EncBinary() + _ = yym61 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Status)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym63 := z.EncBinary() + _ = yym63 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("StatusDescription")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym64 := z.EncBinary() + _ = yym64 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym66 := z.EncBinary() + _ = yym66 + if false { + } else { + r.EncodeBool(bool(x.Stable)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Stable")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym67 := z.EncBinary() + _ = yym67 + if false { + } else { + r.EncodeBool(bool(x.Stable)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym69 := z.EncBinary() + _ = yym69 + if false { + } else { + r.EncodeUint(uint64(x.Version)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Version")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym70 := z.EncBinary() + _ = yym70 + if false { + } else { + r.EncodeUint(uint64(x.Version)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym72 := z.EncBinary() + _ = yym72 + if false { + } else { + r.EncodeInt(int64(x.SubmitTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("SubmitTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym73 := z.EncBinary() + _ = yym73 + if false { + } else { + r.EncodeInt(int64(x.SubmitTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym75 := z.EncBinary() + _ = yym75 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym76 := z.EncBinary() + _ = yym76 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym78 := z.EncBinary() + _ = yym78 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym79 := z.EncBinary() + _ = yym79 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym81 := z.EncBinary() + _ = yym81 + if false { + } else { + r.EncodeUint(uint64(x.JobModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym82 := z.EncBinary() + _ = yym82 + if false { + } else { + r.EncodeUint(uint64(x.JobModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *Job) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *Job) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Stop": + if r.TryDecodeAsNil() { + x.Stop = false + } else { + yyv4 := &x.Stop + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*bool)(yyv4)) = r.DecodeBool() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "ID": + if r.TryDecodeAsNil() { + x.ID = "" + } else { + yyv10 := &x.ID + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "ParentID": + if r.TryDecodeAsNil() { + x.ParentID = "" + } else { + yyv12 := &x.ParentID + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + case "Name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv14 := &x.Name + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + case "Type": + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv16 := &x.Type + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + case "Priority": + if r.TryDecodeAsNil() { + x.Priority = 0 + } else { + yyv18 := &x.Priority + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*int)(yyv18)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "AllAtOnce": + if r.TryDecodeAsNil() { + x.AllAtOnce = false + } else { + yyv20 := &x.AllAtOnce + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*bool)(yyv20)) = r.DecodeBool() + } + } + case "Datacenters": + if r.TryDecodeAsNil() { + x.Datacenters = nil + } else { + yyv22 := &x.Datacenters + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + z.F.DecSliceStringX(yyv22, false, d) + } + } + case "Constraints": + if r.TryDecodeAsNil() { + x.Constraints = nil + } else { + yyv24 := &x.Constraints + yym25 := z.DecBinary() + _ = yym25 + if false { + } else { + h.decSlicePtrtoConstraint((*[]*Constraint)(yyv24), d) + } + } + case "TaskGroups": + if r.TryDecodeAsNil() { + x.TaskGroups = nil + } else { + yyv26 := &x.TaskGroups + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + h.decSlicePtrtoTaskGroup((*[]*TaskGroup)(yyv26), d) + } + } + case "Update": + if r.TryDecodeAsNil() { + x.Update = UpdateStrategy{} + } else { + yyv28 := &x.Update + yyv28.CodecDecodeSelf(d) + } + case "Periodic": + if r.TryDecodeAsNil() { + if x.Periodic != nil { + x.Periodic = nil + } + } else { + if x.Periodic == nil { + x.Periodic = new(PeriodicConfig) + } + x.Periodic.CodecDecodeSelf(d) + } + case "ParameterizedJob": + if r.TryDecodeAsNil() { + if x.ParameterizedJob != nil { + x.ParameterizedJob = nil + } + } else { + if x.ParameterizedJob == nil { + x.ParameterizedJob = new(ParameterizedJobConfig) + } + x.ParameterizedJob.CodecDecodeSelf(d) + } + case "Payload": + if r.TryDecodeAsNil() { + x.Payload = nil + } else { + yyv31 := &x.Payload + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *yyv31 = r.DecodeBytes(*(*[]byte)(yyv31), false, false) + } + } + case "Meta": + if r.TryDecodeAsNil() { + x.Meta = nil + } else { + yyv33 := &x.Meta + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + z.F.DecMapStringStringX(yyv33, false, d) + } + } + case "VaultToken": + if r.TryDecodeAsNil() { + x.VaultToken = "" + } else { + yyv35 := &x.VaultToken + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*string)(yyv35)) = r.DecodeString() + } + } + case "Status": + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv37 := &x.Status + yym38 := z.DecBinary() + _ = yym38 + if false { + } else { + *((*string)(yyv37)) = r.DecodeString() + } + } + case "StatusDescription": + if r.TryDecodeAsNil() { + x.StatusDescription = "" + } else { + yyv39 := &x.StatusDescription + yym40 := z.DecBinary() + _ = yym40 + if false { + } else { + *((*string)(yyv39)) = r.DecodeString() + } + } + case "Stable": + if r.TryDecodeAsNil() { + x.Stable = false + } else { + yyv41 := &x.Stable + yym42 := z.DecBinary() + _ = yym42 + if false { + } else { + *((*bool)(yyv41)) = r.DecodeBool() + } + } + case "Version": + if r.TryDecodeAsNil() { + x.Version = 0 + } else { + yyv43 := &x.Version + yym44 := z.DecBinary() + _ = yym44 + if false { + } else { + *((*uint64)(yyv43)) = uint64(r.DecodeUint(64)) + } + } + case "SubmitTime": + if r.TryDecodeAsNil() { + x.SubmitTime = 0 + } else { + yyv45 := &x.SubmitTime + yym46 := z.DecBinary() + _ = yym46 + if false { + } else { + *((*int64)(yyv45)) = int64(r.DecodeInt(64)) + } + } + case "CreateIndex": + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv47 := &x.CreateIndex + yym48 := z.DecBinary() + _ = yym48 + if false { + } else { + *((*uint64)(yyv47)) = uint64(r.DecodeUint(64)) + } + } + case "ModifyIndex": + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv49 := &x.ModifyIndex + yym50 := z.DecBinary() + _ = yym50 + if false { + } else { + *((*uint64)(yyv49)) = uint64(r.DecodeUint(64)) + } + } + case "JobModifyIndex": + if r.TryDecodeAsNil() { + x.JobModifyIndex = 0 + } else { + yyv51 := &x.JobModifyIndex + yym52 := z.DecBinary() + _ = yym52 + if false { + } else { + *((*uint64)(yyv51)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *Job) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj53 int + var yyb53 bool + var yyhl53 bool = l >= 0 + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Stop = false + } else { + yyv54 := &x.Stop + yym55 := z.DecBinary() + _ = yym55 + if false { + } else { + *((*bool)(yyv54)) = r.DecodeBool() + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv56 := &x.Region + yym57 := z.DecBinary() + _ = yym57 + if false { + } else { + *((*string)(yyv56)) = r.DecodeString() + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv58 := &x.Namespace + yym59 := z.DecBinary() + _ = yym59 + if false { + } else { + *((*string)(yyv58)) = r.DecodeString() + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ID = "" + } else { + yyv60 := &x.ID + yym61 := z.DecBinary() + _ = yym61 + if false { + } else { + *((*string)(yyv60)) = r.DecodeString() + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ParentID = "" + } else { + yyv62 := &x.ParentID + yym63 := z.DecBinary() + _ = yym63 + if false { + } else { + *((*string)(yyv62)) = r.DecodeString() + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv64 := &x.Name + yym65 := z.DecBinary() + _ = yym65 + if false { + } else { + *((*string)(yyv64)) = r.DecodeString() + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv66 := &x.Type + yym67 := z.DecBinary() + _ = yym67 + if false { + } else { + *((*string)(yyv66)) = r.DecodeString() + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Priority = 0 + } else { + yyv68 := &x.Priority + yym69 := z.DecBinary() + _ = yym69 + if false { + } else { + *((*int)(yyv68)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllAtOnce = false + } else { + yyv70 := &x.AllAtOnce + yym71 := z.DecBinary() + _ = yym71 + if false { + } else { + *((*bool)(yyv70)) = r.DecodeBool() + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Datacenters = nil + } else { + yyv72 := &x.Datacenters + yym73 := z.DecBinary() + _ = yym73 + if false { + } else { + z.F.DecSliceStringX(yyv72, false, d) + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Constraints = nil + } else { + yyv74 := &x.Constraints + yym75 := z.DecBinary() + _ = yym75 + if false { + } else { + h.decSlicePtrtoConstraint((*[]*Constraint)(yyv74), d) + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.TaskGroups = nil + } else { + yyv76 := &x.TaskGroups + yym77 := z.DecBinary() + _ = yym77 + if false { + } else { + h.decSlicePtrtoTaskGroup((*[]*TaskGroup)(yyv76), d) + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Update = UpdateStrategy{} + } else { + yyv78 := &x.Update + yyv78.CodecDecodeSelf(d) + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Periodic != nil { + x.Periodic = nil + } + } else { + if x.Periodic == nil { + x.Periodic = new(PeriodicConfig) + } + x.Periodic.CodecDecodeSelf(d) + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.ParameterizedJob != nil { + x.ParameterizedJob = nil + } + } else { + if x.ParameterizedJob == nil { + x.ParameterizedJob = new(ParameterizedJobConfig) + } + x.ParameterizedJob.CodecDecodeSelf(d) + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Payload = nil + } else { + yyv81 := &x.Payload + yym82 := z.DecBinary() + _ = yym82 + if false { + } else { + *yyv81 = r.DecodeBytes(*(*[]byte)(yyv81), false, false) + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Meta = nil + } else { + yyv83 := &x.Meta + yym84 := z.DecBinary() + _ = yym84 + if false { + } else { + z.F.DecMapStringStringX(yyv83, false, d) + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.VaultToken = "" + } else { + yyv85 := &x.VaultToken + yym86 := z.DecBinary() + _ = yym86 + if false { + } else { + *((*string)(yyv85)) = r.DecodeString() + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv87 := &x.Status + yym88 := z.DecBinary() + _ = yym88 + if false { + } else { + *((*string)(yyv87)) = r.DecodeString() + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.StatusDescription = "" + } else { + yyv89 := &x.StatusDescription + yym90 := z.DecBinary() + _ = yym90 + if false { + } else { + *((*string)(yyv89)) = r.DecodeString() + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Stable = false + } else { + yyv91 := &x.Stable + yym92 := z.DecBinary() + _ = yym92 + if false { + } else { + *((*bool)(yyv91)) = r.DecodeBool() + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Version = 0 + } else { + yyv93 := &x.Version + yym94 := z.DecBinary() + _ = yym94 + if false { + } else { + *((*uint64)(yyv93)) = uint64(r.DecodeUint(64)) + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.SubmitTime = 0 + } else { + yyv95 := &x.SubmitTime + yym96 := z.DecBinary() + _ = yym96 + if false { + } else { + *((*int64)(yyv95)) = int64(r.DecodeInt(64)) + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv97 := &x.CreateIndex + yym98 := z.DecBinary() + _ = yym98 + if false { + } else { + *((*uint64)(yyv97)) = uint64(r.DecodeUint(64)) + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv99 := &x.ModifyIndex + yym100 := z.DecBinary() + _ = yym100 + if false { + } else { + *((*uint64)(yyv99)) = uint64(r.DecodeUint(64)) + } + } + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobModifyIndex = 0 + } else { + yyv101 := &x.JobModifyIndex + yym102 := z.DecBinary() + _ = yym102 + if false { + } else { + *((*uint64)(yyv101)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj53++ + if yyhl53 { + yyb53 = yyj53 > l + } else { + yyb53 = r.CheckBreak() + } + if yyb53 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj53-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobListStub) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [15]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(15) + } else { + yynn2 = 15 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ParentID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ParentID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ParentID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Name")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Type)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Type")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Type)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeInt(int64(x.Priority)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Priority")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeInt(int64(x.Priority)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeBool(bool(x.Periodic)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Periodic")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeBool(bool(x.Periodic)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeBool(bool(x.ParameterizedJob)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ParameterizedJob")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeBool(bool(x.ParameterizedJob)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeBool(bool(x.Stop)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Stop")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeBool(bool(x.Stop)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Status)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Status")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym29 := z.EncBinary() + _ = yym29 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Status)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym31 := z.EncBinary() + _ = yym31 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("StatusDescription")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym32 := z.EncBinary() + _ = yym32 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.JobSummary == nil { + r.EncodeNil() + } else { + x.JobSummary.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobSummary")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.JobSummary == nil { + r.EncodeNil() + } else { + x.JobSummary.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym37 := z.EncBinary() + _ = yym37 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym38 := z.EncBinary() + _ = yym38 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym40 := z.EncBinary() + _ = yym40 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym41 := z.EncBinary() + _ = yym41 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym43 := z.EncBinary() + _ = yym43 + if false { + } else { + r.EncodeUint(uint64(x.JobModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym44 := z.EncBinary() + _ = yym44 + if false { + } else { + r.EncodeUint(uint64(x.JobModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym46 := z.EncBinary() + _ = yym46 + if false { + } else { + r.EncodeInt(int64(x.SubmitTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("SubmitTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym47 := z.EncBinary() + _ = yym47 + if false { + } else { + r.EncodeInt(int64(x.SubmitTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobListStub) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobListStub) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "ID": + if r.TryDecodeAsNil() { + x.ID = "" + } else { + yyv4 := &x.ID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "ParentID": + if r.TryDecodeAsNil() { + x.ParentID = "" + } else { + yyv6 := &x.ParentID + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv8 := &x.Name + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Type": + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv10 := &x.Type + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "Priority": + if r.TryDecodeAsNil() { + x.Priority = 0 + } else { + yyv12 := &x.Priority + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*int)(yyv12)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "Periodic": + if r.TryDecodeAsNil() { + x.Periodic = false + } else { + yyv14 := &x.Periodic + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + case "ParameterizedJob": + if r.TryDecodeAsNil() { + x.ParameterizedJob = false + } else { + yyv16 := &x.ParameterizedJob + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*bool)(yyv16)) = r.DecodeBool() + } + } + case "Stop": + if r.TryDecodeAsNil() { + x.Stop = false + } else { + yyv18 := &x.Stop + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*bool)(yyv18)) = r.DecodeBool() + } + } + case "Status": + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv20 := &x.Status + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*string)(yyv20)) = r.DecodeString() + } + } + case "StatusDescription": + if r.TryDecodeAsNil() { + x.StatusDescription = "" + } else { + yyv22 := &x.StatusDescription + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + *((*string)(yyv22)) = r.DecodeString() + } + } + case "JobSummary": + if r.TryDecodeAsNil() { + if x.JobSummary != nil { + x.JobSummary = nil + } + } else { + if x.JobSummary == nil { + x.JobSummary = new(JobSummary) + } + x.JobSummary.CodecDecodeSelf(d) + } + case "CreateIndex": + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv25 := &x.CreateIndex + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*uint64)(yyv25)) = uint64(r.DecodeUint(64)) + } + } + case "ModifyIndex": + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv27 := &x.ModifyIndex + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) + } + } + case "JobModifyIndex": + if r.TryDecodeAsNil() { + x.JobModifyIndex = 0 + } else { + yyv29 := &x.JobModifyIndex + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*uint64)(yyv29)) = uint64(r.DecodeUint(64)) + } + } + case "SubmitTime": + if r.TryDecodeAsNil() { + x.SubmitTime = 0 + } else { + yyv31 := &x.SubmitTime + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*int64)(yyv31)) = int64(r.DecodeInt(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobListStub) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj33 int + var yyb33 bool + var yyhl33 bool = l >= 0 + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ID = "" + } else { + yyv34 := &x.ID + yym35 := z.DecBinary() + _ = yym35 + if false { + } else { + *((*string)(yyv34)) = r.DecodeString() + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ParentID = "" + } else { + yyv36 := &x.ParentID + yym37 := z.DecBinary() + _ = yym37 + if false { + } else { + *((*string)(yyv36)) = r.DecodeString() + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv38 := &x.Name + yym39 := z.DecBinary() + _ = yym39 + if false { + } else { + *((*string)(yyv38)) = r.DecodeString() + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv40 := &x.Type + yym41 := z.DecBinary() + _ = yym41 + if false { + } else { + *((*string)(yyv40)) = r.DecodeString() + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Priority = 0 + } else { + yyv42 := &x.Priority + yym43 := z.DecBinary() + _ = yym43 + if false { + } else { + *((*int)(yyv42)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Periodic = false + } else { + yyv44 := &x.Periodic + yym45 := z.DecBinary() + _ = yym45 + if false { + } else { + *((*bool)(yyv44)) = r.DecodeBool() + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ParameterizedJob = false + } else { + yyv46 := &x.ParameterizedJob + yym47 := z.DecBinary() + _ = yym47 + if false { + } else { + *((*bool)(yyv46)) = r.DecodeBool() + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Stop = false + } else { + yyv48 := &x.Stop + yym49 := z.DecBinary() + _ = yym49 + if false { + } else { + *((*bool)(yyv48)) = r.DecodeBool() + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv50 := &x.Status + yym51 := z.DecBinary() + _ = yym51 + if false { + } else { + *((*string)(yyv50)) = r.DecodeString() + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.StatusDescription = "" + } else { + yyv52 := &x.StatusDescription + yym53 := z.DecBinary() + _ = yym53 + if false { + } else { + *((*string)(yyv52)) = r.DecodeString() + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.JobSummary != nil { + x.JobSummary = nil + } + } else { + if x.JobSummary == nil { + x.JobSummary = new(JobSummary) + } + x.JobSummary.CodecDecodeSelf(d) + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv55 := &x.CreateIndex + yym56 := z.DecBinary() + _ = yym56 + if false { + } else { + *((*uint64)(yyv55)) = uint64(r.DecodeUint(64)) + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv57 := &x.ModifyIndex + yym58 := z.DecBinary() + _ = yym58 + if false { + } else { + *((*uint64)(yyv57)) = uint64(r.DecodeUint(64)) + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobModifyIndex = 0 + } else { + yyv59 := &x.JobModifyIndex + yym60 := z.DecBinary() + _ = yym60 + if false { + } else { + *((*uint64)(yyv59)) = uint64(r.DecodeUint(64)) + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.SubmitTime = 0 + } else { + yyv61 := &x.SubmitTime + yym62 := z.DecBinary() + _ = yym62 + if false { + } else { + *((*int64)(yyv61)) = int64(r.DecodeInt(64)) + } + } + for { + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj33-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobSummary) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) + } else { + yynn2 = 6 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Summary == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + h.encMapstringTaskGroupSummary((map[string]TaskGroupSummary)(x.Summary), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Summary")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Summary == nil { + r.EncodeNil() + } else { + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + h.encMapstringTaskGroupSummary((map[string]TaskGroupSummary)(x.Summary), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Children == nil { + r.EncodeNil() + } else { + x.Children.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Children")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Children == nil { + r.EncodeNil() + } else { + x.Children.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobSummary) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobSummary) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "JobID": + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv4 := &x.JobID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv6 := &x.Namespace + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Summary": + if r.TryDecodeAsNil() { + x.Summary = nil + } else { + yyv8 := &x.Summary + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + h.decMapstringTaskGroupSummary((*map[string]TaskGroupSummary)(yyv8), d) + } + } + case "Children": + if r.TryDecodeAsNil() { + if x.Children != nil { + x.Children = nil + } + } else { + if x.Children == nil { + x.Children = new(JobChildrenSummary) + } + x.Children.CodecDecodeSelf(d) + } + case "CreateIndex": + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv11 := &x.CreateIndex + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*uint64)(yyv11)) = uint64(r.DecodeUint(64)) + } + } + case "ModifyIndex": + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv13 := &x.ModifyIndex + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobSummary) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj15 int + var yyb15 bool + var yyhl15 bool = l >= 0 + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv16 := &x.JobID + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv18 := &x.Namespace + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Summary = nil + } else { + yyv20 := &x.Summary + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + h.decMapstringTaskGroupSummary((*map[string]TaskGroupSummary)(yyv20), d) + } + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Children != nil { + x.Children = nil + } + } else { + if x.Children == nil { + x.Children = new(JobChildrenSummary) + } + x.Children.CodecDecodeSelf(d) + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv23 := &x.CreateIndex + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) + } + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv25 := &x.ModifyIndex + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*uint64)(yyv25)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj15-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *JobChildrenSummary) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 3 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeInt(int64(x.Pending)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Pending")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeInt(int64(x.Pending)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeInt(int64(x.Running)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Running")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeInt(int64(x.Running)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeInt(int64(x.Dead)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Dead")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeInt(int64(x.Dead)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *JobChildrenSummary) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *JobChildrenSummary) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Pending": + if r.TryDecodeAsNil() { + x.Pending = 0 + } else { + yyv4 := &x.Pending + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int64)(yyv4)) = int64(r.DecodeInt(64)) + } + } + case "Running": + if r.TryDecodeAsNil() { + x.Running = 0 + } else { + yyv6 := &x.Running + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int64)(yyv6)) = int64(r.DecodeInt(64)) + } + } + case "Dead": + if r.TryDecodeAsNil() { + x.Dead = 0 + } else { + yyv8 := &x.Dead + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int64)(yyv8)) = int64(r.DecodeInt(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *JobChildrenSummary) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Pending = 0 + } else { + yyv11 := &x.Pending + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*int64)(yyv11)) = int64(r.DecodeInt(64)) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Running = 0 + } else { + yyv13 := &x.Running + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*int64)(yyv13)) = int64(r.DecodeInt(64)) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Dead = 0 + } else { + yyv15 := &x.Dead + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*int64)(yyv15)) = int64(r.DecodeInt(64)) + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *TaskGroupSummary) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) + } else { + yynn2 = 6 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeInt(int64(x.Queued)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Queued")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeInt(int64(x.Queued)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeInt(int64(x.Complete)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Complete")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeInt(int64(x.Complete)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeInt(int64(x.Failed)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Failed")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeInt(int64(x.Failed)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeInt(int64(x.Running)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Running")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeInt(int64(x.Running)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeInt(int64(x.Starting)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Starting")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeInt(int64(x.Starting)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeInt(int64(x.Lost)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Lost")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeInt(int64(x.Lost)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *TaskGroupSummary) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *TaskGroupSummary) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Queued": + if r.TryDecodeAsNil() { + x.Queued = 0 + } else { + yyv4 := &x.Queued + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int)(yyv4)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "Complete": + if r.TryDecodeAsNil() { + x.Complete = 0 + } else { + yyv6 := &x.Complete + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int)(yyv6)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "Failed": + if r.TryDecodeAsNil() { + x.Failed = 0 + } else { + yyv8 := &x.Failed + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int)(yyv8)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "Running": + if r.TryDecodeAsNil() { + x.Running = 0 + } else { + yyv10 := &x.Running + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*int)(yyv10)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "Starting": + if r.TryDecodeAsNil() { + x.Starting = 0 + } else { + yyv12 := &x.Starting + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*int)(yyv12)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "Lost": + if r.TryDecodeAsNil() { + x.Lost = 0 + } else { + yyv14 := &x.Lost + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*int)(yyv14)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *TaskGroupSummary) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj16 int + var yyb16 bool + var yyhl16 bool = l >= 0 + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Queued = 0 + } else { + yyv17 := &x.Queued + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*int)(yyv17)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Complete = 0 + } else { + yyv19 := &x.Complete + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*int)(yyv19)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Failed = 0 + } else { + yyv21 := &x.Failed + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*int)(yyv21)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Running = 0 + } else { + yyv23 := &x.Running + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*int)(yyv23)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Starting = 0 + } else { + yyv25 := &x.Starting + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*int)(yyv25)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Lost = 0 + } else { + yyv27 := &x.Lost + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*int)(yyv27)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + for { + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj16-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *UpdateStrategy) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [7]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(7) + } else { + yynn2 = 7 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else if z.HasExtensions() && z.EncExt(x.Stagger) { + } else { + r.EncodeInt(int64(x.Stagger)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Stagger")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.EncExt(x.Stagger) { + } else { + r.EncodeInt(int64(x.Stagger)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeInt(int64(x.MaxParallel)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxParallel")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeInt(int64(x.MaxParallel)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.HealthCheck)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("HealthCheck")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.HealthCheck)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(x.MinHealthyTime) { + } else { + r.EncodeInt(int64(x.MinHealthyTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinHealthyTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.EncExt(x.MinHealthyTime) { + } else { + r.EncodeInt(int64(x.MinHealthyTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(x.HealthyDeadline) { + } else { + r.EncodeInt(int64(x.HealthyDeadline)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("HealthyDeadline")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.EncExt(x.HealthyDeadline) { + } else { + r.EncodeInt(int64(x.HealthyDeadline)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeBool(bool(x.AutoRevert)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AutoRevert")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeBool(bool(x.AutoRevert)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeInt(int64(x.Canary)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Canary")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeInt(int64(x.Canary)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *UpdateStrategy) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *UpdateStrategy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Stagger": + if r.TryDecodeAsNil() { + x.Stagger = 0 + } else { + yyv4 := &x.Stagger + yym5 := z.DecBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.DecExt(yyv4) { + } else { + *((*int64)(yyv4)) = int64(r.DecodeInt(64)) + } + } + case "MaxParallel": + if r.TryDecodeAsNil() { + x.MaxParallel = 0 + } else { + yyv6 := &x.MaxParallel + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int)(yyv6)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "HealthCheck": + if r.TryDecodeAsNil() { + x.HealthCheck = "" + } else { + yyv8 := &x.HealthCheck + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "MinHealthyTime": + if r.TryDecodeAsNil() { + x.MinHealthyTime = 0 + } else { + yyv10 := &x.MinHealthyTime + yym11 := z.DecBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.DecExt(yyv10) { + } else { + *((*int64)(yyv10)) = int64(r.DecodeInt(64)) + } + } + case "HealthyDeadline": + if r.TryDecodeAsNil() { + x.HealthyDeadline = 0 + } else { + yyv12 := &x.HealthyDeadline + yym13 := z.DecBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.DecExt(yyv12) { + } else { + *((*int64)(yyv12)) = int64(r.DecodeInt(64)) + } + } + case "AutoRevert": + if r.TryDecodeAsNil() { + x.AutoRevert = false + } else { + yyv14 := &x.AutoRevert + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + case "Canary": + if r.TryDecodeAsNil() { + x.Canary = 0 + } else { + yyv16 := &x.Canary + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*int)(yyv16)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *UpdateStrategy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj18 int + var yyb18 bool + var yyhl18 bool = l >= 0 + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Stagger = 0 + } else { + yyv19 := &x.Stagger + yym20 := z.DecBinary() + _ = yym20 + if false { + } else if z.HasExtensions() && z.DecExt(yyv19) { + } else { + *((*int64)(yyv19)) = int64(r.DecodeInt(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxParallel = 0 + } else { + yyv21 := &x.MaxParallel + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*int)(yyv21)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.HealthCheck = "" + } else { + yyv23 := &x.HealthCheck + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinHealthyTime = 0 + } else { + yyv25 := &x.MinHealthyTime + yym26 := z.DecBinary() + _ = yym26 + if false { + } else if z.HasExtensions() && z.DecExt(yyv25) { + } else { + *((*int64)(yyv25)) = int64(r.DecodeInt(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.HealthyDeadline = 0 + } else { + yyv27 := &x.HealthyDeadline + yym28 := z.DecBinary() + _ = yym28 + if false { + } else if z.HasExtensions() && z.DecExt(yyv27) { + } else { + *((*int64)(yyv27)) = int64(r.DecodeInt(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AutoRevert = false + } else { + yyv29 := &x.AutoRevert + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*bool)(yyv29)) = r.DecodeBool() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Canary = 0 + } else { + yyv31 := &x.Canary + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*int)(yyv31)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + for { + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj18-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *PeriodicConfig) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 5 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeBool(bool(x.Enabled)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Enabled")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeBool(bool(x.Enabled)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Spec)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Spec")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Spec)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.SpecType)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("SpecType")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.SpecType)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.ProhibitOverlap)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ProhibitOverlap")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.ProhibitOverlap)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.TimeZone)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("TimeZone")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.TimeZone)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *PeriodicConfig) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *PeriodicConfig) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Enabled": + if r.TryDecodeAsNil() { + x.Enabled = false + } else { + yyv4 := &x.Enabled + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*bool)(yyv4)) = r.DecodeBool() + } + } + case "Spec": + if r.TryDecodeAsNil() { + x.Spec = "" + } else { + yyv6 := &x.Spec + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "SpecType": + if r.TryDecodeAsNil() { + x.SpecType = "" + } else { + yyv8 := &x.SpecType + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "ProhibitOverlap": + if r.TryDecodeAsNil() { + x.ProhibitOverlap = false + } else { + yyv10 := &x.ProhibitOverlap + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } + } + case "TimeZone": + if r.TryDecodeAsNil() { + x.TimeZone = "" + } else { + yyv12 := &x.TimeZone + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *PeriodicConfig) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Enabled = false + } else { + yyv15 := &x.Enabled + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*bool)(yyv15)) = r.DecodeBool() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Spec = "" + } else { + yyv17 := &x.Spec + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.SpecType = "" + } else { + yyv19 := &x.SpecType + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ProhibitOverlap = false + } else { + yyv21 := &x.ProhibitOverlap + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*bool)(yyv21)) = r.DecodeBool() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.TimeZone = "" + } else { + yyv23 := &x.TimeZone + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + for { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj14-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *PeriodicLaunch) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 5 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yy10 := &x.Launch + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if yym12 := z.TimeRtidIfBinc(); yym12 != 0 { + r.EncodeBuiltin(yym12, yy10) + } else if z.HasExtensions() && z.EncExt(yy10) { + } else if yym11 { + z.EncBinaryMarshal(yy10) + } else if !yym11 && z.IsJSONHandle() { + z.EncJSONMarshal(yy10) + } else { + z.EncFallback(yy10) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Launch")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yy13 := &x.Launch + yym14 := z.EncBinary() + _ = yym14 + if false { + } else if yym15 := z.TimeRtidIfBinc(); yym15 != 0 { + r.EncodeBuiltin(yym15, yy13) + } else if z.HasExtensions() && z.EncExt(yy13) { + } else if yym14 { + z.EncBinaryMarshal(yy13) + } else if !yym14 && z.IsJSONHandle() { + z.EncJSONMarshal(yy13) + } else { + z.EncFallback(yy13) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym18 := z.EncBinary() + _ = yym18 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym21 := z.EncBinary() + _ = yym21 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *PeriodicLaunch) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *PeriodicLaunch) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "ID": + if r.TryDecodeAsNil() { + x.ID = "" + } else { + yyv4 := &x.ID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv6 := &x.Namespace + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Launch": + if r.TryDecodeAsNil() { + x.Launch = time.Time{} + } else { + yyv8 := &x.Launch + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if yym10 := z.TimeRtidIfBinc(); yym10 != 0 { + r.DecodeBuiltin(yym10, yyv8) + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else if yym9 { + z.DecBinaryUnmarshal(yyv8) + } else if !yym9 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv8) + } else { + z.DecFallback(yyv8, false) + } + } + case "CreateIndex": + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv11 := &x.CreateIndex + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*uint64)(yyv11)) = uint64(r.DecodeUint(64)) + } + } + case "ModifyIndex": + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv13 := &x.ModifyIndex + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *PeriodicLaunch) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj15 int + var yyb15 bool + var yyhl15 bool = l >= 0 + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ID = "" + } else { + yyv16 := &x.ID + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv18 := &x.Namespace + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Launch = time.Time{} + } else { + yyv20 := &x.Launch + yym21 := z.DecBinary() + _ = yym21 + if false { + } else if yym22 := z.TimeRtidIfBinc(); yym22 != 0 { + r.DecodeBuiltin(yym22, yyv20) + } else if z.HasExtensions() && z.DecExt(yyv20) { + } else if yym21 { + z.DecBinaryUnmarshal(yyv20) + } else if !yym21 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv20) + } else { + z.DecFallback(yyv20, false) + } + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv23 := &x.CreateIndex + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) + } + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv25 := &x.ModifyIndex + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*uint64)(yyv25)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj15-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ParameterizedJobConfig) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 3 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Payload)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Payload")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Payload)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.MetaRequired == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + z.F.EncSliceStringV(x.MetaRequired, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MetaRequired")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.MetaRequired == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + z.F.EncSliceStringV(x.MetaRequired, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.MetaOptional == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + z.F.EncSliceStringV(x.MetaOptional, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MetaOptional")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.MetaOptional == nil { + r.EncodeNil() + } else { + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + z.F.EncSliceStringV(x.MetaOptional, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ParameterizedJobConfig) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ParameterizedJobConfig) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Payload": + if r.TryDecodeAsNil() { + x.Payload = "" + } else { + yyv4 := &x.Payload + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "MetaRequired": + if r.TryDecodeAsNil() { + x.MetaRequired = nil + } else { + yyv6 := &x.MetaRequired + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + z.F.DecSliceStringX(yyv6, false, d) + } + } + case "MetaOptional": + if r.TryDecodeAsNil() { + x.MetaOptional = nil + } else { + yyv8 := &x.MetaOptional + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + z.F.DecSliceStringX(yyv8, false, d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ParameterizedJobConfig) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Payload = "" + } else { + yyv11 := &x.Payload + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MetaRequired = nil + } else { + yyv13 := &x.MetaRequired + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + z.F.DecSliceStringX(yyv13, false, d) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MetaOptional = nil + } else { + yyv15 := &x.MetaOptional + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + z.F.DecSliceStringX(yyv15, false, d) + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *DispatchPayloadConfig) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(1) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.File)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("File")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.File)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *DispatchPayloadConfig) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *DispatchPayloadConfig) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "File": + if r.TryDecodeAsNil() { + x.File = "" + } else { + yyv4 := &x.File + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *DispatchPayloadConfig) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + 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 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.File = "" + } else { + yyv7 := &x.File + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*string)(yyv7)) = r.DecodeString() + } + } + for { + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj6-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *RestartPolicy) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeInt(int64(x.Attempts)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Attempts")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeInt(int64(x.Attempts)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.EncExt(x.Interval) { + } else { + r.EncodeInt(int64(x.Interval)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Interval")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.EncExt(x.Interval) { + } else { + r.EncodeInt(int64(x.Interval)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.Delay) { + } else { + r.EncodeInt(int64(x.Delay)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Delay")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.Delay) { + } else { + r.EncodeInt(int64(x.Delay)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Mode)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Mode")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Mode)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *RestartPolicy) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *RestartPolicy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Attempts": + if r.TryDecodeAsNil() { + x.Attempts = 0 + } else { + yyv4 := &x.Attempts + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int)(yyv4)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "Interval": + if r.TryDecodeAsNil() { + x.Interval = 0 + } else { + yyv6 := &x.Interval + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else { + *((*int64)(yyv6)) = int64(r.DecodeInt(64)) + } + } + case "Delay": + if r.TryDecodeAsNil() { + x.Delay = 0 + } else { + yyv8 := &x.Delay + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + *((*int64)(yyv8)) = int64(r.DecodeInt(64)) + } + } + case "Mode": + if r.TryDecodeAsNil() { + x.Mode = "" + } else { + yyv10 := &x.Mode + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *RestartPolicy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Attempts = 0 + } else { + yyv13 := &x.Attempts + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*int)(yyv13)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Interval = 0 + } else { + yyv15 := &x.Interval + yym16 := z.DecBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.DecExt(yyv15) { + } else { + *((*int64)(yyv15)) = int64(r.DecodeInt(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Delay = 0 + } else { + yyv17 := &x.Delay + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + *((*int64)(yyv17)) = int64(r.DecodeInt(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Mode = "" + } else { + yyv19 := &x.Mode + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *TaskGroup) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(8) + } else { + yynn2 = 8 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Name")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeInt(int64(x.Count)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Count")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeInt(int64(x.Count)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Update == nil { + r.EncodeNil() + } else { + x.Update.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Update")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Update == nil { + r.EncodeNil() + } else { + x.Update.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Constraints == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + h.encSlicePtrtoConstraint(([]*Constraint)(x.Constraints), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Constraints")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Constraints == nil { + r.EncodeNil() + } else { + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + h.encSlicePtrtoConstraint(([]*Constraint)(x.Constraints), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.RestartPolicy == nil { + r.EncodeNil() + } else { + x.RestartPolicy.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("RestartPolicy")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.RestartPolicy == nil { + r.EncodeNil() + } else { + x.RestartPolicy.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Tasks == nil { + r.EncodeNil() + } else { + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + h.encSlicePtrtoTask(([]*Task)(x.Tasks), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Tasks")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Tasks == nil { + r.EncodeNil() + } else { + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + h.encSlicePtrtoTask(([]*Task)(x.Tasks), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.EphemeralDisk == nil { + r.EncodeNil() + } else { + x.EphemeralDisk.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EphemeralDisk")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.EphemeralDisk == nil { + r.EncodeNil() + } else { + x.EphemeralDisk.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Meta == nil { + r.EncodeNil() + } else { + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + z.F.EncMapStringStringV(x.Meta, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Meta")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Meta == nil { + r.EncodeNil() + } else { + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + z.F.EncMapStringStringV(x.Meta, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *TaskGroup) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *TaskGroup) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Count": + if r.TryDecodeAsNil() { + x.Count = 0 + } else { + yyv6 := &x.Count + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int)(yyv6)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "Update": + if r.TryDecodeAsNil() { + if x.Update != nil { + x.Update = nil + } + } else { + if x.Update == nil { + x.Update = new(UpdateStrategy) + } + x.Update.CodecDecodeSelf(d) + } + case "Constraints": + if r.TryDecodeAsNil() { + x.Constraints = nil + } else { + yyv9 := &x.Constraints + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + h.decSlicePtrtoConstraint((*[]*Constraint)(yyv9), d) + } + } + case "RestartPolicy": + if r.TryDecodeAsNil() { + if x.RestartPolicy != nil { + x.RestartPolicy = nil + } + } else { + if x.RestartPolicy == nil { + x.RestartPolicy = new(RestartPolicy) + } + x.RestartPolicy.CodecDecodeSelf(d) + } + case "Tasks": + if r.TryDecodeAsNil() { + x.Tasks = nil + } else { + yyv12 := &x.Tasks + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + h.decSlicePtrtoTask((*[]*Task)(yyv12), d) + } + } + case "EphemeralDisk": + if r.TryDecodeAsNil() { + if x.EphemeralDisk != nil { + x.EphemeralDisk = nil + } + } else { + if x.EphemeralDisk == nil { + x.EphemeralDisk = new(EphemeralDisk) + } + x.EphemeralDisk.CodecDecodeSelf(d) + } + case "Meta": + if r.TryDecodeAsNil() { + x.Meta = nil + } else { + yyv15 := &x.Meta + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + z.F.DecMapStringStringX(yyv15, false, d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *TaskGroup) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj17 int + var yyb17 bool + var yyhl17 bool = l >= 0 + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv18 := &x.Name + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Count = 0 + } else { + yyv20 := &x.Count + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*int)(yyv20)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Update != nil { + x.Update = nil + } + } else { + if x.Update == nil { + x.Update = new(UpdateStrategy) + } + x.Update.CodecDecodeSelf(d) + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Constraints = nil + } else { + yyv23 := &x.Constraints + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + h.decSlicePtrtoConstraint((*[]*Constraint)(yyv23), d) + } + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.RestartPolicy != nil { + x.RestartPolicy = nil + } + } else { + if x.RestartPolicy == nil { + x.RestartPolicy = new(RestartPolicy) + } + x.RestartPolicy.CodecDecodeSelf(d) + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Tasks = nil + } else { + yyv26 := &x.Tasks + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + h.decSlicePtrtoTask((*[]*Task)(yyv26), d) + } + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.EphemeralDisk != nil { + x.EphemeralDisk = nil + } + } else { + if x.EphemeralDisk == nil { + x.EphemeralDisk = new(EphemeralDisk) + } + x.EphemeralDisk.CodecDecodeSelf(d) + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Meta = nil + } else { + yyv29 := &x.Meta + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + z.F.DecMapStringStringX(yyv29, false, d) + } + } + for { + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj17-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *CheckRestart) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 3 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeInt(int64(x.Limit)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Limit")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeInt(int64(x.Limit)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.EncExt(x.Grace) { + } else { + r.EncodeInt(int64(x.Grace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Grace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.EncExt(x.Grace) { + } else { + r.EncodeInt(int64(x.Grace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeBool(bool(x.IgnoreWarnings)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("IgnoreWarnings")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeBool(bool(x.IgnoreWarnings)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *CheckRestart) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *CheckRestart) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Limit": + if r.TryDecodeAsNil() { + x.Limit = 0 + } else { + yyv4 := &x.Limit + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int)(yyv4)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "Grace": + if r.TryDecodeAsNil() { + x.Grace = 0 + } else { + yyv6 := &x.Grace + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else { + *((*int64)(yyv6)) = int64(r.DecodeInt(64)) + } + } + case "IgnoreWarnings": + if r.TryDecodeAsNil() { + x.IgnoreWarnings = false + } else { + yyv8 := &x.IgnoreWarnings + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*bool)(yyv8)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *CheckRestart) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Limit = 0 + } else { + yyv11 := &x.Limit + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*int)(yyv11)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Grace = 0 + } else { + yyv13 := &x.Grace + yym14 := z.DecBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.DecExt(yyv13) { + } else { + *((*int64)(yyv13)) = int64(r.DecodeInt(64)) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.IgnoreWarnings = false + } else { + yyv15 := &x.IgnoreWarnings + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*bool)(yyv15)) = r.DecodeBool() + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ServiceCheck) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [15]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(15) + } else { + yynn2 = 15 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Name")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Type)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Type")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Type)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Command)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Command")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Command)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Args == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + z.F.EncSliceStringV(x.Args, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Args")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Args == nil { + r.EncodeNil() + } else { + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + z.F.EncSliceStringV(x.Args, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Path)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Path")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Path)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Protocol)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Protocol")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Protocol)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.PortLabel)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("PortLabel")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.PortLabel)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AddressMode)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AddressMode")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AddressMode)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym28 := z.EncBinary() + _ = yym28 + if false { + } else if z.HasExtensions() && z.EncExt(x.Interval) { + } else { + r.EncodeInt(int64(x.Interval)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Interval")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym29 := z.EncBinary() + _ = yym29 + if false { + } else if z.HasExtensions() && z.EncExt(x.Interval) { + } else { + r.EncodeInt(int64(x.Interval)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym31 := z.EncBinary() + _ = yym31 + if false { + } else if z.HasExtensions() && z.EncExt(x.Timeout) { + } else { + r.EncodeInt(int64(x.Timeout)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Timeout")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym32 := z.EncBinary() + _ = yym32 + if false { + } else if z.HasExtensions() && z.EncExt(x.Timeout) { + } else { + r.EncodeInt(int64(x.Timeout)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym34 := z.EncBinary() + _ = yym34 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.InitialStatus)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("InitialStatus")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym35 := z.EncBinary() + _ = yym35 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.InitialStatus)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym37 := z.EncBinary() + _ = yym37 + if false { + } else { + r.EncodeBool(bool(x.TLSSkipVerify)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("TLSSkipVerify")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym38 := z.EncBinary() + _ = yym38 + if false { + } else { + r.EncodeBool(bool(x.TLSSkipVerify)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym40 := z.EncBinary() + _ = yym40 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Method)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Method")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym41 := z.EncBinary() + _ = yym41 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Method)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Header == nil { + r.EncodeNil() + } else { + yym43 := z.EncBinary() + _ = yym43 + if false { + } else { + h.encMapstringSlicestring((map[string][]string)(x.Header), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Header")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Header == nil { + r.EncodeNil() + } else { + yym44 := z.EncBinary() + _ = yym44 + if false { + } else { + h.encMapstringSlicestring((map[string][]string)(x.Header), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.CheckRestart == nil { + r.EncodeNil() + } else { + x.CheckRestart.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CheckRestart")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.CheckRestart == nil { + r.EncodeNil() + } else { + x.CheckRestart.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ServiceCheck) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ServiceCheck) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Type": + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv6 := &x.Type + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Command": + if r.TryDecodeAsNil() { + x.Command = "" + } else { + yyv8 := &x.Command + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Args": + if r.TryDecodeAsNil() { + x.Args = nil + } else { + yyv10 := &x.Args + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + z.F.DecSliceStringX(yyv10, false, d) + } + } + case "Path": + if r.TryDecodeAsNil() { + x.Path = "" + } else { + yyv12 := &x.Path + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + case "Protocol": + if r.TryDecodeAsNil() { + x.Protocol = "" + } else { + yyv14 := &x.Protocol + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + case "PortLabel": + if r.TryDecodeAsNil() { + x.PortLabel = "" + } else { + yyv16 := &x.PortLabel + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + case "AddressMode": + if r.TryDecodeAsNil() { + x.AddressMode = "" + } else { + yyv18 := &x.AddressMode + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + case "Interval": + if r.TryDecodeAsNil() { + x.Interval = 0 + } else { + yyv20 := &x.Interval + yym21 := z.DecBinary() + _ = yym21 + if false { + } else if z.HasExtensions() && z.DecExt(yyv20) { + } else { + *((*int64)(yyv20)) = int64(r.DecodeInt(64)) + } + } + case "Timeout": + if r.TryDecodeAsNil() { + x.Timeout = 0 + } else { + yyv22 := &x.Timeout + yym23 := z.DecBinary() + _ = yym23 + if false { + } else if z.HasExtensions() && z.DecExt(yyv22) { + } else { + *((*int64)(yyv22)) = int64(r.DecodeInt(64)) + } + } + case "InitialStatus": + if r.TryDecodeAsNil() { + x.InitialStatus = "" + } else { + yyv24 := &x.InitialStatus + yym25 := z.DecBinary() + _ = yym25 + if false { + } else { + *((*string)(yyv24)) = r.DecodeString() + } + } + case "TLSSkipVerify": + if r.TryDecodeAsNil() { + x.TLSSkipVerify = false + } else { + yyv26 := &x.TLSSkipVerify + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + *((*bool)(yyv26)) = r.DecodeBool() + } + } + case "Method": + if r.TryDecodeAsNil() { + x.Method = "" + } else { + yyv28 := &x.Method + yym29 := z.DecBinary() + _ = yym29 + if false { + } else { + *((*string)(yyv28)) = r.DecodeString() + } + } + case "Header": + if r.TryDecodeAsNil() { + x.Header = nil + } else { + yyv30 := &x.Header + yym31 := z.DecBinary() + _ = yym31 + if false { + } else { + h.decMapstringSlicestring((*map[string][]string)(yyv30), d) + } + } + case "CheckRestart": + if r.TryDecodeAsNil() { + if x.CheckRestart != nil { + x.CheckRestart = nil + } + } else { + if x.CheckRestart == nil { + x.CheckRestart = new(CheckRestart) + } + x.CheckRestart.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ServiceCheck) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj33 int + var yyb33 bool + var yyhl33 bool = l >= 0 + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv34 := &x.Name + yym35 := z.DecBinary() + _ = yym35 + if false { + } else { + *((*string)(yyv34)) = r.DecodeString() + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv36 := &x.Type + yym37 := z.DecBinary() + _ = yym37 + if false { + } else { + *((*string)(yyv36)) = r.DecodeString() + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Command = "" + } else { + yyv38 := &x.Command + yym39 := z.DecBinary() + _ = yym39 + if false { + } else { + *((*string)(yyv38)) = r.DecodeString() + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Args = nil + } else { + yyv40 := &x.Args + yym41 := z.DecBinary() + _ = yym41 + if false { + } else { + z.F.DecSliceStringX(yyv40, false, d) + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Path = "" + } else { + yyv42 := &x.Path + yym43 := z.DecBinary() + _ = yym43 + if false { + } else { + *((*string)(yyv42)) = r.DecodeString() + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Protocol = "" + } else { + yyv44 := &x.Protocol + yym45 := z.DecBinary() + _ = yym45 + if false { + } else { + *((*string)(yyv44)) = r.DecodeString() + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.PortLabel = "" + } else { + yyv46 := &x.PortLabel + yym47 := z.DecBinary() + _ = yym47 + if false { + } else { + *((*string)(yyv46)) = r.DecodeString() + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AddressMode = "" + } else { + yyv48 := &x.AddressMode + yym49 := z.DecBinary() + _ = yym49 + if false { + } else { + *((*string)(yyv48)) = r.DecodeString() + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Interval = 0 + } else { + yyv50 := &x.Interval + yym51 := z.DecBinary() + _ = yym51 + if false { + } else if z.HasExtensions() && z.DecExt(yyv50) { + } else { + *((*int64)(yyv50)) = int64(r.DecodeInt(64)) + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Timeout = 0 + } else { + yyv52 := &x.Timeout + yym53 := z.DecBinary() + _ = yym53 + if false { + } else if z.HasExtensions() && z.DecExt(yyv52) { + } else { + *((*int64)(yyv52)) = int64(r.DecodeInt(64)) + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.InitialStatus = "" + } else { + yyv54 := &x.InitialStatus + yym55 := z.DecBinary() + _ = yym55 + if false { + } else { + *((*string)(yyv54)) = r.DecodeString() + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.TLSSkipVerify = false + } else { + yyv56 := &x.TLSSkipVerify + yym57 := z.DecBinary() + _ = yym57 + if false { + } else { + *((*bool)(yyv56)) = r.DecodeBool() + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Method = "" + } else { + yyv58 := &x.Method + yym59 := z.DecBinary() + _ = yym59 + if false { + } else { + *((*string)(yyv58)) = r.DecodeString() + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Header = nil + } else { + yyv60 := &x.Header + yym61 := z.DecBinary() + _ = yym61 + if false { + } else { + h.decMapstringSlicestring((*map[string][]string)(yyv60), d) + } + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.CheckRestart != nil { + x.CheckRestart = nil + } + } else { + if x.CheckRestart == nil { + x.CheckRestart = new(CheckRestart) + } + x.CheckRestart.CodecDecodeSelf(d) + } + for { + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj33-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *Service) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 5 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Name")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.PortLabel)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("PortLabel")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.PortLabel)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AddressMode)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AddressMode")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AddressMode)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Tags == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + z.F.EncSliceStringV(x.Tags, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Tags")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Tags == nil { + r.EncodeNil() + } else { + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + z.F.EncSliceStringV(x.Tags, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Checks == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSlicePtrtoServiceCheck(([]*ServiceCheck)(x.Checks), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Checks")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Checks == nil { + r.EncodeNil() + } else { + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + h.encSlicePtrtoServiceCheck(([]*ServiceCheck)(x.Checks), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *Service) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *Service) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "PortLabel": + if r.TryDecodeAsNil() { + x.PortLabel = "" + } else { + yyv6 := &x.PortLabel + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "AddressMode": + if r.TryDecodeAsNil() { + x.AddressMode = "" + } else { + yyv8 := &x.AddressMode + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Tags": + if r.TryDecodeAsNil() { + x.Tags = nil + } else { + yyv10 := &x.Tags + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + z.F.DecSliceStringX(yyv10, false, d) + } + } + case "Checks": + if r.TryDecodeAsNil() { + x.Checks = nil + } else { + yyv12 := &x.Checks + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + h.decSlicePtrtoServiceCheck((*[]*ServiceCheck)(yyv12), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *Service) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv15 := &x.Name + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.PortLabel = "" + } else { + yyv17 := &x.PortLabel + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AddressMode = "" + } else { + yyv19 := &x.AddressMode + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Tags = nil + } else { + yyv21 := &x.Tags + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + z.F.DecSliceStringX(yyv21, false, d) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Checks = nil + } else { + yyv23 := &x.Checks + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + h.decSlicePtrtoServiceCheck((*[]*ServiceCheck)(yyv23), d) + } + } + for { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj14-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *LogConfig) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeInt(int64(x.MaxFiles)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxFiles")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeInt(int64(x.MaxFiles)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeInt(int64(x.MaxFileSizeMB)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxFileSizeMB")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeInt(int64(x.MaxFileSizeMB)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *LogConfig) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *LogConfig) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "MaxFiles": + if r.TryDecodeAsNil() { + x.MaxFiles = 0 + } else { + yyv4 := &x.MaxFiles + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int)(yyv4)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "MaxFileSizeMB": + if r.TryDecodeAsNil() { + x.MaxFileSizeMB = 0 + } else { + yyv6 := &x.MaxFileSizeMB + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int)(yyv6)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *LogConfig) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxFiles = 0 + } else { + yyv9 := &x.MaxFiles + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*int)(yyv9)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxFileSizeMB = 0 + } else { + yyv11 := &x.MaxFileSizeMB + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*int)(yyv11)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *Task) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [18]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(18) + } else { + yynn2 = 18 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Name")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Driver)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Driver")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Driver)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.User)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("User")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.User)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Config == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + z.F.EncMapStringIntfV(x.Config, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Config")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Config == nil { + r.EncodeNil() + } else { + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + z.F.EncMapStringIntfV(x.Config, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Env == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + z.F.EncMapStringStringV(x.Env, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Env")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Env == nil { + r.EncodeNil() + } else { + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + z.F.EncMapStringStringV(x.Env, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Services == nil { + r.EncodeNil() + } else { + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + h.encSlicePtrtoService(([]*Service)(x.Services), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Services")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Services == nil { + r.EncodeNil() + } else { + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + h.encSlicePtrtoService(([]*Service)(x.Services), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Vault == nil { + r.EncodeNil() + } else { + x.Vault.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Vault")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Vault == nil { + r.EncodeNil() + } else { + x.Vault.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Templates == nil { + r.EncodeNil() + } else { + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + h.encSlicePtrtoTemplate(([]*Template)(x.Templates), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Templates")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Templates == nil { + r.EncodeNil() + } else { + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + h.encSlicePtrtoTemplate(([]*Template)(x.Templates), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Constraints == nil { + r.EncodeNil() + } else { + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + h.encSlicePtrtoConstraint(([]*Constraint)(x.Constraints), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Constraints")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Constraints == nil { + r.EncodeNil() + } else { + yym29 := z.EncBinary() + _ = yym29 + if false { + } else { + h.encSlicePtrtoConstraint(([]*Constraint)(x.Constraints), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Resources == nil { + r.EncodeNil() + } else { + x.Resources.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Resources")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Resources == nil { + r.EncodeNil() + } else { + x.Resources.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.DispatchPayload == nil { + r.EncodeNil() + } else { + x.DispatchPayload.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DispatchPayload")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.DispatchPayload == nil { + r.EncodeNil() + } else { + x.DispatchPayload.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Meta == nil { + r.EncodeNil() + } else { + yym37 := z.EncBinary() + _ = yym37 + if false { + } else { + z.F.EncMapStringStringV(x.Meta, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Meta")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Meta == nil { + r.EncodeNil() + } else { + yym38 := z.EncBinary() + _ = yym38 + if false { + } else { + z.F.EncMapStringStringV(x.Meta, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym40 := z.EncBinary() + _ = yym40 + if false { + } else if z.HasExtensions() && z.EncExt(x.KillTimeout) { + } else { + r.EncodeInt(int64(x.KillTimeout)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KillTimeout")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym41 := z.EncBinary() + _ = yym41 + if false { + } else if z.HasExtensions() && z.EncExt(x.KillTimeout) { + } else { + r.EncodeInt(int64(x.KillTimeout)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.LogConfig == nil { + r.EncodeNil() + } else { + x.LogConfig.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LogConfig")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.LogConfig == nil { + r.EncodeNil() + } else { + x.LogConfig.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Artifacts == nil { + r.EncodeNil() + } else { + yym46 := z.EncBinary() + _ = yym46 + if false { + } else { + h.encSlicePtrtoTaskArtifact(([]*TaskArtifact)(x.Artifacts), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Artifacts")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Artifacts == nil { + r.EncodeNil() + } else { + yym47 := z.EncBinary() + _ = yym47 + if false { + } else { + h.encSlicePtrtoTaskArtifact(([]*TaskArtifact)(x.Artifacts), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym49 := z.EncBinary() + _ = yym49 + if false { + } else { + r.EncodeBool(bool(x.Leader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Leader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym50 := z.EncBinary() + _ = yym50 + if false { + } else { + r.EncodeBool(bool(x.Leader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym52 := z.EncBinary() + _ = yym52 + if false { + } else if z.HasExtensions() && z.EncExt(x.ShutdownDelay) { + } else { + r.EncodeInt(int64(x.ShutdownDelay)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ShutdownDelay")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym53 := z.EncBinary() + _ = yym53 + if false { + } else if z.HasExtensions() && z.EncExt(x.ShutdownDelay) { + } else { + r.EncodeInt(int64(x.ShutdownDelay)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym55 := z.EncBinary() + _ = yym55 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.KillSignal)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KillSignal")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym56 := z.EncBinary() + _ = yym56 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.KillSignal)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *Task) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *Task) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Driver": + if r.TryDecodeAsNil() { + x.Driver = "" + } else { + yyv6 := &x.Driver + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "User": + if r.TryDecodeAsNil() { + x.User = "" + } else { + yyv8 := &x.User + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Config": + if r.TryDecodeAsNil() { + x.Config = nil + } else { + yyv10 := &x.Config + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + z.F.DecMapStringIntfX(yyv10, false, d) + } + } + case "Env": + if r.TryDecodeAsNil() { + x.Env = nil + } else { + yyv12 := &x.Env + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + z.F.DecMapStringStringX(yyv12, false, d) + } + } + case "Services": + if r.TryDecodeAsNil() { + x.Services = nil + } else { + yyv14 := &x.Services + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + h.decSlicePtrtoService((*[]*Service)(yyv14), d) + } + } + case "Vault": + if r.TryDecodeAsNil() { + if x.Vault != nil { + x.Vault = nil + } + } else { + if x.Vault == nil { + x.Vault = new(Vault) + } + x.Vault.CodecDecodeSelf(d) + } + case "Templates": + if r.TryDecodeAsNil() { + x.Templates = nil + } else { + yyv17 := &x.Templates + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + h.decSlicePtrtoTemplate((*[]*Template)(yyv17), d) + } + } + case "Constraints": + if r.TryDecodeAsNil() { + x.Constraints = nil + } else { + yyv19 := &x.Constraints + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSlicePtrtoConstraint((*[]*Constraint)(yyv19), d) + } + } + case "Resources": + if r.TryDecodeAsNil() { + if x.Resources != nil { + x.Resources = nil + } + } else { + if x.Resources == nil { + x.Resources = new(Resources) + } + x.Resources.CodecDecodeSelf(d) + } + case "DispatchPayload": + if r.TryDecodeAsNil() { + if x.DispatchPayload != nil { + x.DispatchPayload = nil + } + } else { + if x.DispatchPayload == nil { + x.DispatchPayload = new(DispatchPayloadConfig) + } + x.DispatchPayload.CodecDecodeSelf(d) + } + case "Meta": + if r.TryDecodeAsNil() { + x.Meta = nil + } else { + yyv23 := &x.Meta + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + z.F.DecMapStringStringX(yyv23, false, d) + } + } + case "KillTimeout": + if r.TryDecodeAsNil() { + x.KillTimeout = 0 + } else { + yyv25 := &x.KillTimeout + yym26 := z.DecBinary() + _ = yym26 + if false { + } else if z.HasExtensions() && z.DecExt(yyv25) { + } else { + *((*int64)(yyv25)) = int64(r.DecodeInt(64)) + } + } + case "LogConfig": + if r.TryDecodeAsNil() { + if x.LogConfig != nil { + x.LogConfig = nil + } + } else { + if x.LogConfig == nil { + x.LogConfig = new(LogConfig) + } + x.LogConfig.CodecDecodeSelf(d) + } + case "Artifacts": + if r.TryDecodeAsNil() { + x.Artifacts = nil + } else { + yyv28 := &x.Artifacts + yym29 := z.DecBinary() + _ = yym29 + if false { + } else { + h.decSlicePtrtoTaskArtifact((*[]*TaskArtifact)(yyv28), d) + } + } + case "Leader": + if r.TryDecodeAsNil() { + x.Leader = false + } else { + yyv30 := &x.Leader + yym31 := z.DecBinary() + _ = yym31 + if false { + } else { + *((*bool)(yyv30)) = r.DecodeBool() + } + } + case "ShutdownDelay": + if r.TryDecodeAsNil() { + x.ShutdownDelay = 0 + } else { + yyv32 := &x.ShutdownDelay + yym33 := z.DecBinary() + _ = yym33 + if false { + } else if z.HasExtensions() && z.DecExt(yyv32) { + } else { + *((*int64)(yyv32)) = int64(r.DecodeInt(64)) + } + } + case "KillSignal": + if r.TryDecodeAsNil() { + x.KillSignal = "" + } else { + yyv34 := &x.KillSignal + yym35 := z.DecBinary() + _ = yym35 + if false { + } else { + *((*string)(yyv34)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *Task) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj36 int + var yyb36 bool + var yyhl36 bool = l >= 0 + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l + } else { + yyb36 = r.CheckBreak() + } + if yyb36 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv37 := &x.Name + yym38 := z.DecBinary() + _ = yym38 + if false { + } else { + *((*string)(yyv37)) = r.DecodeString() + } + } + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l + } else { + yyb36 = r.CheckBreak() + } + if yyb36 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Driver = "" + } else { + yyv39 := &x.Driver + yym40 := z.DecBinary() + _ = yym40 + if false { + } else { + *((*string)(yyv39)) = r.DecodeString() + } + } + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l + } else { + yyb36 = r.CheckBreak() + } + if yyb36 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.User = "" + } else { + yyv41 := &x.User + yym42 := z.DecBinary() + _ = yym42 + if false { + } else { + *((*string)(yyv41)) = r.DecodeString() + } + } + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l + } else { + yyb36 = r.CheckBreak() + } + if yyb36 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Config = nil + } else { + yyv43 := &x.Config + yym44 := z.DecBinary() + _ = yym44 + if false { + } else { + z.F.DecMapStringIntfX(yyv43, false, d) + } + } + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l + } else { + yyb36 = r.CheckBreak() + } + if yyb36 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Env = nil + } else { + yyv45 := &x.Env + yym46 := z.DecBinary() + _ = yym46 + if false { + } else { + z.F.DecMapStringStringX(yyv45, false, d) + } + } + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l + } else { + yyb36 = r.CheckBreak() + } + if yyb36 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Services = nil + } else { + yyv47 := &x.Services + yym48 := z.DecBinary() + _ = yym48 + if false { + } else { + h.decSlicePtrtoService((*[]*Service)(yyv47), d) + } + } + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l + } else { + yyb36 = r.CheckBreak() + } + if yyb36 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Vault != nil { + x.Vault = nil + } + } else { + if x.Vault == nil { + x.Vault = new(Vault) + } + x.Vault.CodecDecodeSelf(d) + } + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l + } else { + yyb36 = r.CheckBreak() + } + if yyb36 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Templates = nil + } else { + yyv50 := &x.Templates + yym51 := z.DecBinary() + _ = yym51 + if false { + } else { + h.decSlicePtrtoTemplate((*[]*Template)(yyv50), d) + } + } + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l + } else { + yyb36 = r.CheckBreak() + } + if yyb36 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Constraints = nil + } else { + yyv52 := &x.Constraints + yym53 := z.DecBinary() + _ = yym53 + if false { + } else { + h.decSlicePtrtoConstraint((*[]*Constraint)(yyv52), d) + } + } + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l + } else { + yyb36 = r.CheckBreak() + } + if yyb36 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Resources != nil { + x.Resources = nil + } + } else { + if x.Resources == nil { + x.Resources = new(Resources) + } + x.Resources.CodecDecodeSelf(d) + } + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l + } else { + yyb36 = r.CheckBreak() + } + if yyb36 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.DispatchPayload != nil { + x.DispatchPayload = nil + } + } else { + if x.DispatchPayload == nil { + x.DispatchPayload = new(DispatchPayloadConfig) + } + x.DispatchPayload.CodecDecodeSelf(d) + } + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l + } else { + yyb36 = r.CheckBreak() + } + if yyb36 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Meta = nil + } else { + yyv56 := &x.Meta + yym57 := z.DecBinary() + _ = yym57 + if false { + } else { + z.F.DecMapStringStringX(yyv56, false, d) + } + } + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l + } else { + yyb36 = r.CheckBreak() + } + if yyb36 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KillTimeout = 0 + } else { + yyv58 := &x.KillTimeout + yym59 := z.DecBinary() + _ = yym59 + if false { + } else if z.HasExtensions() && z.DecExt(yyv58) { + } else { + *((*int64)(yyv58)) = int64(r.DecodeInt(64)) + } + } + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l + } else { + yyb36 = r.CheckBreak() + } + if yyb36 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.LogConfig != nil { + x.LogConfig = nil + } + } else { + if x.LogConfig == nil { + x.LogConfig = new(LogConfig) + } + x.LogConfig.CodecDecodeSelf(d) + } + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l + } else { + yyb36 = r.CheckBreak() + } + if yyb36 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Artifacts = nil + } else { + yyv61 := &x.Artifacts + yym62 := z.DecBinary() + _ = yym62 + if false { + } else { + h.decSlicePtrtoTaskArtifact((*[]*TaskArtifact)(yyv61), d) + } + } + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l + } else { + yyb36 = r.CheckBreak() + } + if yyb36 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Leader = false + } else { + yyv63 := &x.Leader + yym64 := z.DecBinary() + _ = yym64 + if false { + } else { + *((*bool)(yyv63)) = r.DecodeBool() + } + } + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l + } else { + yyb36 = r.CheckBreak() + } + if yyb36 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ShutdownDelay = 0 + } else { + yyv65 := &x.ShutdownDelay + yym66 := z.DecBinary() + _ = yym66 + if false { + } else if z.HasExtensions() && z.DecExt(yyv65) { + } else { + *((*int64)(yyv65)) = int64(r.DecodeInt(64)) + } + } + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l + } else { + yyb36 = r.CheckBreak() + } + if yyb36 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KillSignal = "" + } else { + yyv67 := &x.KillSignal + yym68 := z.DecBinary() + _ = yym68 + if false { + } else { + *((*string)(yyv67)) = r.DecodeString() + } + } + for { + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l + } else { + yyb36 = r.CheckBreak() + } + if yyb36 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj36-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *Template) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [11]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(11) + } else { + yynn2 = 11 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.SourcePath)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("SourcePath")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.SourcePath)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DestPath)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DestPath")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DestPath)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EmbeddedTmpl)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EmbeddedTmpl")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EmbeddedTmpl)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ChangeMode)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ChangeMode")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ChangeMode)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ChangeSignal)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ChangeSignal")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ChangeSignal)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else if z.HasExtensions() && z.EncExt(x.Splay) { + } else { + r.EncodeInt(int64(x.Splay)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Splay")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else if z.HasExtensions() && z.EncExt(x.Splay) { + } else { + r.EncodeInt(int64(x.Splay)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Perms)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Perms")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Perms)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.LeftDelim)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LeftDelim")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.LeftDelim)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.RightDelim)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("RightDelim")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym29 := z.EncBinary() + _ = yym29 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.RightDelim)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym31 := z.EncBinary() + _ = yym31 + if false { + } else { + r.EncodeBool(bool(x.Envvars)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Envvars")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym32 := z.EncBinary() + _ = yym32 + if false { + } else { + r.EncodeBool(bool(x.Envvars)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym34 := z.EncBinary() + _ = yym34 + if false { + } else if z.HasExtensions() && z.EncExt(x.VaultGrace) { + } else { + r.EncodeInt(int64(x.VaultGrace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("VaultGrace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym35 := z.EncBinary() + _ = yym35 + if false { + } else if z.HasExtensions() && z.EncExt(x.VaultGrace) { + } else { + r.EncodeInt(int64(x.VaultGrace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *Template) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *Template) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "SourcePath": + if r.TryDecodeAsNil() { + x.SourcePath = "" + } else { + yyv4 := &x.SourcePath + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "DestPath": + if r.TryDecodeAsNil() { + x.DestPath = "" + } else { + yyv6 := &x.DestPath + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "EmbeddedTmpl": + if r.TryDecodeAsNil() { + x.EmbeddedTmpl = "" + } else { + yyv8 := &x.EmbeddedTmpl + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "ChangeMode": + if r.TryDecodeAsNil() { + x.ChangeMode = "" + } else { + yyv10 := &x.ChangeMode + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "ChangeSignal": + if r.TryDecodeAsNil() { + x.ChangeSignal = "" + } else { + yyv12 := &x.ChangeSignal + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + case "Splay": + if r.TryDecodeAsNil() { + x.Splay = 0 + } else { + yyv14 := &x.Splay + yym15 := z.DecBinary() + _ = yym15 + if false { + } else if z.HasExtensions() && z.DecExt(yyv14) { + } else { + *((*int64)(yyv14)) = int64(r.DecodeInt(64)) + } + } + case "Perms": + if r.TryDecodeAsNil() { + x.Perms = "" + } else { + yyv16 := &x.Perms + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + case "LeftDelim": + if r.TryDecodeAsNil() { + x.LeftDelim = "" + } else { + yyv18 := &x.LeftDelim + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + case "RightDelim": + if r.TryDecodeAsNil() { + x.RightDelim = "" + } else { + yyv20 := &x.RightDelim + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*string)(yyv20)) = r.DecodeString() + } + } + case "Envvars": + if r.TryDecodeAsNil() { + x.Envvars = false + } else { + yyv22 := &x.Envvars + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + *((*bool)(yyv22)) = r.DecodeBool() + } + } + case "VaultGrace": + if r.TryDecodeAsNil() { + x.VaultGrace = 0 + } else { + yyv24 := &x.VaultGrace + yym25 := z.DecBinary() + _ = yym25 + if false { + } else if z.HasExtensions() && z.DecExt(yyv24) { + } else { + *((*int64)(yyv24)) = int64(r.DecodeInt(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *Template) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj26 int + var yyb26 bool + var yyhl26 bool = l >= 0 + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.SourcePath = "" + } else { + yyv27 := &x.SourcePath + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DestPath = "" + } else { + yyv29 := &x.DestPath + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EmbeddedTmpl = "" + } else { + yyv31 := &x.EmbeddedTmpl + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ChangeMode = "" + } else { + yyv33 := &x.ChangeMode + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*string)(yyv33)) = r.DecodeString() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ChangeSignal = "" + } else { + yyv35 := &x.ChangeSignal + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*string)(yyv35)) = r.DecodeString() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Splay = 0 + } else { + yyv37 := &x.Splay + yym38 := z.DecBinary() + _ = yym38 + if false { + } else if z.HasExtensions() && z.DecExt(yyv37) { + } else { + *((*int64)(yyv37)) = int64(r.DecodeInt(64)) + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Perms = "" + } else { + yyv39 := &x.Perms + yym40 := z.DecBinary() + _ = yym40 + if false { + } else { + *((*string)(yyv39)) = r.DecodeString() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LeftDelim = "" + } else { + yyv41 := &x.LeftDelim + yym42 := z.DecBinary() + _ = yym42 + if false { + } else { + *((*string)(yyv41)) = r.DecodeString() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.RightDelim = "" + } else { + yyv43 := &x.RightDelim + yym44 := z.DecBinary() + _ = yym44 + if false { + } else { + *((*string)(yyv43)) = r.DecodeString() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Envvars = false + } else { + yyv45 := &x.Envvars + yym46 := z.DecBinary() + _ = yym46 + if false { + } else { + *((*bool)(yyv45)) = r.DecodeBool() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.VaultGrace = 0 + } else { + yyv47 := &x.VaultGrace + yym48 := z.DecBinary() + _ = yym48 + if false { + } else if z.HasExtensions() && z.DecExt(yyv47) { + } else { + *((*int64)(yyv47)) = int64(r.DecodeInt(64)) + } + } + for { + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj26-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *TaskState) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [7]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(7) + } else { + yynn2 = 7 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.State)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("State")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.State)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeBool(bool(x.Failed)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Failed")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeBool(bool(x.Failed)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.Restarts)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Restarts")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.Restarts)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yy13 := &x.LastRestart + yym14 := z.EncBinary() + _ = yym14 + if false { + } else if yym15 := z.TimeRtidIfBinc(); yym15 != 0 { + r.EncodeBuiltin(yym15, yy13) + } else if z.HasExtensions() && z.EncExt(yy13) { + } else if yym14 { + z.EncBinaryMarshal(yy13) + } else if !yym14 && z.IsJSONHandle() { + z.EncJSONMarshal(yy13) + } else { + z.EncFallback(yy13) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastRestart")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yy16 := &x.LastRestart + yym17 := z.EncBinary() + _ = yym17 + if false { + } else if yym18 := z.TimeRtidIfBinc(); yym18 != 0 { + r.EncodeBuiltin(yym18, yy16) + } else if z.HasExtensions() && z.EncExt(yy16) { + } else if yym17 { + z.EncBinaryMarshal(yy16) + } else if !yym17 && z.IsJSONHandle() { + z.EncJSONMarshal(yy16) + } else { + z.EncFallback(yy16) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yy20 := &x.StartedAt + yym21 := z.EncBinary() + _ = yym21 + if false { + } else if yym22 := z.TimeRtidIfBinc(); yym22 != 0 { + r.EncodeBuiltin(yym22, yy20) + } else if z.HasExtensions() && z.EncExt(yy20) { + } else if yym21 { + z.EncBinaryMarshal(yy20) + } else if !yym21 && z.IsJSONHandle() { + z.EncJSONMarshal(yy20) + } else { + z.EncFallback(yy20) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("StartedAt")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yy23 := &x.StartedAt + yym24 := z.EncBinary() + _ = yym24 + if false { + } else if yym25 := z.TimeRtidIfBinc(); yym25 != 0 { + r.EncodeBuiltin(yym25, yy23) + } else if z.HasExtensions() && z.EncExt(yy23) { + } else if yym24 { + z.EncBinaryMarshal(yy23) + } else if !yym24 && z.IsJSONHandle() { + z.EncJSONMarshal(yy23) + } else { + z.EncFallback(yy23) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yy27 := &x.FinishedAt + yym28 := z.EncBinary() + _ = yym28 + if false { + } else if yym29 := z.TimeRtidIfBinc(); yym29 != 0 { + r.EncodeBuiltin(yym29, yy27) + } else if z.HasExtensions() && z.EncExt(yy27) { + } else if yym28 { + z.EncBinaryMarshal(yy27) + } else if !yym28 && z.IsJSONHandle() { + z.EncJSONMarshal(yy27) + } else { + z.EncFallback(yy27) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("FinishedAt")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yy30 := &x.FinishedAt + yym31 := z.EncBinary() + _ = yym31 + if false { + } else if yym32 := z.TimeRtidIfBinc(); yym32 != 0 { + r.EncodeBuiltin(yym32, yy30) + } else if z.HasExtensions() && z.EncExt(yy30) { + } else if yym31 { + z.EncBinaryMarshal(yy30) + } else if !yym31 && z.IsJSONHandle() { + z.EncJSONMarshal(yy30) + } else { + z.EncFallback(yy30) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Events == nil { + r.EncodeNil() + } else { + yym34 := z.EncBinary() + _ = yym34 + if false { + } else { + h.encSlicePtrtoTaskEvent(([]*TaskEvent)(x.Events), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Events")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Events == nil { + r.EncodeNil() + } else { + yym35 := z.EncBinary() + _ = yym35 + if false { + } else { + h.encSlicePtrtoTaskEvent(([]*TaskEvent)(x.Events), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *TaskState) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *TaskState) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "State": + if r.TryDecodeAsNil() { + x.State = "" + } else { + yyv4 := &x.State + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Failed": + if r.TryDecodeAsNil() { + x.Failed = false + } else { + yyv6 := &x.Failed + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*bool)(yyv6)) = r.DecodeBool() + } + } + case "Restarts": + if r.TryDecodeAsNil() { + x.Restarts = 0 + } else { + yyv8 := &x.Restarts + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) + } + } + case "LastRestart": + if r.TryDecodeAsNil() { + x.LastRestart = time.Time{} + } else { + yyv10 := &x.LastRestart + yym11 := z.DecBinary() + _ = yym11 + if false { + } else if yym12 := z.TimeRtidIfBinc(); yym12 != 0 { + r.DecodeBuiltin(yym12, yyv10) + } else if z.HasExtensions() && z.DecExt(yyv10) { + } else if yym11 { + z.DecBinaryUnmarshal(yyv10) + } else if !yym11 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv10) + } else { + z.DecFallback(yyv10, false) + } + } + case "StartedAt": + if r.TryDecodeAsNil() { + x.StartedAt = time.Time{} + } else { + yyv13 := &x.StartedAt + yym14 := z.DecBinary() + _ = yym14 + if false { + } else if yym15 := z.TimeRtidIfBinc(); yym15 != 0 { + r.DecodeBuiltin(yym15, yyv13) + } else if z.HasExtensions() && z.DecExt(yyv13) { + } else if yym14 { + z.DecBinaryUnmarshal(yyv13) + } else if !yym14 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv13) + } else { + z.DecFallback(yyv13, false) + } + } + case "FinishedAt": + if r.TryDecodeAsNil() { + x.FinishedAt = time.Time{} + } else { + yyv16 := &x.FinishedAt + yym17 := z.DecBinary() + _ = yym17 + if false { + } else if yym18 := z.TimeRtidIfBinc(); yym18 != 0 { + r.DecodeBuiltin(yym18, yyv16) + } else if z.HasExtensions() && z.DecExt(yyv16) { + } else if yym17 { + z.DecBinaryUnmarshal(yyv16) + } else if !yym17 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv16) + } else { + z.DecFallback(yyv16, false) + } + } + case "Events": + if r.TryDecodeAsNil() { + x.Events = nil + } else { + yyv19 := &x.Events + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSlicePtrtoTaskEvent((*[]*TaskEvent)(yyv19), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *TaskState) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj21 int + var yyb21 bool + var yyhl21 bool = l >= 0 + yyj21++ + if yyhl21 { + yyb21 = yyj21 > l + } else { + yyb21 = r.CheckBreak() + } + if yyb21 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.State = "" + } else { + yyv22 := &x.State + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + *((*string)(yyv22)) = r.DecodeString() + } + } + yyj21++ + if yyhl21 { + yyb21 = yyj21 > l + } else { + yyb21 = r.CheckBreak() + } + if yyb21 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Failed = false + } else { + yyv24 := &x.Failed + yym25 := z.DecBinary() + _ = yym25 + if false { + } else { + *((*bool)(yyv24)) = r.DecodeBool() + } + } + yyj21++ + if yyhl21 { + yyb21 = yyj21 > l + } else { + yyb21 = r.CheckBreak() + } + if yyb21 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Restarts = 0 + } else { + yyv26 := &x.Restarts + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + *((*uint64)(yyv26)) = uint64(r.DecodeUint(64)) + } + } + yyj21++ + if yyhl21 { + yyb21 = yyj21 > l + } else { + yyb21 = r.CheckBreak() + } + if yyb21 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastRestart = time.Time{} + } else { + yyv28 := &x.LastRestart + yym29 := z.DecBinary() + _ = yym29 + if false { + } else if yym30 := z.TimeRtidIfBinc(); yym30 != 0 { + r.DecodeBuiltin(yym30, yyv28) + } else if z.HasExtensions() && z.DecExt(yyv28) { + } else if yym29 { + z.DecBinaryUnmarshal(yyv28) + } else if !yym29 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv28) + } else { + z.DecFallback(yyv28, false) + } + } + yyj21++ + if yyhl21 { + yyb21 = yyj21 > l + } else { + yyb21 = r.CheckBreak() + } + if yyb21 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.StartedAt = time.Time{} + } else { + yyv31 := &x.StartedAt + yym32 := z.DecBinary() + _ = yym32 + if false { + } else if yym33 := z.TimeRtidIfBinc(); yym33 != 0 { + r.DecodeBuiltin(yym33, yyv31) + } else if z.HasExtensions() && z.DecExt(yyv31) { + } else if yym32 { + z.DecBinaryUnmarshal(yyv31) + } else if !yym32 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv31) + } else { + z.DecFallback(yyv31, false) + } + } + yyj21++ + if yyhl21 { + yyb21 = yyj21 > l + } else { + yyb21 = r.CheckBreak() + } + if yyb21 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.FinishedAt = time.Time{} + } else { + yyv34 := &x.FinishedAt + yym35 := z.DecBinary() + _ = yym35 + if false { + } else if yym36 := z.TimeRtidIfBinc(); yym36 != 0 { + r.DecodeBuiltin(yym36, yyv34) + } else if z.HasExtensions() && z.DecExt(yyv34) { + } else if yym35 { + z.DecBinaryUnmarshal(yyv34) + } else if !yym35 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv34) + } else { + z.DecFallback(yyv34, false) + } + } + yyj21++ + if yyhl21 { + yyb21 = yyj21 > l + } else { + yyb21 = r.CheckBreak() + } + if yyb21 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Events = nil + } else { + yyv37 := &x.Events + yym38 := z.DecBinary() + _ = yym38 + if false { + } else { + h.decSlicePtrtoTaskEvent((*[]*TaskEvent)(yyv37), d) + } + } + for { + yyj21++ + if yyhl21 { + yyb21 = yyj21 > l + } else { + yyb21 = r.CheckBreak() + } + if yyb21 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj21-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *TaskEvent) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [24]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(24) + } else { + yynn2 = 24 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Type)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Type")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Type)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeInt(int64(x.Time)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Time")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeInt(int64(x.Time)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Message)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Message")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Message)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DisplayMessage)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DisplayMessage")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DisplayMessage)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Details == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + z.F.EncMapStringStringV(x.Details, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Details")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Details == nil { + r.EncodeNil() + } else { + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + z.F.EncMapStringStringV(x.Details, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeBool(bool(x.FailsTask)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("FailsTask")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeBool(bool(x.FailsTask)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.RestartReason)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("RestartReason")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.RestartReason)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.SetupError)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("SetupError")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.SetupError)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DriverError)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DriverError")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym29 := z.EncBinary() + _ = yym29 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DriverError)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym31 := z.EncBinary() + _ = yym31 + if false { + } else { + r.EncodeInt(int64(x.ExitCode)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ExitCode")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym32 := z.EncBinary() + _ = yym32 + if false { + } else { + r.EncodeInt(int64(x.ExitCode)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym34 := z.EncBinary() + _ = yym34 + if false { + } else { + r.EncodeInt(int64(x.Signal)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Signal")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym35 := z.EncBinary() + _ = yym35 + if false { + } else { + r.EncodeInt(int64(x.Signal)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym37 := z.EncBinary() + _ = yym37 + if false { + } else if z.HasExtensions() && z.EncExt(x.KillTimeout) { + } else { + r.EncodeInt(int64(x.KillTimeout)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KillTimeout")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym38 := z.EncBinary() + _ = yym38 + if false { + } else if z.HasExtensions() && z.EncExt(x.KillTimeout) { + } else { + r.EncodeInt(int64(x.KillTimeout)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym40 := z.EncBinary() + _ = yym40 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.KillError)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KillError")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym41 := z.EncBinary() + _ = yym41 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.KillError)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym43 := z.EncBinary() + _ = yym43 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.KillReason)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KillReason")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym44 := z.EncBinary() + _ = yym44 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.KillReason)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym46 := z.EncBinary() + _ = yym46 + if false { + } else { + r.EncodeInt(int64(x.StartDelay)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("StartDelay")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym47 := z.EncBinary() + _ = yym47 + if false { + } else { + r.EncodeInt(int64(x.StartDelay)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym49 := z.EncBinary() + _ = yym49 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DownloadError)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DownloadError")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym50 := z.EncBinary() + _ = yym50 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DownloadError)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym52 := z.EncBinary() + _ = yym52 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ValidationError)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ValidationError")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym53 := z.EncBinary() + _ = yym53 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ValidationError)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym55 := z.EncBinary() + _ = yym55 + if false { + } else { + r.EncodeInt(int64(x.DiskLimit)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DiskLimit")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym56 := z.EncBinary() + _ = yym56 + if false { + } else { + r.EncodeInt(int64(x.DiskLimit)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym58 := z.EncBinary() + _ = yym58 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.FailedSibling)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("FailedSibling")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym59 := z.EncBinary() + _ = yym59 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.FailedSibling)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym61 := z.EncBinary() + _ = yym61 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.VaultError)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("VaultError")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym62 := z.EncBinary() + _ = yym62 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.VaultError)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym64 := z.EncBinary() + _ = yym64 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.TaskSignalReason)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("TaskSignalReason")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym65 := z.EncBinary() + _ = yym65 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.TaskSignalReason)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym67 := z.EncBinary() + _ = yym67 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.TaskSignal)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("TaskSignal")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym68 := z.EncBinary() + _ = yym68 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.TaskSignal)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym70 := z.EncBinary() + _ = yym70 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DriverMessage)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DriverMessage")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym71 := z.EncBinary() + _ = yym71 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DriverMessage)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym73 := z.EncBinary() + _ = yym73 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.GenericSource)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("GenericSource")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym74 := z.EncBinary() + _ = yym74 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.GenericSource)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *TaskEvent) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *TaskEvent) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Type": + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv4 := &x.Type + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Time": + if r.TryDecodeAsNil() { + x.Time = 0 + } else { + yyv6 := &x.Time + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int64)(yyv6)) = int64(r.DecodeInt(64)) + } + } + case "Message": + if r.TryDecodeAsNil() { + x.Message = "" + } else { + yyv8 := &x.Message + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "DisplayMessage": + if r.TryDecodeAsNil() { + x.DisplayMessage = "" + } else { + yyv10 := &x.DisplayMessage + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "Details": + if r.TryDecodeAsNil() { + x.Details = nil + } else { + yyv12 := &x.Details + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + z.F.DecMapStringStringX(yyv12, false, d) + } + } + case "FailsTask": + if r.TryDecodeAsNil() { + x.FailsTask = false + } else { + yyv14 := &x.FailsTask + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + case "RestartReason": + if r.TryDecodeAsNil() { + x.RestartReason = "" + } else { + yyv16 := &x.RestartReason + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + case "SetupError": + if r.TryDecodeAsNil() { + x.SetupError = "" + } else { + yyv18 := &x.SetupError + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + case "DriverError": + if r.TryDecodeAsNil() { + x.DriverError = "" + } else { + yyv20 := &x.DriverError + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*string)(yyv20)) = r.DecodeString() + } + } + case "ExitCode": + if r.TryDecodeAsNil() { + x.ExitCode = 0 + } else { + yyv22 := &x.ExitCode + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + *((*int)(yyv22)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "Signal": + if r.TryDecodeAsNil() { + x.Signal = 0 + } else { + yyv24 := &x.Signal + yym25 := z.DecBinary() + _ = yym25 + if false { + } else { + *((*int)(yyv24)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "KillTimeout": + if r.TryDecodeAsNil() { + x.KillTimeout = 0 + } else { + yyv26 := &x.KillTimeout + yym27 := z.DecBinary() + _ = yym27 + if false { + } else if z.HasExtensions() && z.DecExt(yyv26) { + } else { + *((*int64)(yyv26)) = int64(r.DecodeInt(64)) + } + } + case "KillError": + if r.TryDecodeAsNil() { + x.KillError = "" + } else { + yyv28 := &x.KillError + yym29 := z.DecBinary() + _ = yym29 + if false { + } else { + *((*string)(yyv28)) = r.DecodeString() + } + } + case "KillReason": + if r.TryDecodeAsNil() { + x.KillReason = "" + } else { + yyv30 := &x.KillReason + yym31 := z.DecBinary() + _ = yym31 + if false { + } else { + *((*string)(yyv30)) = r.DecodeString() + } + } + case "StartDelay": + if r.TryDecodeAsNil() { + x.StartDelay = 0 + } else { + yyv32 := &x.StartDelay + yym33 := z.DecBinary() + _ = yym33 + if false { + } else { + *((*int64)(yyv32)) = int64(r.DecodeInt(64)) + } + } + case "DownloadError": + if r.TryDecodeAsNil() { + x.DownloadError = "" + } else { + yyv34 := &x.DownloadError + yym35 := z.DecBinary() + _ = yym35 + if false { + } else { + *((*string)(yyv34)) = r.DecodeString() + } + } + case "ValidationError": + if r.TryDecodeAsNil() { + x.ValidationError = "" + } else { + yyv36 := &x.ValidationError + yym37 := z.DecBinary() + _ = yym37 + if false { + } else { + *((*string)(yyv36)) = r.DecodeString() + } + } + case "DiskLimit": + if r.TryDecodeAsNil() { + x.DiskLimit = 0 + } else { + yyv38 := &x.DiskLimit + yym39 := z.DecBinary() + _ = yym39 + if false { + } else { + *((*int64)(yyv38)) = int64(r.DecodeInt(64)) + } + } + case "FailedSibling": + if r.TryDecodeAsNil() { + x.FailedSibling = "" + } else { + yyv40 := &x.FailedSibling + yym41 := z.DecBinary() + _ = yym41 + if false { + } else { + *((*string)(yyv40)) = r.DecodeString() + } + } + case "VaultError": + if r.TryDecodeAsNil() { + x.VaultError = "" + } else { + yyv42 := &x.VaultError + yym43 := z.DecBinary() + _ = yym43 + if false { + } else { + *((*string)(yyv42)) = r.DecodeString() + } + } + case "TaskSignalReason": + if r.TryDecodeAsNil() { + x.TaskSignalReason = "" + } else { + yyv44 := &x.TaskSignalReason + yym45 := z.DecBinary() + _ = yym45 + if false { + } else { + *((*string)(yyv44)) = r.DecodeString() + } + } + case "TaskSignal": + if r.TryDecodeAsNil() { + x.TaskSignal = "" + } else { + yyv46 := &x.TaskSignal + yym47 := z.DecBinary() + _ = yym47 + if false { + } else { + *((*string)(yyv46)) = r.DecodeString() + } + } + case "DriverMessage": + if r.TryDecodeAsNil() { + x.DriverMessage = "" + } else { + yyv48 := &x.DriverMessage + yym49 := z.DecBinary() + _ = yym49 + if false { + } else { + *((*string)(yyv48)) = r.DecodeString() + } + } + case "GenericSource": + if r.TryDecodeAsNil() { + x.GenericSource = "" + } else { + yyv50 := &x.GenericSource + yym51 := z.DecBinary() + _ = yym51 + if false { + } else { + *((*string)(yyv50)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *TaskEvent) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj52 int + var yyb52 bool + var yyhl52 bool = l >= 0 + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv53 := &x.Type + yym54 := z.DecBinary() + _ = yym54 + if false { + } else { + *((*string)(yyv53)) = r.DecodeString() + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Time = 0 + } else { + yyv55 := &x.Time + yym56 := z.DecBinary() + _ = yym56 + if false { + } else { + *((*int64)(yyv55)) = int64(r.DecodeInt(64)) + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Message = "" + } else { + yyv57 := &x.Message + yym58 := z.DecBinary() + _ = yym58 + if false { + } else { + *((*string)(yyv57)) = r.DecodeString() + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DisplayMessage = "" + } else { + yyv59 := &x.DisplayMessage + yym60 := z.DecBinary() + _ = yym60 + if false { + } else { + *((*string)(yyv59)) = r.DecodeString() + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Details = nil + } else { + yyv61 := &x.Details + yym62 := z.DecBinary() + _ = yym62 + if false { + } else { + z.F.DecMapStringStringX(yyv61, false, d) + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.FailsTask = false + } else { + yyv63 := &x.FailsTask + yym64 := z.DecBinary() + _ = yym64 + if false { + } else { + *((*bool)(yyv63)) = r.DecodeBool() + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.RestartReason = "" + } else { + yyv65 := &x.RestartReason + yym66 := z.DecBinary() + _ = yym66 + if false { + } else { + *((*string)(yyv65)) = r.DecodeString() + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.SetupError = "" + } else { + yyv67 := &x.SetupError + yym68 := z.DecBinary() + _ = yym68 + if false { + } else { + *((*string)(yyv67)) = r.DecodeString() + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DriverError = "" + } else { + yyv69 := &x.DriverError + yym70 := z.DecBinary() + _ = yym70 + if false { + } else { + *((*string)(yyv69)) = r.DecodeString() + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ExitCode = 0 + } else { + yyv71 := &x.ExitCode + yym72 := z.DecBinary() + _ = yym72 + if false { + } else { + *((*int)(yyv71)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Signal = 0 + } else { + yyv73 := &x.Signal + yym74 := z.DecBinary() + _ = yym74 + if false { + } else { + *((*int)(yyv73)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KillTimeout = 0 + } else { + yyv75 := &x.KillTimeout + yym76 := z.DecBinary() + _ = yym76 + if false { + } else if z.HasExtensions() && z.DecExt(yyv75) { + } else { + *((*int64)(yyv75)) = int64(r.DecodeInt(64)) + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KillError = "" + } else { + yyv77 := &x.KillError + yym78 := z.DecBinary() + _ = yym78 + if false { + } else { + *((*string)(yyv77)) = r.DecodeString() + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KillReason = "" + } else { + yyv79 := &x.KillReason + yym80 := z.DecBinary() + _ = yym80 + if false { + } else { + *((*string)(yyv79)) = r.DecodeString() + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.StartDelay = 0 + } else { + yyv81 := &x.StartDelay + yym82 := z.DecBinary() + _ = yym82 + if false { + } else { + *((*int64)(yyv81)) = int64(r.DecodeInt(64)) + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DownloadError = "" + } else { + yyv83 := &x.DownloadError + yym84 := z.DecBinary() + _ = yym84 + if false { + } else { + *((*string)(yyv83)) = r.DecodeString() + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ValidationError = "" + } else { + yyv85 := &x.ValidationError + yym86 := z.DecBinary() + _ = yym86 + if false { + } else { + *((*string)(yyv85)) = r.DecodeString() + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DiskLimit = 0 + } else { + yyv87 := &x.DiskLimit + yym88 := z.DecBinary() + _ = yym88 + if false { + } else { + *((*int64)(yyv87)) = int64(r.DecodeInt(64)) + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.FailedSibling = "" + } else { + yyv89 := &x.FailedSibling + yym90 := z.DecBinary() + _ = yym90 + if false { + } else { + *((*string)(yyv89)) = r.DecodeString() + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.VaultError = "" + } else { + yyv91 := &x.VaultError + yym92 := z.DecBinary() + _ = yym92 + if false { + } else { + *((*string)(yyv91)) = r.DecodeString() + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.TaskSignalReason = "" + } else { + yyv93 := &x.TaskSignalReason + yym94 := z.DecBinary() + _ = yym94 + if false { + } else { + *((*string)(yyv93)) = r.DecodeString() + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.TaskSignal = "" + } else { + yyv95 := &x.TaskSignal + yym96 := z.DecBinary() + _ = yym96 + if false { + } else { + *((*string)(yyv95)) = r.DecodeString() + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DriverMessage = "" + } else { + yyv97 := &x.DriverMessage + yym98 := z.DecBinary() + _ = yym98 + if false { + } else { + *((*string)(yyv97)) = r.DecodeString() + } + } + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.GenericSource = "" + } else { + yyv99 := &x.GenericSource + yym100 := z.DecBinary() + _ = yym100 + if false { + } else { + *((*string)(yyv99)) = r.DecodeString() + } + } + for { + yyj52++ + if yyhl52 { + yyb52 = yyj52 > l + } else { + yyb52 = r.CheckBreak() + } + if yyb52 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj52-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *TaskArtifact) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.GetterSource)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("GetterSource")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.GetterSource)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.GetterOptions == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + z.F.EncMapStringStringV(x.GetterOptions, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("GetterOptions")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.GetterOptions == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + z.F.EncMapStringStringV(x.GetterOptions, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.GetterMode)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("GetterMode")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.GetterMode)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.RelativeDest)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("RelativeDest")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.RelativeDest)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *TaskArtifact) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *TaskArtifact) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "GetterSource": + if r.TryDecodeAsNil() { + x.GetterSource = "" + } else { + yyv4 := &x.GetterSource + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "GetterOptions": + if r.TryDecodeAsNil() { + x.GetterOptions = nil + } else { + yyv6 := &x.GetterOptions + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + z.F.DecMapStringStringX(yyv6, false, d) + } + } + case "GetterMode": + if r.TryDecodeAsNil() { + x.GetterMode = "" + } else { + yyv8 := &x.GetterMode + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "RelativeDest": + if r.TryDecodeAsNil() { + x.RelativeDest = "" + } else { + yyv10 := &x.RelativeDest + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *TaskArtifact) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.GetterSource = "" + } else { + yyv13 := &x.GetterSource + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.GetterOptions = nil + } else { + yyv15 := &x.GetterOptions + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + z.F.DecMapStringStringX(yyv15, false, d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.GetterMode = "" + } else { + yyv17 := &x.GetterMode + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.RelativeDest = "" + } else { + yyv19 := &x.RelativeDest + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *Constraint) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 3 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.LTarget)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LTarget")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.LTarget)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.RTarget)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("RTarget")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.RTarget)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Operand)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Operand")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Operand)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *Constraint) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *Constraint) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "LTarget": + if r.TryDecodeAsNil() { + x.LTarget = "" + } else { + yyv4 := &x.LTarget + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "RTarget": + if r.TryDecodeAsNil() { + x.RTarget = "" + } else { + yyv6 := &x.RTarget + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Operand": + if r.TryDecodeAsNil() { + x.Operand = "" + } else { + yyv8 := &x.Operand + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *Constraint) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LTarget = "" + } else { + yyv11 := &x.LTarget + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.RTarget = "" + } else { + yyv13 := &x.RTarget + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Operand = "" + } else { + yyv15 := &x.Operand + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *EphemeralDisk) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 3 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeBool(bool(x.Sticky)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Sticky")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeBool(bool(x.Sticky)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeInt(int64(x.SizeMB)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("SizeMB")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeInt(int64(x.SizeMB)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeBool(bool(x.Migrate)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Migrate")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeBool(bool(x.Migrate)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *EphemeralDisk) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *EphemeralDisk) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Sticky": + if r.TryDecodeAsNil() { + x.Sticky = false + } else { + yyv4 := &x.Sticky + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*bool)(yyv4)) = r.DecodeBool() + } + } + case "SizeMB": + if r.TryDecodeAsNil() { + x.SizeMB = 0 + } else { + yyv6 := &x.SizeMB + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int)(yyv6)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "Migrate": + if r.TryDecodeAsNil() { + x.Migrate = false + } else { + yyv8 := &x.Migrate + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*bool)(yyv8)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *EphemeralDisk) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Sticky = false + } else { + yyv11 := &x.Sticky + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*bool)(yyv11)) = r.DecodeBool() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.SizeMB = 0 + } else { + yyv13 := &x.SizeMB + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*int)(yyv13)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Migrate = false + } else { + yyv15 := &x.Migrate + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*bool)(yyv15)) = r.DecodeBool() + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *Vault) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Policies == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + z.F.EncSliceStringV(x.Policies, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Policies")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Policies == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + z.F.EncSliceStringV(x.Policies, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeBool(bool(x.Env)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Env")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeBool(bool(x.Env)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ChangeMode)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ChangeMode")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ChangeMode)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ChangeSignal)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ChangeSignal")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ChangeSignal)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *Vault) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *Vault) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Policies": + if r.TryDecodeAsNil() { + x.Policies = nil + } else { + yyv4 := &x.Policies + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + z.F.DecSliceStringX(yyv4, false, d) + } + } + case "Env": + if r.TryDecodeAsNil() { + x.Env = false + } else { + yyv6 := &x.Env + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*bool)(yyv6)) = r.DecodeBool() + } + } + case "ChangeMode": + if r.TryDecodeAsNil() { + x.ChangeMode = "" + } else { + yyv8 := &x.ChangeMode + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "ChangeSignal": + if r.TryDecodeAsNil() { + x.ChangeSignal = "" + } else { + yyv10 := &x.ChangeSignal + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *Vault) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Policies = nil + } else { + yyv13 := &x.Policies + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + z.F.DecSliceStringX(yyv13, false, d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Env = false + } else { + yyv15 := &x.Env + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*bool)(yyv15)) = r.DecodeBool() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ChangeMode = "" + } else { + yyv17 := &x.ChangeMode + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ChangeSignal = "" + } else { + yyv19 := &x.ChangeSignal + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *Deployment) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [11]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(11) + } else { + yynn2 = 11 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeUint(uint64(x.JobVersion)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeUint(uint64(x.JobVersion)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeUint(uint64(x.JobModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeUint(uint64(x.JobModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeUint(uint64(x.JobCreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobCreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeUint(uint64(x.JobCreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.TaskGroups == nil { + r.EncodeNil() + } else { + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + h.encMapstringPtrtoDeploymentState((map[string]*DeploymentState)(x.TaskGroups), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("TaskGroups")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.TaskGroups == nil { + r.EncodeNil() + } else { + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + h.encMapstringPtrtoDeploymentState((map[string]*DeploymentState)(x.TaskGroups), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Status)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Status")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Status)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("StatusDescription")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym29 := z.EncBinary() + _ = yym29 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym31 := z.EncBinary() + _ = yym31 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym32 := z.EncBinary() + _ = yym32 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym34 := z.EncBinary() + _ = yym34 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym35 := z.EncBinary() + _ = yym35 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *Deployment) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *Deployment) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "ID": + if r.TryDecodeAsNil() { + x.ID = "" + } else { + yyv4 := &x.ID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv6 := &x.Namespace + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "JobID": + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv8 := &x.JobID + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "JobVersion": + if r.TryDecodeAsNil() { + x.JobVersion = 0 + } else { + yyv10 := &x.JobVersion + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) + } + } + case "JobModifyIndex": + if r.TryDecodeAsNil() { + x.JobModifyIndex = 0 + } else { + yyv12 := &x.JobModifyIndex + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*uint64)(yyv12)) = uint64(r.DecodeUint(64)) + } + } + case "JobCreateIndex": + if r.TryDecodeAsNil() { + x.JobCreateIndex = 0 + } else { + yyv14 := &x.JobCreateIndex + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*uint64)(yyv14)) = uint64(r.DecodeUint(64)) + } + } + case "TaskGroups": + if r.TryDecodeAsNil() { + x.TaskGroups = nil + } else { + yyv16 := &x.TaskGroups + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + h.decMapstringPtrtoDeploymentState((*map[string]*DeploymentState)(yyv16), d) + } + } + case "Status": + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv18 := &x.Status + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + case "StatusDescription": + if r.TryDecodeAsNil() { + x.StatusDescription = "" + } else { + yyv20 := &x.StatusDescription + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*string)(yyv20)) = r.DecodeString() + } + } + case "CreateIndex": + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv22 := &x.CreateIndex + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + *((*uint64)(yyv22)) = uint64(r.DecodeUint(64)) + } + } + case "ModifyIndex": + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv24 := &x.ModifyIndex + yym25 := z.DecBinary() + _ = yym25 + if false { + } else { + *((*uint64)(yyv24)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *Deployment) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj26 int + var yyb26 bool + var yyhl26 bool = l >= 0 + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ID = "" + } else { + yyv27 := &x.ID + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv29 := &x.Namespace + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv31 := &x.JobID + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobVersion = 0 + } else { + yyv33 := &x.JobVersion + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*uint64)(yyv33)) = uint64(r.DecodeUint(64)) + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobModifyIndex = 0 + } else { + yyv35 := &x.JobModifyIndex + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*uint64)(yyv35)) = uint64(r.DecodeUint(64)) + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobCreateIndex = 0 + } else { + yyv37 := &x.JobCreateIndex + yym38 := z.DecBinary() + _ = yym38 + if false { + } else { + *((*uint64)(yyv37)) = uint64(r.DecodeUint(64)) + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.TaskGroups = nil + } else { + yyv39 := &x.TaskGroups + yym40 := z.DecBinary() + _ = yym40 + if false { + } else { + h.decMapstringPtrtoDeploymentState((*map[string]*DeploymentState)(yyv39), d) + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv41 := &x.Status + yym42 := z.DecBinary() + _ = yym42 + if false { + } else { + *((*string)(yyv41)) = r.DecodeString() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.StatusDescription = "" + } else { + yyv43 := &x.StatusDescription + yym44 := z.DecBinary() + _ = yym44 + if false { + } else { + *((*string)(yyv43)) = r.DecodeString() + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv45 := &x.CreateIndex + yym46 := z.DecBinary() + _ = yym46 + if false { + } else { + *((*uint64)(yyv45)) = uint64(r.DecodeUint(64)) + } + } + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv47 := &x.ModifyIndex + yym48 := z.DecBinary() + _ = yym48 + if false { + } else { + *((*uint64)(yyv47)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj26++ + if yyhl26 { + yyb26 = yyj26 > l + } else { + yyb26 = r.CheckBreak() + } + if yyb26 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj26-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *DeploymentState) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(8) + } else { + yynn2 = 8 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeBool(bool(x.AutoRevert)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AutoRevert")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeBool(bool(x.AutoRevert)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeBool(bool(x.Promoted)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Promoted")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeBool(bool(x.Promoted)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.PlacedCanaries == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + z.F.EncSliceStringV(x.PlacedCanaries, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("PlacedCanaries")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.PlacedCanaries == nil { + r.EncodeNil() + } else { + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + z.F.EncSliceStringV(x.PlacedCanaries, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeInt(int64(x.DesiredCanaries)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DesiredCanaries")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeInt(int64(x.DesiredCanaries)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeInt(int64(x.DesiredTotal)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DesiredTotal")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeInt(int64(x.DesiredTotal)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeInt(int64(x.PlacedAllocs)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("PlacedAllocs")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeInt(int64(x.PlacedAllocs)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeInt(int64(x.HealthyAllocs)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("HealthyAllocs")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeInt(int64(x.HealthyAllocs)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeInt(int64(x.UnhealthyAllocs)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("UnhealthyAllocs")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeInt(int64(x.UnhealthyAllocs)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *DeploymentState) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *DeploymentState) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "AutoRevert": + if r.TryDecodeAsNil() { + x.AutoRevert = false + } else { + yyv4 := &x.AutoRevert + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*bool)(yyv4)) = r.DecodeBool() + } + } + case "Promoted": + if r.TryDecodeAsNil() { + x.Promoted = false + } else { + yyv6 := &x.Promoted + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*bool)(yyv6)) = r.DecodeBool() + } + } + case "PlacedCanaries": + if r.TryDecodeAsNil() { + x.PlacedCanaries = nil + } else { + yyv8 := &x.PlacedCanaries + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + z.F.DecSliceStringX(yyv8, false, d) + } + } + case "DesiredCanaries": + if r.TryDecodeAsNil() { + x.DesiredCanaries = 0 + } else { + yyv10 := &x.DesiredCanaries + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*int)(yyv10)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "DesiredTotal": + if r.TryDecodeAsNil() { + x.DesiredTotal = 0 + } else { + yyv12 := &x.DesiredTotal + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*int)(yyv12)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "PlacedAllocs": + if r.TryDecodeAsNil() { + x.PlacedAllocs = 0 + } else { + yyv14 := &x.PlacedAllocs + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*int)(yyv14)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "HealthyAllocs": + if r.TryDecodeAsNil() { + x.HealthyAllocs = 0 + } else { + yyv16 := &x.HealthyAllocs + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*int)(yyv16)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "UnhealthyAllocs": + if r.TryDecodeAsNil() { + x.UnhealthyAllocs = 0 + } else { + yyv18 := &x.UnhealthyAllocs + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*int)(yyv18)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *DeploymentState) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj20 int + var yyb20 bool + var yyhl20 bool = l >= 0 + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AutoRevert = false + } else { + yyv21 := &x.AutoRevert + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*bool)(yyv21)) = r.DecodeBool() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Promoted = false + } else { + yyv23 := &x.Promoted + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*bool)(yyv23)) = r.DecodeBool() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.PlacedCanaries = nil + } else { + yyv25 := &x.PlacedCanaries + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + z.F.DecSliceStringX(yyv25, false, d) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DesiredCanaries = 0 + } else { + yyv27 := &x.DesiredCanaries + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*int)(yyv27)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DesiredTotal = 0 + } else { + yyv29 := &x.DesiredTotal + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*int)(yyv29)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.PlacedAllocs = 0 + } else { + yyv31 := &x.PlacedAllocs + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*int)(yyv31)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.HealthyAllocs = 0 + } else { + yyv33 := &x.HealthyAllocs + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*int)(yyv33)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.UnhealthyAllocs = 0 + } else { + yyv35 := &x.UnhealthyAllocs + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*int)(yyv35)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + for { + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj20-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *DeploymentStatusUpdate) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 3 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DeploymentID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Status)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Status")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Status)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("StatusDescription")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *DeploymentStatusUpdate) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *DeploymentStatusUpdate) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "DeploymentID": + if r.TryDecodeAsNil() { + x.DeploymentID = "" + } else { + yyv4 := &x.DeploymentID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Status": + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv6 := &x.Status + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "StatusDescription": + if r.TryDecodeAsNil() { + x.StatusDescription = "" + } else { + yyv8 := &x.StatusDescription + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *DeploymentStatusUpdate) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DeploymentID = "" + } else { + yyv11 := &x.DeploymentID + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv13 := &x.Status + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.StatusDescription = "" + } else { + yyv15 := &x.StatusDescription + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *Allocation) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [25]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(25) + } else { + yynn2 = 25 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Name")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodeID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Job == nil { + r.EncodeNil() + } else { + x.Job.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Job")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Job == nil { + r.EncodeNil() + } else { + x.Job.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.TaskGroup)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("TaskGroup")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.TaskGroup)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Resources == nil { + r.EncodeNil() + } else { + x.Resources.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Resources")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Resources == nil { + r.EncodeNil() + } else { + x.Resources.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.SharedResources == nil { + r.EncodeNil() + } else { + x.SharedResources.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("SharedResources")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.SharedResources == nil { + r.EncodeNil() + } else { + x.SharedResources.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.TaskResources == nil { + r.EncodeNil() + } else { + yym34 := z.EncBinary() + _ = yym34 + if false { + } else { + h.encMapstringPtrtoResources((map[string]*Resources)(x.TaskResources), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("TaskResources")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.TaskResources == nil { + r.EncodeNil() + } else { + yym35 := z.EncBinary() + _ = yym35 + if false { + } else { + h.encMapstringPtrtoResources((map[string]*Resources)(x.TaskResources), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Metrics == nil { + r.EncodeNil() + } else { + x.Metrics.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Metrics")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Metrics == nil { + r.EncodeNil() + } else { + x.Metrics.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym40 := z.EncBinary() + _ = yym40 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DesiredStatus)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DesiredStatus")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym41 := z.EncBinary() + _ = yym41 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DesiredStatus)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym43 := z.EncBinary() + _ = yym43 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DesiredDescription)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DesiredDescription")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym44 := z.EncBinary() + _ = yym44 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DesiredDescription)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym46 := z.EncBinary() + _ = yym46 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ClientStatus)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ClientStatus")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym47 := z.EncBinary() + _ = yym47 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ClientStatus)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym49 := z.EncBinary() + _ = yym49 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ClientDescription)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ClientDescription")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym50 := z.EncBinary() + _ = yym50 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ClientDescription)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.TaskStates == nil { + r.EncodeNil() + } else { + yym52 := z.EncBinary() + _ = yym52 + if false { + } else { + h.encMapstringPtrtoTaskState((map[string]*TaskState)(x.TaskStates), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("TaskStates")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.TaskStates == nil { + r.EncodeNil() + } else { + yym53 := z.EncBinary() + _ = yym53 + if false { + } else { + h.encMapstringPtrtoTaskState((map[string]*TaskState)(x.TaskStates), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym55 := z.EncBinary() + _ = yym55 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.PreviousAllocation)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("PreviousAllocation")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym56 := z.EncBinary() + _ = yym56 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.PreviousAllocation)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym58 := z.EncBinary() + _ = yym58 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DeploymentID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym59 := z.EncBinary() + _ = yym59 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.DeploymentStatus == nil { + r.EncodeNil() + } else { + x.DeploymentStatus.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DeploymentStatus")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.DeploymentStatus == nil { + r.EncodeNil() + } else { + x.DeploymentStatus.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym64 := z.EncBinary() + _ = yym64 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym65 := z.EncBinary() + _ = yym65 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym67 := z.EncBinary() + _ = yym67 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym68 := z.EncBinary() + _ = yym68 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym70 := z.EncBinary() + _ = yym70 + if false { + } else { + r.EncodeUint(uint64(x.AllocModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllocModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym71 := z.EncBinary() + _ = yym71 + if false { + } else { + r.EncodeUint(uint64(x.AllocModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym73 := z.EncBinary() + _ = yym73 + if false { + } else { + r.EncodeInt(int64(x.CreateTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CreateTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym74 := z.EncBinary() + _ = yym74 + if false { + } else { + r.EncodeInt(int64(x.CreateTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym76 := z.EncBinary() + _ = yym76 + if false { + } else { + r.EncodeInt(int64(x.ModifyTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ModifyTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym77 := z.EncBinary() + _ = yym77 + if false { + } else { + r.EncodeInt(int64(x.ModifyTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *Allocation) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *Allocation) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "ID": + if r.TryDecodeAsNil() { + x.ID = "" + } else { + yyv4 := &x.ID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv6 := &x.Namespace + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "EvalID": + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv8 := &x.EvalID + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv10 := &x.Name + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "NodeID": + if r.TryDecodeAsNil() { + x.NodeID = "" + } else { + yyv12 := &x.NodeID + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + case "JobID": + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv14 := &x.JobID + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + case "Job": + if r.TryDecodeAsNil() { + if x.Job != nil { + x.Job = nil + } + } else { + if x.Job == nil { + x.Job = new(Job) + } + x.Job.CodecDecodeSelf(d) + } + case "TaskGroup": + if r.TryDecodeAsNil() { + x.TaskGroup = "" + } else { + yyv17 := &x.TaskGroup + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + case "Resources": + if r.TryDecodeAsNil() { + if x.Resources != nil { + x.Resources = nil + } + } else { + if x.Resources == nil { + x.Resources = new(Resources) + } + x.Resources.CodecDecodeSelf(d) + } + case "SharedResources": + if r.TryDecodeAsNil() { + if x.SharedResources != nil { + x.SharedResources = nil + } + } else { + if x.SharedResources == nil { + x.SharedResources = new(Resources) + } + x.SharedResources.CodecDecodeSelf(d) + } + case "TaskResources": + if r.TryDecodeAsNil() { + x.TaskResources = nil + } else { + yyv21 := &x.TaskResources + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + h.decMapstringPtrtoResources((*map[string]*Resources)(yyv21), d) + } + } + case "Metrics": + if r.TryDecodeAsNil() { + if x.Metrics != nil { + x.Metrics = nil + } + } else { + if x.Metrics == nil { + x.Metrics = new(AllocMetric) + } + x.Metrics.CodecDecodeSelf(d) + } + case "DesiredStatus": + if r.TryDecodeAsNil() { + x.DesiredStatus = "" + } else { + yyv24 := &x.DesiredStatus + yym25 := z.DecBinary() + _ = yym25 + if false { + } else { + *((*string)(yyv24)) = r.DecodeString() + } + } + case "DesiredDescription": + if r.TryDecodeAsNil() { + x.DesiredDescription = "" + } else { + yyv26 := &x.DesiredDescription + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + *((*string)(yyv26)) = r.DecodeString() + } + } + case "ClientStatus": + if r.TryDecodeAsNil() { + x.ClientStatus = "" + } else { + yyv28 := &x.ClientStatus + yym29 := z.DecBinary() + _ = yym29 + if false { + } else { + *((*string)(yyv28)) = r.DecodeString() + } + } + case "ClientDescription": + if r.TryDecodeAsNil() { + x.ClientDescription = "" + } else { + yyv30 := &x.ClientDescription + yym31 := z.DecBinary() + _ = yym31 + if false { + } else { + *((*string)(yyv30)) = r.DecodeString() + } + } + case "TaskStates": + if r.TryDecodeAsNil() { + x.TaskStates = nil + } else { + yyv32 := &x.TaskStates + yym33 := z.DecBinary() + _ = yym33 + if false { + } else { + h.decMapstringPtrtoTaskState((*map[string]*TaskState)(yyv32), d) + } + } + case "PreviousAllocation": + if r.TryDecodeAsNil() { + x.PreviousAllocation = "" + } else { + yyv34 := &x.PreviousAllocation + yym35 := z.DecBinary() + _ = yym35 + if false { + } else { + *((*string)(yyv34)) = r.DecodeString() + } + } + case "DeploymentID": + if r.TryDecodeAsNil() { + x.DeploymentID = "" + } else { + yyv36 := &x.DeploymentID + yym37 := z.DecBinary() + _ = yym37 + if false { + } else { + *((*string)(yyv36)) = r.DecodeString() + } + } + case "DeploymentStatus": + if r.TryDecodeAsNil() { + if x.DeploymentStatus != nil { + x.DeploymentStatus = nil + } + } else { + if x.DeploymentStatus == nil { + x.DeploymentStatus = new(AllocDeploymentStatus) + } + x.DeploymentStatus.CodecDecodeSelf(d) + } + case "CreateIndex": + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv39 := &x.CreateIndex + yym40 := z.DecBinary() + _ = yym40 + if false { + } else { + *((*uint64)(yyv39)) = uint64(r.DecodeUint(64)) + } + } + case "ModifyIndex": + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv41 := &x.ModifyIndex + yym42 := z.DecBinary() + _ = yym42 + if false { + } else { + *((*uint64)(yyv41)) = uint64(r.DecodeUint(64)) + } + } + case "AllocModifyIndex": + if r.TryDecodeAsNil() { + x.AllocModifyIndex = 0 + } else { + yyv43 := &x.AllocModifyIndex + yym44 := z.DecBinary() + _ = yym44 + if false { + } else { + *((*uint64)(yyv43)) = uint64(r.DecodeUint(64)) + } + } + case "CreateTime": + if r.TryDecodeAsNil() { + x.CreateTime = 0 + } else { + yyv45 := &x.CreateTime + yym46 := z.DecBinary() + _ = yym46 + if false { + } else { + *((*int64)(yyv45)) = int64(r.DecodeInt(64)) + } + } + case "ModifyTime": + if r.TryDecodeAsNil() { + x.ModifyTime = 0 + } else { + yyv47 := &x.ModifyTime + yym48 := z.DecBinary() + _ = yym48 + if false { + } else { + *((*int64)(yyv47)) = int64(r.DecodeInt(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *Allocation) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj49 int + var yyb49 bool + var yyhl49 bool = l >= 0 + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ID = "" + } else { + yyv50 := &x.ID + yym51 := z.DecBinary() + _ = yym51 + if false { + } else { + *((*string)(yyv50)) = r.DecodeString() + } + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv52 := &x.Namespace + yym53 := z.DecBinary() + _ = yym53 + if false { + } else { + *((*string)(yyv52)) = r.DecodeString() + } + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv54 := &x.EvalID + yym55 := z.DecBinary() + _ = yym55 + if false { + } else { + *((*string)(yyv54)) = r.DecodeString() + } + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv56 := &x.Name + yym57 := z.DecBinary() + _ = yym57 + if false { + } else { + *((*string)(yyv56)) = r.DecodeString() + } + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodeID = "" + } else { + yyv58 := &x.NodeID + yym59 := z.DecBinary() + _ = yym59 + if false { + } else { + *((*string)(yyv58)) = r.DecodeString() + } + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv60 := &x.JobID + yym61 := z.DecBinary() + _ = yym61 + if false { + } else { + *((*string)(yyv60)) = r.DecodeString() + } + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Job != nil { + x.Job = nil + } + } else { + if x.Job == nil { + x.Job = new(Job) + } + x.Job.CodecDecodeSelf(d) + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.TaskGroup = "" + } else { + yyv63 := &x.TaskGroup + yym64 := z.DecBinary() + _ = yym64 + if false { + } else { + *((*string)(yyv63)) = r.DecodeString() + } + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Resources != nil { + x.Resources = nil + } + } else { + if x.Resources == nil { + x.Resources = new(Resources) + } + x.Resources.CodecDecodeSelf(d) + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.SharedResources != nil { + x.SharedResources = nil + } + } else { + if x.SharedResources == nil { + x.SharedResources = new(Resources) + } + x.SharedResources.CodecDecodeSelf(d) + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.TaskResources = nil + } else { + yyv67 := &x.TaskResources + yym68 := z.DecBinary() + _ = yym68 + if false { + } else { + h.decMapstringPtrtoResources((*map[string]*Resources)(yyv67), d) + } + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Metrics != nil { + x.Metrics = nil + } + } else { + if x.Metrics == nil { + x.Metrics = new(AllocMetric) + } + x.Metrics.CodecDecodeSelf(d) + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DesiredStatus = "" + } else { + yyv70 := &x.DesiredStatus + yym71 := z.DecBinary() + _ = yym71 + if false { + } else { + *((*string)(yyv70)) = r.DecodeString() + } + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DesiredDescription = "" + } else { + yyv72 := &x.DesiredDescription + yym73 := z.DecBinary() + _ = yym73 + if false { + } else { + *((*string)(yyv72)) = r.DecodeString() + } + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ClientStatus = "" + } else { + yyv74 := &x.ClientStatus + yym75 := z.DecBinary() + _ = yym75 + if false { + } else { + *((*string)(yyv74)) = r.DecodeString() + } + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ClientDescription = "" + } else { + yyv76 := &x.ClientDescription + yym77 := z.DecBinary() + _ = yym77 + if false { + } else { + *((*string)(yyv76)) = r.DecodeString() + } + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.TaskStates = nil + } else { + yyv78 := &x.TaskStates + yym79 := z.DecBinary() + _ = yym79 + if false { + } else { + h.decMapstringPtrtoTaskState((*map[string]*TaskState)(yyv78), d) + } + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.PreviousAllocation = "" + } else { + yyv80 := &x.PreviousAllocation + yym81 := z.DecBinary() + _ = yym81 + if false { + } else { + *((*string)(yyv80)) = r.DecodeString() + } + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DeploymentID = "" + } else { + yyv82 := &x.DeploymentID + yym83 := z.DecBinary() + _ = yym83 + if false { + } else { + *((*string)(yyv82)) = r.DecodeString() + } + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.DeploymentStatus != nil { + x.DeploymentStatus = nil + } + } else { + if x.DeploymentStatus == nil { + x.DeploymentStatus = new(AllocDeploymentStatus) + } + x.DeploymentStatus.CodecDecodeSelf(d) + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv85 := &x.CreateIndex + yym86 := z.DecBinary() + _ = yym86 + if false { + } else { + *((*uint64)(yyv85)) = uint64(r.DecodeUint(64)) + } + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv87 := &x.ModifyIndex + yym88 := z.DecBinary() + _ = yym88 + if false { + } else { + *((*uint64)(yyv87)) = uint64(r.DecodeUint(64)) + } + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllocModifyIndex = 0 + } else { + yyv89 := &x.AllocModifyIndex + yym90 := z.DecBinary() + _ = yym90 + if false { + } else { + *((*uint64)(yyv89)) = uint64(r.DecodeUint(64)) + } + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CreateTime = 0 + } else { + yyv91 := &x.CreateTime + yym92 := z.DecBinary() + _ = yym92 + if false { + } else { + *((*int64)(yyv91)) = int64(r.DecodeInt(64)) + } + } + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ModifyTime = 0 + } else { + yyv93 := &x.ModifyTime + yym94 := z.DecBinary() + _ = yym94 + if false { + } else { + *((*int64)(yyv93)) = int64(r.DecodeInt(64)) + } + } + for { + yyj49++ + if yyhl49 { + yyb49 = yyj49 > l + } else { + yyb49 = r.CheckBreak() + } + if yyb49 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj49-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *AllocListStub) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [17]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(17) + } else { + yynn2 = 17 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Name")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodeID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeUint(uint64(x.JobVersion)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeUint(uint64(x.JobVersion)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.TaskGroup)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("TaskGroup")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.TaskGroup)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DesiredStatus)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DesiredStatus")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DesiredStatus)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DesiredDescription)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DesiredDescription")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym29 := z.EncBinary() + _ = yym29 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DesiredDescription)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym31 := z.EncBinary() + _ = yym31 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ClientStatus)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ClientStatus")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym32 := z.EncBinary() + _ = yym32 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ClientStatus)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym34 := z.EncBinary() + _ = yym34 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ClientDescription)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ClientDescription")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym35 := z.EncBinary() + _ = yym35 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ClientDescription)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.TaskStates == nil { + r.EncodeNil() + } else { + yym37 := z.EncBinary() + _ = yym37 + if false { + } else { + h.encMapstringPtrtoTaskState((map[string]*TaskState)(x.TaskStates), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("TaskStates")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.TaskStates == nil { + r.EncodeNil() + } else { + yym38 := z.EncBinary() + _ = yym38 + if false { + } else { + h.encMapstringPtrtoTaskState((map[string]*TaskState)(x.TaskStates), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.DeploymentStatus == nil { + r.EncodeNil() + } else { + x.DeploymentStatus.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DeploymentStatus")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.DeploymentStatus == nil { + r.EncodeNil() + } else { + x.DeploymentStatus.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym43 := z.EncBinary() + _ = yym43 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym44 := z.EncBinary() + _ = yym44 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym46 := z.EncBinary() + _ = yym46 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym47 := z.EncBinary() + _ = yym47 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym49 := z.EncBinary() + _ = yym49 + if false { + } else { + r.EncodeInt(int64(x.CreateTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CreateTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym50 := z.EncBinary() + _ = yym50 + if false { + } else { + r.EncodeInt(int64(x.CreateTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym52 := z.EncBinary() + _ = yym52 + if false { + } else { + r.EncodeInt(int64(x.ModifyTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ModifyTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym53 := z.EncBinary() + _ = yym53 + if false { + } else { + r.EncodeInt(int64(x.ModifyTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *AllocListStub) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *AllocListStub) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "ID": + if r.TryDecodeAsNil() { + x.ID = "" + } else { + yyv4 := &x.ID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "EvalID": + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv6 := &x.EvalID + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv8 := &x.Name + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "NodeID": + if r.TryDecodeAsNil() { + x.NodeID = "" + } else { + yyv10 := &x.NodeID + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "JobID": + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv12 := &x.JobID + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + case "JobVersion": + if r.TryDecodeAsNil() { + x.JobVersion = 0 + } else { + yyv14 := &x.JobVersion + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*uint64)(yyv14)) = uint64(r.DecodeUint(64)) + } + } + case "TaskGroup": + if r.TryDecodeAsNil() { + x.TaskGroup = "" + } else { + yyv16 := &x.TaskGroup + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + case "DesiredStatus": + if r.TryDecodeAsNil() { + x.DesiredStatus = "" + } else { + yyv18 := &x.DesiredStatus + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + case "DesiredDescription": + if r.TryDecodeAsNil() { + x.DesiredDescription = "" + } else { + yyv20 := &x.DesiredDescription + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*string)(yyv20)) = r.DecodeString() + } + } + case "ClientStatus": + if r.TryDecodeAsNil() { + x.ClientStatus = "" + } else { + yyv22 := &x.ClientStatus + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + *((*string)(yyv22)) = r.DecodeString() + } + } + case "ClientDescription": + if r.TryDecodeAsNil() { + x.ClientDescription = "" + } else { + yyv24 := &x.ClientDescription + yym25 := z.DecBinary() + _ = yym25 + if false { + } else { + *((*string)(yyv24)) = r.DecodeString() + } + } + case "TaskStates": + if r.TryDecodeAsNil() { + x.TaskStates = nil + } else { + yyv26 := &x.TaskStates + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + h.decMapstringPtrtoTaskState((*map[string]*TaskState)(yyv26), d) + } + } + case "DeploymentStatus": + if r.TryDecodeAsNil() { + if x.DeploymentStatus != nil { + x.DeploymentStatus = nil + } + } else { + if x.DeploymentStatus == nil { + x.DeploymentStatus = new(AllocDeploymentStatus) + } + x.DeploymentStatus.CodecDecodeSelf(d) + } + case "CreateIndex": + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv29 := &x.CreateIndex + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*uint64)(yyv29)) = uint64(r.DecodeUint(64)) + } + } + case "ModifyIndex": + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv31 := &x.ModifyIndex + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*uint64)(yyv31)) = uint64(r.DecodeUint(64)) + } + } + case "CreateTime": + if r.TryDecodeAsNil() { + x.CreateTime = 0 + } else { + yyv33 := &x.CreateTime + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*int64)(yyv33)) = int64(r.DecodeInt(64)) + } + } + case "ModifyTime": + if r.TryDecodeAsNil() { + x.ModifyTime = 0 + } else { + yyv35 := &x.ModifyTime + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*int64)(yyv35)) = int64(r.DecodeInt(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *AllocListStub) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj37 int + var yyb37 bool + var yyhl37 bool = l >= 0 + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l + } else { + yyb37 = r.CheckBreak() + } + if yyb37 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ID = "" + } else { + yyv38 := &x.ID + yym39 := z.DecBinary() + _ = yym39 + if false { + } else { + *((*string)(yyv38)) = r.DecodeString() + } + } + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l + } else { + yyb37 = r.CheckBreak() + } + if yyb37 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv40 := &x.EvalID + yym41 := z.DecBinary() + _ = yym41 + if false { + } else { + *((*string)(yyv40)) = r.DecodeString() + } + } + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l + } else { + yyb37 = r.CheckBreak() + } + if yyb37 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv42 := &x.Name + yym43 := z.DecBinary() + _ = yym43 + if false { + } else { + *((*string)(yyv42)) = r.DecodeString() + } + } + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l + } else { + yyb37 = r.CheckBreak() + } + if yyb37 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodeID = "" + } else { + yyv44 := &x.NodeID + yym45 := z.DecBinary() + _ = yym45 + if false { + } else { + *((*string)(yyv44)) = r.DecodeString() + } + } + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l + } else { + yyb37 = r.CheckBreak() + } + if yyb37 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv46 := &x.JobID + yym47 := z.DecBinary() + _ = yym47 + if false { + } else { + *((*string)(yyv46)) = r.DecodeString() + } + } + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l + } else { + yyb37 = r.CheckBreak() + } + if yyb37 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobVersion = 0 + } else { + yyv48 := &x.JobVersion + yym49 := z.DecBinary() + _ = yym49 + if false { + } else { + *((*uint64)(yyv48)) = uint64(r.DecodeUint(64)) + } + } + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l + } else { + yyb37 = r.CheckBreak() + } + if yyb37 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.TaskGroup = "" + } else { + yyv50 := &x.TaskGroup + yym51 := z.DecBinary() + _ = yym51 + if false { + } else { + *((*string)(yyv50)) = r.DecodeString() + } + } + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l + } else { + yyb37 = r.CheckBreak() + } + if yyb37 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DesiredStatus = "" + } else { + yyv52 := &x.DesiredStatus + yym53 := z.DecBinary() + _ = yym53 + if false { + } else { + *((*string)(yyv52)) = r.DecodeString() + } + } + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l + } else { + yyb37 = r.CheckBreak() + } + if yyb37 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DesiredDescription = "" + } else { + yyv54 := &x.DesiredDescription + yym55 := z.DecBinary() + _ = yym55 + if false { + } else { + *((*string)(yyv54)) = r.DecodeString() + } + } + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l + } else { + yyb37 = r.CheckBreak() + } + if yyb37 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ClientStatus = "" + } else { + yyv56 := &x.ClientStatus + yym57 := z.DecBinary() + _ = yym57 + if false { + } else { + *((*string)(yyv56)) = r.DecodeString() + } + } + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l + } else { + yyb37 = r.CheckBreak() + } + if yyb37 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ClientDescription = "" + } else { + yyv58 := &x.ClientDescription + yym59 := z.DecBinary() + _ = yym59 + if false { + } else { + *((*string)(yyv58)) = r.DecodeString() + } + } + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l + } else { + yyb37 = r.CheckBreak() + } + if yyb37 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.TaskStates = nil + } else { + yyv60 := &x.TaskStates + yym61 := z.DecBinary() + _ = yym61 + if false { + } else { + h.decMapstringPtrtoTaskState((*map[string]*TaskState)(yyv60), d) + } + } + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l + } else { + yyb37 = r.CheckBreak() + } + if yyb37 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.DeploymentStatus != nil { + x.DeploymentStatus = nil + } + } else { + if x.DeploymentStatus == nil { + x.DeploymentStatus = new(AllocDeploymentStatus) + } + x.DeploymentStatus.CodecDecodeSelf(d) + } + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l + } else { + yyb37 = r.CheckBreak() + } + if yyb37 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv63 := &x.CreateIndex + yym64 := z.DecBinary() + _ = yym64 + if false { + } else { + *((*uint64)(yyv63)) = uint64(r.DecodeUint(64)) + } + } + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l + } else { + yyb37 = r.CheckBreak() + } + if yyb37 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv65 := &x.ModifyIndex + yym66 := z.DecBinary() + _ = yym66 + if false { + } else { + *((*uint64)(yyv65)) = uint64(r.DecodeUint(64)) + } + } + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l + } else { + yyb37 = r.CheckBreak() + } + if yyb37 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CreateTime = 0 + } else { + yyv67 := &x.CreateTime + yym68 := z.DecBinary() + _ = yym68 + if false { + } else { + *((*int64)(yyv67)) = int64(r.DecodeInt(64)) + } + } + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l + } else { + yyb37 = r.CheckBreak() + } + if yyb37 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ModifyTime = 0 + } else { + yyv69 := &x.ModifyTime + yym70 := z.DecBinary() + _ = yym70 + if false { + } else { + *((*int64)(yyv69)) = int64(r.DecodeInt(64)) + } + } + for { + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l + } else { + yyb37 = r.CheckBreak() + } + if yyb37 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj37-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *AllocMetric) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [12]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(12) + } else { + yynn2 = 12 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeInt(int64(x.NodesEvaluated)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodesEvaluated")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeInt(int64(x.NodesEvaluated)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeInt(int64(x.NodesFiltered)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodesFiltered")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeInt(int64(x.NodesFiltered)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.NodesAvailable == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + z.F.EncMapStringIntV(x.NodesAvailable, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodesAvailable")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.NodesAvailable == nil { + r.EncodeNil() + } else { + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + z.F.EncMapStringIntV(x.NodesAvailable, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.ClassFiltered == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + z.F.EncMapStringIntV(x.ClassFiltered, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ClassFiltered")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.ClassFiltered == nil { + r.EncodeNil() + } else { + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + z.F.EncMapStringIntV(x.ClassFiltered, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.ConstraintFiltered == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + z.F.EncMapStringIntV(x.ConstraintFiltered, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ConstraintFiltered")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.ConstraintFiltered == nil { + r.EncodeNil() + } else { + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + z.F.EncMapStringIntV(x.ConstraintFiltered, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeInt(int64(x.NodesExhausted)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodesExhausted")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeInt(int64(x.NodesExhausted)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.ClassExhausted == nil { + r.EncodeNil() + } else { + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + z.F.EncMapStringIntV(x.ClassExhausted, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ClassExhausted")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.ClassExhausted == nil { + r.EncodeNil() + } else { + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + z.F.EncMapStringIntV(x.ClassExhausted, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.DimensionExhausted == nil { + r.EncodeNil() + } else { + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + z.F.EncMapStringIntV(x.DimensionExhausted, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DimensionExhausted")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.DimensionExhausted == nil { + r.EncodeNil() + } else { + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + z.F.EncMapStringIntV(x.DimensionExhausted, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.QuotaExhausted == nil { + r.EncodeNil() + } else { + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + z.F.EncSliceStringV(x.QuotaExhausted, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("QuotaExhausted")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.QuotaExhausted == nil { + r.EncodeNil() + } else { + yym29 := z.EncBinary() + _ = yym29 + if false { + } else { + z.F.EncSliceStringV(x.QuotaExhausted, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Scores == nil { + r.EncodeNil() + } else { + yym31 := z.EncBinary() + _ = yym31 + if false { + } else { + z.F.EncMapStringFloat64V(x.Scores, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Scores")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Scores == nil { + r.EncodeNil() + } else { + yym32 := z.EncBinary() + _ = yym32 + if false { + } else { + z.F.EncMapStringFloat64V(x.Scores, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym34 := z.EncBinary() + _ = yym34 + if false { + } else if z.HasExtensions() && z.EncExt(x.AllocationTime) { + } else { + r.EncodeInt(int64(x.AllocationTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllocationTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym35 := z.EncBinary() + _ = yym35 + if false { + } else if z.HasExtensions() && z.EncExt(x.AllocationTime) { + } else { + r.EncodeInt(int64(x.AllocationTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym37 := z.EncBinary() + _ = yym37 + if false { + } else { + r.EncodeInt(int64(x.CoalescedFailures)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CoalescedFailures")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym38 := z.EncBinary() + _ = yym38 + if false { + } else { + r.EncodeInt(int64(x.CoalescedFailures)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *AllocMetric) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *AllocMetric) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "NodesEvaluated": + if r.TryDecodeAsNil() { + x.NodesEvaluated = 0 + } else { + yyv4 := &x.NodesEvaluated + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int)(yyv4)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "NodesFiltered": + if r.TryDecodeAsNil() { + x.NodesFiltered = 0 + } else { + yyv6 := &x.NodesFiltered + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int)(yyv6)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "NodesAvailable": + if r.TryDecodeAsNil() { + x.NodesAvailable = nil + } else { + yyv8 := &x.NodesAvailable + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + z.F.DecMapStringIntX(yyv8, false, d) + } + } + case "ClassFiltered": + if r.TryDecodeAsNil() { + x.ClassFiltered = nil + } else { + yyv10 := &x.ClassFiltered + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + z.F.DecMapStringIntX(yyv10, false, d) + } + } + case "ConstraintFiltered": + if r.TryDecodeAsNil() { + x.ConstraintFiltered = nil + } else { + yyv12 := &x.ConstraintFiltered + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + z.F.DecMapStringIntX(yyv12, false, d) + } + } + case "NodesExhausted": + if r.TryDecodeAsNil() { + x.NodesExhausted = 0 + } else { + yyv14 := &x.NodesExhausted + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*int)(yyv14)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "ClassExhausted": + if r.TryDecodeAsNil() { + x.ClassExhausted = nil + } else { + yyv16 := &x.ClassExhausted + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + z.F.DecMapStringIntX(yyv16, false, d) + } + } + case "DimensionExhausted": + if r.TryDecodeAsNil() { + x.DimensionExhausted = nil + } else { + yyv18 := &x.DimensionExhausted + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + z.F.DecMapStringIntX(yyv18, false, d) + } + } + case "QuotaExhausted": + if r.TryDecodeAsNil() { + x.QuotaExhausted = nil + } else { + yyv20 := &x.QuotaExhausted + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + z.F.DecSliceStringX(yyv20, false, d) + } + } + case "Scores": + if r.TryDecodeAsNil() { + x.Scores = nil + } else { + yyv22 := &x.Scores + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + z.F.DecMapStringFloat64X(yyv22, false, d) + } + } + case "AllocationTime": + if r.TryDecodeAsNil() { + x.AllocationTime = 0 + } else { + yyv24 := &x.AllocationTime + yym25 := z.DecBinary() + _ = yym25 + if false { + } else if z.HasExtensions() && z.DecExt(yyv24) { + } else { + *((*int64)(yyv24)) = int64(r.DecodeInt(64)) + } + } + case "CoalescedFailures": + if r.TryDecodeAsNil() { + x.CoalescedFailures = 0 + } else { + yyv26 := &x.CoalescedFailures + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + *((*int)(yyv26)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *AllocMetric) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj28 int + var yyb28 bool + var yyhl28 bool = l >= 0 + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l + } else { + yyb28 = r.CheckBreak() + } + if yyb28 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodesEvaluated = 0 + } else { + yyv29 := &x.NodesEvaluated + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*int)(yyv29)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l + } else { + yyb28 = r.CheckBreak() + } + if yyb28 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodesFiltered = 0 + } else { + yyv31 := &x.NodesFiltered + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*int)(yyv31)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l + } else { + yyb28 = r.CheckBreak() + } + if yyb28 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodesAvailable = nil + } else { + yyv33 := &x.NodesAvailable + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + z.F.DecMapStringIntX(yyv33, false, d) + } + } + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l + } else { + yyb28 = r.CheckBreak() + } + if yyb28 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ClassFiltered = nil + } else { + yyv35 := &x.ClassFiltered + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + z.F.DecMapStringIntX(yyv35, false, d) + } + } + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l + } else { + yyb28 = r.CheckBreak() + } + if yyb28 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ConstraintFiltered = nil + } else { + yyv37 := &x.ConstraintFiltered + yym38 := z.DecBinary() + _ = yym38 + if false { + } else { + z.F.DecMapStringIntX(yyv37, false, d) + } + } + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l + } else { + yyb28 = r.CheckBreak() + } + if yyb28 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodesExhausted = 0 + } else { + yyv39 := &x.NodesExhausted + yym40 := z.DecBinary() + _ = yym40 + if false { + } else { + *((*int)(yyv39)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l + } else { + yyb28 = r.CheckBreak() + } + if yyb28 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ClassExhausted = nil + } else { + yyv41 := &x.ClassExhausted + yym42 := z.DecBinary() + _ = yym42 + if false { + } else { + z.F.DecMapStringIntX(yyv41, false, d) + } + } + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l + } else { + yyb28 = r.CheckBreak() + } + if yyb28 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DimensionExhausted = nil + } else { + yyv43 := &x.DimensionExhausted + yym44 := z.DecBinary() + _ = yym44 + if false { + } else { + z.F.DecMapStringIntX(yyv43, false, d) + } + } + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l + } else { + yyb28 = r.CheckBreak() + } + if yyb28 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.QuotaExhausted = nil + } else { + yyv45 := &x.QuotaExhausted + yym46 := z.DecBinary() + _ = yym46 + if false { + } else { + z.F.DecSliceStringX(yyv45, false, d) + } + } + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l + } else { + yyb28 = r.CheckBreak() + } + if yyb28 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Scores = nil + } else { + yyv47 := &x.Scores + yym48 := z.DecBinary() + _ = yym48 + if false { + } else { + z.F.DecMapStringFloat64X(yyv47, false, d) + } + } + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l + } else { + yyb28 = r.CheckBreak() + } + if yyb28 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllocationTime = 0 + } else { + yyv49 := &x.AllocationTime + yym50 := z.DecBinary() + _ = yym50 + if false { + } else if z.HasExtensions() && z.DecExt(yyv49) { + } else { + *((*int64)(yyv49)) = int64(r.DecodeInt(64)) + } + } + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l + } else { + yyb28 = r.CheckBreak() + } + if yyb28 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CoalescedFailures = 0 + } else { + yyv51 := &x.CoalescedFailures + yym52 := z.DecBinary() + _ = yym52 + if false { + } else { + *((*int)(yyv51)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + for { + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l + } else { + yyb28 = r.CheckBreak() + } + if yyb28 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj28-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *AllocDeploymentStatus) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Healthy == nil { + r.EncodeNil() + } else { + yy4 := *x.Healthy + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeBool(bool(yy4)) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Healthy")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Healthy == nil { + r.EncodeNil() + } else { + yy6 := *x.Healthy + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeBool(bool(yy6)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym9 := z.EncBinary() + _ = yym9 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *AllocDeploymentStatus) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *AllocDeploymentStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Healthy": + if r.TryDecodeAsNil() { + if x.Healthy != nil { + x.Healthy = nil + } + } else { + if x.Healthy == nil { + x.Healthy = new(bool) + } + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*bool)(x.Healthy)) = r.DecodeBool() + } + } + case "ModifyIndex": + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv6 := &x.ModifyIndex + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *AllocDeploymentStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Healthy != nil { + x.Healthy = nil + } + } else { + if x.Healthy == nil { + x.Healthy = new(bool) + } + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*bool)(x.Healthy)) = r.DecodeBool() + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv11 := &x.ModifyIndex + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*uint64)(yyv11)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *Evaluation) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [26]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(26) + } else { + yynn2 = 26 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.ID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeInt(int64(x.Priority)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Priority")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeInt(int64(x.Priority)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Type)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Type")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Type)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.TriggeredBy)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("TriggeredBy")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.TriggeredBy)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeUint(uint64(x.JobModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("JobModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeUint(uint64(x.JobModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodeID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + r.EncodeUint(uint64(x.NodeModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodeModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym29 := z.EncBinary() + _ = yym29 + if false { + } else { + r.EncodeUint(uint64(x.NodeModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym31 := z.EncBinary() + _ = yym31 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DeploymentID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym32 := z.EncBinary() + _ = yym32 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym34 := z.EncBinary() + _ = yym34 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Status)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Status")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym35 := z.EncBinary() + _ = yym35 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Status)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym37 := z.EncBinary() + _ = yym37 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("StatusDescription")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym38 := z.EncBinary() + _ = yym38 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym40 := z.EncBinary() + _ = yym40 + if false { + } else if z.HasExtensions() && z.EncExt(x.Wait) { + } else { + r.EncodeInt(int64(x.Wait)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Wait")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym41 := z.EncBinary() + _ = yym41 + if false { + } else if z.HasExtensions() && z.EncExt(x.Wait) { + } else { + r.EncodeInt(int64(x.Wait)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym43 := z.EncBinary() + _ = yym43 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NextEval)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NextEval")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym44 := z.EncBinary() + _ = yym44 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.NextEval)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym46 := z.EncBinary() + _ = yym46 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.PreviousEval)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("PreviousEval")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym47 := z.EncBinary() + _ = yym47 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.PreviousEval)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym49 := z.EncBinary() + _ = yym49 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.BlockedEval)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("BlockedEval")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym50 := z.EncBinary() + _ = yym50 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.BlockedEval)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.FailedTGAllocs == nil { + r.EncodeNil() + } else { + yym52 := z.EncBinary() + _ = yym52 + if false { + } else { + h.encMapstringPtrtoAllocMetric((map[string]*AllocMetric)(x.FailedTGAllocs), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("FailedTGAllocs")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.FailedTGAllocs == nil { + r.EncodeNil() + } else { + yym53 := z.EncBinary() + _ = yym53 + if false { + } else { + h.encMapstringPtrtoAllocMetric((map[string]*AllocMetric)(x.FailedTGAllocs), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.ClassEligibility == nil { + r.EncodeNil() + } else { + yym55 := z.EncBinary() + _ = yym55 + if false { + } else { + z.F.EncMapStringBoolV(x.ClassEligibility, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ClassEligibility")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.ClassEligibility == nil { + r.EncodeNil() + } else { + yym56 := z.EncBinary() + _ = yym56 + if false { + } else { + z.F.EncMapStringBoolV(x.ClassEligibility, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym58 := z.EncBinary() + _ = yym58 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.QuotaLimitReached)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("QuotaLimitReached")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym59 := z.EncBinary() + _ = yym59 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.QuotaLimitReached)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym61 := z.EncBinary() + _ = yym61 + if false { + } else { + r.EncodeBool(bool(x.EscapedComputedClass)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EscapedComputedClass")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym62 := z.EncBinary() + _ = yym62 + if false { + } else { + r.EncodeBool(bool(x.EscapedComputedClass)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym64 := z.EncBinary() + _ = yym64 + if false { + } else { + r.EncodeBool(bool(x.AnnotatePlan)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AnnotatePlan")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym65 := z.EncBinary() + _ = yym65 + if false { + } else { + r.EncodeBool(bool(x.AnnotatePlan)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.QueuedAllocations == nil { + r.EncodeNil() + } else { + yym67 := z.EncBinary() + _ = yym67 + if false { + } else { + z.F.EncMapStringIntV(x.QueuedAllocations, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("QueuedAllocations")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.QueuedAllocations == nil { + r.EncodeNil() + } else { + yym68 := z.EncBinary() + _ = yym68 + if false { + } else { + z.F.EncMapStringIntV(x.QueuedAllocations, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym70 := z.EncBinary() + _ = yym70 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.LeaderACL)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LeaderACL")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym71 := z.EncBinary() + _ = yym71 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.LeaderACL)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym73 := z.EncBinary() + _ = yym73 + if false { + } else { + r.EncodeUint(uint64(x.SnapshotIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("SnapshotIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym74 := z.EncBinary() + _ = yym74 + if false { + } else { + r.EncodeUint(uint64(x.SnapshotIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym76 := z.EncBinary() + _ = yym76 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym77 := z.EncBinary() + _ = yym77 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym79 := z.EncBinary() + _ = yym79 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym80 := z.EncBinary() + _ = yym80 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *Evaluation) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *Evaluation) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "ID": + if r.TryDecodeAsNil() { + x.ID = "" + } else { + yyv4 := &x.ID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv6 := &x.Namespace + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Priority": + if r.TryDecodeAsNil() { + x.Priority = 0 + } else { + yyv8 := &x.Priority + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int)(yyv8)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "Type": + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv10 := &x.Type + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "TriggeredBy": + if r.TryDecodeAsNil() { + x.TriggeredBy = "" + } else { + yyv12 := &x.TriggeredBy + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + case "JobID": + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv14 := &x.JobID + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + case "JobModifyIndex": + if r.TryDecodeAsNil() { + x.JobModifyIndex = 0 + } else { + yyv16 := &x.JobModifyIndex + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*uint64)(yyv16)) = uint64(r.DecodeUint(64)) + } + } + case "NodeID": + if r.TryDecodeAsNil() { + x.NodeID = "" + } else { + yyv18 := &x.NodeID + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + case "NodeModifyIndex": + if r.TryDecodeAsNil() { + x.NodeModifyIndex = 0 + } else { + yyv20 := &x.NodeModifyIndex + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*uint64)(yyv20)) = uint64(r.DecodeUint(64)) + } + } + case "DeploymentID": + if r.TryDecodeAsNil() { + x.DeploymentID = "" + } else { + yyv22 := &x.DeploymentID + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + *((*string)(yyv22)) = r.DecodeString() + } + } + case "Status": + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv24 := &x.Status + yym25 := z.DecBinary() + _ = yym25 + if false { + } else { + *((*string)(yyv24)) = r.DecodeString() + } + } + case "StatusDescription": + if r.TryDecodeAsNil() { + x.StatusDescription = "" + } else { + yyv26 := &x.StatusDescription + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + *((*string)(yyv26)) = r.DecodeString() + } + } + case "Wait": + if r.TryDecodeAsNil() { + x.Wait = 0 + } else { + yyv28 := &x.Wait + yym29 := z.DecBinary() + _ = yym29 + if false { + } else if z.HasExtensions() && z.DecExt(yyv28) { + } else { + *((*int64)(yyv28)) = int64(r.DecodeInt(64)) + } + } + case "NextEval": + if r.TryDecodeAsNil() { + x.NextEval = "" + } else { + yyv30 := &x.NextEval + yym31 := z.DecBinary() + _ = yym31 + if false { + } else { + *((*string)(yyv30)) = r.DecodeString() + } + } + case "PreviousEval": + if r.TryDecodeAsNil() { + x.PreviousEval = "" + } else { + yyv32 := &x.PreviousEval + yym33 := z.DecBinary() + _ = yym33 + if false { + } else { + *((*string)(yyv32)) = r.DecodeString() + } + } + case "BlockedEval": + if r.TryDecodeAsNil() { + x.BlockedEval = "" + } else { + yyv34 := &x.BlockedEval + yym35 := z.DecBinary() + _ = yym35 + if false { + } else { + *((*string)(yyv34)) = r.DecodeString() + } + } + case "FailedTGAllocs": + if r.TryDecodeAsNil() { + x.FailedTGAllocs = nil + } else { + yyv36 := &x.FailedTGAllocs + yym37 := z.DecBinary() + _ = yym37 + if false { + } else { + h.decMapstringPtrtoAllocMetric((*map[string]*AllocMetric)(yyv36), d) + } + } + case "ClassEligibility": + if r.TryDecodeAsNil() { + x.ClassEligibility = nil + } else { + yyv38 := &x.ClassEligibility + yym39 := z.DecBinary() + _ = yym39 + if false { + } else { + z.F.DecMapStringBoolX(yyv38, false, d) + } + } + case "QuotaLimitReached": + if r.TryDecodeAsNil() { + x.QuotaLimitReached = "" + } else { + yyv40 := &x.QuotaLimitReached + yym41 := z.DecBinary() + _ = yym41 + if false { + } else { + *((*string)(yyv40)) = r.DecodeString() + } + } + case "EscapedComputedClass": + if r.TryDecodeAsNil() { + x.EscapedComputedClass = false + } else { + yyv42 := &x.EscapedComputedClass + yym43 := z.DecBinary() + _ = yym43 + if false { + } else { + *((*bool)(yyv42)) = r.DecodeBool() + } + } + case "AnnotatePlan": + if r.TryDecodeAsNil() { + x.AnnotatePlan = false + } else { + yyv44 := &x.AnnotatePlan + yym45 := z.DecBinary() + _ = yym45 + if false { + } else { + *((*bool)(yyv44)) = r.DecodeBool() + } + } + case "QueuedAllocations": + if r.TryDecodeAsNil() { + x.QueuedAllocations = nil + } else { + yyv46 := &x.QueuedAllocations + yym47 := z.DecBinary() + _ = yym47 + if false { + } else { + z.F.DecMapStringIntX(yyv46, false, d) + } + } + case "LeaderACL": + if r.TryDecodeAsNil() { + x.LeaderACL = "" + } else { + yyv48 := &x.LeaderACL + yym49 := z.DecBinary() + _ = yym49 + if false { + } else { + *((*string)(yyv48)) = r.DecodeString() + } + } + case "SnapshotIndex": + if r.TryDecodeAsNil() { + x.SnapshotIndex = 0 + } else { + yyv50 := &x.SnapshotIndex + yym51 := z.DecBinary() + _ = yym51 + if false { + } else { + *((*uint64)(yyv50)) = uint64(r.DecodeUint(64)) + } + } + case "CreateIndex": + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv52 := &x.CreateIndex + yym53 := z.DecBinary() + _ = yym53 + if false { + } else { + *((*uint64)(yyv52)) = uint64(r.DecodeUint(64)) + } + } + case "ModifyIndex": + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv54 := &x.ModifyIndex + yym55 := z.DecBinary() + _ = yym55 + if false { + } else { + *((*uint64)(yyv54)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *Evaluation) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj56 int + var yyb56 bool + var yyhl56 bool = l >= 0 + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ID = "" + } else { + yyv57 := &x.ID + yym58 := z.DecBinary() + _ = yym58 + if false { + } else { + *((*string)(yyv57)) = r.DecodeString() + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv59 := &x.Namespace + yym60 := z.DecBinary() + _ = yym60 + if false { + } else { + *((*string)(yyv59)) = r.DecodeString() + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Priority = 0 + } else { + yyv61 := &x.Priority + yym62 := z.DecBinary() + _ = yym62 + if false { + } else { + *((*int)(yyv61)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv63 := &x.Type + yym64 := z.DecBinary() + _ = yym64 + if false { + } else { + *((*string)(yyv63)) = r.DecodeString() + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.TriggeredBy = "" + } else { + yyv65 := &x.TriggeredBy + yym66 := z.DecBinary() + _ = yym66 + if false { + } else { + *((*string)(yyv65)) = r.DecodeString() + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobID = "" + } else { + yyv67 := &x.JobID + yym68 := z.DecBinary() + _ = yym68 + if false { + } else { + *((*string)(yyv67)) = r.DecodeString() + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.JobModifyIndex = 0 + } else { + yyv69 := &x.JobModifyIndex + yym70 := z.DecBinary() + _ = yym70 + if false { + } else { + *((*uint64)(yyv69)) = uint64(r.DecodeUint(64)) + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodeID = "" + } else { + yyv71 := &x.NodeID + yym72 := z.DecBinary() + _ = yym72 + if false { + } else { + *((*string)(yyv71)) = r.DecodeString() + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodeModifyIndex = 0 + } else { + yyv73 := &x.NodeModifyIndex + yym74 := z.DecBinary() + _ = yym74 + if false { + } else { + *((*uint64)(yyv73)) = uint64(r.DecodeUint(64)) + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DeploymentID = "" + } else { + yyv75 := &x.DeploymentID + yym76 := z.DecBinary() + _ = yym76 + if false { + } else { + *((*string)(yyv75)) = r.DecodeString() + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv77 := &x.Status + yym78 := z.DecBinary() + _ = yym78 + if false { + } else { + *((*string)(yyv77)) = r.DecodeString() + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.StatusDescription = "" + } else { + yyv79 := &x.StatusDescription + yym80 := z.DecBinary() + _ = yym80 + if false { + } else { + *((*string)(yyv79)) = r.DecodeString() + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Wait = 0 + } else { + yyv81 := &x.Wait + yym82 := z.DecBinary() + _ = yym82 + if false { + } else if z.HasExtensions() && z.DecExt(yyv81) { + } else { + *((*int64)(yyv81)) = int64(r.DecodeInt(64)) + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NextEval = "" + } else { + yyv83 := &x.NextEval + yym84 := z.DecBinary() + _ = yym84 + if false { + } else { + *((*string)(yyv83)) = r.DecodeString() + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.PreviousEval = "" + } else { + yyv85 := &x.PreviousEval + yym86 := z.DecBinary() + _ = yym86 + if false { + } else { + *((*string)(yyv85)) = r.DecodeString() + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.BlockedEval = "" + } else { + yyv87 := &x.BlockedEval + yym88 := z.DecBinary() + _ = yym88 + if false { + } else { + *((*string)(yyv87)) = r.DecodeString() + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.FailedTGAllocs = nil + } else { + yyv89 := &x.FailedTGAllocs + yym90 := z.DecBinary() + _ = yym90 + if false { + } else { + h.decMapstringPtrtoAllocMetric((*map[string]*AllocMetric)(yyv89), d) + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ClassEligibility = nil + } else { + yyv91 := &x.ClassEligibility + yym92 := z.DecBinary() + _ = yym92 + if false { + } else { + z.F.DecMapStringBoolX(yyv91, false, d) + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.QuotaLimitReached = "" + } else { + yyv93 := &x.QuotaLimitReached + yym94 := z.DecBinary() + _ = yym94 + if false { + } else { + *((*string)(yyv93)) = r.DecodeString() + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EscapedComputedClass = false + } else { + yyv95 := &x.EscapedComputedClass + yym96 := z.DecBinary() + _ = yym96 + if false { + } else { + *((*bool)(yyv95)) = r.DecodeBool() + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AnnotatePlan = false + } else { + yyv97 := &x.AnnotatePlan + yym98 := z.DecBinary() + _ = yym98 + if false { + } else { + *((*bool)(yyv97)) = r.DecodeBool() + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.QueuedAllocations = nil + } else { + yyv99 := &x.QueuedAllocations + yym100 := z.DecBinary() + _ = yym100 + if false { + } else { + z.F.DecMapStringIntX(yyv99, false, d) + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LeaderACL = "" + } else { + yyv101 := &x.LeaderACL + yym102 := z.DecBinary() + _ = yym102 + if false { + } else { + *((*string)(yyv101)) = r.DecodeString() + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.SnapshotIndex = 0 + } else { + yyv103 := &x.SnapshotIndex + yym104 := z.DecBinary() + _ = yym104 + if false { + } else { + *((*uint64)(yyv103)) = uint64(r.DecodeUint(64)) + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv105 := &x.CreateIndex + yym106 := z.DecBinary() + _ = yym106 + if false { + } else { + *((*uint64)(yyv105)) = uint64(r.DecodeUint(64)) + } + } + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv107 := &x.ModifyIndex + yym108 := z.DecBinary() + _ = yym108 + if false { + } else { + *((*uint64)(yyv107)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj56++ + if yyhl56 { + yyb56 = yyj56 > l + } else { + yyb56 = r.CheckBreak() + } + if yyb56 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj56-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *Plan) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [10]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(10) + } else { + yynn2 = 10 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("EvalToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.EvalToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeInt(int64(x.Priority)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Priority")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeInt(int64(x.Priority)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.AllAtOnce)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllAtOnce")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.AllAtOnce)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Job == nil { + r.EncodeNil() + } else { + x.Job.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Job")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Job == nil { + r.EncodeNil() + } else { + x.Job.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.NodeUpdate == nil { + r.EncodeNil() + } else { + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + h.encMapstringSlicePtrtoAllocation((map[string][]*Allocation)(x.NodeUpdate), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodeUpdate")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.NodeUpdate == nil { + r.EncodeNil() + } else { + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + h.encMapstringSlicePtrtoAllocation((map[string][]*Allocation)(x.NodeUpdate), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.NodeAllocation == nil { + r.EncodeNil() + } else { + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + h.encMapstringSlicePtrtoAllocation((map[string][]*Allocation)(x.NodeAllocation), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodeAllocation")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.NodeAllocation == nil { + r.EncodeNil() + } else { + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + h.encMapstringSlicePtrtoAllocation((map[string][]*Allocation)(x.NodeAllocation), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Annotations == nil { + r.EncodeNil() + } else { + x.Annotations.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Annotations")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Annotations == nil { + r.EncodeNil() + } else { + x.Annotations.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Deployment == nil { + r.EncodeNil() + } else { + x.Deployment.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Deployment")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Deployment == nil { + r.EncodeNil() + } else { + x.Deployment.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.DeploymentUpdates == nil { + r.EncodeNil() + } else { + yym31 := z.EncBinary() + _ = yym31 + if false { + } else { + h.encSlicePtrtoDeploymentStatusUpdate(([]*DeploymentStatusUpdate)(x.DeploymentUpdates), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DeploymentUpdates")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.DeploymentUpdates == nil { + r.EncodeNil() + } else { + yym32 := z.EncBinary() + _ = yym32 + if false { + } else { + h.encSlicePtrtoDeploymentStatusUpdate(([]*DeploymentStatusUpdate)(x.DeploymentUpdates), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *Plan) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *Plan) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "EvalID": + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv4 := &x.EvalID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "EvalToken": + if r.TryDecodeAsNil() { + x.EvalToken = "" + } else { + yyv6 := &x.EvalToken + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Priority": + if r.TryDecodeAsNil() { + x.Priority = 0 + } else { + yyv8 := &x.Priority + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int)(yyv8)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + case "AllAtOnce": + if r.TryDecodeAsNil() { + x.AllAtOnce = false + } else { + yyv10 := &x.AllAtOnce + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } + } + case "Job": + if r.TryDecodeAsNil() { + if x.Job != nil { + x.Job = nil + } + } else { + if x.Job == nil { + x.Job = new(Job) + } + x.Job.CodecDecodeSelf(d) + } + case "NodeUpdate": + if r.TryDecodeAsNil() { + x.NodeUpdate = nil + } else { + yyv13 := &x.NodeUpdate + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decMapstringSlicePtrtoAllocation((*map[string][]*Allocation)(yyv13), d) + } + } + case "NodeAllocation": + if r.TryDecodeAsNil() { + x.NodeAllocation = nil + } else { + yyv15 := &x.NodeAllocation + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + h.decMapstringSlicePtrtoAllocation((*map[string][]*Allocation)(yyv15), d) + } + } + case "Annotations": + if r.TryDecodeAsNil() { + if x.Annotations != nil { + x.Annotations = nil + } + } else { + if x.Annotations == nil { + x.Annotations = new(PlanAnnotations) + } + x.Annotations.CodecDecodeSelf(d) + } + case "Deployment": + if r.TryDecodeAsNil() { + if x.Deployment != nil { + x.Deployment = nil + } + } else { + if x.Deployment == nil { + x.Deployment = new(Deployment) + } + x.Deployment.CodecDecodeSelf(d) + } + case "DeploymentUpdates": + if r.TryDecodeAsNil() { + x.DeploymentUpdates = nil + } else { + yyv19 := &x.DeploymentUpdates + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSlicePtrtoDeploymentStatusUpdate((*[]*DeploymentStatusUpdate)(yyv19), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *Plan) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj21 int + var yyb21 bool + var yyhl21 bool = l >= 0 + yyj21++ + if yyhl21 { + yyb21 = yyj21 > l + } else { + yyb21 = r.CheckBreak() + } + if yyb21 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalID = "" + } else { + yyv22 := &x.EvalID + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + *((*string)(yyv22)) = r.DecodeString() + } + } + yyj21++ + if yyhl21 { + yyb21 = yyj21 > l + } else { + yyb21 = r.CheckBreak() + } + if yyb21 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.EvalToken = "" + } else { + yyv24 := &x.EvalToken + yym25 := z.DecBinary() + _ = yym25 + if false { + } else { + *((*string)(yyv24)) = r.DecodeString() + } + } + yyj21++ + if yyhl21 { + yyb21 = yyj21 > l + } else { + yyb21 = r.CheckBreak() + } + if yyb21 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Priority = 0 + } else { + yyv26 := &x.Priority + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + *((*int)(yyv26)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + yyj21++ + if yyhl21 { + yyb21 = yyj21 > l + } else { + yyb21 = r.CheckBreak() + } + if yyb21 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllAtOnce = false + } else { + yyv28 := &x.AllAtOnce + yym29 := z.DecBinary() + _ = yym29 + if false { + } else { + *((*bool)(yyv28)) = r.DecodeBool() + } + } + yyj21++ + if yyhl21 { + yyb21 = yyj21 > l + } else { + yyb21 = r.CheckBreak() + } + if yyb21 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Job != nil { + x.Job = nil + } + } else { + if x.Job == nil { + x.Job = new(Job) + } + x.Job.CodecDecodeSelf(d) + } + yyj21++ + if yyhl21 { + yyb21 = yyj21 > l + } else { + yyb21 = r.CheckBreak() + } + if yyb21 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodeUpdate = nil + } else { + yyv31 := &x.NodeUpdate + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + h.decMapstringSlicePtrtoAllocation((*map[string][]*Allocation)(yyv31), d) + } + } + yyj21++ + if yyhl21 { + yyb21 = yyj21 > l + } else { + yyb21 = r.CheckBreak() + } + if yyb21 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodeAllocation = nil + } else { + yyv33 := &x.NodeAllocation + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + h.decMapstringSlicePtrtoAllocation((*map[string][]*Allocation)(yyv33), d) + } + } + yyj21++ + if yyhl21 { + yyb21 = yyj21 > l + } else { + yyb21 = r.CheckBreak() + } + if yyb21 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Annotations != nil { + x.Annotations = nil + } + } else { + if x.Annotations == nil { + x.Annotations = new(PlanAnnotations) + } + x.Annotations.CodecDecodeSelf(d) + } + yyj21++ + if yyhl21 { + yyb21 = yyj21 > l + } else { + yyb21 = r.CheckBreak() + } + if yyb21 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Deployment != nil { + x.Deployment = nil + } + } else { + if x.Deployment == nil { + x.Deployment = new(Deployment) + } + x.Deployment.CodecDecodeSelf(d) + } + yyj21++ + if yyhl21 { + yyb21 = yyj21 > l + } else { + yyb21 = r.CheckBreak() + } + if yyb21 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DeploymentUpdates = nil + } else { + yyv37 := &x.DeploymentUpdates + yym38 := z.DecBinary() + _ = yym38 + if false { + } else { + h.decSlicePtrtoDeploymentStatusUpdate((*[]*DeploymentStatusUpdate)(yyv37), d) + } + } + for { + yyj21++ + if yyhl21 { + yyb21 = yyj21 > l + } else { + yyb21 = r.CheckBreak() + } + if yyb21 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj21-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *PlanResult) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) + } else { + yynn2 = 6 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.NodeUpdate == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encMapstringSlicePtrtoAllocation((map[string][]*Allocation)(x.NodeUpdate), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodeUpdate")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.NodeUpdate == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encMapstringSlicePtrtoAllocation((map[string][]*Allocation)(x.NodeUpdate), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.NodeAllocation == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + h.encMapstringSlicePtrtoAllocation((map[string][]*Allocation)(x.NodeAllocation), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NodeAllocation")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.NodeAllocation == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + h.encMapstringSlicePtrtoAllocation((map[string][]*Allocation)(x.NodeAllocation), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Deployment == nil { + r.EncodeNil() + } else { + x.Deployment.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Deployment")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Deployment == nil { + r.EncodeNil() + } else { + x.Deployment.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.DeploymentUpdates == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + h.encSlicePtrtoDeploymentStatusUpdate(([]*DeploymentStatusUpdate)(x.DeploymentUpdates), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DeploymentUpdates")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.DeploymentUpdates == nil { + r.EncodeNil() + } else { + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + h.encSlicePtrtoDeploymentStatusUpdate(([]*DeploymentStatusUpdate)(x.DeploymentUpdates), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeUint(uint64(x.RefreshIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("RefreshIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeUint(uint64(x.RefreshIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeUint(uint64(x.AllocIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllocIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeUint(uint64(x.AllocIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *PlanResult) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *PlanResult) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "NodeUpdate": + if r.TryDecodeAsNil() { + x.NodeUpdate = nil + } else { + yyv4 := &x.NodeUpdate + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decMapstringSlicePtrtoAllocation((*map[string][]*Allocation)(yyv4), d) + } + } + case "NodeAllocation": + if r.TryDecodeAsNil() { + x.NodeAllocation = nil + } else { + yyv6 := &x.NodeAllocation + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + h.decMapstringSlicePtrtoAllocation((*map[string][]*Allocation)(yyv6), d) + } + } + case "Deployment": + if r.TryDecodeAsNil() { + if x.Deployment != nil { + x.Deployment = nil + } + } else { + if x.Deployment == nil { + x.Deployment = new(Deployment) + } + x.Deployment.CodecDecodeSelf(d) + } + case "DeploymentUpdates": + if r.TryDecodeAsNil() { + x.DeploymentUpdates = nil + } else { + yyv9 := &x.DeploymentUpdates + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + h.decSlicePtrtoDeploymentStatusUpdate((*[]*DeploymentStatusUpdate)(yyv9), d) + } + } + case "RefreshIndex": + if r.TryDecodeAsNil() { + x.RefreshIndex = 0 + } else { + yyv11 := &x.RefreshIndex + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*uint64)(yyv11)) = uint64(r.DecodeUint(64)) + } + } + case "AllocIndex": + if r.TryDecodeAsNil() { + x.AllocIndex = 0 + } else { + yyv13 := &x.AllocIndex + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *PlanResult) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj15 int + var yyb15 bool + var yyhl15 bool = l >= 0 + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodeUpdate = nil + } else { + yyv16 := &x.NodeUpdate + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + h.decMapstringSlicePtrtoAllocation((*map[string][]*Allocation)(yyv16), d) + } + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NodeAllocation = nil + } else { + yyv18 := &x.NodeAllocation + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + h.decMapstringSlicePtrtoAllocation((*map[string][]*Allocation)(yyv18), d) + } + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Deployment != nil { + x.Deployment = nil + } + } else { + if x.Deployment == nil { + x.Deployment = new(Deployment) + } + x.Deployment.CodecDecodeSelf(d) + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DeploymentUpdates = nil + } else { + yyv21 := &x.DeploymentUpdates + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + h.decSlicePtrtoDeploymentStatusUpdate((*[]*DeploymentStatusUpdate)(yyv21), d) + } + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.RefreshIndex = 0 + } else { + yyv23 := &x.RefreshIndex + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) + } + } + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllocIndex = 0 + } else { + yyv25 := &x.AllocIndex + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*uint64)(yyv25)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l + } else { + yyb15 = r.CheckBreak() + } + if yyb15 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj15-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *PlanAnnotations) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(1) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.DesiredTGUpdates == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encMapstringPtrtoDesiredUpdates((map[string]*DesiredUpdates)(x.DesiredTGUpdates), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DesiredTGUpdates")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.DesiredTGUpdates == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encMapstringPtrtoDesiredUpdates((map[string]*DesiredUpdates)(x.DesiredTGUpdates), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *PlanAnnotations) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *PlanAnnotations) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "DesiredTGUpdates": + if r.TryDecodeAsNil() { + x.DesiredTGUpdates = nil + } else { + yyv4 := &x.DesiredTGUpdates + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decMapstringPtrtoDesiredUpdates((*map[string]*DesiredUpdates)(yyv4), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *PlanAnnotations) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + 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 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DesiredTGUpdates = nil + } else { + yyv7 := &x.DesiredTGUpdates + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + h.decMapstringPtrtoDesiredUpdates((*map[string]*DesiredUpdates)(yyv7), d) + } + } + for { + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj6-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *DesiredUpdates) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [7]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(7) + } else { + yynn2 = 7 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeUint(uint64(x.Ignore)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Ignore")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeUint(uint64(x.Ignore)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Place)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Place")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Place)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.Migrate)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Migrate")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.Migrate)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeUint(uint64(x.Stop)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Stop")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeUint(uint64(x.Stop)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeUint(uint64(x.InPlaceUpdate)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("InPlaceUpdate")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeUint(uint64(x.InPlaceUpdate)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeUint(uint64(x.DestructiveUpdate)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("DestructiveUpdate")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeUint(uint64(x.DestructiveUpdate)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeUint(uint64(x.Canary)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Canary")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeUint(uint64(x.Canary)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *DesiredUpdates) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *DesiredUpdates) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Ignore": + if r.TryDecodeAsNil() { + x.Ignore = 0 + } else { + yyv4 := &x.Ignore + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*uint64)(yyv4)) = uint64(r.DecodeUint(64)) + } + } + case "Place": + if r.TryDecodeAsNil() { + x.Place = 0 + } else { + yyv6 := &x.Place + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "Migrate": + if r.TryDecodeAsNil() { + x.Migrate = 0 + } else { + yyv8 := &x.Migrate + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) + } + } + case "Stop": + if r.TryDecodeAsNil() { + x.Stop = 0 + } else { + yyv10 := &x.Stop + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) + } + } + case "InPlaceUpdate": + if r.TryDecodeAsNil() { + x.InPlaceUpdate = 0 + } else { + yyv12 := &x.InPlaceUpdate + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*uint64)(yyv12)) = uint64(r.DecodeUint(64)) + } + } + case "DestructiveUpdate": + if r.TryDecodeAsNil() { + x.DestructiveUpdate = 0 + } else { + yyv14 := &x.DestructiveUpdate + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*uint64)(yyv14)) = uint64(r.DecodeUint(64)) + } + } + case "Canary": + if r.TryDecodeAsNil() { + x.Canary = 0 + } else { + yyv16 := &x.Canary + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*uint64)(yyv16)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *DesiredUpdates) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj18 int + var yyb18 bool + var yyhl18 bool = l >= 0 + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Ignore = 0 + } else { + yyv19 := &x.Ignore + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Place = 0 + } else { + yyv21 := &x.Place + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*uint64)(yyv21)) = uint64(r.DecodeUint(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Migrate = 0 + } else { + yyv23 := &x.Migrate + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Stop = 0 + } else { + yyv25 := &x.Stop + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*uint64)(yyv25)) = uint64(r.DecodeUint(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.InPlaceUpdate = 0 + } else { + yyv27 := &x.InPlaceUpdate + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.DestructiveUpdate = 0 + } else { + yyv29 := &x.DestructiveUpdate + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*uint64)(yyv29)) = uint64(r.DecodeUint(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Canary = 0 + } else { + yyv31 := &x.Canary + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*uint64)(yyv31)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj18-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *KeyringResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 3 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Messages == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + z.F.EncMapStringStringV(x.Messages, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Messages")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Messages == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + z.F.EncMapStringStringV(x.Messages, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Keys == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + z.F.EncMapStringIntV(x.Keys, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Keys")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Keys == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + z.F.EncMapStringIntV(x.Keys, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeInt(int64(x.NumNodes)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("NumNodes")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeInt(int64(x.NumNodes)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *KeyringResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *KeyringResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Messages": + if r.TryDecodeAsNil() { + x.Messages = nil + } else { + yyv4 := &x.Messages + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + z.F.DecMapStringStringX(yyv4, false, d) + } + } + case "Keys": + if r.TryDecodeAsNil() { + x.Keys = nil + } else { + yyv6 := &x.Keys + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + z.F.DecMapStringIntX(yyv6, false, d) + } + } + case "NumNodes": + if r.TryDecodeAsNil() { + x.NumNodes = 0 + } else { + yyv8 := &x.NumNodes + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int)(yyv8)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *KeyringResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Messages = nil + } else { + yyv11 := &x.Messages + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + z.F.DecMapStringStringX(yyv11, false, d) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Keys = nil + } else { + yyv13 := &x.Keys + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + z.F.DecMapStringIntX(yyv13, false, d) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.NumNodes = 0 + } else { + yyv15 := &x.NumNodes + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*int)(yyv15)) = int(r.DecodeInt(codecSelferBitsize100)) + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *KeyringRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(1) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Key)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Key")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Key)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *KeyringRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *KeyringRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Key": + if r.TryDecodeAsNil() { + x.Key = "" + } else { + yyv4 := &x.Key + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *KeyringRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + 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 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Key = "" + } else { + yyv7 := &x.Key + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*string)(yyv7)) = r.DecodeString() + } + } + for { + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj6-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *RecoverableError) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Err)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Err")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Err)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeBool(bool(x.Recoverable)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Recoverable")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeBool(bool(x.Recoverable)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *RecoverableError) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *RecoverableError) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Err": + if r.TryDecodeAsNil() { + x.Err = "" + } else { + yyv4 := &x.Err + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Recoverable": + if r.TryDecodeAsNil() { + x.Recoverable = false + } else { + yyv6 := &x.Recoverable + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*bool)(yyv6)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *RecoverableError) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Err = "" + } else { + yyv9 := &x.Err + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Recoverable = false + } else { + yyv11 := &x.Recoverable + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*bool)(yyv11)) = r.DecodeBool() + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ACLPolicy) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) + } else { + yynn2 = 6 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Name")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Description)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Description")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Description)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Rules)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Rules")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Rules)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Hash == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Hash)) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Hash")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Hash == nil { + r.EncodeNil() + } else { + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Hash)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ACLPolicy) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ACLPolicy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Description": + if r.TryDecodeAsNil() { + x.Description = "" + } else { + yyv6 := &x.Description + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Rules": + if r.TryDecodeAsNil() { + x.Rules = "" + } else { + yyv8 := &x.Rules + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Hash": + if r.TryDecodeAsNil() { + x.Hash = nil + } else { + yyv10 := &x.Hash + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *yyv10 = r.DecodeBytes(*(*[]byte)(yyv10), false, false) + } + } + case "CreateIndex": + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv12 := &x.CreateIndex + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*uint64)(yyv12)) = uint64(r.DecodeUint(64)) + } + } + case "ModifyIndex": + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv14 := &x.ModifyIndex + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*uint64)(yyv14)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ACLPolicy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj16 int + var yyb16 bool + var yyhl16 bool = l >= 0 + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv17 := &x.Name + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Description = "" + } else { + yyv19 := &x.Description + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Rules = "" + } else { + yyv21 := &x.Rules + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Hash = nil + } else { + yyv23 := &x.Hash + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *yyv23 = r.DecodeBytes(*(*[]byte)(yyv23), false, false) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv25 := &x.CreateIndex + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*uint64)(yyv25)) = uint64(r.DecodeUint(64)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv27 := &x.ModifyIndex + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj16-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ACLPolicyListStub) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 5 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Name")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Description)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Description")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Description)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Hash == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Hash)) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Hash")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Hash == nil { + r.EncodeNil() + } else { + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Hash)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ACLPolicyListStub) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ACLPolicyListStub) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Description": + if r.TryDecodeAsNil() { + x.Description = "" + } else { + yyv6 := &x.Description + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Hash": + if r.TryDecodeAsNil() { + x.Hash = nil + } else { + yyv8 := &x.Hash + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *yyv8 = r.DecodeBytes(*(*[]byte)(yyv8), false, false) + } + } + case "CreateIndex": + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv10 := &x.CreateIndex + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) + } + } + case "ModifyIndex": + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv12 := &x.ModifyIndex + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*uint64)(yyv12)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ACLPolicyListStub) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv15 := &x.Name + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Description = "" + } else { + yyv17 := &x.Description + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Hash = nil + } else { + yyv19 := &x.Hash + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *yyv19 = r.DecodeBytes(*(*[]byte)(yyv19), false, false) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv21 := &x.CreateIndex + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*uint64)(yyv21)) = uint64(r.DecodeUint(64)) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv23 := &x.ModifyIndex + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj14-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ACLPolicyListRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [7]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(7) + } else { + yynn2 = 7 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ACLPolicyListRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ACLPolicyListRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv4 := &x.Region + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv6 := &x.Namespace + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv8 := &x.MinQueryIndex + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv10 := &x.MaxQueryTime + yym11 := z.DecBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.DecExt(yyv10) { + } else { + *((*int64)(yyv10)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv12 := &x.AllowStale + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*bool)(yyv12)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv14 := &x.Prefix + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv16 := &x.AuthToken + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ACLPolicyListRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj18 int + var yyb18 bool + var yyhl18 bool = l >= 0 + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv19 := &x.Region + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv21 := &x.Namespace + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv23 := &x.MinQueryIndex + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv25 := &x.MaxQueryTime + yym26 := z.DecBinary() + _ = yym26 + if false { + } else if z.HasExtensions() && z.DecExt(yyv25) { + } else { + *((*int64)(yyv25)) = int64(r.DecodeInt(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv27 := &x.AllowStale + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*bool)(yyv27)) = r.DecodeBool() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv29 := &x.Prefix + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv31 := &x.AuthToken + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } + } + for { + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj18-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ACLPolicySpecificRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(8) + } else { + yynn2 = 8 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Name")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ACLPolicySpecificRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ACLPolicySpecificRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv10 := &x.MinQueryIndex + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv12 := &x.MaxQueryTime + yym13 := z.DecBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.DecExt(yyv12) { + } else { + *((*int64)(yyv12)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv14 := &x.AllowStale + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv16 := &x.Prefix + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv18 := &x.AuthToken + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ACLPolicySpecificRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj20 int + var yyb20 bool + var yyhl20 bool = l >= 0 + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv21 := &x.Name + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv23 := &x.Region + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv25 := &x.Namespace + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv27 := &x.MinQueryIndex + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv29 := &x.MaxQueryTime + yym30 := z.DecBinary() + _ = yym30 + if false { + } else if z.HasExtensions() && z.DecExt(yyv29) { + } else { + *((*int64)(yyv29)) = int64(r.DecodeInt(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv31 := &x.AllowStale + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*bool)(yyv31)) = r.DecodeBool() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv33 := &x.Prefix + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*string)(yyv33)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv35 := &x.AuthToken + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*string)(yyv35)) = r.DecodeString() + } + } + for { + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj20-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ACLPolicySetRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(8) + } else { + yynn2 = 8 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Names == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + z.F.EncSliceStringV(x.Names, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Names")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Names == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + z.F.EncSliceStringV(x.Names, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ACLPolicySetRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ACLPolicySetRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Names": + if r.TryDecodeAsNil() { + x.Names = nil + } else { + yyv4 := &x.Names + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + z.F.DecSliceStringX(yyv4, false, d) + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv10 := &x.MinQueryIndex + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv12 := &x.MaxQueryTime + yym13 := z.DecBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.DecExt(yyv12) { + } else { + *((*int64)(yyv12)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv14 := &x.AllowStale + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv16 := &x.Prefix + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv18 := &x.AuthToken + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ACLPolicySetRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj20 int + var yyb20 bool + var yyhl20 bool = l >= 0 + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Names = nil + } else { + yyv21 := &x.Names + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + z.F.DecSliceStringX(yyv21, false, d) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv23 := &x.Region + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv25 := &x.Namespace + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv27 := &x.MinQueryIndex + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv29 := &x.MaxQueryTime + yym30 := z.DecBinary() + _ = yym30 + if false { + } else if z.HasExtensions() && z.DecExt(yyv29) { + } else { + *((*int64)(yyv29)) = int64(r.DecodeInt(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv31 := &x.AllowStale + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*bool)(yyv31)) = r.DecodeBool() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv33 := &x.Prefix + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*string)(yyv33)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv35 := &x.AuthToken + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*string)(yyv35)) = r.DecodeString() + } + } + for { + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj20-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ACLPolicyListResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Policies == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSlicePtrtoACLPolicyListStub(([]*ACLPolicyListStub)(x.Policies), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Policies")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Policies == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSlicePtrtoACLPolicyListStub(([]*ACLPolicyListStub)(x.Policies), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ACLPolicyListResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ACLPolicyListResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Policies": + if r.TryDecodeAsNil() { + x.Policies = nil + } else { + yyv4 := &x.Policies + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSlicePtrtoACLPolicyListStub((*[]*ACLPolicyListStub)(yyv4), d) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv6 := &x.Index + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv8 := &x.LastContact + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + *((*int64)(yyv8)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv10 := &x.KnownLeader + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ACLPolicyListResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Policies = nil + } else { + yyv13 := &x.Policies + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decSlicePtrtoACLPolicyListStub((*[]*ACLPolicyListStub)(yyv13), d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv15 := &x.Index + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv17 := &x.LastContact + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + *((*int64)(yyv17)) = int64(r.DecodeInt(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv19 := &x.KnownLeader + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *SingleACLPolicyResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Policy == nil { + r.EncodeNil() + } else { + x.Policy.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Policy")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Policy == nil { + r.EncodeNil() + } else { + x.Policy.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *SingleACLPolicyResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *SingleACLPolicyResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Policy": + if r.TryDecodeAsNil() { + if x.Policy != nil { + x.Policy = nil + } + } else { + if x.Policy == nil { + x.Policy = new(ACLPolicy) + } + x.Policy.CodecDecodeSelf(d) + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv5 := &x.Index + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv7 := &x.LastContact + yym8 := z.DecBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.DecExt(yyv7) { + } else { + *((*int64)(yyv7)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv9 := &x.KnownLeader + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*bool)(yyv9)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *SingleACLPolicyResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Policy != nil { + x.Policy = nil + } + } else { + if x.Policy == nil { + x.Policy = new(ACLPolicy) + } + x.Policy.CodecDecodeSelf(d) + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv13 := &x.Index + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv15 := &x.LastContact + yym16 := z.DecBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.DecExt(yyv15) { + } else { + *((*int64)(yyv15)) = int64(r.DecodeInt(64)) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv17 := &x.KnownLeader + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*bool)(yyv17)) = r.DecodeBool() + } + } + for { + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj11-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ACLPolicySetResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Policies == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encMapstringPtrtoACLPolicy((map[string]*ACLPolicy)(x.Policies), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Policies")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Policies == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encMapstringPtrtoACLPolicy((map[string]*ACLPolicy)(x.Policies), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ACLPolicySetResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ACLPolicySetResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Policies": + if r.TryDecodeAsNil() { + x.Policies = nil + } else { + yyv4 := &x.Policies + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decMapstringPtrtoACLPolicy((*map[string]*ACLPolicy)(yyv4), d) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv6 := &x.Index + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv8 := &x.LastContact + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + *((*int64)(yyv8)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv10 := &x.KnownLeader + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ACLPolicySetResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Policies = nil + } else { + yyv13 := &x.Policies + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decMapstringPtrtoACLPolicy((*map[string]*ACLPolicy)(yyv13), d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv15 := &x.Index + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv17 := &x.LastContact + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + *((*int64)(yyv17)) = int64(r.DecodeInt(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv19 := &x.KnownLeader + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ACLPolicyDeleteRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Names == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + z.F.EncSliceStringV(x.Names, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Names")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Names == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + z.F.EncSliceStringV(x.Names, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ACLPolicyDeleteRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ACLPolicyDeleteRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Names": + if r.TryDecodeAsNil() { + x.Names = nil + } else { + yyv4 := &x.Names + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + z.F.DecSliceStringX(yyv4, false, d) + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv10 := &x.AuthToken + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ACLPolicyDeleteRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Names = nil + } else { + yyv13 := &x.Names + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + z.F.DecSliceStringX(yyv13, false, d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv15 := &x.Region + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv17 := &x.Namespace + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv19 := &x.AuthToken + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ACLPolicyUpsertRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Policies == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSlicePtrtoACLPolicy(([]*ACLPolicy)(x.Policies), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Policies")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Policies == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSlicePtrtoACLPolicy(([]*ACLPolicy)(x.Policies), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ACLPolicyUpsertRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ACLPolicyUpsertRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Policies": + if r.TryDecodeAsNil() { + x.Policies = nil + } else { + yyv4 := &x.Policies + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSlicePtrtoACLPolicy((*[]*ACLPolicy)(yyv4), d) + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv10 := &x.AuthToken + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ACLPolicyUpsertRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Policies = nil + } else { + yyv13 := &x.Policies + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decSlicePtrtoACLPolicy((*[]*ACLPolicy)(yyv13), d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv15 := &x.Region + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv17 := &x.Namespace + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv19 := &x.AuthToken + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ACLToken) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [10]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(10) + } else { + yynn2 = 10 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AccessorID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AccessorID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AccessorID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.SecretID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("SecretID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.SecretID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Name")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Type)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Type")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Type)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Policies == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + z.F.EncSliceStringV(x.Policies, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Policies")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Policies == nil { + r.EncodeNil() + } else { + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + z.F.EncSliceStringV(x.Policies, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeBool(bool(x.Global)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Global")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeBool(bool(x.Global)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Hash == nil { + r.EncodeNil() + } else { + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Hash)) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Hash")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Hash == nil { + r.EncodeNil() + } else { + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Hash)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yy25 := &x.CreateTime + yym26 := z.EncBinary() + _ = yym26 + if false { + } else if yym27 := z.TimeRtidIfBinc(); yym27 != 0 { + r.EncodeBuiltin(yym27, yy25) + } else if z.HasExtensions() && z.EncExt(yy25) { + } else if yym26 { + z.EncBinaryMarshal(yy25) + } else if !yym26 && z.IsJSONHandle() { + z.EncJSONMarshal(yy25) + } else { + z.EncFallback(yy25) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CreateTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yy28 := &x.CreateTime + yym29 := z.EncBinary() + _ = yym29 + if false { + } else if yym30 := z.TimeRtidIfBinc(); yym30 != 0 { + r.EncodeBuiltin(yym30, yy28) + } else if z.HasExtensions() && z.EncExt(yy28) { + } else if yym29 { + z.EncBinaryMarshal(yy28) + } else if !yym29 && z.IsJSONHandle() { + z.EncJSONMarshal(yy28) + } else { + z.EncFallback(yy28) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym32 := z.EncBinary() + _ = yym32 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym33 := z.EncBinary() + _ = yym33 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym35 := z.EncBinary() + _ = yym35 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym36 := z.EncBinary() + _ = yym36 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ACLToken) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ACLToken) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "AccessorID": + if r.TryDecodeAsNil() { + x.AccessorID = "" + } else { + yyv4 := &x.AccessorID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "SecretID": + if r.TryDecodeAsNil() { + x.SecretID = "" + } else { + yyv6 := &x.SecretID + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv8 := &x.Name + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Type": + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv10 := &x.Type + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "Policies": + if r.TryDecodeAsNil() { + x.Policies = nil + } else { + yyv12 := &x.Policies + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + z.F.DecSliceStringX(yyv12, false, d) + } + } + case "Global": + if r.TryDecodeAsNil() { + x.Global = false + } else { + yyv14 := &x.Global + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + case "Hash": + if r.TryDecodeAsNil() { + x.Hash = nil + } else { + yyv16 := &x.Hash + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *yyv16 = r.DecodeBytes(*(*[]byte)(yyv16), false, false) + } + } + case "CreateTime": + if r.TryDecodeAsNil() { + x.CreateTime = time.Time{} + } else { + yyv18 := &x.CreateTime + yym19 := z.DecBinary() + _ = yym19 + if false { + } else if yym20 := z.TimeRtidIfBinc(); yym20 != 0 { + r.DecodeBuiltin(yym20, yyv18) + } else if z.HasExtensions() && z.DecExt(yyv18) { + } else if yym19 { + z.DecBinaryUnmarshal(yyv18) + } else if !yym19 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv18) + } else { + z.DecFallback(yyv18, false) + } + } + case "CreateIndex": + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv21 := &x.CreateIndex + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*uint64)(yyv21)) = uint64(r.DecodeUint(64)) + } + } + case "ModifyIndex": + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv23 := &x.ModifyIndex + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ACLToken) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj25 int + var yyb25 bool + var yyhl25 bool = l >= 0 + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l + } else { + yyb25 = r.CheckBreak() + } + if yyb25 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AccessorID = "" + } else { + yyv26 := &x.AccessorID + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + *((*string)(yyv26)) = r.DecodeString() + } + } + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l + } else { + yyb25 = r.CheckBreak() + } + if yyb25 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.SecretID = "" + } else { + yyv28 := &x.SecretID + yym29 := z.DecBinary() + _ = yym29 + if false { + } else { + *((*string)(yyv28)) = r.DecodeString() + } + } + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l + } else { + yyb25 = r.CheckBreak() + } + if yyb25 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv30 := &x.Name + yym31 := z.DecBinary() + _ = yym31 + if false { + } else { + *((*string)(yyv30)) = r.DecodeString() + } + } + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l + } else { + yyb25 = r.CheckBreak() + } + if yyb25 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv32 := &x.Type + yym33 := z.DecBinary() + _ = yym33 + if false { + } else { + *((*string)(yyv32)) = r.DecodeString() + } + } + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l + } else { + yyb25 = r.CheckBreak() + } + if yyb25 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Policies = nil + } else { + yyv34 := &x.Policies + yym35 := z.DecBinary() + _ = yym35 + if false { + } else { + z.F.DecSliceStringX(yyv34, false, d) + } + } + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l + } else { + yyb25 = r.CheckBreak() + } + if yyb25 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Global = false + } else { + yyv36 := &x.Global + yym37 := z.DecBinary() + _ = yym37 + if false { + } else { + *((*bool)(yyv36)) = r.DecodeBool() + } + } + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l + } else { + yyb25 = r.CheckBreak() + } + if yyb25 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Hash = nil + } else { + yyv38 := &x.Hash + yym39 := z.DecBinary() + _ = yym39 + if false { + } else { + *yyv38 = r.DecodeBytes(*(*[]byte)(yyv38), false, false) + } + } + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l + } else { + yyb25 = r.CheckBreak() + } + if yyb25 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CreateTime = time.Time{} + } else { + yyv40 := &x.CreateTime + yym41 := z.DecBinary() + _ = yym41 + if false { + } else if yym42 := z.TimeRtidIfBinc(); yym42 != 0 { + r.DecodeBuiltin(yym42, yyv40) + } else if z.HasExtensions() && z.DecExt(yyv40) { + } else if yym41 { + z.DecBinaryUnmarshal(yyv40) + } else if !yym41 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv40) + } else { + z.DecFallback(yyv40, false) + } + } + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l + } else { + yyb25 = r.CheckBreak() + } + if yyb25 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv43 := &x.CreateIndex + yym44 := z.DecBinary() + _ = yym44 + if false { + } else { + *((*uint64)(yyv43)) = uint64(r.DecodeUint(64)) + } + } + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l + } else { + yyb25 = r.CheckBreak() + } + if yyb25 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv45 := &x.ModifyIndex + yym46 := z.DecBinary() + _ = yym46 + if false { + } else { + *((*uint64)(yyv45)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l + } else { + yyb25 = r.CheckBreak() + } + if yyb25 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj25-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ACLTokenListStub) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [9]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(9) + } else { + yynn2 = 9 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AccessorID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AccessorID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AccessorID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Name")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Type)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Type")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Type)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Policies == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + z.F.EncSliceStringV(x.Policies, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Policies")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Policies == nil { + r.EncodeNil() + } else { + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + z.F.EncSliceStringV(x.Policies, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeBool(bool(x.Global)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Global")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeBool(bool(x.Global)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Hash == nil { + r.EncodeNil() + } else { + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Hash)) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Hash")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Hash == nil { + r.EncodeNil() + } else { + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Hash)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yy22 := &x.CreateTime + yym23 := z.EncBinary() + _ = yym23 + if false { + } else if yym24 := z.TimeRtidIfBinc(); yym24 != 0 { + r.EncodeBuiltin(yym24, yy22) + } else if z.HasExtensions() && z.EncExt(yy22) { + } else if yym23 { + z.EncBinaryMarshal(yy22) + } else if !yym23 && z.IsJSONHandle() { + z.EncJSONMarshal(yy22) + } else { + z.EncFallback(yy22) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CreateTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yy25 := &x.CreateTime + yym26 := z.EncBinary() + _ = yym26 + if false { + } else if yym27 := z.TimeRtidIfBinc(); yym27 != 0 { + r.EncodeBuiltin(yym27, yy25) + } else if z.HasExtensions() && z.EncExt(yy25) { + } else if yym26 { + z.EncBinaryMarshal(yy25) + } else if !yym26 && z.IsJSONHandle() { + z.EncJSONMarshal(yy25) + } else { + z.EncFallback(yy25) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym29 := z.EncBinary() + _ = yym29 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym30 := z.EncBinary() + _ = yym30 + if false { + } else { + r.EncodeUint(uint64(x.CreateIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym32 := z.EncBinary() + _ = yym32 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym33 := z.EncBinary() + _ = yym33 + if false { + } else { + r.EncodeUint(uint64(x.ModifyIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ACLTokenListStub) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ACLTokenListStub) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "AccessorID": + if r.TryDecodeAsNil() { + x.AccessorID = "" + } else { + yyv4 := &x.AccessorID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv6 := &x.Name + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Type": + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv8 := &x.Type + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "Policies": + if r.TryDecodeAsNil() { + x.Policies = nil + } else { + yyv10 := &x.Policies + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + z.F.DecSliceStringX(yyv10, false, d) + } + } + case "Global": + if r.TryDecodeAsNil() { + x.Global = false + } else { + yyv12 := &x.Global + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*bool)(yyv12)) = r.DecodeBool() + } + } + case "Hash": + if r.TryDecodeAsNil() { + x.Hash = nil + } else { + yyv14 := &x.Hash + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *yyv14 = r.DecodeBytes(*(*[]byte)(yyv14), false, false) + } + } + case "CreateTime": + if r.TryDecodeAsNil() { + x.CreateTime = time.Time{} + } else { + yyv16 := &x.CreateTime + yym17 := z.DecBinary() + _ = yym17 + if false { + } else if yym18 := z.TimeRtidIfBinc(); yym18 != 0 { + r.DecodeBuiltin(yym18, yyv16) + } else if z.HasExtensions() && z.DecExt(yyv16) { + } else if yym17 { + z.DecBinaryUnmarshal(yyv16) + } else if !yym17 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv16) + } else { + z.DecFallback(yyv16, false) + } + } + case "CreateIndex": + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv19 := &x.CreateIndex + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) + } + } + case "ModifyIndex": + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv21 := &x.ModifyIndex + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*uint64)(yyv21)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ACLTokenListStub) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj23 int + var yyb23 bool + var yyhl23 bool = l >= 0 + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AccessorID = "" + } else { + yyv24 := &x.AccessorID + yym25 := z.DecBinary() + _ = yym25 + if false { + } else { + *((*string)(yyv24)) = r.DecodeString() + } + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv26 := &x.Name + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + *((*string)(yyv26)) = r.DecodeString() + } + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv28 := &x.Type + yym29 := z.DecBinary() + _ = yym29 + if false { + } else { + *((*string)(yyv28)) = r.DecodeString() + } + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Policies = nil + } else { + yyv30 := &x.Policies + yym31 := z.DecBinary() + _ = yym31 + if false { + } else { + z.F.DecSliceStringX(yyv30, false, d) + } + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Global = false + } else { + yyv32 := &x.Global + yym33 := z.DecBinary() + _ = yym33 + if false { + } else { + *((*bool)(yyv32)) = r.DecodeBool() + } + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Hash = nil + } else { + yyv34 := &x.Hash + yym35 := z.DecBinary() + _ = yym35 + if false { + } else { + *yyv34 = r.DecodeBytes(*(*[]byte)(yyv34), false, false) + } + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CreateTime = time.Time{} + } else { + yyv36 := &x.CreateTime + yym37 := z.DecBinary() + _ = yym37 + if false { + } else if yym38 := z.TimeRtidIfBinc(); yym38 != 0 { + r.DecodeBuiltin(yym38, yyv36) + } else if z.HasExtensions() && z.DecExt(yyv36) { + } else if yym37 { + z.DecBinaryUnmarshal(yyv36) + } else if !yym37 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv36) + } else { + z.DecFallback(yyv36, false) + } + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.CreateIndex = 0 + } else { + yyv39 := &x.CreateIndex + yym40 := z.DecBinary() + _ = yym40 + if false { + } else { + *((*uint64)(yyv39)) = uint64(r.DecodeUint(64)) + } + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ModifyIndex = 0 + } else { + yyv41 := &x.ModifyIndex + yym42 := z.DecBinary() + _ = yym42 + if false { + } else { + *((*uint64)(yyv41)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj23-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ACLTokenListRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(8) + } else { + yynn2 = 8 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeBool(bool(x.GlobalOnly)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("GlobalOnly")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeBool(bool(x.GlobalOnly)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ACLTokenListRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ACLTokenListRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "GlobalOnly": + if r.TryDecodeAsNil() { + x.GlobalOnly = false + } else { + yyv4 := &x.GlobalOnly + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*bool)(yyv4)) = r.DecodeBool() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv10 := &x.MinQueryIndex + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv12 := &x.MaxQueryTime + yym13 := z.DecBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.DecExt(yyv12) { + } else { + *((*int64)(yyv12)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv14 := &x.AllowStale + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv16 := &x.Prefix + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv18 := &x.AuthToken + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ACLTokenListRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj20 int + var yyb20 bool + var yyhl20 bool = l >= 0 + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.GlobalOnly = false + } else { + yyv21 := &x.GlobalOnly + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*bool)(yyv21)) = r.DecodeBool() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv23 := &x.Region + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv25 := &x.Namespace + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv27 := &x.MinQueryIndex + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv29 := &x.MaxQueryTime + yym30 := z.DecBinary() + _ = yym30 + if false { + } else if z.HasExtensions() && z.DecExt(yyv29) { + } else { + *((*int64)(yyv29)) = int64(r.DecodeInt(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv31 := &x.AllowStale + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*bool)(yyv31)) = r.DecodeBool() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv33 := &x.Prefix + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*string)(yyv33)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv35 := &x.AuthToken + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*string)(yyv35)) = r.DecodeString() + } + } + for { + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj20-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ACLTokenSpecificRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(8) + } else { + yynn2 = 8 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AccessorID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AccessorID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AccessorID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ACLTokenSpecificRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ACLTokenSpecificRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "AccessorID": + if r.TryDecodeAsNil() { + x.AccessorID = "" + } else { + yyv4 := &x.AccessorID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv10 := &x.MinQueryIndex + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv12 := &x.MaxQueryTime + yym13 := z.DecBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.DecExt(yyv12) { + } else { + *((*int64)(yyv12)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv14 := &x.AllowStale + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv16 := &x.Prefix + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv18 := &x.AuthToken + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ACLTokenSpecificRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj20 int + var yyb20 bool + var yyhl20 bool = l >= 0 + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AccessorID = "" + } else { + yyv21 := &x.AccessorID + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv23 := &x.Region + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv25 := &x.Namespace + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv27 := &x.MinQueryIndex + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv29 := &x.MaxQueryTime + yym30 := z.DecBinary() + _ = yym30 + if false { + } else if z.HasExtensions() && z.DecExt(yyv29) { + } else { + *((*int64)(yyv29)) = int64(r.DecodeInt(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv31 := &x.AllowStale + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*bool)(yyv31)) = r.DecodeBool() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv33 := &x.Prefix + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*string)(yyv33)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv35 := &x.AuthToken + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*string)(yyv35)) = r.DecodeString() + } + } + for { + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj20-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ACLTokenSetRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(8) + } else { + yynn2 = 8 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.AccessorIDS == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + z.F.EncSliceStringV(x.AccessorIDS, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AccessorIDS")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.AccessorIDS == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + z.F.EncSliceStringV(x.AccessorIDS, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ACLTokenSetRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ACLTokenSetRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "AccessorIDS": + if r.TryDecodeAsNil() { + x.AccessorIDS = nil + } else { + yyv4 := &x.AccessorIDS + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + z.F.DecSliceStringX(yyv4, false, d) + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv10 := &x.MinQueryIndex + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv12 := &x.MaxQueryTime + yym13 := z.DecBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.DecExt(yyv12) { + } else { + *((*int64)(yyv12)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv14 := &x.AllowStale + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv16 := &x.Prefix + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv18 := &x.AuthToken + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ACLTokenSetRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj20 int + var yyb20 bool + var yyhl20 bool = l >= 0 + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AccessorIDS = nil + } else { + yyv21 := &x.AccessorIDS + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + z.F.DecSliceStringX(yyv21, false, d) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv23 := &x.Region + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv25 := &x.Namespace + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv27 := &x.MinQueryIndex + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv29 := &x.MaxQueryTime + yym30 := z.DecBinary() + _ = yym30 + if false { + } else if z.HasExtensions() && z.DecExt(yyv29) { + } else { + *((*int64)(yyv29)) = int64(r.DecodeInt(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv31 := &x.AllowStale + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*bool)(yyv31)) = r.DecodeBool() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv33 := &x.Prefix + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*string)(yyv33)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv35 := &x.AuthToken + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*string)(yyv35)) = r.DecodeString() + } + } + for { + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj20-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ACLTokenListResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Tokens == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSlicePtrtoACLTokenListStub(([]*ACLTokenListStub)(x.Tokens), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Tokens")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Tokens == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSlicePtrtoACLTokenListStub(([]*ACLTokenListStub)(x.Tokens), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ACLTokenListResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ACLTokenListResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Tokens": + if r.TryDecodeAsNil() { + x.Tokens = nil + } else { + yyv4 := &x.Tokens + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSlicePtrtoACLTokenListStub((*[]*ACLTokenListStub)(yyv4), d) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv6 := &x.Index + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv8 := &x.LastContact + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + *((*int64)(yyv8)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv10 := &x.KnownLeader + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ACLTokenListResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Tokens = nil + } else { + yyv13 := &x.Tokens + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decSlicePtrtoACLTokenListStub((*[]*ACLTokenListStub)(yyv13), d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv15 := &x.Index + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv17 := &x.LastContact + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + *((*int64)(yyv17)) = int64(r.DecodeInt(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv19 := &x.KnownLeader + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *SingleACLTokenResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Token == nil { + r.EncodeNil() + } else { + x.Token.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Token")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Token == nil { + r.EncodeNil() + } else { + x.Token.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *SingleACLTokenResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *SingleACLTokenResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Token": + if r.TryDecodeAsNil() { + if x.Token != nil { + x.Token = nil + } + } else { + if x.Token == nil { + x.Token = new(ACLToken) + } + x.Token.CodecDecodeSelf(d) + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv5 := &x.Index + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv7 := &x.LastContact + yym8 := z.DecBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.DecExt(yyv7) { + } else { + *((*int64)(yyv7)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv9 := &x.KnownLeader + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*bool)(yyv9)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *SingleACLTokenResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Token != nil { + x.Token = nil + } + } else { + if x.Token == nil { + x.Token = new(ACLToken) + } + x.Token.CodecDecodeSelf(d) + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv13 := &x.Index + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv15 := &x.LastContact + yym16 := z.DecBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.DecExt(yyv15) { + } else { + *((*int64)(yyv15)) = int64(r.DecodeInt(64)) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv17 := &x.KnownLeader + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*bool)(yyv17)) = r.DecodeBool() + } + } + for { + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj11-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ACLTokenSetResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Tokens == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encMapstringPtrtoACLToken((map[string]*ACLToken)(x.Tokens), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Tokens")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Tokens == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encMapstringPtrtoACLToken((map[string]*ACLToken)(x.Tokens), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ACLTokenSetResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ACLTokenSetResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Tokens": + if r.TryDecodeAsNil() { + x.Tokens = nil + } else { + yyv4 := &x.Tokens + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decMapstringPtrtoACLToken((*map[string]*ACLToken)(yyv4), d) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv6 := &x.Index + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv8 := &x.LastContact + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + *((*int64)(yyv8)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv10 := &x.KnownLeader + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ACLTokenSetResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Tokens = nil + } else { + yyv13 := &x.Tokens + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decMapstringPtrtoACLToken((*map[string]*ACLToken)(yyv13), d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv15 := &x.Index + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv17 := &x.LastContact + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + *((*int64)(yyv17)) = int64(r.DecodeInt(64)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv19 := &x.KnownLeader + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ResolveACLTokenRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(8) + } else { + yynn2 = 8 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.SecretID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("SecretID")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.SecretID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeUint(uint64(x.MinQueryIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { + } else { + r.EncodeInt(int64(x.MaxQueryTime)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeBool(bool(x.AllowStale)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Prefix")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ResolveACLTokenRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ResolveACLTokenRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "SecretID": + if r.TryDecodeAsNil() { + x.SecretID = "" + } else { + yyv4 := &x.SecretID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "MinQueryIndex": + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv10 := &x.MinQueryIndex + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) + } + } + case "MaxQueryTime": + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv12 := &x.MaxQueryTime + yym13 := z.DecBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.DecExt(yyv12) { + } else { + *((*int64)(yyv12)) = int64(r.DecodeInt(64)) + } + } + case "AllowStale": + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv14 := &x.AllowStale + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + case "Prefix": + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv16 := &x.Prefix + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv18 := &x.AuthToken + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ResolveACLTokenRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj20 int + var yyb20 bool + var yyhl20 bool = l >= 0 + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.SecretID = "" + } else { + yyv21 := &x.SecretID + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv23 := &x.Region + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv25 := &x.Namespace + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MinQueryIndex = 0 + } else { + yyv27 := &x.MinQueryIndex + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.MaxQueryTime = 0 + } else { + yyv29 := &x.MaxQueryTime + yym30 := z.DecBinary() + _ = yym30 + if false { + } else if z.HasExtensions() && z.DecExt(yyv29) { + } else { + *((*int64)(yyv29)) = int64(r.DecodeInt(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AllowStale = false + } else { + yyv31 := &x.AllowStale + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*bool)(yyv31)) = r.DecodeBool() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Prefix = "" + } else { + yyv33 := &x.Prefix + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*string)(yyv33)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv35 := &x.AuthToken + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*string)(yyv35)) = r.DecodeString() + } + } + for { + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj20-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ResolveACLTokenResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Token == nil { + r.EncodeNil() + } else { + x.Token.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Token")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Token == nil { + r.EncodeNil() + } else { + x.Token.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("LastContact")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastContact) { + } else { + r.EncodeInt(int64(x.LastContact)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.KnownLeader)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ResolveACLTokenResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ResolveACLTokenResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Token": + if r.TryDecodeAsNil() { + if x.Token != nil { + x.Token = nil + } + } else { + if x.Token == nil { + x.Token = new(ACLToken) + } + x.Token.CodecDecodeSelf(d) + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv5 := &x.Index + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) + } + } + case "LastContact": + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv7 := &x.LastContact + yym8 := z.DecBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.DecExt(yyv7) { + } else { + *((*int64)(yyv7)) = int64(r.DecodeInt(64)) + } + } + case "KnownLeader": + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv9 := &x.KnownLeader + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*bool)(yyv9)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ResolveACLTokenResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Token != nil { + x.Token = nil + } + } else { + if x.Token == nil { + x.Token = new(ACLToken) + } + x.Token.CodecDecodeSelf(d) + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv13 := &x.Index + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.LastContact = 0 + } else { + yyv15 := &x.LastContact + yym16 := z.DecBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.DecExt(yyv15) { + } else { + *((*int64)(yyv15)) = int64(r.DecodeInt(64)) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.KnownLeader = false + } else { + yyv17 := &x.KnownLeader + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*bool)(yyv17)) = r.DecodeBool() + } + } + for { + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj11-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ACLTokenDeleteRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.AccessorIDs == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + z.F.EncSliceStringV(x.AccessorIDs, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AccessorIDs")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.AccessorIDs == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + z.F.EncSliceStringV(x.AccessorIDs, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ACLTokenDeleteRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ACLTokenDeleteRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "AccessorIDs": + if r.TryDecodeAsNil() { + x.AccessorIDs = nil + } else { + yyv4 := &x.AccessorIDs + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + z.F.DecSliceStringX(yyv4, false, d) + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv10 := &x.AuthToken + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ACLTokenDeleteRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AccessorIDs = nil + } else { + yyv13 := &x.AccessorIDs + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + z.F.DecSliceStringX(yyv13, false, d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv15 := &x.Region + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv17 := &x.Namespace + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv19 := &x.AuthToken + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ACLTokenBootstrapRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 5 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Token == nil { + r.EncodeNil() + } else { + x.Token.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Token")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Token == nil { + r.EncodeNil() + } else { + x.Token.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.ResetIndex)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("ResetIndex")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.ResetIndex)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ACLTokenBootstrapRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ACLTokenBootstrapRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Token": + if r.TryDecodeAsNil() { + if x.Token != nil { + x.Token = nil + } + } else { + if x.Token == nil { + x.Token = new(ACLToken) + } + x.Token.CodecDecodeSelf(d) + } + case "ResetIndex": + if r.TryDecodeAsNil() { + x.ResetIndex = 0 + } else { + yyv5 := &x.ResetIndex + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv7 := &x.Region + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*string)(yyv7)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv9 := &x.Namespace + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv11 := &x.AuthToken + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ACLTokenBootstrapRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj13 int + var yyb13 bool + var yyhl13 bool = l >= 0 + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + if x.Token != nil { + x.Token = nil + } + } else { + if x.Token == nil { + x.Token = new(ACLToken) + } + x.Token.CodecDecodeSelf(d) + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.ResetIndex = 0 + } else { + yyv15 := &x.ResetIndex + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv17 := &x.Region + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv19 := &x.Namespace + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv21 := &x.AuthToken + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + for { + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj13-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ACLTokenUpsertRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Tokens == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSlicePtrtoACLToken(([]*ACLToken)(x.Tokens), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Tokens")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Tokens == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSlicePtrtoACLToken(([]*ACLToken)(x.Tokens), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Region")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Region)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ACLTokenUpsertRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ACLTokenUpsertRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Tokens": + if r.TryDecodeAsNil() { + x.Tokens = nil + } else { + yyv4 := &x.Tokens + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSlicePtrtoACLToken((*[]*ACLToken)(yyv4), d) + } + } + case "Region": + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv6 := &x.Region + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "Namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "AuthToken": + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv10 := &x.AuthToken + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ACLTokenUpsertRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Tokens = nil + } else { + yyv13 := &x.Tokens + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decSlicePtrtoACLToken((*[]*ACLToken)(yyv13), d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Region = "" + } else { + yyv15 := &x.Region + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv17 := &x.Namespace + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.AuthToken = "" + } else { + yyv19 := &x.AuthToken + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x *ACLTokenUpsertResponse) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if x.Tokens == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSlicePtrtoACLToken(([]*ACLToken)(x.Tokens), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Tokens")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if x.Tokens == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSlicePtrtoACLToken(([]*ACLToken)(x.Tokens), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey100) + r.EncodeString(codecSelferC_UTF8100, string("Index")) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeUint(uint64(x.Index)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd100) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd100) + } + } + } +} + +func (x *ACLTokenUpsertResponse) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap100 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd100) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray100 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) + } + } +} + +func (x *ACLTokenUpsertResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey100) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue100) + switch yys3 { + case "Tokens": + if r.TryDecodeAsNil() { + x.Tokens = nil + } else { + yyv4 := &x.Tokens + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSlicePtrtoACLToken((*[]*ACLToken)(yyv4), d) + } + } + case "Index": + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv6 := &x.Index + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x *ACLTokenUpsertResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Tokens = nil + } else { + yyv9 := &x.Tokens + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + h.decSlicePtrtoACLToken((*[]*ACLToken)(yyv9), d) + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd100) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + if r.TryDecodeAsNil() { + x.Index = 0 + } else { + yyv11 := &x.Index + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*uint64)(yyv11)) = uint64(r.DecodeUint(64)) + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem100) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) encMapContextSlicestring(v map[Context][]string, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeMapStart(len(v)) + for yyk1, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerMapKey100) + yyk1.CodecEncodeSelf(e) + z.EncSendContainerState(codecSelfer_containerMapValue100) + if yyv1 == nil { + r.EncodeNil() + } else { + yym3 := z.EncBinary() + _ = yym3 + if false { + } else { + z.F.EncSliceStringV(yyv1, false, e) + } + } + } + z.EncSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) decMapContextSlicestring(v *map[Context][]string, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyl1 := r.ReadMapStart() + yybh1 := z.DecBasicHandle() + if yyv1 == nil { + yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 40) + yyv1 = make(map[Context][]string, yyrl1) + *v = yyv1 + } + var yymk1 Context + var yymv1 []string + var yymg1 bool + if yybh1.MapValueReset { + yymg1 = true + } + if yyl1 > 0 { + for yyj1 := 0; yyj1 < yyl1; yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv2 := &yymk1 + yyv2.CodecDecodeSelf(d) + } + + if yymg1 { + yymv1 = yyv1[yymk1] + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + yymv1 = nil + } else { + yyv3 := &yymv1 + yym4 := z.DecBinary() + _ = yym4 + if false { + } else { + z.F.DecSliceStringX(yyv3, false, d) + } + } + + if yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } else if yyl1 < 0 { + for yyj1 := 0; !r.CheckBreak(); yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv5 := &yymk1 + yyv5.CodecDecodeSelf(d) + } + + if yymg1 { + yymv1 = yyv1[yymk1] + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + yymv1 = nil + } else { + yyv6 := &yymv1 + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + z.F.DecSliceStringX(yyv6, false, d) + } + } + + if yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } // else len==0: TODO: Should we clear map entries? + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) encSlicestring(v []string, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yym2 := z.EncBinary() + _ = yym2 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(yyv1)) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicestring(v *[]string, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []string{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]string, yyrl1) + } + } else { + yyv1 = make([]string, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = "" + } else { + yyv2 := &yyv1[yyj1] + yym3 := z.DecBinary() + _ = yym3 + if false { + } else { + *((*string)(yyv2)) = r.DecodeString() + } + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, "") + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = "" + } else { + yyv4 := &yyv1[yyj1] + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, "") // var yyz1 string + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = "" + } else { + yyv6 := &yyv1[yyj1] + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []string{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encMapContextbool(v map[Context]bool, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeMapStart(len(v)) + for yyk1, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerMapKey100) + yyk1.CodecEncodeSelf(e) + z.EncSendContainerState(codecSelfer_containerMapValue100) + yym3 := z.EncBinary() + _ = yym3 + if false { + } else { + r.EncodeBool(bool(yyv1)) + } + } + z.EncSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) decMapContextbool(v *map[Context]bool, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyl1 := r.ReadMapStart() + yybh1 := z.DecBasicHandle() + if yyv1 == nil { + yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 17) + yyv1 = make(map[Context]bool, yyrl1) + *v = yyv1 + } + var yymk1 Context + var yymv1 bool + var yymg1 bool + if yybh1.MapValueReset { + } + if yyl1 > 0 { + for yyj1 := 0; yyj1 < yyl1; yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv2 := &yymk1 + yyv2.CodecDecodeSelf(d) + } + + if yymg1 { + yymv1 = yyv1[yymk1] + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + yymv1 = false + } else { + yyv3 := &yymv1 + yym4 := z.DecBinary() + _ = yym4 + if false { + } else { + *((*bool)(yyv3)) = r.DecodeBool() + } + } + + if yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } else if yyl1 < 0 { + for yyj1 := 0; !r.CheckBreak(); yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv5 := &yymk1 + yyv5.CodecDecodeSelf(d) + } + + if yymg1 { + yymv1 = yyv1[yymk1] + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + yymv1 = false + } else { + yyv6 := &yymv1 + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*bool)(yyv6)) = r.DecodeBool() + } + } + + if yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } // else len==0: TODO: Should we clear map entries? + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) encSlicePtrtoEvaluation(v []*Evaluation, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoEvaluation(v *[]*Evaluation, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*Evaluation{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*Evaluation, yyrl1) + } + } else { + yyv1 = make([]*Evaluation, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Evaluation{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Evaluation) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Evaluation{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Evaluation) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *Evaluation + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Evaluation{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Evaluation) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*Evaluation{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encSlicePtrtoAllocation(v []*Allocation, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoAllocation(v *[]*Allocation, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*Allocation{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*Allocation, yyrl1) + } + } else { + yyv1 = make([]*Allocation, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Allocation{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Allocation) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Allocation{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Allocation) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *Allocation + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Allocation{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Allocation) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*Allocation{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encSlicePtrtoDeploymentStatusUpdate(v []*DeploymentStatusUpdate, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoDeploymentStatusUpdate(v *[]*DeploymentStatusUpdate, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*DeploymentStatusUpdate{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*DeploymentStatusUpdate, yyrl1) + } + } else { + yyv1 = make([]*DeploymentStatusUpdate, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = DeploymentStatusUpdate{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(DeploymentStatusUpdate) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = DeploymentStatusUpdate{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(DeploymentStatusUpdate) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *DeploymentStatusUpdate + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = DeploymentStatusUpdate{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(DeploymentStatusUpdate) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*DeploymentStatusUpdate{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encSlicePtrtoServerMember(v []*ServerMember, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoServerMember(v *[]*ServerMember, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*ServerMember{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*ServerMember, yyrl1) + } + } else { + yyv1 = make([]*ServerMember, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = ServerMember{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(ServerMember) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = ServerMember{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(ServerMember) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *ServerMember + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = ServerMember{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(ServerMember) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*ServerMember{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encnet_IP(v net.IP, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeStringBytes(codecSelferC_RAW100, []byte(v)) +} + +func (x codecSelfer100) decnet_IP(v *net.IP, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + *v = r.DecodeBytes(*((*[]byte)(v)), false, false) +} + +func (x codecSelfer100) encSlicePtrtoVaultAccessor(v []*VaultAccessor, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoVaultAccessor(v *[]*VaultAccessor, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*VaultAccessor{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*VaultAccessor, yyrl1) + } + } else { + yyv1 = make([]*VaultAccessor, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = VaultAccessor{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(VaultAccessor) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = VaultAccessor{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(VaultAccessor) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *VaultAccessor + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = VaultAccessor{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(VaultAccessor) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*VaultAccessor{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encSlicePtrtoNodeServerInfo(v []*NodeServerInfo, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoNodeServerInfo(v *[]*NodeServerInfo, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*NodeServerInfo{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*NodeServerInfo, yyrl1) + } + } else { + yyv1 = make([]*NodeServerInfo, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = NodeServerInfo{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(NodeServerInfo) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = NodeServerInfo{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(NodeServerInfo) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *NodeServerInfo + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = NodeServerInfo{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(NodeServerInfo) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*NodeServerInfo{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encSlicePtrtoNodeListStub(v []*NodeListStub, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoNodeListStub(v *[]*NodeListStub, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*NodeListStub{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*NodeListStub, yyrl1) + } + } else { + yyv1 = make([]*NodeListStub, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = NodeListStub{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(NodeListStub) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = NodeListStub{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(NodeListStub) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *NodeListStub + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = NodeListStub{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(NodeListStub) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*NodeListStub{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encSlicePtrtoJobListStub(v []*JobListStub, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoJobListStub(v *[]*JobListStub, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*JobListStub{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*JobListStub, yyrl1) + } + } else { + yyv1 = make([]*JobListStub, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = JobListStub{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(JobListStub) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = JobListStub{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(JobListStub) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *JobListStub + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = JobListStub{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(JobListStub) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*JobListStub{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encSlicePtrtoJob(v []*Job, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoJob(v *[]*Job, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*Job{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*Job, yyrl1) + } + } else { + yyv1 = make([]*Job, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Job{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Job) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Job{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Job) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *Job + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Job{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Job) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*Job{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encSlicePtrtoJobDiff(v []*JobDiff, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yym2 := z.EncBinary() + _ = yym2 + if false { + } else if z.HasExtensions() && z.EncExt(yyv1) { + } else { + z.EncFallback(yyv1) + } + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoJobDiff(v *[]*JobDiff, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*JobDiff{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*JobDiff, yyrl1) + } + } else { + yyv1 = make([]*JobDiff, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = JobDiff{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(JobDiff) + } + yyw2 := yyv1[yyj1] + yym3 := z.DecBinary() + _ = yym3 + if false { + } else if z.HasExtensions() && z.DecExt(yyw2) { + } else { + z.DecFallback(yyw2, false) + } + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = JobDiff{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(JobDiff) + } + yyw4 := yyv1[yyj1] + yym5 := z.DecBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.DecExt(yyw4) { + } else { + z.DecFallback(yyw4, false) + } + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *JobDiff + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = JobDiff{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(JobDiff) + } + yyw6 := yyv1[yyj1] + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(yyw6) { + } else { + z.DecFallback(yyw6, false) + } + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*JobDiff{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encMapstringPtrtoAllocMetric(v map[string]*AllocMetric, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeMapStart(len(v)) + for yyk1, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerMapKey100) + yym2 := z.EncBinary() + _ = yym2 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(yyk1)) + } + z.EncSendContainerState(codecSelfer_containerMapValue100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) decMapstringPtrtoAllocMetric(v *map[string]*AllocMetric, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyl1 := r.ReadMapStart() + yybh1 := z.DecBasicHandle() + if yyv1 == nil { + yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 24) + yyv1 = make(map[string]*AllocMetric, yyrl1) + *v = yyv1 + } + var yymk1 string + var yymv1 *AllocMetric + var yymg1, yyms1, yymok1 bool + if yybh1.MapValueReset { + yymg1 = true + } + if yyl1 > 0 { + for yyj1 := 0; yyj1 < yyl1; yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv2 := &yymk1 + yym3 := z.DecBinary() + _ = yym3 + if false { + } else { + *((*string)(yyv2)) = r.DecodeString() + } + } + + yyms1 = true + if yymg1 { + yymv1, yymok1 = yyv1[yymk1] + if yymok1 { + yyms1 = false + } + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + if yymv1 != nil { + *yymv1 = AllocMetric{} + } + } else { + if yymv1 == nil { + yymv1 = new(AllocMetric) + } + yymv1.CodecDecodeSelf(d) + } + + if yyms1 && yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } else if yyl1 < 0 { + for yyj1 := 0; !r.CheckBreak(); yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv5 := &yymk1 + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } + } + + yyms1 = true + if yymg1 { + yymv1, yymok1 = yyv1[yymk1] + if yymok1 { + yyms1 = false + } + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + if yymv1 != nil { + *yymv1 = AllocMetric{} + } + } else { + if yymv1 == nil { + yymv1 = new(AllocMetric) + } + yymv1.CodecDecodeSelf(d) + } + + if yyms1 && yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } // else len==0: TODO: Should we clear map entries? + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) encSlicePtrtoAllocListStub(v []*AllocListStub, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoAllocListStub(v *[]*AllocListStub, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*AllocListStub{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*AllocListStub, yyrl1) + } + } else { + yyv1 = make([]*AllocListStub, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = AllocListStub{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(AllocListStub) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = AllocListStub{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(AllocListStub) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *AllocListStub + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = AllocListStub{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(AllocListStub) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*AllocListStub{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encSlicePtrtoDeployment(v []*Deployment, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoDeployment(v *[]*Deployment, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*Deployment{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*Deployment, yyrl1) + } + } else { + yyv1 = make([]*Deployment, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Deployment{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Deployment) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Deployment{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Deployment) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *Deployment + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Deployment{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Deployment) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*Deployment{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encNetworks(v Networks, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decNetworks(v *Networks, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*NetworkResource{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*NetworkResource, yyrl1) + } + } else { + yyv1 = make([]*NetworkResource, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = NetworkResource{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(NetworkResource) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = NetworkResource{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(NetworkResource) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *NetworkResource + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = NetworkResource{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(NetworkResource) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*NetworkResource{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encSlicePort(v []Port, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePort(v *[]Port, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Port{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 24) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]Port, yyrl1) + } + } else { + yyv1 = make([]Port, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Port{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Port{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Port{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Port{}) // var yyz1 Port + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = Port{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Port{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encSlicePtrtoConstraint(v []*Constraint, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoConstraint(v *[]*Constraint, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*Constraint{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*Constraint, yyrl1) + } + } else { + yyv1 = make([]*Constraint, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Constraint{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Constraint) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Constraint{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Constraint) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *Constraint + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Constraint{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Constraint) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*Constraint{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encSlicePtrtoTaskGroup(v []*TaskGroup, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoTaskGroup(v *[]*TaskGroup, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*TaskGroup{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*TaskGroup, yyrl1) + } + } else { + yyv1 = make([]*TaskGroup, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = TaskGroup{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(TaskGroup) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = TaskGroup{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(TaskGroup) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *TaskGroup + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = TaskGroup{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(TaskGroup) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*TaskGroup{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encMapstringTaskGroupSummary(v map[string]TaskGroupSummary, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeMapStart(len(v)) + for yyk1, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerMapKey100) + yym2 := z.EncBinary() + _ = yym2 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(yyk1)) + } + z.EncSendContainerState(codecSelfer_containerMapValue100) + yy3 := &yyv1 + yy3.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) decMapstringTaskGroupSummary(v *map[string]TaskGroupSummary, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyl1 := r.ReadMapStart() + yybh1 := z.DecBasicHandle() + if yyv1 == nil { + yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 64) + yyv1 = make(map[string]TaskGroupSummary, yyrl1) + *v = yyv1 + } + var yymk1 string + var yymv1 TaskGroupSummary + var yymg1 bool + if yybh1.MapValueReset { + yymg1 = true + } + if yyl1 > 0 { + for yyj1 := 0; yyj1 < yyl1; yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv2 := &yymk1 + yym3 := z.DecBinary() + _ = yym3 + if false { + } else { + *((*string)(yyv2)) = r.DecodeString() + } + } + + if yymg1 { + yymv1 = yyv1[yymk1] + } else { + yymv1 = TaskGroupSummary{} + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + yymv1 = TaskGroupSummary{} + } else { + yyv4 := &yymv1 + yyv4.CodecDecodeSelf(d) + } + + if yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } else if yyl1 < 0 { + for yyj1 := 0; !r.CheckBreak(); yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv5 := &yymk1 + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } + } + + if yymg1 { + yymv1 = yyv1[yymk1] + } else { + yymv1 = TaskGroupSummary{} + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + yymv1 = TaskGroupSummary{} + } else { + yyv7 := &yymv1 + yyv7.CodecDecodeSelf(d) + } + + if yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } // else len==0: TODO: Should we clear map entries? + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) encSlicePtrtoTask(v []*Task, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoTask(v *[]*Task, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*Task{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*Task, yyrl1) + } + } else { + yyv1 = make([]*Task, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Task{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Task) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Task{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Task) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *Task + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Task{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Task) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*Task{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encMapstringSlicestring(v map[string][]string, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeMapStart(len(v)) + for yyk1, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerMapKey100) + yym2 := z.EncBinary() + _ = yym2 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(yyk1)) + } + z.EncSendContainerState(codecSelfer_containerMapValue100) + if yyv1 == nil { + r.EncodeNil() + } else { + yym3 := z.EncBinary() + _ = yym3 + if false { + } else { + z.F.EncSliceStringV(yyv1, false, e) + } + } + } + z.EncSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) decMapstringSlicestring(v *map[string][]string, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyl1 := r.ReadMapStart() + yybh1 := z.DecBasicHandle() + if yyv1 == nil { + yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 40) + yyv1 = make(map[string][]string, yyrl1) + *v = yyv1 + } + var yymk1 string + var yymv1 []string + var yymg1 bool + if yybh1.MapValueReset { + yymg1 = true + } + if yyl1 > 0 { + for yyj1 := 0; yyj1 < yyl1; yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv2 := &yymk1 + yym3 := z.DecBinary() + _ = yym3 + if false { + } else { + *((*string)(yyv2)) = r.DecodeString() + } + } + + if yymg1 { + yymv1 = yyv1[yymk1] + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + yymv1 = nil + } else { + yyv4 := &yymv1 + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + z.F.DecSliceStringX(yyv4, false, d) + } + } + + if yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } else if yyl1 < 0 { + for yyj1 := 0; !r.CheckBreak(); yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv6 := &yymk1 + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + + if yymg1 { + yymv1 = yyv1[yymk1] + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + yymv1 = nil + } else { + yyv8 := &yymv1 + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + z.F.DecSliceStringX(yyv8, false, d) + } + } + + if yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } // else len==0: TODO: Should we clear map entries? + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) encSlicePtrtoServiceCheck(v []*ServiceCheck, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoServiceCheck(v *[]*ServiceCheck, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*ServiceCheck{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*ServiceCheck, yyrl1) + } + } else { + yyv1 = make([]*ServiceCheck, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = ServiceCheck{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(ServiceCheck) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = ServiceCheck{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(ServiceCheck) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *ServiceCheck + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = ServiceCheck{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(ServiceCheck) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*ServiceCheck{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encSlicePtrtoService(v []*Service, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoService(v *[]*Service, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*Service{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*Service, yyrl1) + } + } else { + yyv1 = make([]*Service, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Service{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Service) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Service{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Service) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *Service + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Service{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Service) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*Service{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encSlicePtrtoTemplate(v []*Template, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoTemplate(v *[]*Template, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*Template{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*Template, yyrl1) + } + } else { + yyv1 = make([]*Template, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Template{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Template) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Template{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Template) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *Template + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = Template{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(Template) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*Template{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encSlicePtrtoTaskArtifact(v []*TaskArtifact, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoTaskArtifact(v *[]*TaskArtifact, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*TaskArtifact{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*TaskArtifact, yyrl1) + } + } else { + yyv1 = make([]*TaskArtifact, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = TaskArtifact{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(TaskArtifact) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = TaskArtifact{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(TaskArtifact) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *TaskArtifact + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = TaskArtifact{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(TaskArtifact) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*TaskArtifact{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encSlicePtrtoTaskEvent(v []*TaskEvent, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoTaskEvent(v *[]*TaskEvent, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*TaskEvent{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*TaskEvent, yyrl1) + } + } else { + yyv1 = make([]*TaskEvent, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = TaskEvent{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(TaskEvent) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = TaskEvent{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(TaskEvent) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *TaskEvent + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = TaskEvent{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(TaskEvent) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*TaskEvent{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encMapstringPtrtoDeploymentState(v map[string]*DeploymentState, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeMapStart(len(v)) + for yyk1, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerMapKey100) + yym2 := z.EncBinary() + _ = yym2 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(yyk1)) + } + z.EncSendContainerState(codecSelfer_containerMapValue100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) decMapstringPtrtoDeploymentState(v *map[string]*DeploymentState, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyl1 := r.ReadMapStart() + yybh1 := z.DecBasicHandle() + if yyv1 == nil { + yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 24) + yyv1 = make(map[string]*DeploymentState, yyrl1) + *v = yyv1 + } + var yymk1 string + var yymv1 *DeploymentState + var yymg1, yyms1, yymok1 bool + if yybh1.MapValueReset { + yymg1 = true + } + if yyl1 > 0 { + for yyj1 := 0; yyj1 < yyl1; yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv2 := &yymk1 + yym3 := z.DecBinary() + _ = yym3 + if false { + } else { + *((*string)(yyv2)) = r.DecodeString() + } + } + + yyms1 = true + if yymg1 { + yymv1, yymok1 = yyv1[yymk1] + if yymok1 { + yyms1 = false + } + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + if yymv1 != nil { + *yymv1 = DeploymentState{} + } + } else { + if yymv1 == nil { + yymv1 = new(DeploymentState) + } + yymv1.CodecDecodeSelf(d) + } + + if yyms1 && yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } else if yyl1 < 0 { + for yyj1 := 0; !r.CheckBreak(); yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv5 := &yymk1 + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } + } + + yyms1 = true + if yymg1 { + yymv1, yymok1 = yyv1[yymk1] + if yymok1 { + yyms1 = false + } + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + if yymv1 != nil { + *yymv1 = DeploymentState{} + } + } else { + if yymv1 == nil { + yymv1 = new(DeploymentState) + } + yymv1.CodecDecodeSelf(d) + } + + if yyms1 && yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } // else len==0: TODO: Should we clear map entries? + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) encMapstringPtrtoResources(v map[string]*Resources, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeMapStart(len(v)) + for yyk1, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerMapKey100) + yym2 := z.EncBinary() + _ = yym2 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(yyk1)) + } + z.EncSendContainerState(codecSelfer_containerMapValue100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) decMapstringPtrtoResources(v *map[string]*Resources, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyl1 := r.ReadMapStart() + yybh1 := z.DecBasicHandle() + if yyv1 == nil { + yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 24) + yyv1 = make(map[string]*Resources, yyrl1) + *v = yyv1 + } + var yymk1 string + var yymv1 *Resources + var yymg1, yyms1, yymok1 bool + if yybh1.MapValueReset { + yymg1 = true + } + if yyl1 > 0 { + for yyj1 := 0; yyj1 < yyl1; yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv2 := &yymk1 + yym3 := z.DecBinary() + _ = yym3 + if false { + } else { + *((*string)(yyv2)) = r.DecodeString() + } + } + + yyms1 = true + if yymg1 { + yymv1, yymok1 = yyv1[yymk1] + if yymok1 { + yyms1 = false + } + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + if yymv1 != nil { + *yymv1 = Resources{} + } + } else { + if yymv1 == nil { + yymv1 = new(Resources) + } + yymv1.CodecDecodeSelf(d) + } + + if yyms1 && yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } else if yyl1 < 0 { + for yyj1 := 0; !r.CheckBreak(); yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv5 := &yymk1 + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } + } + + yyms1 = true + if yymg1 { + yymv1, yymok1 = yyv1[yymk1] + if yymok1 { + yyms1 = false + } + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + if yymv1 != nil { + *yymv1 = Resources{} + } + } else { + if yymv1 == nil { + yymv1 = new(Resources) + } + yymv1.CodecDecodeSelf(d) + } + + if yyms1 && yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } // else len==0: TODO: Should we clear map entries? + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) encMapstringPtrtoTaskState(v map[string]*TaskState, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeMapStart(len(v)) + for yyk1, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerMapKey100) + yym2 := z.EncBinary() + _ = yym2 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(yyk1)) + } + z.EncSendContainerState(codecSelfer_containerMapValue100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) decMapstringPtrtoTaskState(v *map[string]*TaskState, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyl1 := r.ReadMapStart() + yybh1 := z.DecBasicHandle() + if yyv1 == nil { + yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 24) + yyv1 = make(map[string]*TaskState, yyrl1) + *v = yyv1 + } + var yymk1 string + var yymv1 *TaskState + var yymg1, yyms1, yymok1 bool + if yybh1.MapValueReset { + yymg1 = true + } + if yyl1 > 0 { + for yyj1 := 0; yyj1 < yyl1; yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv2 := &yymk1 + yym3 := z.DecBinary() + _ = yym3 + if false { + } else { + *((*string)(yyv2)) = r.DecodeString() + } + } + + yyms1 = true + if yymg1 { + yymv1, yymok1 = yyv1[yymk1] + if yymok1 { + yyms1 = false + } + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + if yymv1 != nil { + *yymv1 = TaskState{} + } + } else { + if yymv1 == nil { + yymv1 = new(TaskState) + } + yymv1.CodecDecodeSelf(d) + } + + if yyms1 && yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } else if yyl1 < 0 { + for yyj1 := 0; !r.CheckBreak(); yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv5 := &yymk1 + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } + } + + yyms1 = true + if yymg1 { + yymv1, yymok1 = yyv1[yymk1] + if yymok1 { + yyms1 = false + } + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + if yymv1 != nil { + *yymv1 = TaskState{} + } + } else { + if yymv1 == nil { + yymv1 = new(TaskState) + } + yymv1.CodecDecodeSelf(d) + } + + if yyms1 && yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } // else len==0: TODO: Should we clear map entries? + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) encMapstringSlicePtrtoAllocation(v map[string][]*Allocation, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeMapStart(len(v)) + for yyk1, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerMapKey100) + yym2 := z.EncBinary() + _ = yym2 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(yyk1)) + } + z.EncSendContainerState(codecSelfer_containerMapValue100) + if yyv1 == nil { + r.EncodeNil() + } else { + yym3 := z.EncBinary() + _ = yym3 + if false { + } else { + h.encSlicePtrtoAllocation(([]*Allocation)(yyv1), e) + } + } + } + z.EncSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) decMapstringSlicePtrtoAllocation(v *map[string][]*Allocation, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyl1 := r.ReadMapStart() + yybh1 := z.DecBasicHandle() + if yyv1 == nil { + yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 40) + yyv1 = make(map[string][]*Allocation, yyrl1) + *v = yyv1 + } + var yymk1 string + var yymv1 []*Allocation + var yymg1 bool + if yybh1.MapValueReset { + yymg1 = true + } + if yyl1 > 0 { + for yyj1 := 0; yyj1 < yyl1; yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv2 := &yymk1 + yym3 := z.DecBinary() + _ = yym3 + if false { + } else { + *((*string)(yyv2)) = r.DecodeString() + } + } + + if yymg1 { + yymv1 = yyv1[yymk1] + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + yymv1 = nil + } else { + yyv4 := &yymv1 + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSlicePtrtoAllocation((*[]*Allocation)(yyv4), d) + } + } + + if yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } else if yyl1 < 0 { + for yyj1 := 0; !r.CheckBreak(); yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv6 := &yymk1 + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + + if yymg1 { + yymv1 = yyv1[yymk1] + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + yymv1 = nil + } else { + yyv8 := &yymv1 + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + h.decSlicePtrtoAllocation((*[]*Allocation)(yyv8), d) + } + } + + if yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } // else len==0: TODO: Should we clear map entries? + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) encMapstringPtrtoDesiredUpdates(v map[string]*DesiredUpdates, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeMapStart(len(v)) + for yyk1, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerMapKey100) + yym2 := z.EncBinary() + _ = yym2 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(yyk1)) + } + z.EncSendContainerState(codecSelfer_containerMapValue100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) decMapstringPtrtoDesiredUpdates(v *map[string]*DesiredUpdates, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyl1 := r.ReadMapStart() + yybh1 := z.DecBasicHandle() + if yyv1 == nil { + yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 24) + yyv1 = make(map[string]*DesiredUpdates, yyrl1) + *v = yyv1 + } + var yymk1 string + var yymv1 *DesiredUpdates + var yymg1, yyms1, yymok1 bool + if yybh1.MapValueReset { + yymg1 = true + } + if yyl1 > 0 { + for yyj1 := 0; yyj1 < yyl1; yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv2 := &yymk1 + yym3 := z.DecBinary() + _ = yym3 + if false { + } else { + *((*string)(yyv2)) = r.DecodeString() + } + } + + yyms1 = true + if yymg1 { + yymv1, yymok1 = yyv1[yymk1] + if yymok1 { + yyms1 = false + } + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + if yymv1 != nil { + *yymv1 = DesiredUpdates{} + } + } else { + if yymv1 == nil { + yymv1 = new(DesiredUpdates) + } + yymv1.CodecDecodeSelf(d) + } + + if yyms1 && yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } else if yyl1 < 0 { + for yyj1 := 0; !r.CheckBreak(); yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv5 := &yymk1 + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } + } + + yyms1 = true + if yymg1 { + yymv1, yymok1 = yyv1[yymk1] + if yymok1 { + yyms1 = false + } + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + if yymv1 != nil { + *yymv1 = DesiredUpdates{} + } + } else { + if yymv1 == nil { + yymv1 = new(DesiredUpdates) + } + yymv1.CodecDecodeSelf(d) + } + + if yyms1 && yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } // else len==0: TODO: Should we clear map entries? + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) encSlicePtrtoACLPolicyListStub(v []*ACLPolicyListStub, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoACLPolicyListStub(v *[]*ACLPolicyListStub, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*ACLPolicyListStub{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*ACLPolicyListStub, yyrl1) + } + } else { + yyv1 = make([]*ACLPolicyListStub, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = ACLPolicyListStub{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(ACLPolicyListStub) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = ACLPolicyListStub{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(ACLPolicyListStub) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *ACLPolicyListStub + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = ACLPolicyListStub{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(ACLPolicyListStub) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*ACLPolicyListStub{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encMapstringPtrtoACLPolicy(v map[string]*ACLPolicy, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeMapStart(len(v)) + for yyk1, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerMapKey100) + yym2 := z.EncBinary() + _ = yym2 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(yyk1)) + } + z.EncSendContainerState(codecSelfer_containerMapValue100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) decMapstringPtrtoACLPolicy(v *map[string]*ACLPolicy, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyl1 := r.ReadMapStart() + yybh1 := z.DecBasicHandle() + if yyv1 == nil { + yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 24) + yyv1 = make(map[string]*ACLPolicy, yyrl1) + *v = yyv1 + } + var yymk1 string + var yymv1 *ACLPolicy + var yymg1, yyms1, yymok1 bool + if yybh1.MapValueReset { + yymg1 = true + } + if yyl1 > 0 { + for yyj1 := 0; yyj1 < yyl1; yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv2 := &yymk1 + yym3 := z.DecBinary() + _ = yym3 + if false { + } else { + *((*string)(yyv2)) = r.DecodeString() + } + } + + yyms1 = true + if yymg1 { + yymv1, yymok1 = yyv1[yymk1] + if yymok1 { + yyms1 = false + } + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + if yymv1 != nil { + *yymv1 = ACLPolicy{} + } + } else { + if yymv1 == nil { + yymv1 = new(ACLPolicy) + } + yymv1.CodecDecodeSelf(d) + } + + if yyms1 && yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } else if yyl1 < 0 { + for yyj1 := 0; !r.CheckBreak(); yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv5 := &yymk1 + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } + } + + yyms1 = true + if yymg1 { + yymv1, yymok1 = yyv1[yymk1] + if yymok1 { + yyms1 = false + } + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + if yymv1 != nil { + *yymv1 = ACLPolicy{} + } + } else { + if yymv1 == nil { + yymv1 = new(ACLPolicy) + } + yymv1.CodecDecodeSelf(d) + } + + if yyms1 && yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } // else len==0: TODO: Should we clear map entries? + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) encSlicePtrtoACLPolicy(v []*ACLPolicy, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoACLPolicy(v *[]*ACLPolicy, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*ACLPolicy{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*ACLPolicy, yyrl1) + } + } else { + yyv1 = make([]*ACLPolicy, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = ACLPolicy{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(ACLPolicy) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = ACLPolicy{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(ACLPolicy) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *ACLPolicy + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = ACLPolicy{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(ACLPolicy) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*ACLPolicy{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encSlicePtrtoACLTokenListStub(v []*ACLTokenListStub, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoACLTokenListStub(v *[]*ACLTokenListStub, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*ACLTokenListStub{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*ACLTokenListStub, yyrl1) + } + } else { + yyv1 = make([]*ACLTokenListStub, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = ACLTokenListStub{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(ACLTokenListStub) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = ACLTokenListStub{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(ACLTokenListStub) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *ACLTokenListStub + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = ACLTokenListStub{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(ACLTokenListStub) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*ACLTokenListStub{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer100) encMapstringPtrtoACLToken(v map[string]*ACLToken, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeMapStart(len(v)) + for yyk1, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerMapKey100) + yym2 := z.EncBinary() + _ = yym2 + if false { + } else { + r.EncodeString(codecSelferC_UTF8100, string(yyk1)) + } + z.EncSendContainerState(codecSelfer_containerMapValue100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) decMapstringPtrtoACLToken(v *map[string]*ACLToken, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyl1 := r.ReadMapStart() + yybh1 := z.DecBasicHandle() + if yyv1 == nil { + yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 24) + yyv1 = make(map[string]*ACLToken, yyrl1) + *v = yyv1 + } + var yymk1 string + var yymv1 *ACLToken + var yymg1, yyms1, yymok1 bool + if yybh1.MapValueReset { + yymg1 = true + } + if yyl1 > 0 { + for yyj1 := 0; yyj1 < yyl1; yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv2 := &yymk1 + yym3 := z.DecBinary() + _ = yym3 + if false { + } else { + *((*string)(yyv2)) = r.DecodeString() + } + } + + yyms1 = true + if yymg1 { + yymv1, yymok1 = yyv1[yymk1] + if yymok1 { + yyms1 = false + } + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + if yymv1 != nil { + *yymv1 = ACLToken{} + } + } else { + if yymv1 == nil { + yymv1 = new(ACLToken) + } + yymv1.CodecDecodeSelf(d) + } + + if yyms1 && yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } else if yyl1 < 0 { + for yyj1 := 0; !r.CheckBreak(); yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey100) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv5 := &yymk1 + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } + } + + yyms1 = true + if yymg1 { + yymv1, yymok1 = yyv1[yymk1] + if yymok1 { + yyms1 = false + } + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue100) + if r.TryDecodeAsNil() { + if yymv1 != nil { + *yymv1 = ACLToken{} + } + } else { + if yymv1 == nil { + yymv1 = new(ACLToken) + } + yymv1.CodecDecodeSelf(d) + } + + if yyms1 && yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } // else len==0: TODO: Should we clear map entries? + z.DecSendContainerState(codecSelfer_containerMapEnd100) +} + +func (x codecSelfer100) encSlicePtrtoACLToken(v []*ACLToken, e *codec1978.Encoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem100) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd100) +} + +func (x codecSelfer100) decSlicePtrtoACLToken(v *[]*ACLToken, d *codec1978.Decoder) { + var h codecSelfer100 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []*ACLToken{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]*ACLToken, yyrl1) + } + } else { + yyv1 = make([]*ACLToken, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = ACLToken{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(ACLToken) + } + yyw2 := yyv1[yyj1] + yyw2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, nil) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = ACLToken{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(ACLToken) + } + yyw3 := yyv1[yyj1] + yyw3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, nil) // var yyz1 *ACLToken + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + if yyv1[yyj1] != nil { + *yyv1[yyj1] = ACLToken{} + } + } else { + if yyv1[yyj1] == nil { + yyv1[yyj1] = new(ACLToken) + } + yyw4 := yyv1[yyj1] + yyw4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []*ACLToken{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} From 2f245ac7fc9b916eb4af8a62a471dcd0b468a8c8 Mon Sep 17 00:00:00 2001 From: Alex Dadgar Date: Tue, 19 Dec 2017 17:06:39 -0800 Subject: [PATCH 020/136] Release v0.7.1 --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index c5826fb51..a828d589e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,4 @@ -## 0.7.1 (Unreleased) +## 0.7.1 (December 19, 2017) __BACKWARDS INCOMPATIBILITIES:__ * client: The format of service IDs in Consul has changed. If you rely upon From 742107aa2b5ce8c81378a57dd4ae454ac09885e7 Mon Sep 17 00:00:00 2001 From: Alex Dadgar Date: Tue, 19 Dec 2017 17:10:52 -0800 Subject: [PATCH 021/136] bump version and remove generated structs --- command/agent/fs_endpoint.generated.go | 1061 - nomad/structs/structs.generated.go | 77269 ----------------------- version/version.go | 4 +- 3 files changed, 2 insertions(+), 78332 deletions(-) delete mode 100644 command/agent/fs_endpoint.generated.go delete mode 100644 nomad/structs/structs.generated.go diff --git a/command/agent/fs_endpoint.generated.go b/command/agent/fs_endpoint.generated.go deleted file mode 100644 index 3102e636c..000000000 --- a/command/agent/fs_endpoint.generated.go +++ /dev/null @@ -1,1061 +0,0 @@ -// ************************************************************ -// DO NOT EDIT. -// THIS FILE IS AUTO-GENERATED BY codecgen. -// ************************************************************ - -package agent - -import ( - "errors" - "fmt" - codec1978 "github.com/ugorji/go/codec" - io "io" - "reflect" - "runtime" -) - -const ( - // ----- content types ---- - codecSelferC_UTF8101 = 1 - codecSelferC_RAW101 = 0 - // ----- value types used ---- - codecSelferValueTypeArray101 = 10 - codecSelferValueTypeMap101 = 9 - // ----- containerStateValues ---- - codecSelfer_containerMapKey101 = 2 - codecSelfer_containerMapValue101 = 3 - codecSelfer_containerMapEnd101 = 4 - codecSelfer_containerArrayElem101 = 6 - codecSelfer_containerArrayEnd101 = 7 -) - -var ( - codecSelferBitsize101 = uint8(reflect.TypeOf(uint(0)).Bits()) - codecSelferOnlyMapOrArrayEncodeToStructErr101 = errors.New(`only encoded map or array can be decoded into a struct`) -) - -type codecSelfer101 struct{} - -func init() { - if codec1978.GenVersion != 5 { - _, file, _, _ := runtime.Caller(0) - err := fmt.Errorf("codecgen version mismatch: current: %v, need %v. Re-generate file: %v", - 5, codec1978.GenVersion, file) - panic(err) - } - if false { // reference the types, but skip this branch at build/run time - var v0 io.Reader - _ = v0 - } -} - -func (x *ReadCloserWrapper) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer101 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [2]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(2) - } else { - yynn2 = 2 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem101) - if x.Reader == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else if z.HasExtensions() && z.EncExt(x.Reader) { - } else { - z.EncFallback(x.Reader) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey101) - r.EncodeString(codecSelferC_UTF8101, string("Reader")) - z.EncSendContainerState(codecSelfer_containerMapValue101) - if x.Reader == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else if z.HasExtensions() && z.EncExt(x.Reader) { - } else { - z.EncFallback(x.Reader) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem101) - if x.Closer == nil { - r.EncodeNil() - } else { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else if z.HasExtensions() && z.EncExt(x.Closer) { - } else { - z.EncFallback(x.Closer) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey101) - r.EncodeString(codecSelferC_UTF8101, string("Closer")) - z.EncSendContainerState(codecSelfer_containerMapValue101) - if x.Closer == nil { - r.EncodeNil() - } else { - yym8 := z.EncBinary() - _ = yym8 - if false { - } else if z.HasExtensions() && z.EncExt(x.Closer) { - } else { - z.EncFallback(x.Closer) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd101) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd101) - } - } - } -} - -func (x *ReadCloserWrapper) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer101 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap101 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd101) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray101 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd101) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr101) - } - } -} - -func (x *ReadCloserWrapper) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer101 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey101) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue101) - switch yys3 { - case "Reader": - if r.TryDecodeAsNil() { - x.Reader = nil - } else { - yyv4 := &x.Reader - yym5 := z.DecBinary() - _ = yym5 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4) { - } else { - z.DecFallback(yyv4, true) - } - } - case "Closer": - if r.TryDecodeAsNil() { - x.Closer = nil - } else { - yyv6 := &x.Closer - yym7 := z.DecBinary() - _ = yym7 - if false { - } else if z.HasExtensions() && z.DecExt(yyv6) { - } else { - z.DecFallback(yyv6, true) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd101) -} - -func (x *ReadCloserWrapper) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer101 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj8 int - var yyb8 bool - var yyhl8 bool = l >= 0 - yyj8++ - if yyhl8 { - yyb8 = yyj8 > l - } else { - yyb8 = r.CheckBreak() - } - if yyb8 { - z.DecSendContainerState(codecSelfer_containerArrayEnd101) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem101) - if r.TryDecodeAsNil() { - x.Reader = nil - } else { - yyv9 := &x.Reader - yym10 := z.DecBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.DecExt(yyv9) { - } else { - z.DecFallback(yyv9, true) - } - } - yyj8++ - if yyhl8 { - yyb8 = yyj8 > l - } else { - yyb8 = r.CheckBreak() - } - if yyb8 { - z.DecSendContainerState(codecSelfer_containerArrayEnd101) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem101) - if r.TryDecodeAsNil() { - x.Closer = nil - } else { - yyv11 := &x.Closer - yym12 := z.DecBinary() - _ = yym12 - if false { - } else if z.HasExtensions() && z.DecExt(yyv11) { - } else { - z.DecFallback(yyv11, true) - } - } - for { - yyj8++ - if yyhl8 { - yyb8 = yyj8 > l - } else { - yyb8 = r.CheckBreak() - } - if yyb8 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem101) - z.DecStructFieldNotFound(yyj8-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd101) -} - -func (x *StreamFrame) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer101 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - yyq2[0] = x.Offset != 0 - yyq2[1] = len(x.Data) != 0 - yyq2[2] = x.File != "" - yyq2[3] = x.FileEvent != "" - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 0 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem101) - if yyq2[0] { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeInt(int64(x.Offset)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq2[0] { - z.EncSendContainerState(codecSelfer_containerMapKey101) - r.EncodeString(codecSelferC_UTF8101, string("Offset")) - z.EncSendContainerState(codecSelfer_containerMapValue101) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeInt(int64(x.Offset)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem101) - if yyq2[1] { - if x.Data == nil { - r.EncodeNil() - } else { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW101, []byte(x.Data)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2[1] { - z.EncSendContainerState(codecSelfer_containerMapKey101) - r.EncodeString(codecSelferC_UTF8101, string("Data")) - z.EncSendContainerState(codecSelfer_containerMapValue101) - if x.Data == nil { - r.EncodeNil() - } else { - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW101, []byte(x.Data)) - } - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem101) - if yyq2[2] { - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8101, string(x.File)) - } - } else { - r.EncodeString(codecSelferC_UTF8101, "") - } - } else { - if yyq2[2] { - z.EncSendContainerState(codecSelfer_containerMapKey101) - r.EncodeString(codecSelferC_UTF8101, string("File")) - z.EncSendContainerState(codecSelfer_containerMapValue101) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8101, string(x.File)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem101) - if yyq2[3] { - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8101, string(x.FileEvent)) - } - } else { - r.EncodeString(codecSelferC_UTF8101, "") - } - } else { - if yyq2[3] { - z.EncSendContainerState(codecSelfer_containerMapKey101) - r.EncodeString(codecSelferC_UTF8101, string("FileEvent")) - z.EncSendContainerState(codecSelfer_containerMapValue101) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8101, string(x.FileEvent)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd101) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd101) - } - } - } -} - -func (x *StreamFrame) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer101 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap101 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd101) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray101 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd101) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr101) - } - } -} - -func (x *StreamFrame) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer101 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey101) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue101) - switch yys3 { - case "Offset": - if r.TryDecodeAsNil() { - x.Offset = 0 - } else { - yyv4 := &x.Offset - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*int64)(yyv4)) = int64(r.DecodeInt(64)) - } - } - case "Data": - if r.TryDecodeAsNil() { - x.Data = nil - } else { - yyv6 := &x.Data - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *yyv6 = r.DecodeBytes(*(*[]byte)(yyv6), false, false) - } - } - case "File": - if r.TryDecodeAsNil() { - x.File = "" - } else { - yyv8 := &x.File - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "FileEvent": - if r.TryDecodeAsNil() { - x.FileEvent = "" - } else { - yyv10 := &x.FileEvent - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd101) -} - -func (x *StreamFrame) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer101 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd101) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem101) - if r.TryDecodeAsNil() { - x.Offset = 0 - } else { - yyv13 := &x.Offset - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*int64)(yyv13)) = int64(r.DecodeInt(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd101) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem101) - if r.TryDecodeAsNil() { - x.Data = nil - } else { - yyv15 := &x.Data - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *yyv15 = r.DecodeBytes(*(*[]byte)(yyv15), false, false) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd101) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem101) - if r.TryDecodeAsNil() { - x.File = "" - } else { - yyv17 := &x.File - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd101) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem101) - if r.TryDecodeAsNil() { - x.FileEvent = "" - } else { - yyv19 := &x.FileEvent - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem101) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd101) -} - -func (x *StreamFramer) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer101 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [0]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(0) - } else { - yynn2 = 0 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd101) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd101) - } - } - } -} - -func (x *StreamFramer) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer101 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap101 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd101) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray101 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd101) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr101) - } - } -} - -func (x *StreamFramer) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer101 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey101) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue101) - switch yys3 { - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd101) -} - -func (x *StreamFramer) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer101 - 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 - } - z.DecSendContainerState(codecSelfer_containerArrayElem101) - z.DecStructFieldNotFound(yyj4-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd101) -} - -func (x *indexTuple) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer101 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [0]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(0) - } else { - yynn2 = 0 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd101) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd101) - } - } - } -} - -func (x *indexTuple) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer101 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap101 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd101) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray101 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd101) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr101) - } - } -} - -func (x *indexTuple) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer101 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey101) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue101) - switch yys3 { - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd101) -} - -func (x *indexTuple) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer101 - 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 - } - z.DecSendContainerState(codecSelfer_containerArrayElem101) - z.DecStructFieldNotFound(yyj4-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd101) -} - -func (x indexTupleArray) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer101 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - h.encindexTupleArray((indexTupleArray)(x), e) - } - } -} - -func (x *indexTupleArray) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer101 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - h.decindexTupleArray((*indexTupleArray)(x), d) - } -} - -func (x codecSelfer101) encindexTupleArray(v indexTupleArray, e *codec1978.Encoder) { - var h codecSelfer101 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem101) - yy2 := &yyv1 - yy2.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd101) -} - -func (x codecSelfer101) decindexTupleArray(v *indexTupleArray, d *codec1978.Decoder) { - var h codecSelfer101 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []indexTuple{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]indexTuple, yyrl1) - } - } else { - yyv1 = make([]indexTuple, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - yyv1[yyj1] = indexTuple{} - } else { - yyv2 := &yyv1[yyj1] - yyv2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, indexTuple{}) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - yyv1[yyj1] = indexTuple{} - } else { - yyv3 := &yyv1[yyj1] - yyv3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, indexTuple{}) // var yyz1 indexTuple - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - yyv1[yyj1] = indexTuple{} - } else { - yyv4 := &yyv1[yyj1] - yyv4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []indexTuple{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} diff --git a/nomad/structs/structs.generated.go b/nomad/structs/structs.generated.go deleted file mode 100644 index d6cf62887..000000000 --- a/nomad/structs/structs.generated.go +++ /dev/null @@ -1,77269 +0,0 @@ -// ************************************************************ -// DO NOT EDIT. -// THIS FILE IS AUTO-GENERATED BY codecgen. -// ************************************************************ - -package structs - -import ( - "errors" - "fmt" - codec1978 "github.com/ugorji/go/codec" - net "net" - "reflect" - "runtime" - time "time" -) - -const ( - // ----- content types ---- - codecSelferC_UTF8100 = 1 - codecSelferC_RAW100 = 0 - // ----- value types used ---- - codecSelferValueTypeArray100 = 10 - codecSelferValueTypeMap100 = 9 - // ----- containerStateValues ---- - codecSelfer_containerMapKey100 = 2 - codecSelfer_containerMapValue100 = 3 - codecSelfer_containerMapEnd100 = 4 - codecSelfer_containerArrayElem100 = 6 - codecSelfer_containerArrayEnd100 = 7 -) - -var ( - codecSelferBitsize100 = uint8(reflect.TypeOf(uint(0)).Bits()) - codecSelferOnlyMapOrArrayEncodeToStructErr100 = errors.New(`only encoded map or array can be decoded into a struct`) -) - -type codecSelfer100 struct{} - -func init() { - if codec1978.GenVersion != 5 { - _, file, _, _ := runtime.Caller(0) - err := fmt.Errorf("codecgen version mismatch: current: %v, need %v. Re-generate file: %v", - 5, codec1978.GenVersion, file) - panic(err) - } - if false { // reference the types, but skip this branch at build/run time - var v0 net.IP - var v1 time.Duration - _, _ = v0, v1 - } -} - -func (x MessageType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - r.EncodeUint(uint64(x)) - } -} - -func (x *MessageType) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*uint8)(x)) = uint8(r.DecodeUint(8)) - } -} - -func (x Context) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x)) - } -} - -func (x *Context) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x *NamespacedID) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [2]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(2) - } else { - yynn2 = 2 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *NamespacedID) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *NamespacedID) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "ID": - if r.TryDecodeAsNil() { - x.ID = "" - } else { - yyv4 := &x.ID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv6 := &x.Namespace - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *NamespacedID) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj8 int - var yyb8 bool - var yyhl8 bool = l >= 0 - yyj8++ - if yyhl8 { - yyb8 = yyj8 > l - } else { - yyb8 = r.CheckBreak() - } - if yyb8 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ID = "" - } else { - yyv9 := &x.ID - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*string)(yyv9)) = r.DecodeString() - } - } - yyj8++ - if yyhl8 { - yyb8 = yyj8 > l - } else { - yyb8 = r.CheckBreak() - } - if yyb8 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv11 := &x.Namespace - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*string)(yyv11)) = r.DecodeString() - } - } - for { - yyj8++ - if yyhl8 { - yyb8 = yyj8 > l - } else { - yyb8 = r.CheckBreak() - } - if yyb8 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj8-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *QueryOptions) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [7]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(7) - } else { - yynn2 = 7 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *QueryOptions) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *QueryOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv4 := &x.Region - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv6 := &x.Namespace - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv8 := &x.MinQueryIndex - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv10 := &x.MaxQueryTime - yym11 := z.DecBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.DecExt(yyv10) { - } else { - *((*int64)(yyv10)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv12 := &x.AllowStale - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*bool)(yyv12)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv14 := &x.Prefix - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*string)(yyv14)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv16 := &x.AuthToken - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *QueryOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj18 int - var yyb18 bool - var yyhl18 bool = l >= 0 - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv19 := &x.Region - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv21 := &x.Namespace - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv23 := &x.MinQueryIndex - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv25 := &x.MaxQueryTime - yym26 := z.DecBinary() - _ = yym26 - if false { - } else if z.HasExtensions() && z.DecExt(yyv25) { - } else { - *((*int64)(yyv25)) = int64(r.DecodeInt(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv27 := &x.AllowStale - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*bool)(yyv27)) = r.DecodeBool() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv29 := &x.Prefix - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*string)(yyv29)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv31 := &x.AuthToken - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*string)(yyv31)) = r.DecodeString() - } - } - for { - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj18-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *WriteRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [3]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(3) - } else { - yynn2 = 3 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *WriteRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *WriteRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv4 := &x.Region - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv6 := &x.Namespace - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv8 := &x.AuthToken - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *WriteRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj10 int - var yyb10 bool - var yyhl10 bool = l >= 0 - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv11 := &x.Region - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*string)(yyv11)) = r.DecodeString() - } - } - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv13 := &x.Namespace - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*string)(yyv13)) = r.DecodeString() - } - } - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv15 := &x.AuthToken - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - for { - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj10-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *QueryMeta) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [3]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(3) - } else { - yynn2 = 3 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *QueryMeta) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *QueryMeta) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv4 := &x.Index - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*uint64)(yyv4)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv6 := &x.LastContact - yym7 := z.DecBinary() - _ = yym7 - if false { - } else if z.HasExtensions() && z.DecExt(yyv6) { - } else { - *((*int64)(yyv6)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv8 := &x.KnownLeader - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*bool)(yyv8)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *QueryMeta) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj10 int - var yyb10 bool - var yyhl10 bool = l >= 0 - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv11 := &x.Index - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*uint64)(yyv11)) = uint64(r.DecodeUint(64)) - } - } - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv13 := &x.LastContact - yym14 := z.DecBinary() - _ = yym14 - if false { - } else if z.HasExtensions() && z.DecExt(yyv13) { - } else { - *((*int64)(yyv13)) = int64(r.DecodeInt(64)) - } - } - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv15 := &x.KnownLeader - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*bool)(yyv15)) = r.DecodeBool() - } - } - for { - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj10-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *WriteMeta) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [1]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(1) - } else { - yynn2 = 1 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *WriteMeta) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *WriteMeta) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv4 := &x.Index - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*uint64)(yyv4)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *WriteMeta) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - 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 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv7 := &x.Index - yym8 := z.DecBinary() - _ = yym8 - if false { - } else { - *((*uint64)(yyv7)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj6++ - if yyhl6 { - yyb6 = yyj6 > l - } else { - yyb6 = r.CheckBreak() - } - if yyb6 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj6-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *NodeRegisterRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Node == nil { - r.EncodeNil() - } else { - x.Node.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Node")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Node == nil { - r.EncodeNil() - } else { - x.Node.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *NodeRegisterRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *NodeRegisterRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Node": - if r.TryDecodeAsNil() { - if x.Node != nil { - x.Node = nil - } - } else { - if x.Node == nil { - x.Node = new(Node) - } - x.Node.CodecDecodeSelf(d) - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv5 := &x.Region - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*string)(yyv5)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv7 := &x.Namespace - yym8 := z.DecBinary() - _ = yym8 - if false { - } else { - *((*string)(yyv7)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv9 := &x.AuthToken - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*string)(yyv9)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *NodeRegisterRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj11 int - var yyb11 bool - var yyhl11 bool = l >= 0 - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Node != nil { - x.Node = nil - } - } else { - if x.Node == nil { - x.Node = new(Node) - } - x.Node.CodecDecodeSelf(d) - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv13 := &x.Region - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*string)(yyv13)) = r.DecodeString() - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv15 := &x.Namespace - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv17 := &x.AuthToken - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - for { - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj11-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *NodeDeregisterRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodeID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *NodeDeregisterRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *NodeDeregisterRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "NodeID": - if r.TryDecodeAsNil() { - x.NodeID = "" - } else { - yyv4 := &x.NodeID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv10 := &x.AuthToken - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *NodeDeregisterRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodeID = "" - } else { - yyv13 := &x.NodeID - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*string)(yyv13)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv15 := &x.Region - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv17 := &x.Namespace - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv19 := &x.AuthToken - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *NodeServerInfo) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.RPCAdvertiseAddr)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("RPCAdvertiseAddr")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.RPCAdvertiseAddr)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeInt(int64(x.RPCMajorVersion)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("RPCMajorVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeInt(int64(x.RPCMajorVersion)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeInt(int64(x.RPCMinorVersion)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("RPCMinorVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeInt(int64(x.RPCMinorVersion)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Datacenter)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Datacenter")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Datacenter)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *NodeServerInfo) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *NodeServerInfo) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "RPCAdvertiseAddr": - if r.TryDecodeAsNil() { - x.RPCAdvertiseAddr = "" - } else { - yyv4 := &x.RPCAdvertiseAddr - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "RPCMajorVersion": - if r.TryDecodeAsNil() { - x.RPCMajorVersion = 0 - } else { - yyv6 := &x.RPCMajorVersion - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*int32)(yyv6)) = int32(r.DecodeInt(32)) - } - } - case "RPCMinorVersion": - if r.TryDecodeAsNil() { - x.RPCMinorVersion = 0 - } else { - yyv8 := &x.RPCMinorVersion - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*int32)(yyv8)) = int32(r.DecodeInt(32)) - } - } - case "Datacenter": - if r.TryDecodeAsNil() { - x.Datacenter = "" - } else { - yyv10 := &x.Datacenter - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *NodeServerInfo) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.RPCAdvertiseAddr = "" - } else { - yyv13 := &x.RPCAdvertiseAddr - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*string)(yyv13)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.RPCMajorVersion = 0 - } else { - yyv15 := &x.RPCMajorVersion - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*int32)(yyv15)) = int32(r.DecodeInt(32)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.RPCMinorVersion = 0 - } else { - yyv17 := &x.RPCMinorVersion - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*int32)(yyv17)) = int32(r.DecodeInt(32)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Datacenter = "" - } else { - yyv19 := &x.Datacenter - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *NodeUpdateStatusRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 5 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodeID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Status)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Status")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Status)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *NodeUpdateStatusRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *NodeUpdateStatusRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "NodeID": - if r.TryDecodeAsNil() { - x.NodeID = "" - } else { - yyv4 := &x.NodeID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Status": - if r.TryDecodeAsNil() { - x.Status = "" - } else { - yyv6 := &x.Status - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv8 := &x.Region - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv10 := &x.Namespace - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv12 := &x.AuthToken - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *NodeUpdateStatusRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj14 int - var yyb14 bool - var yyhl14 bool = l >= 0 - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodeID = "" - } else { - yyv15 := &x.NodeID - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - yyv17 := &x.Status - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv19 := &x.Region - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv21 := &x.Namespace - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv23 := &x.AuthToken - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - for { - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj14-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *NodeUpdateDrainRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 5 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodeID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeBool(bool(x.Drain)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Drain")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeBool(bool(x.Drain)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *NodeUpdateDrainRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *NodeUpdateDrainRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "NodeID": - if r.TryDecodeAsNil() { - x.NodeID = "" - } else { - yyv4 := &x.NodeID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Drain": - if r.TryDecodeAsNil() { - x.Drain = false - } else { - yyv6 := &x.Drain - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*bool)(yyv6)) = r.DecodeBool() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv8 := &x.Region - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv10 := &x.Namespace - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv12 := &x.AuthToken - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *NodeUpdateDrainRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj14 int - var yyb14 bool - var yyhl14 bool = l >= 0 - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodeID = "" - } else { - yyv15 := &x.NodeID - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Drain = false - } else { - yyv17 := &x.Drain - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*bool)(yyv17)) = r.DecodeBool() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv19 := &x.Region - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv21 := &x.Namespace - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv23 := &x.AuthToken - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - for { - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj14-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *NodeEvaluateRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodeID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *NodeEvaluateRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *NodeEvaluateRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "NodeID": - if r.TryDecodeAsNil() { - x.NodeID = "" - } else { - yyv4 := &x.NodeID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv10 := &x.AuthToken - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *NodeEvaluateRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodeID = "" - } else { - yyv13 := &x.NodeID - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*string)(yyv13)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv15 := &x.Region - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv17 := &x.Namespace - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv19 := &x.AuthToken - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *NodeSpecificRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [9]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(9) - } else { - yynn2 = 9 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodeID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.SecretID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("SecretID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.SecretID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym28 := z.EncBinary() - _ = yym28 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym29 := z.EncBinary() - _ = yym29 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *NodeSpecificRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *NodeSpecificRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "NodeID": - if r.TryDecodeAsNil() { - x.NodeID = "" - } else { - yyv4 := &x.NodeID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "SecretID": - if r.TryDecodeAsNil() { - x.SecretID = "" - } else { - yyv6 := &x.SecretID - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv8 := &x.Region - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv10 := &x.Namespace - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv12 := &x.MinQueryIndex - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*uint64)(yyv12)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv14 := &x.MaxQueryTime - yym15 := z.DecBinary() - _ = yym15 - if false { - } else if z.HasExtensions() && z.DecExt(yyv14) { - } else { - *((*int64)(yyv14)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv16 := &x.AllowStale - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*bool)(yyv16)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv18 := &x.Prefix - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv20 := &x.AuthToken - yym21 := z.DecBinary() - _ = yym21 - if false { - } else { - *((*string)(yyv20)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *NodeSpecificRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj22 int - var yyb22 bool - var yyhl22 bool = l >= 0 - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodeID = "" - } else { - yyv23 := &x.NodeID - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.SecretID = "" - } else { - yyv25 := &x.SecretID - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv27 := &x.Region - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*string)(yyv27)) = r.DecodeString() - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv29 := &x.Namespace - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*string)(yyv29)) = r.DecodeString() - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv31 := &x.MinQueryIndex - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*uint64)(yyv31)) = uint64(r.DecodeUint(64)) - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv33 := &x.MaxQueryTime - yym34 := z.DecBinary() - _ = yym34 - if false { - } else if z.HasExtensions() && z.DecExt(yyv33) { - } else { - *((*int64)(yyv33)) = int64(r.DecodeInt(64)) - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv35 := &x.AllowStale - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*bool)(yyv35)) = r.DecodeBool() - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv37 := &x.Prefix - yym38 := z.DecBinary() - _ = yym38 - if false { - } else { - *((*string)(yyv37)) = r.DecodeString() - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv39 := &x.AuthToken - yym40 := z.DecBinary() - _ = yym40 - if false { - } else { - *((*string)(yyv39)) = r.DecodeString() - } - } - for { - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj22-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *SearchResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 5 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Matches == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encMapContextSlicestring((map[Context][]string)(x.Matches), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Matches")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Matches == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encMapContextSlicestring((map[Context][]string)(x.Matches), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Truncations == nil { - r.EncodeNil() - } else { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - h.encMapContextbool((map[Context]bool)(x.Truncations), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Truncations")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Truncations == nil { - r.EncodeNil() - } else { - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - h.encMapContextbool((map[Context]bool)(x.Truncations), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *SearchResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *SearchResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Matches": - if r.TryDecodeAsNil() { - x.Matches = nil - } else { - yyv4 := &x.Matches - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decMapContextSlicestring((*map[Context][]string)(yyv4), d) - } - } - case "Truncations": - if r.TryDecodeAsNil() { - x.Truncations = nil - } else { - yyv6 := &x.Truncations - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - h.decMapContextbool((*map[Context]bool)(yyv6), d) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv8 := &x.Index - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv10 := &x.LastContact - yym11 := z.DecBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.DecExt(yyv10) { - } else { - *((*int64)(yyv10)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv12 := &x.KnownLeader - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*bool)(yyv12)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *SearchResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj14 int - var yyb14 bool - var yyhl14 bool = l >= 0 - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Matches = nil - } else { - yyv15 := &x.Matches - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - h.decMapContextSlicestring((*map[Context][]string)(yyv15), d) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Truncations = nil - } else { - yyv17 := &x.Truncations - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - h.decMapContextbool((*map[Context]bool)(yyv17), d) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv19 := &x.Index - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv21 := &x.LastContact - yym22 := z.DecBinary() - _ = yym22 - if false { - } else if z.HasExtensions() && z.DecExt(yyv21) { - } else { - *((*int64)(yyv21)) = int64(r.DecodeInt(64)) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv23 := &x.KnownLeader - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*bool)(yyv23)) = r.DecodeBool() - } - } - for { - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj14-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *SearchRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [8]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(8) - } else { - yynn2 = 8 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - x.Context.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Context")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - x.Context.CodecEncodeSelf(e) - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *SearchRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *SearchRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv4 := &x.Prefix - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Context": - if r.TryDecodeAsNil() { - x.Context = "" - } else { - yyv6 := &x.Context - yyv6.CodecDecodeSelf(d) - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv7 := &x.Region - yym8 := z.DecBinary() - _ = yym8 - if false { - } else { - *((*string)(yyv7)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv9 := &x.Namespace - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*string)(yyv9)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv11 := &x.MinQueryIndex - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*uint64)(yyv11)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv13 := &x.MaxQueryTime - yym14 := z.DecBinary() - _ = yym14 - if false { - } else if z.HasExtensions() && z.DecExt(yyv13) { - } else { - *((*int64)(yyv13)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv15 := &x.AllowStale - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*bool)(yyv15)) = r.DecodeBool() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv17 := &x.AuthToken - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *SearchRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj19 int - var yyb19 bool - var yyhl19 bool = l >= 0 - yyj19++ - if yyhl19 { - yyb19 = yyj19 > l - } else { - yyb19 = r.CheckBreak() - } - if yyb19 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv20 := &x.Prefix - yym21 := z.DecBinary() - _ = yym21 - if false { - } else { - *((*string)(yyv20)) = r.DecodeString() - } - } - yyj19++ - if yyhl19 { - yyb19 = yyj19 > l - } else { - yyb19 = r.CheckBreak() - } - if yyb19 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Context = "" - } else { - yyv22 := &x.Context - yyv22.CodecDecodeSelf(d) - } - yyj19++ - if yyhl19 { - yyb19 = yyj19 > l - } else { - yyb19 = r.CheckBreak() - } - if yyb19 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv23 := &x.Region - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj19++ - if yyhl19 { - yyb19 = yyj19 > l - } else { - yyb19 = r.CheckBreak() - } - if yyb19 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv25 := &x.Namespace - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj19++ - if yyhl19 { - yyb19 = yyj19 > l - } else { - yyb19 = r.CheckBreak() - } - if yyb19 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv27 := &x.MinQueryIndex - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) - } - } - yyj19++ - if yyhl19 { - yyb19 = yyj19 > l - } else { - yyb19 = r.CheckBreak() - } - if yyb19 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv29 := &x.MaxQueryTime - yym30 := z.DecBinary() - _ = yym30 - if false { - } else if z.HasExtensions() && z.DecExt(yyv29) { - } else { - *((*int64)(yyv29)) = int64(r.DecodeInt(64)) - } - } - yyj19++ - if yyhl19 { - yyb19 = yyj19 > l - } else { - yyb19 = r.CheckBreak() - } - if yyb19 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv31 := &x.AllowStale - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*bool)(yyv31)) = r.DecodeBool() - } - } - yyj19++ - if yyhl19 { - yyb19 = yyj19 > l - } else { - yyb19 = r.CheckBreak() - } - if yyb19 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv33 := &x.AuthToken - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - *((*string)(yyv33)) = r.DecodeString() - } - } - for { - yyj19++ - if yyhl19 { - yyb19 = yyj19 > l - } else { - yyb19 = r.CheckBreak() - } - if yyb19 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj19-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobRegisterRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [7]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(7) - } else { - yynn2 = 7 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Job == nil { - r.EncodeNil() - } else { - x.Job.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Job")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Job == nil { - r.EncodeNil() - } else { - x.Job.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeBool(bool(x.EnforceIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EnforceIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeBool(bool(x.EnforceIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.JobModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.JobModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.PolicyOverride)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("PolicyOverride")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.PolicyOverride)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobRegisterRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobRegisterRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Job": - if r.TryDecodeAsNil() { - if x.Job != nil { - x.Job = nil - } - } else { - if x.Job == nil { - x.Job = new(Job) - } - x.Job.CodecDecodeSelf(d) - } - case "EnforceIndex": - if r.TryDecodeAsNil() { - x.EnforceIndex = false - } else { - yyv5 := &x.EnforceIndex - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*bool)(yyv5)) = r.DecodeBool() - } - } - case "JobModifyIndex": - if r.TryDecodeAsNil() { - x.JobModifyIndex = 0 - } else { - yyv7 := &x.JobModifyIndex - yym8 := z.DecBinary() - _ = yym8 - if false { - } else { - *((*uint64)(yyv7)) = uint64(r.DecodeUint(64)) - } - } - case "PolicyOverride": - if r.TryDecodeAsNil() { - x.PolicyOverride = false - } else { - yyv9 := &x.PolicyOverride - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*bool)(yyv9)) = r.DecodeBool() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv11 := &x.Region - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*string)(yyv11)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv13 := &x.Namespace - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*string)(yyv13)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv15 := &x.AuthToken - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobRegisterRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj17 int - var yyb17 bool - var yyhl17 bool = l >= 0 - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Job != nil { - x.Job = nil - } - } else { - if x.Job == nil { - x.Job = new(Job) - } - x.Job.CodecDecodeSelf(d) - } - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EnforceIndex = false - } else { - yyv19 := &x.EnforceIndex - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*bool)(yyv19)) = r.DecodeBool() - } - } - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobModifyIndex = 0 - } else { - yyv21 := &x.JobModifyIndex - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*uint64)(yyv21)) = uint64(r.DecodeUint(64)) - } - } - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.PolicyOverride = false - } else { - yyv23 := &x.PolicyOverride - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*bool)(yyv23)) = r.DecodeBool() - } - } - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv25 := &x.Region - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv27 := &x.Namespace - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*string)(yyv27)) = r.DecodeString() - } - } - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv29 := &x.AuthToken - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*string)(yyv29)) = r.DecodeString() - } - } - for { - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj17-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobDeregisterRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 5 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeBool(bool(x.Purge)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Purge")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeBool(bool(x.Purge)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobDeregisterRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobDeregisterRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "JobID": - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv4 := &x.JobID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Purge": - if r.TryDecodeAsNil() { - x.Purge = false - } else { - yyv6 := &x.Purge - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*bool)(yyv6)) = r.DecodeBool() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv8 := &x.Region - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv10 := &x.Namespace - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv12 := &x.AuthToken - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobDeregisterRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj14 int - var yyb14 bool - var yyhl14 bool = l >= 0 - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv15 := &x.JobID - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Purge = false - } else { - yyv17 := &x.Purge - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*bool)(yyv17)) = r.DecodeBool() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv19 := &x.Region - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv21 := &x.Namespace - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv23 := &x.AuthToken - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - for { - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj14-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobEvaluateRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobEvaluateRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobEvaluateRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "JobID": - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv4 := &x.JobID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv10 := &x.AuthToken - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobEvaluateRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv13 := &x.JobID - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*string)(yyv13)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv15 := &x.Region - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv17 := &x.Namespace - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv19 := &x.AuthToken - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobSpecificRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [9]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(9) - } else { - yynn2 = 9 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeBool(bool(x.AllAllocs)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllAllocs")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeBool(bool(x.AllAllocs)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym28 := z.EncBinary() - _ = yym28 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym29 := z.EncBinary() - _ = yym29 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobSpecificRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobSpecificRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "JobID": - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv4 := &x.JobID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "AllAllocs": - if r.TryDecodeAsNil() { - x.AllAllocs = false - } else { - yyv6 := &x.AllAllocs - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*bool)(yyv6)) = r.DecodeBool() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv8 := &x.Region - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv10 := &x.Namespace - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv12 := &x.MinQueryIndex - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*uint64)(yyv12)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv14 := &x.MaxQueryTime - yym15 := z.DecBinary() - _ = yym15 - if false { - } else if z.HasExtensions() && z.DecExt(yyv14) { - } else { - *((*int64)(yyv14)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv16 := &x.AllowStale - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*bool)(yyv16)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv18 := &x.Prefix - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv20 := &x.AuthToken - yym21 := z.DecBinary() - _ = yym21 - if false { - } else { - *((*string)(yyv20)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobSpecificRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj22 int - var yyb22 bool - var yyhl22 bool = l >= 0 - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv23 := &x.JobID - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllAllocs = false - } else { - yyv25 := &x.AllAllocs - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*bool)(yyv25)) = r.DecodeBool() - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv27 := &x.Region - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*string)(yyv27)) = r.DecodeString() - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv29 := &x.Namespace - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*string)(yyv29)) = r.DecodeString() - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv31 := &x.MinQueryIndex - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*uint64)(yyv31)) = uint64(r.DecodeUint(64)) - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv33 := &x.MaxQueryTime - yym34 := z.DecBinary() - _ = yym34 - if false { - } else if z.HasExtensions() && z.DecExt(yyv33) { - } else { - *((*int64)(yyv33)) = int64(r.DecodeInt(64)) - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv35 := &x.AllowStale - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*bool)(yyv35)) = r.DecodeBool() - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv37 := &x.Prefix - yym38 := z.DecBinary() - _ = yym38 - if false { - } else { - *((*string)(yyv37)) = r.DecodeString() - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv39 := &x.AuthToken - yym40 := z.DecBinary() - _ = yym40 - if false { - } else { - *((*string)(yyv39)) = r.DecodeString() - } - } - for { - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj22-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobListRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [7]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(7) - } else { - yynn2 = 7 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobListRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobListRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv4 := &x.Region - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv6 := &x.Namespace - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv8 := &x.MinQueryIndex - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv10 := &x.MaxQueryTime - yym11 := z.DecBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.DecExt(yyv10) { - } else { - *((*int64)(yyv10)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv12 := &x.AllowStale - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*bool)(yyv12)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv14 := &x.Prefix - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*string)(yyv14)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv16 := &x.AuthToken - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobListRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj18 int - var yyb18 bool - var yyhl18 bool = l >= 0 - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv19 := &x.Region - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv21 := &x.Namespace - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv23 := &x.MinQueryIndex - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv25 := &x.MaxQueryTime - yym26 := z.DecBinary() - _ = yym26 - if false { - } else if z.HasExtensions() && z.DecExt(yyv25) { - } else { - *((*int64)(yyv25)) = int64(r.DecodeInt(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv27 := &x.AllowStale - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*bool)(yyv27)) = r.DecodeBool() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv29 := &x.Prefix - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*string)(yyv29)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv31 := &x.AuthToken - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*string)(yyv31)) = r.DecodeString() - } - } - for { - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj18-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobPlanRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [6]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(6) - } else { - yynn2 = 6 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Job == nil { - r.EncodeNil() - } else { - x.Job.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Job")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Job == nil { - r.EncodeNil() - } else { - x.Job.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeBool(bool(x.Diff)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Diff")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeBool(bool(x.Diff)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeBool(bool(x.PolicyOverride)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("PolicyOverride")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeBool(bool(x.PolicyOverride)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobPlanRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobPlanRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Job": - if r.TryDecodeAsNil() { - if x.Job != nil { - x.Job = nil - } - } else { - if x.Job == nil { - x.Job = new(Job) - } - x.Job.CodecDecodeSelf(d) - } - case "Diff": - if r.TryDecodeAsNil() { - x.Diff = false - } else { - yyv5 := &x.Diff - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*bool)(yyv5)) = r.DecodeBool() - } - } - case "PolicyOverride": - if r.TryDecodeAsNil() { - x.PolicyOverride = false - } else { - yyv7 := &x.PolicyOverride - yym8 := z.DecBinary() - _ = yym8 - if false { - } else { - *((*bool)(yyv7)) = r.DecodeBool() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv9 := &x.Region - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*string)(yyv9)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv11 := &x.Namespace - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*string)(yyv11)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv13 := &x.AuthToken - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*string)(yyv13)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobPlanRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj15 int - var yyb15 bool - var yyhl15 bool = l >= 0 - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Job != nil { - x.Job = nil - } - } else { - if x.Job == nil { - x.Job = new(Job) - } - x.Job.CodecDecodeSelf(d) - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Diff = false - } else { - yyv17 := &x.Diff - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*bool)(yyv17)) = r.DecodeBool() - } - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.PolicyOverride = false - } else { - yyv19 := &x.PolicyOverride - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*bool)(yyv19)) = r.DecodeBool() - } - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv21 := &x.Region - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv23 := &x.Namespace - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv25 := &x.AuthToken - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - for { - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj15-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobSummaryRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [8]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(8) - } else { - yynn2 = 8 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobSummaryRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobSummaryRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "JobID": - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv4 := &x.JobID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv10 := &x.MinQueryIndex - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv12 := &x.MaxQueryTime - yym13 := z.DecBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.DecExt(yyv12) { - } else { - *((*int64)(yyv12)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv14 := &x.AllowStale - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*bool)(yyv14)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv16 := &x.Prefix - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv18 := &x.AuthToken - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobSummaryRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj20 int - var yyb20 bool - var yyhl20 bool = l >= 0 - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv21 := &x.JobID - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv23 := &x.Region - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv25 := &x.Namespace - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv27 := &x.MinQueryIndex - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv29 := &x.MaxQueryTime - yym30 := z.DecBinary() - _ = yym30 - if false { - } else if z.HasExtensions() && z.DecExt(yyv29) { - } else { - *((*int64)(yyv29)) = int64(r.DecodeInt(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv31 := &x.AllowStale - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*bool)(yyv31)) = r.DecodeBool() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv33 := &x.Prefix - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - *((*string)(yyv33)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv35 := &x.AuthToken - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*string)(yyv35)) = r.DecodeString() - } - } - for { - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj20-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobDispatchRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [6]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(6) - } else { - yynn2 = 6 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Payload == nil { - r.EncodeNil() - } else { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Payload)) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Payload")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Payload == nil { - r.EncodeNil() - } else { - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Payload)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Meta == nil { - r.EncodeNil() - } else { - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - z.F.EncMapStringStringV(x.Meta, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Meta")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Meta == nil { - r.EncodeNil() - } else { - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - z.F.EncMapStringStringV(x.Meta, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobDispatchRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobDispatchRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "JobID": - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv4 := &x.JobID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Payload": - if r.TryDecodeAsNil() { - x.Payload = nil - } else { - yyv6 := &x.Payload - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *yyv6 = r.DecodeBytes(*(*[]byte)(yyv6), false, false) - } - } - case "Meta": - if r.TryDecodeAsNil() { - x.Meta = nil - } else { - yyv8 := &x.Meta - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - z.F.DecMapStringStringX(yyv8, false, d) - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv10 := &x.Region - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv12 := &x.Namespace - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv14 := &x.AuthToken - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*string)(yyv14)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobDispatchRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj16 int - var yyb16 bool - var yyhl16 bool = l >= 0 - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv17 := &x.JobID - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Payload = nil - } else { - yyv19 := &x.Payload - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *yyv19 = r.DecodeBytes(*(*[]byte)(yyv19), false, false) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Meta = nil - } else { - yyv21 := &x.Meta - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - z.F.DecMapStringStringX(yyv21, false, d) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv23 := &x.Region - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv25 := &x.Namespace - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv27 := &x.AuthToken - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*string)(yyv27)) = r.DecodeString() - } - } - for { - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj16-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobValidateRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Job == nil { - r.EncodeNil() - } else { - x.Job.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Job")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Job == nil { - r.EncodeNil() - } else { - x.Job.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobValidateRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobValidateRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Job": - if r.TryDecodeAsNil() { - if x.Job != nil { - x.Job = nil - } - } else { - if x.Job == nil { - x.Job = new(Job) - } - x.Job.CodecDecodeSelf(d) - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv5 := &x.Region - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*string)(yyv5)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv7 := &x.Namespace - yym8 := z.DecBinary() - _ = yym8 - if false { - } else { - *((*string)(yyv7)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv9 := &x.AuthToken - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*string)(yyv9)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobValidateRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj11 int - var yyb11 bool - var yyhl11 bool = l >= 0 - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Job != nil { - x.Job = nil - } - } else { - if x.Job == nil { - x.Job = new(Job) - } - x.Job.CodecDecodeSelf(d) - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv13 := &x.Region - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*string)(yyv13)) = r.DecodeString() - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv15 := &x.Namespace - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv17 := &x.AuthToken - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - for { - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj11-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobRevertRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [6]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(6) - } else { - yynn2 = 6 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.JobVersion)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.JobVersion)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.EnforcePriorVersion == nil { - r.EncodeNil() - } else { - yy10 := *x.EnforcePriorVersion - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(yy10)) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EnforcePriorVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.EnforcePriorVersion == nil { - r.EncodeNil() - } else { - yy12 := *x.EnforcePriorVersion - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeUint(uint64(yy12)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym15 := z.EncBinary() - _ = yym15 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym18 := z.EncBinary() - _ = yym18 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym21 := z.EncBinary() - _ = yym21 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobRevertRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobRevertRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "JobID": - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv4 := &x.JobID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "JobVersion": - if r.TryDecodeAsNil() { - x.JobVersion = 0 - } else { - yyv6 := &x.JobVersion - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "EnforcePriorVersion": - if r.TryDecodeAsNil() { - if x.EnforcePriorVersion != nil { - x.EnforcePriorVersion = nil - } - } else { - if x.EnforcePriorVersion == nil { - x.EnforcePriorVersion = new(uint64) - } - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(x.EnforcePriorVersion)) = uint64(r.DecodeUint(64)) - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv10 := &x.Region - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv12 := &x.Namespace - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv14 := &x.AuthToken - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*string)(yyv14)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobRevertRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj16 int - var yyb16 bool - var yyhl16 bool = l >= 0 - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv17 := &x.JobID - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobVersion = 0 - } else { - yyv19 := &x.JobVersion - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.EnforcePriorVersion != nil { - x.EnforcePriorVersion = nil - } - } else { - if x.EnforcePriorVersion == nil { - x.EnforcePriorVersion = new(uint64) - } - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*uint64)(x.EnforcePriorVersion)) = uint64(r.DecodeUint(64)) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv23 := &x.Region - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv25 := &x.Namespace - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv27 := &x.AuthToken - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*string)(yyv27)) = r.DecodeString() - } - } - for { - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj16-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobStabilityRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [6]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(6) - } else { - yynn2 = 6 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.JobVersion)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.JobVersion)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeBool(bool(x.Stable)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Stable")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeBool(bool(x.Stable)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobStabilityRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobStabilityRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "JobID": - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv4 := &x.JobID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "JobVersion": - if r.TryDecodeAsNil() { - x.JobVersion = 0 - } else { - yyv6 := &x.JobVersion - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "Stable": - if r.TryDecodeAsNil() { - x.Stable = false - } else { - yyv8 := &x.Stable - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*bool)(yyv8)) = r.DecodeBool() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv10 := &x.Region - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv12 := &x.Namespace - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv14 := &x.AuthToken - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*string)(yyv14)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobStabilityRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj16 int - var yyb16 bool - var yyhl16 bool = l >= 0 - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv17 := &x.JobID - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobVersion = 0 - } else { - yyv19 := &x.JobVersion - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Stable = false - } else { - yyv21 := &x.Stable - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*bool)(yyv21)) = r.DecodeBool() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv23 := &x.Region - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv25 := &x.Namespace - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv27 := &x.AuthToken - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*string)(yyv27)) = r.DecodeString() - } - } - for { - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj16-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobStabilityResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [1]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(1) - } else { - yynn2 = 1 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobStabilityResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobStabilityResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv4 := &x.Index - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*uint64)(yyv4)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobStabilityResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - 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 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv7 := &x.Index - yym8 := z.DecBinary() - _ = yym8 - if false { - } else { - *((*uint64)(yyv7)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj6++ - if yyhl6 { - yyb6 = yyj6 > l - } else { - yyb6 = r.CheckBreak() - } - if yyb6 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj6-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *NodeListRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [7]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(7) - } else { - yynn2 = 7 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *NodeListRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *NodeListRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv4 := &x.Region - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv6 := &x.Namespace - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv8 := &x.MinQueryIndex - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv10 := &x.MaxQueryTime - yym11 := z.DecBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.DecExt(yyv10) { - } else { - *((*int64)(yyv10)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv12 := &x.AllowStale - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*bool)(yyv12)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv14 := &x.Prefix - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*string)(yyv14)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv16 := &x.AuthToken - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *NodeListRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj18 int - var yyb18 bool - var yyhl18 bool = l >= 0 - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv19 := &x.Region - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv21 := &x.Namespace - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv23 := &x.MinQueryIndex - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv25 := &x.MaxQueryTime - yym26 := z.DecBinary() - _ = yym26 - if false { - } else if z.HasExtensions() && z.DecExt(yyv25) { - } else { - *((*int64)(yyv25)) = int64(r.DecodeInt(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv27 := &x.AllowStale - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*bool)(yyv27)) = r.DecodeBool() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv29 := &x.Prefix - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*string)(yyv29)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv31 := &x.AuthToken - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*string)(yyv31)) = r.DecodeString() - } - } - for { - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj18-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *EvalUpdateRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 5 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Evals == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encSlicePtrtoEvaluation(([]*Evaluation)(x.Evals), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Evals")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Evals == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encSlicePtrtoEvaluation(([]*Evaluation)(x.Evals), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *EvalUpdateRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *EvalUpdateRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Evals": - if r.TryDecodeAsNil() { - x.Evals = nil - } else { - yyv4 := &x.Evals - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decSlicePtrtoEvaluation((*[]*Evaluation)(yyv4), d) - } - } - case "EvalToken": - if r.TryDecodeAsNil() { - x.EvalToken = "" - } else { - yyv6 := &x.EvalToken - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv8 := &x.Region - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv10 := &x.Namespace - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv12 := &x.AuthToken - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *EvalUpdateRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj14 int - var yyb14 bool - var yyhl14 bool = l >= 0 - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Evals = nil - } else { - yyv15 := &x.Evals - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - h.decSlicePtrtoEvaluation((*[]*Evaluation)(yyv15), d) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalToken = "" - } else { - yyv17 := &x.EvalToken - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv19 := &x.Region - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv21 := &x.Namespace - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv23 := &x.AuthToken - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - for { - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj14-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *EvalDeleteRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 5 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Evals == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - z.F.EncSliceStringV(x.Evals, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Evals")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Evals == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - z.F.EncSliceStringV(x.Evals, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Allocs == nil { - r.EncodeNil() - } else { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - z.F.EncSliceStringV(x.Allocs, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Allocs")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Allocs == nil { - r.EncodeNil() - } else { - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - z.F.EncSliceStringV(x.Allocs, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *EvalDeleteRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *EvalDeleteRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Evals": - if r.TryDecodeAsNil() { - x.Evals = nil - } else { - yyv4 := &x.Evals - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - z.F.DecSliceStringX(yyv4, false, d) - } - } - case "Allocs": - if r.TryDecodeAsNil() { - x.Allocs = nil - } else { - yyv6 := &x.Allocs - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - z.F.DecSliceStringX(yyv6, false, d) - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv8 := &x.Region - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv10 := &x.Namespace - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv12 := &x.AuthToken - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *EvalDeleteRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj14 int - var yyb14 bool - var yyhl14 bool = l >= 0 - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Evals = nil - } else { - yyv15 := &x.Evals - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - z.F.DecSliceStringX(yyv15, false, d) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Allocs = nil - } else { - yyv17 := &x.Allocs - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - z.F.DecSliceStringX(yyv17, false, d) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv19 := &x.Region - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv21 := &x.Namespace - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv23 := &x.AuthToken - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - for { - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj14-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *EvalSpecificRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [8]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(8) - } else { - yynn2 = 8 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *EvalSpecificRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *EvalSpecificRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "EvalID": - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv4 := &x.EvalID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv10 := &x.MinQueryIndex - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv12 := &x.MaxQueryTime - yym13 := z.DecBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.DecExt(yyv12) { - } else { - *((*int64)(yyv12)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv14 := &x.AllowStale - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*bool)(yyv14)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv16 := &x.Prefix - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv18 := &x.AuthToken - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *EvalSpecificRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj20 int - var yyb20 bool - var yyhl20 bool = l >= 0 - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv21 := &x.EvalID - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv23 := &x.Region - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv25 := &x.Namespace - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv27 := &x.MinQueryIndex - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv29 := &x.MaxQueryTime - yym30 := z.DecBinary() - _ = yym30 - if false { - } else if z.HasExtensions() && z.DecExt(yyv29) { - } else { - *((*int64)(yyv29)) = int64(r.DecodeInt(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv31 := &x.AllowStale - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*bool)(yyv31)) = r.DecodeBool() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv33 := &x.Prefix - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - *((*string)(yyv33)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv35 := &x.AuthToken - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*string)(yyv35)) = r.DecodeString() - } - } - for { - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj20-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *EvalAckRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 5 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Token)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Token")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Token)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *EvalAckRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *EvalAckRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "EvalID": - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv4 := &x.EvalID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Token": - if r.TryDecodeAsNil() { - x.Token = "" - } else { - yyv6 := &x.Token - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv8 := &x.Region - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv10 := &x.Namespace - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv12 := &x.AuthToken - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *EvalAckRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj14 int - var yyb14 bool - var yyhl14 bool = l >= 0 - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv15 := &x.EvalID - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Token = "" - } else { - yyv17 := &x.Token - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv19 := &x.Region - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv21 := &x.Namespace - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv23 := &x.AuthToken - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - for { - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj14-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *EvalDequeueRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [6]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(6) - } else { - yynn2 = 6 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Schedulers == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - z.F.EncSliceStringV(x.Schedulers, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Schedulers")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Schedulers == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - z.F.EncSliceStringV(x.Schedulers, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else if z.HasExtensions() && z.EncExt(x.Timeout) { - } else { - r.EncodeInt(int64(x.Timeout)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Timeout")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else if z.HasExtensions() && z.EncExt(x.Timeout) { - } else { - r.EncodeInt(int64(x.Timeout)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.SchedulerVersion)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("SchedulerVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.SchedulerVersion)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *EvalDequeueRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *EvalDequeueRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Schedulers": - if r.TryDecodeAsNil() { - x.Schedulers = nil - } else { - yyv4 := &x.Schedulers - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - z.F.DecSliceStringX(yyv4, false, d) - } - } - case "Timeout": - if r.TryDecodeAsNil() { - x.Timeout = 0 - } else { - yyv6 := &x.Timeout - yym7 := z.DecBinary() - _ = yym7 - if false { - } else if z.HasExtensions() && z.DecExt(yyv6) { - } else { - *((*int64)(yyv6)) = int64(r.DecodeInt(64)) - } - } - case "SchedulerVersion": - if r.TryDecodeAsNil() { - x.SchedulerVersion = 0 - } else { - yyv8 := &x.SchedulerVersion - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint16)(yyv8)) = uint16(r.DecodeUint(16)) - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv10 := &x.Region - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv12 := &x.Namespace - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv14 := &x.AuthToken - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*string)(yyv14)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *EvalDequeueRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj16 int - var yyb16 bool - var yyhl16 bool = l >= 0 - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Schedulers = nil - } else { - yyv17 := &x.Schedulers - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - z.F.DecSliceStringX(yyv17, false, d) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Timeout = 0 - } else { - yyv19 := &x.Timeout - yym20 := z.DecBinary() - _ = yym20 - if false { - } else if z.HasExtensions() && z.DecExt(yyv19) { - } else { - *((*int64)(yyv19)) = int64(r.DecodeInt(64)) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.SchedulerVersion = 0 - } else { - yyv21 := &x.SchedulerVersion - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*uint16)(yyv21)) = uint16(r.DecodeUint(16)) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv23 := &x.Region - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv25 := &x.Namespace - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv27 := &x.AuthToken - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*string)(yyv27)) = r.DecodeString() - } - } - for { - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj16-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *EvalListRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [7]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(7) - } else { - yynn2 = 7 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *EvalListRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *EvalListRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv4 := &x.Region - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv6 := &x.Namespace - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv8 := &x.MinQueryIndex - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv10 := &x.MaxQueryTime - yym11 := z.DecBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.DecExt(yyv10) { - } else { - *((*int64)(yyv10)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv12 := &x.AllowStale - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*bool)(yyv12)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv14 := &x.Prefix - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*string)(yyv14)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv16 := &x.AuthToken - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *EvalListRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj18 int - var yyb18 bool - var yyhl18 bool = l >= 0 - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv19 := &x.Region - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv21 := &x.Namespace - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv23 := &x.MinQueryIndex - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv25 := &x.MaxQueryTime - yym26 := z.DecBinary() - _ = yym26 - if false { - } else if z.HasExtensions() && z.DecExt(yyv25) { - } else { - *((*int64)(yyv25)) = int64(r.DecodeInt(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv27 := &x.AllowStale - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*bool)(yyv27)) = r.DecodeBool() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv29 := &x.Prefix - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*string)(yyv29)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv31 := &x.AuthToken - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*string)(yyv31)) = r.DecodeString() - } - } - for { - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj18-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *PlanRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Plan == nil { - r.EncodeNil() - } else { - x.Plan.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Plan")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Plan == nil { - r.EncodeNil() - } else { - x.Plan.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *PlanRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *PlanRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Plan": - if r.TryDecodeAsNil() { - if x.Plan != nil { - x.Plan = nil - } - } else { - if x.Plan == nil { - x.Plan = new(Plan) - } - x.Plan.CodecDecodeSelf(d) - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv5 := &x.Region - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*string)(yyv5)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv7 := &x.Namespace - yym8 := z.DecBinary() - _ = yym8 - if false { - } else { - *((*string)(yyv7)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv9 := &x.AuthToken - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*string)(yyv9)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *PlanRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj11 int - var yyb11 bool - var yyhl11 bool = l >= 0 - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Plan != nil { - x.Plan = nil - } - } else { - if x.Plan == nil { - x.Plan = new(Plan) - } - x.Plan.CodecDecodeSelf(d) - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv13 := &x.Region - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*string)(yyv13)) = r.DecodeString() - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv15 := &x.Namespace - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv17 := &x.AuthToken - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - for { - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj11-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ApplyPlanResultsRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [8]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(8) - } else { - yynn2 = 8 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Alloc == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encSlicePtrtoAllocation(([]*Allocation)(x.Alloc), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Alloc")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Alloc == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encSlicePtrtoAllocation(([]*Allocation)(x.Alloc), e) - } - } - } - var yyn6 bool - if x.AllocUpdateRequest.Job == nil { - yyn6 = true - goto LABEL6 - } - LABEL6: - if yyr2 || yy2arr2 { - if yyn6 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Job == nil { - r.EncodeNil() - } else { - x.Job.CodecEncodeSelf(e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Job")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if yyn6 { - r.EncodeNil() - } else { - if x.Job == nil { - r.EncodeNil() - } else { - x.Job.CodecEncodeSelf(e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Deployment == nil { - r.EncodeNil() - } else { - x.Deployment.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Deployment")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Deployment == nil { - r.EncodeNil() - } else { - x.Deployment.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.DeploymentUpdates == nil { - r.EncodeNil() - } else { - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - h.encSlicePtrtoDeploymentStatusUpdate(([]*DeploymentStatusUpdate)(x.DeploymentUpdates), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DeploymentUpdates")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.DeploymentUpdates == nil { - r.EncodeNil() - } else { - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - h.encSlicePtrtoDeploymentStatusUpdate(([]*DeploymentStatusUpdate)(x.DeploymentUpdates), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ApplyPlanResultsRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ApplyPlanResultsRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Alloc": - if r.TryDecodeAsNil() { - x.Alloc = nil - } else { - yyv4 := &x.Alloc - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decSlicePtrtoAllocation((*[]*Allocation)(yyv4), d) - } - } - case "Job": - if x.AllocUpdateRequest.Job == nil { - x.AllocUpdateRequest.Job = new(Job) - } - if r.TryDecodeAsNil() { - if x.Job != nil { - x.Job = nil - } - } else { - if x.Job == nil { - x.Job = new(Job) - } - x.Job.CodecDecodeSelf(d) - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv7 := &x.Region - yym8 := z.DecBinary() - _ = yym8 - if false { - } else { - *((*string)(yyv7)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv9 := &x.Namespace - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*string)(yyv9)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv11 := &x.AuthToken - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*string)(yyv11)) = r.DecodeString() - } - } - case "Deployment": - if r.TryDecodeAsNil() { - if x.Deployment != nil { - x.Deployment = nil - } - } else { - if x.Deployment == nil { - x.Deployment = new(Deployment) - } - x.Deployment.CodecDecodeSelf(d) - } - case "DeploymentUpdates": - if r.TryDecodeAsNil() { - x.DeploymentUpdates = nil - } else { - yyv14 := &x.DeploymentUpdates - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - h.decSlicePtrtoDeploymentStatusUpdate((*[]*DeploymentStatusUpdate)(yyv14), d) - } - } - case "EvalID": - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv16 := &x.EvalID - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ApplyPlanResultsRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj18 int - var yyb18 bool - var yyhl18 bool = l >= 0 - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Alloc = nil - } else { - yyv19 := &x.Alloc - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - h.decSlicePtrtoAllocation((*[]*Allocation)(yyv19), d) - } - } - if x.AllocUpdateRequest.Job == nil { - x.AllocUpdateRequest.Job = new(Job) - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Job != nil { - x.Job = nil - } - } else { - if x.Job == nil { - x.Job = new(Job) - } - x.Job.CodecDecodeSelf(d) - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv22 := &x.Region - yym23 := z.DecBinary() - _ = yym23 - if false { - } else { - *((*string)(yyv22)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv24 := &x.Namespace - yym25 := z.DecBinary() - _ = yym25 - if false { - } else { - *((*string)(yyv24)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv26 := &x.AuthToken - yym27 := z.DecBinary() - _ = yym27 - if false { - } else { - *((*string)(yyv26)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Deployment != nil { - x.Deployment = nil - } - } else { - if x.Deployment == nil { - x.Deployment = new(Deployment) - } - x.Deployment.CodecDecodeSelf(d) - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DeploymentUpdates = nil - } else { - yyv29 := &x.DeploymentUpdates - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - h.decSlicePtrtoDeploymentStatusUpdate((*[]*DeploymentStatusUpdate)(yyv29), d) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv31 := &x.EvalID - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*string)(yyv31)) = r.DecodeString() - } - } - for { - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj18-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *AllocUpdateRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 5 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Alloc == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encSlicePtrtoAllocation(([]*Allocation)(x.Alloc), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Alloc")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Alloc == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encSlicePtrtoAllocation(([]*Allocation)(x.Alloc), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Job == nil { - r.EncodeNil() - } else { - x.Job.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Job")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Job == nil { - r.EncodeNil() - } else { - x.Job.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *AllocUpdateRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *AllocUpdateRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Alloc": - if r.TryDecodeAsNil() { - x.Alloc = nil - } else { - yyv4 := &x.Alloc - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decSlicePtrtoAllocation((*[]*Allocation)(yyv4), d) - } - } - case "Job": - if r.TryDecodeAsNil() { - if x.Job != nil { - x.Job = nil - } - } else { - if x.Job == nil { - x.Job = new(Job) - } - x.Job.CodecDecodeSelf(d) - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv7 := &x.Region - yym8 := z.DecBinary() - _ = yym8 - if false { - } else { - *((*string)(yyv7)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv9 := &x.Namespace - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*string)(yyv9)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv11 := &x.AuthToken - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*string)(yyv11)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *AllocUpdateRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj13 int - var yyb13 bool - var yyhl13 bool = l >= 0 - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Alloc = nil - } else { - yyv14 := &x.Alloc - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - h.decSlicePtrtoAllocation((*[]*Allocation)(yyv14), d) - } - } - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Job != nil { - x.Job = nil - } - } else { - if x.Job == nil { - x.Job = new(Job) - } - x.Job.CodecDecodeSelf(d) - } - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv17 := &x.Region - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv19 := &x.Namespace - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv21 := &x.AuthToken - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - for { - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj13-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *AllocListRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [7]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(7) - } else { - yynn2 = 7 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *AllocListRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *AllocListRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv4 := &x.Region - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv6 := &x.Namespace - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv8 := &x.MinQueryIndex - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv10 := &x.MaxQueryTime - yym11 := z.DecBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.DecExt(yyv10) { - } else { - *((*int64)(yyv10)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv12 := &x.AllowStale - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*bool)(yyv12)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv14 := &x.Prefix - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*string)(yyv14)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv16 := &x.AuthToken - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *AllocListRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj18 int - var yyb18 bool - var yyhl18 bool = l >= 0 - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv19 := &x.Region - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv21 := &x.Namespace - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv23 := &x.MinQueryIndex - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv25 := &x.MaxQueryTime - yym26 := z.DecBinary() - _ = yym26 - if false { - } else if z.HasExtensions() && z.DecExt(yyv25) { - } else { - *((*int64)(yyv25)) = int64(r.DecodeInt(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv27 := &x.AllowStale - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*bool)(yyv27)) = r.DecodeBool() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv29 := &x.Prefix - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*string)(yyv29)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv31 := &x.AuthToken - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*string)(yyv31)) = r.DecodeString() - } - } - for { - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj18-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *AllocSpecificRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [8]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(8) - } else { - yynn2 = 8 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AllocID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllocID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AllocID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *AllocSpecificRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *AllocSpecificRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "AllocID": - if r.TryDecodeAsNil() { - x.AllocID = "" - } else { - yyv4 := &x.AllocID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv10 := &x.MinQueryIndex - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv12 := &x.MaxQueryTime - yym13 := z.DecBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.DecExt(yyv12) { - } else { - *((*int64)(yyv12)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv14 := &x.AllowStale - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*bool)(yyv14)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv16 := &x.Prefix - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv18 := &x.AuthToken - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *AllocSpecificRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj20 int - var yyb20 bool - var yyhl20 bool = l >= 0 - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllocID = "" - } else { - yyv21 := &x.AllocID - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv23 := &x.Region - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv25 := &x.Namespace - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv27 := &x.MinQueryIndex - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv29 := &x.MaxQueryTime - yym30 := z.DecBinary() - _ = yym30 - if false { - } else if z.HasExtensions() && z.DecExt(yyv29) { - } else { - *((*int64)(yyv29)) = int64(r.DecodeInt(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv31 := &x.AllowStale - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*bool)(yyv31)) = r.DecodeBool() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv33 := &x.Prefix - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - *((*string)(yyv33)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv35 := &x.AuthToken - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*string)(yyv35)) = r.DecodeString() - } - } - for { - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj20-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *AllocsGetRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [8]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(8) - } else { - yynn2 = 8 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.AllocIDs == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - z.F.EncSliceStringV(x.AllocIDs, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllocIDs")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.AllocIDs == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - z.F.EncSliceStringV(x.AllocIDs, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *AllocsGetRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *AllocsGetRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "AllocIDs": - if r.TryDecodeAsNil() { - x.AllocIDs = nil - } else { - yyv4 := &x.AllocIDs - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - z.F.DecSliceStringX(yyv4, false, d) - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv10 := &x.MinQueryIndex - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv12 := &x.MaxQueryTime - yym13 := z.DecBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.DecExt(yyv12) { - } else { - *((*int64)(yyv12)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv14 := &x.AllowStale - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*bool)(yyv14)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv16 := &x.Prefix - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv18 := &x.AuthToken - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *AllocsGetRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj20 int - var yyb20 bool - var yyhl20 bool = l >= 0 - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllocIDs = nil - } else { - yyv21 := &x.AllocIDs - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - z.F.DecSliceStringX(yyv21, false, d) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv23 := &x.Region - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv25 := &x.Namespace - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv27 := &x.MinQueryIndex - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv29 := &x.MaxQueryTime - yym30 := z.DecBinary() - _ = yym30 - if false { - } else if z.HasExtensions() && z.DecExt(yyv29) { - } else { - *((*int64)(yyv29)) = int64(r.DecodeInt(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv31 := &x.AllowStale - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*bool)(yyv31)) = r.DecodeBool() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv33 := &x.Prefix - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - *((*string)(yyv33)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv35 := &x.AuthToken - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*string)(yyv35)) = r.DecodeString() - } - } - for { - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj20-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *PeriodicForceRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *PeriodicForceRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *PeriodicForceRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "JobID": - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv4 := &x.JobID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv10 := &x.AuthToken - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *PeriodicForceRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv13 := &x.JobID - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*string)(yyv13)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv15 := &x.Region - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv17 := &x.Namespace - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv19 := &x.AuthToken - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ServerMembersResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ServerName)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ServerName")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ServerName)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ServerRegion)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ServerRegion")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ServerRegion)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ServerDC)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ServerDC")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ServerDC)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Members == nil { - r.EncodeNil() - } else { - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - h.encSlicePtrtoServerMember(([]*ServerMember)(x.Members), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Members")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Members == nil { - r.EncodeNil() - } else { - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - h.encSlicePtrtoServerMember(([]*ServerMember)(x.Members), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ServerMembersResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ServerMembersResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "ServerName": - if r.TryDecodeAsNil() { - x.ServerName = "" - } else { - yyv4 := &x.ServerName - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "ServerRegion": - if r.TryDecodeAsNil() { - x.ServerRegion = "" - } else { - yyv6 := &x.ServerRegion - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "ServerDC": - if r.TryDecodeAsNil() { - x.ServerDC = "" - } else { - yyv8 := &x.ServerDC - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Members": - if r.TryDecodeAsNil() { - x.Members = nil - } else { - yyv10 := &x.Members - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - h.decSlicePtrtoServerMember((*[]*ServerMember)(yyv10), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ServerMembersResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ServerName = "" - } else { - yyv13 := &x.ServerName - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*string)(yyv13)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ServerRegion = "" - } else { - yyv15 := &x.ServerRegion - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ServerDC = "" - } else { - yyv17 := &x.ServerDC - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Members = nil - } else { - yyv19 := &x.Members - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - h.decSlicePtrtoServerMember((*[]*ServerMember)(yyv19), d) - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ServerMember) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [11]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(11) - } else { - yynn2 = 11 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Name")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Addr == nil { - r.EncodeNil() - } else { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else if z.HasExtensions() && z.EncExt(x.Addr) { - } else if !yym7 { - z.EncTextMarshal(x.Addr) - } else { - h.encnet_IP((net.IP)(x.Addr), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Addr")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Addr == nil { - r.EncodeNil() - } else { - yym8 := z.EncBinary() - _ = yym8 - if false { - } else if z.HasExtensions() && z.EncExt(x.Addr) { - } else if !yym8 { - z.EncTextMarshal(x.Addr) - } else { - h.encnet_IP((net.IP)(x.Addr), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.Port)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Port")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.Port)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Tags == nil { - r.EncodeNil() - } else { - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - z.F.EncMapStringStringV(x.Tags, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Tags")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Tags == nil { - r.EncodeNil() - } else { - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - z.F.EncMapStringStringV(x.Tags, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Status)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Status")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Status)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeUint(uint64(x.ProtocolMin)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ProtocolMin")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeUint(uint64(x.ProtocolMin)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeUint(uint64(x.ProtocolMax)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ProtocolMax")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeUint(uint64(x.ProtocolMax)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeUint(uint64(x.ProtocolCur)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ProtocolCur")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeUint(uint64(x.ProtocolCur)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym28 := z.EncBinary() - _ = yym28 - if false { - } else { - r.EncodeUint(uint64(x.DelegateMin)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DelegateMin")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym29 := z.EncBinary() - _ = yym29 - if false { - } else { - r.EncodeUint(uint64(x.DelegateMin)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym31 := z.EncBinary() - _ = yym31 - if false { - } else { - r.EncodeUint(uint64(x.DelegateMax)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DelegateMax")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym32 := z.EncBinary() - _ = yym32 - if false { - } else { - r.EncodeUint(uint64(x.DelegateMax)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym34 := z.EncBinary() - _ = yym34 - if false { - } else { - r.EncodeUint(uint64(x.DelegateCur)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DelegateCur")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym35 := z.EncBinary() - _ = yym35 - if false { - } else { - r.EncodeUint(uint64(x.DelegateCur)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ServerMember) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ServerMember) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv4 := &x.Name - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Addr": - if r.TryDecodeAsNil() { - x.Addr = nil - } else { - yyv6 := &x.Addr - yym7 := z.DecBinary() - _ = yym7 - if false { - } else if z.HasExtensions() && z.DecExt(yyv6) { - } else if !yym7 { - z.DecTextUnmarshal(yyv6) - } else { - h.decnet_IP((*net.IP)(yyv6), d) - } - } - case "Port": - if r.TryDecodeAsNil() { - x.Port = 0 - } else { - yyv8 := &x.Port - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint16)(yyv8)) = uint16(r.DecodeUint(16)) - } - } - case "Tags": - if r.TryDecodeAsNil() { - x.Tags = nil - } else { - yyv10 := &x.Tags - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - z.F.DecMapStringStringX(yyv10, false, d) - } - } - case "Status": - if r.TryDecodeAsNil() { - x.Status = "" - } else { - yyv12 := &x.Status - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - case "ProtocolMin": - if r.TryDecodeAsNil() { - x.ProtocolMin = 0 - } else { - yyv14 := &x.ProtocolMin - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*uint8)(yyv14)) = uint8(r.DecodeUint(8)) - } - } - case "ProtocolMax": - if r.TryDecodeAsNil() { - x.ProtocolMax = 0 - } else { - yyv16 := &x.ProtocolMax - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*uint8)(yyv16)) = uint8(r.DecodeUint(8)) - } - } - case "ProtocolCur": - if r.TryDecodeAsNil() { - x.ProtocolCur = 0 - } else { - yyv18 := &x.ProtocolCur - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*uint8)(yyv18)) = uint8(r.DecodeUint(8)) - } - } - case "DelegateMin": - if r.TryDecodeAsNil() { - x.DelegateMin = 0 - } else { - yyv20 := &x.DelegateMin - yym21 := z.DecBinary() - _ = yym21 - if false { - } else { - *((*uint8)(yyv20)) = uint8(r.DecodeUint(8)) - } - } - case "DelegateMax": - if r.TryDecodeAsNil() { - x.DelegateMax = 0 - } else { - yyv22 := &x.DelegateMax - yym23 := z.DecBinary() - _ = yym23 - if false { - } else { - *((*uint8)(yyv22)) = uint8(r.DecodeUint(8)) - } - } - case "DelegateCur": - if r.TryDecodeAsNil() { - x.DelegateCur = 0 - } else { - yyv24 := &x.DelegateCur - yym25 := z.DecBinary() - _ = yym25 - if false { - } else { - *((*uint8)(yyv24)) = uint8(r.DecodeUint(8)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ServerMember) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj26 int - var yyb26 bool - var yyhl26 bool = l >= 0 - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv27 := &x.Name - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*string)(yyv27)) = r.DecodeString() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Addr = nil - } else { - yyv29 := &x.Addr - yym30 := z.DecBinary() - _ = yym30 - if false { - } else if z.HasExtensions() && z.DecExt(yyv29) { - } else if !yym30 { - z.DecTextUnmarshal(yyv29) - } else { - h.decnet_IP((*net.IP)(yyv29), d) - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Port = 0 - } else { - yyv31 := &x.Port - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*uint16)(yyv31)) = uint16(r.DecodeUint(16)) - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Tags = nil - } else { - yyv33 := &x.Tags - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - z.F.DecMapStringStringX(yyv33, false, d) - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - yyv35 := &x.Status - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*string)(yyv35)) = r.DecodeString() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ProtocolMin = 0 - } else { - yyv37 := &x.ProtocolMin - yym38 := z.DecBinary() - _ = yym38 - if false { - } else { - *((*uint8)(yyv37)) = uint8(r.DecodeUint(8)) - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ProtocolMax = 0 - } else { - yyv39 := &x.ProtocolMax - yym40 := z.DecBinary() - _ = yym40 - if false { - } else { - *((*uint8)(yyv39)) = uint8(r.DecodeUint(8)) - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ProtocolCur = 0 - } else { - yyv41 := &x.ProtocolCur - yym42 := z.DecBinary() - _ = yym42 - if false { - } else { - *((*uint8)(yyv41)) = uint8(r.DecodeUint(8)) - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DelegateMin = 0 - } else { - yyv43 := &x.DelegateMin - yym44 := z.DecBinary() - _ = yym44 - if false { - } else { - *((*uint8)(yyv43)) = uint8(r.DecodeUint(8)) - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DelegateMax = 0 - } else { - yyv45 := &x.DelegateMax - yym46 := z.DecBinary() - _ = yym46 - if false { - } else { - *((*uint8)(yyv45)) = uint8(r.DecodeUint(8)) - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DelegateCur = 0 - } else { - yyv47 := &x.DelegateCur - yym48 := z.DecBinary() - _ = yym48 - if false { - } else { - *((*uint8)(yyv47)) = uint8(r.DecodeUint(8)) - } - } - for { - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj26-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *DeriveVaultTokenRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [11]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(11) - } else { - yynn2 = 11 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodeID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.SecretID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("SecretID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.SecretID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AllocID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllocID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AllocID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Tasks == nil { - r.EncodeNil() - } else { - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - z.F.EncSliceStringV(x.Tasks, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Tasks")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Tasks == nil { - r.EncodeNil() - } else { - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - z.F.EncSliceStringV(x.Tasks, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym28 := z.EncBinary() - _ = yym28 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym29 := z.EncBinary() - _ = yym29 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym31 := z.EncBinary() - _ = yym31 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym32 := z.EncBinary() - _ = yym32 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym34 := z.EncBinary() - _ = yym34 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym35 := z.EncBinary() - _ = yym35 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *DeriveVaultTokenRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *DeriveVaultTokenRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "NodeID": - if r.TryDecodeAsNil() { - x.NodeID = "" - } else { - yyv4 := &x.NodeID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "SecretID": - if r.TryDecodeAsNil() { - x.SecretID = "" - } else { - yyv6 := &x.SecretID - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "AllocID": - if r.TryDecodeAsNil() { - x.AllocID = "" - } else { - yyv8 := &x.AllocID - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Tasks": - if r.TryDecodeAsNil() { - x.Tasks = nil - } else { - yyv10 := &x.Tasks - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - z.F.DecSliceStringX(yyv10, false, d) - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv12 := &x.Region - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv14 := &x.Namespace - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*string)(yyv14)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv16 := &x.MinQueryIndex - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*uint64)(yyv16)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv18 := &x.MaxQueryTime - yym19 := z.DecBinary() - _ = yym19 - if false { - } else if z.HasExtensions() && z.DecExt(yyv18) { - } else { - *((*int64)(yyv18)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv20 := &x.AllowStale - yym21 := z.DecBinary() - _ = yym21 - if false { - } else { - *((*bool)(yyv20)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv22 := &x.Prefix - yym23 := z.DecBinary() - _ = yym23 - if false { - } else { - *((*string)(yyv22)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv24 := &x.AuthToken - yym25 := z.DecBinary() - _ = yym25 - if false { - } else { - *((*string)(yyv24)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *DeriveVaultTokenRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj26 int - var yyb26 bool - var yyhl26 bool = l >= 0 - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodeID = "" - } else { - yyv27 := &x.NodeID - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*string)(yyv27)) = r.DecodeString() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.SecretID = "" - } else { - yyv29 := &x.SecretID - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*string)(yyv29)) = r.DecodeString() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllocID = "" - } else { - yyv31 := &x.AllocID - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*string)(yyv31)) = r.DecodeString() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Tasks = nil - } else { - yyv33 := &x.Tasks - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - z.F.DecSliceStringX(yyv33, false, d) - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv35 := &x.Region - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*string)(yyv35)) = r.DecodeString() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv37 := &x.Namespace - yym38 := z.DecBinary() - _ = yym38 - if false { - } else { - *((*string)(yyv37)) = r.DecodeString() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv39 := &x.MinQueryIndex - yym40 := z.DecBinary() - _ = yym40 - if false { - } else { - *((*uint64)(yyv39)) = uint64(r.DecodeUint(64)) - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv41 := &x.MaxQueryTime - yym42 := z.DecBinary() - _ = yym42 - if false { - } else if z.HasExtensions() && z.DecExt(yyv41) { - } else { - *((*int64)(yyv41)) = int64(r.DecodeInt(64)) - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv43 := &x.AllowStale - yym44 := z.DecBinary() - _ = yym44 - if false { - } else { - *((*bool)(yyv43)) = r.DecodeBool() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv45 := &x.Prefix - yym46 := z.DecBinary() - _ = yym46 - if false { - } else { - *((*string)(yyv45)) = r.DecodeString() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv47 := &x.AuthToken - yym48 := z.DecBinary() - _ = yym48 - if false { - } else { - *((*string)(yyv47)) = r.DecodeString() - } - } - for { - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj26-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *VaultAccessorsRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [1]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(1) - } else { - yynn2 = 1 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Accessors == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encSlicePtrtoVaultAccessor(([]*VaultAccessor)(x.Accessors), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Accessors")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Accessors == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encSlicePtrtoVaultAccessor(([]*VaultAccessor)(x.Accessors), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *VaultAccessorsRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *VaultAccessorsRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Accessors": - if r.TryDecodeAsNil() { - x.Accessors = nil - } else { - yyv4 := &x.Accessors - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decSlicePtrtoVaultAccessor((*[]*VaultAccessor)(yyv4), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *VaultAccessorsRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - 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 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Accessors = nil - } else { - yyv7 := &x.Accessors - yym8 := z.DecBinary() - _ = yym8 - if false { - } else { - h.decSlicePtrtoVaultAccessor((*[]*VaultAccessor)(yyv7), d) - } - } - for { - yyj6++ - if yyhl6 { - yyb6 = yyj6 > l - } else { - yyb6 = r.CheckBreak() - } - if yyb6 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj6-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *VaultAccessor) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [6]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(6) - } else { - yynn2 = 6 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AllocID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllocID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AllocID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Task)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Task")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Task)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodeID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Accessor)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Accessor")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Accessor)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeInt(int64(x.CreationTTL)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CreationTTL")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeInt(int64(x.CreationTTL)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *VaultAccessor) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *VaultAccessor) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "AllocID": - if r.TryDecodeAsNil() { - x.AllocID = "" - } else { - yyv4 := &x.AllocID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Task": - if r.TryDecodeAsNil() { - x.Task = "" - } else { - yyv6 := &x.Task - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "NodeID": - if r.TryDecodeAsNil() { - x.NodeID = "" - } else { - yyv8 := &x.NodeID - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Accessor": - if r.TryDecodeAsNil() { - x.Accessor = "" - } else { - yyv10 := &x.Accessor - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "CreationTTL": - if r.TryDecodeAsNil() { - x.CreationTTL = 0 - } else { - yyv12 := &x.CreationTTL - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*int)(yyv12)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "CreateIndex": - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv14 := &x.CreateIndex - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*uint64)(yyv14)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *VaultAccessor) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj16 int - var yyb16 bool - var yyhl16 bool = l >= 0 - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllocID = "" - } else { - yyv17 := &x.AllocID - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Task = "" - } else { - yyv19 := &x.Task - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodeID = "" - } else { - yyv21 := &x.NodeID - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Accessor = "" - } else { - yyv23 := &x.Accessor - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CreationTTL = 0 - } else { - yyv25 := &x.CreationTTL - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*int)(yyv25)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv27 := &x.CreateIndex - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj16-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *DeriveVaultTokenResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 5 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Tasks == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - z.F.EncMapStringStringV(x.Tasks, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Tasks")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Tasks == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - z.F.EncMapStringStringV(x.Tasks, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Error == nil { - r.EncodeNil() - } else { - x.Error.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Error")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Error == nil { - r.EncodeNil() - } else { - x.Error.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *DeriveVaultTokenResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *DeriveVaultTokenResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Tasks": - if r.TryDecodeAsNil() { - x.Tasks = nil - } else { - yyv4 := &x.Tasks - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - z.F.DecMapStringStringX(yyv4, false, d) - } - } - case "Error": - if r.TryDecodeAsNil() { - if x.Error != nil { - x.Error = nil - } - } else { - if x.Error == nil { - x.Error = new(RecoverableError) - } - x.Error.CodecDecodeSelf(d) - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv7 := &x.Index - yym8 := z.DecBinary() - _ = yym8 - if false { - } else { - *((*uint64)(yyv7)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv9 := &x.LastContact - yym10 := z.DecBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.DecExt(yyv9) { - } else { - *((*int64)(yyv9)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv11 := &x.KnownLeader - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*bool)(yyv11)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *DeriveVaultTokenResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj13 int - var yyb13 bool - var yyhl13 bool = l >= 0 - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Tasks = nil - } else { - yyv14 := &x.Tasks - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - z.F.DecMapStringStringX(yyv14, false, d) - } - } - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Error != nil { - x.Error = nil - } - } else { - if x.Error == nil { - x.Error = new(RecoverableError) - } - x.Error.CodecDecodeSelf(d) - } - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv17 := &x.Index - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*uint64)(yyv17)) = uint64(r.DecodeUint(64)) - } - } - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv19 := &x.LastContact - yym20 := z.DecBinary() - _ = yym20 - if false { - } else if z.HasExtensions() && z.DecExt(yyv19) { - } else { - *((*int64)(yyv19)) = int64(r.DecodeInt(64)) - } - } - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv21 := &x.KnownLeader - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*bool)(yyv21)) = r.DecodeBool() - } - } - for { - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj13-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *GenericRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [7]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(7) - } else { - yynn2 = 7 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *GenericRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *GenericRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv4 := &x.Region - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv6 := &x.Namespace - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv8 := &x.MinQueryIndex - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv10 := &x.MaxQueryTime - yym11 := z.DecBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.DecExt(yyv10) { - } else { - *((*int64)(yyv10)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv12 := &x.AllowStale - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*bool)(yyv12)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv14 := &x.Prefix - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*string)(yyv14)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv16 := &x.AuthToken - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *GenericRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj18 int - var yyb18 bool - var yyhl18 bool = l >= 0 - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv19 := &x.Region - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv21 := &x.Namespace - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv23 := &x.MinQueryIndex - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv25 := &x.MaxQueryTime - yym26 := z.DecBinary() - _ = yym26 - if false { - } else if z.HasExtensions() && z.DecExt(yyv25) { - } else { - *((*int64)(yyv25)) = int64(r.DecodeInt(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv27 := &x.AllowStale - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*bool)(yyv27)) = r.DecodeBool() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv29 := &x.Prefix - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*string)(yyv29)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv31 := &x.AuthToken - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*string)(yyv31)) = r.DecodeString() - } - } - for { - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj18-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *DeploymentListRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [7]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(7) - } else { - yynn2 = 7 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *DeploymentListRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *DeploymentListRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv4 := &x.Region - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv6 := &x.Namespace - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv8 := &x.MinQueryIndex - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv10 := &x.MaxQueryTime - yym11 := z.DecBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.DecExt(yyv10) { - } else { - *((*int64)(yyv10)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv12 := &x.AllowStale - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*bool)(yyv12)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv14 := &x.Prefix - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*string)(yyv14)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv16 := &x.AuthToken - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *DeploymentListRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj18 int - var yyb18 bool - var yyhl18 bool = l >= 0 - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv19 := &x.Region - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv21 := &x.Namespace - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv23 := &x.MinQueryIndex - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv25 := &x.MaxQueryTime - yym26 := z.DecBinary() - _ = yym26 - if false { - } else if z.HasExtensions() && z.DecExt(yyv25) { - } else { - *((*int64)(yyv25)) = int64(r.DecodeInt(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv27 := &x.AllowStale - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*bool)(yyv27)) = r.DecodeBool() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv29 := &x.Prefix - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*string)(yyv29)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv31 := &x.AuthToken - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*string)(yyv31)) = r.DecodeString() - } - } - for { - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj18-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *DeploymentDeleteRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Deployments == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - z.F.EncSliceStringV(x.Deployments, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Deployments")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Deployments == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - z.F.EncSliceStringV(x.Deployments, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *DeploymentDeleteRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *DeploymentDeleteRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Deployments": - if r.TryDecodeAsNil() { - x.Deployments = nil - } else { - yyv4 := &x.Deployments - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - z.F.DecSliceStringX(yyv4, false, d) - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv10 := &x.AuthToken - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *DeploymentDeleteRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Deployments = nil - } else { - yyv13 := &x.Deployments - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - z.F.DecSliceStringX(yyv13, false, d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv15 := &x.Region - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv17 := &x.Namespace - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv19 := &x.AuthToken - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *DeploymentStatusUpdateRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [3]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(3) - } else { - yynn2 = 3 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Eval == nil { - r.EncodeNil() - } else { - x.Eval.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Eval")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Eval == nil { - r.EncodeNil() - } else { - x.Eval.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.DeploymentUpdate == nil { - r.EncodeNil() - } else { - x.DeploymentUpdate.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DeploymentUpdate")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.DeploymentUpdate == nil { - r.EncodeNil() - } else { - x.DeploymentUpdate.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Job == nil { - r.EncodeNil() - } else { - x.Job.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Job")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Job == nil { - r.EncodeNil() - } else { - x.Job.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *DeploymentStatusUpdateRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *DeploymentStatusUpdateRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Eval": - if r.TryDecodeAsNil() { - if x.Eval != nil { - x.Eval = nil - } - } else { - if x.Eval == nil { - x.Eval = new(Evaluation) - } - x.Eval.CodecDecodeSelf(d) - } - case "DeploymentUpdate": - if r.TryDecodeAsNil() { - if x.DeploymentUpdate != nil { - x.DeploymentUpdate = nil - } - } else { - if x.DeploymentUpdate == nil { - x.DeploymentUpdate = new(DeploymentStatusUpdate) - } - x.DeploymentUpdate.CodecDecodeSelf(d) - } - case "Job": - if r.TryDecodeAsNil() { - if x.Job != nil { - x.Job = nil - } - } else { - if x.Job == nil { - x.Job = new(Job) - } - x.Job.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *DeploymentStatusUpdateRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj7 int - var yyb7 bool - var yyhl7 bool = l >= 0 - yyj7++ - if yyhl7 { - yyb7 = yyj7 > l - } else { - yyb7 = r.CheckBreak() - } - if yyb7 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Eval != nil { - x.Eval = nil - } - } else { - if x.Eval == nil { - x.Eval = new(Evaluation) - } - x.Eval.CodecDecodeSelf(d) - } - yyj7++ - if yyhl7 { - yyb7 = yyj7 > l - } else { - yyb7 = r.CheckBreak() - } - if yyb7 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.DeploymentUpdate != nil { - x.DeploymentUpdate = nil - } - } else { - if x.DeploymentUpdate == nil { - x.DeploymentUpdate = new(DeploymentStatusUpdate) - } - x.DeploymentUpdate.CodecDecodeSelf(d) - } - yyj7++ - if yyhl7 { - yyb7 = yyj7 > l - } else { - yyb7 = r.CheckBreak() - } - if yyb7 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Job != nil { - x.Job = nil - } - } else { - if x.Job == nil { - x.Job = new(Job) - } - x.Job.CodecDecodeSelf(d) - } - for { - yyj7++ - if yyhl7 { - yyb7 = yyj7 > l - } else { - yyb7 = r.CheckBreak() - } - if yyb7 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj7-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *DeploymentAllocHealthRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [6]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(6) - } else { - yynn2 = 6 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DeploymentID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.HealthyAllocationIDs == nil { - r.EncodeNil() - } else { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - z.F.EncSliceStringV(x.HealthyAllocationIDs, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("HealthyAllocationIDs")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.HealthyAllocationIDs == nil { - r.EncodeNil() - } else { - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - z.F.EncSliceStringV(x.HealthyAllocationIDs, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.UnhealthyAllocationIDs == nil { - r.EncodeNil() - } else { - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - z.F.EncSliceStringV(x.UnhealthyAllocationIDs, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("UnhealthyAllocationIDs")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.UnhealthyAllocationIDs == nil { - r.EncodeNil() - } else { - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - z.F.EncSliceStringV(x.UnhealthyAllocationIDs, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *DeploymentAllocHealthRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *DeploymentAllocHealthRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "DeploymentID": - if r.TryDecodeAsNil() { - x.DeploymentID = "" - } else { - yyv4 := &x.DeploymentID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "HealthyAllocationIDs": - if r.TryDecodeAsNil() { - x.HealthyAllocationIDs = nil - } else { - yyv6 := &x.HealthyAllocationIDs - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - z.F.DecSliceStringX(yyv6, false, d) - } - } - case "UnhealthyAllocationIDs": - if r.TryDecodeAsNil() { - x.UnhealthyAllocationIDs = nil - } else { - yyv8 := &x.UnhealthyAllocationIDs - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - z.F.DecSliceStringX(yyv8, false, d) - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv10 := &x.Region - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv12 := &x.Namespace - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv14 := &x.AuthToken - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*string)(yyv14)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *DeploymentAllocHealthRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj16 int - var yyb16 bool - var yyhl16 bool = l >= 0 - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DeploymentID = "" - } else { - yyv17 := &x.DeploymentID - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.HealthyAllocationIDs = nil - } else { - yyv19 := &x.HealthyAllocationIDs - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - z.F.DecSliceStringX(yyv19, false, d) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.UnhealthyAllocationIDs = nil - } else { - yyv21 := &x.UnhealthyAllocationIDs - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - z.F.DecSliceStringX(yyv21, false, d) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv23 := &x.Region - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv25 := &x.Namespace - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv27 := &x.AuthToken - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*string)(yyv27)) = r.DecodeString() - } - } - for { - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj16-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ApplyDeploymentAllocHealthRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [9]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(9) - } else { - yynn2 = 9 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DeploymentID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.HealthyAllocationIDs == nil { - r.EncodeNil() - } else { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - z.F.EncSliceStringV(x.HealthyAllocationIDs, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("HealthyAllocationIDs")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.HealthyAllocationIDs == nil { - r.EncodeNil() - } else { - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - z.F.EncSliceStringV(x.HealthyAllocationIDs, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.UnhealthyAllocationIDs == nil { - r.EncodeNil() - } else { - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - z.F.EncSliceStringV(x.UnhealthyAllocationIDs, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("UnhealthyAllocationIDs")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.UnhealthyAllocationIDs == nil { - r.EncodeNil() - } else { - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - z.F.EncSliceStringV(x.UnhealthyAllocationIDs, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.DeploymentUpdate == nil { - r.EncodeNil() - } else { - x.DeploymentUpdate.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DeploymentUpdate")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.DeploymentUpdate == nil { - r.EncodeNil() - } else { - x.DeploymentUpdate.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Job == nil { - r.EncodeNil() - } else { - x.Job.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Job")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Job == nil { - r.EncodeNil() - } else { - x.Job.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Eval == nil { - r.EncodeNil() - } else { - x.Eval.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Eval")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Eval == nil { - r.EncodeNil() - } else { - x.Eval.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ApplyDeploymentAllocHealthRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ApplyDeploymentAllocHealthRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "DeploymentID": - if r.TryDecodeAsNil() { - x.DeploymentID = "" - } else { - yyv4 := &x.DeploymentID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "HealthyAllocationIDs": - if r.TryDecodeAsNil() { - x.HealthyAllocationIDs = nil - } else { - yyv6 := &x.HealthyAllocationIDs - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - z.F.DecSliceStringX(yyv6, false, d) - } - } - case "UnhealthyAllocationIDs": - if r.TryDecodeAsNil() { - x.UnhealthyAllocationIDs = nil - } else { - yyv8 := &x.UnhealthyAllocationIDs - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - z.F.DecSliceStringX(yyv8, false, d) - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv10 := &x.Region - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv12 := &x.Namespace - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv14 := &x.AuthToken - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*string)(yyv14)) = r.DecodeString() - } - } - case "DeploymentUpdate": - if r.TryDecodeAsNil() { - if x.DeploymentUpdate != nil { - x.DeploymentUpdate = nil - } - } else { - if x.DeploymentUpdate == nil { - x.DeploymentUpdate = new(DeploymentStatusUpdate) - } - x.DeploymentUpdate.CodecDecodeSelf(d) - } - case "Job": - if r.TryDecodeAsNil() { - if x.Job != nil { - x.Job = nil - } - } else { - if x.Job == nil { - x.Job = new(Job) - } - x.Job.CodecDecodeSelf(d) - } - case "Eval": - if r.TryDecodeAsNil() { - if x.Eval != nil { - x.Eval = nil - } - } else { - if x.Eval == nil { - x.Eval = new(Evaluation) - } - x.Eval.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ApplyDeploymentAllocHealthRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj19 int - var yyb19 bool - var yyhl19 bool = l >= 0 - yyj19++ - if yyhl19 { - yyb19 = yyj19 > l - } else { - yyb19 = r.CheckBreak() - } - if yyb19 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DeploymentID = "" - } else { - yyv20 := &x.DeploymentID - yym21 := z.DecBinary() - _ = yym21 - if false { - } else { - *((*string)(yyv20)) = r.DecodeString() - } - } - yyj19++ - if yyhl19 { - yyb19 = yyj19 > l - } else { - yyb19 = r.CheckBreak() - } - if yyb19 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.HealthyAllocationIDs = nil - } else { - yyv22 := &x.HealthyAllocationIDs - yym23 := z.DecBinary() - _ = yym23 - if false { - } else { - z.F.DecSliceStringX(yyv22, false, d) - } - } - yyj19++ - if yyhl19 { - yyb19 = yyj19 > l - } else { - yyb19 = r.CheckBreak() - } - if yyb19 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.UnhealthyAllocationIDs = nil - } else { - yyv24 := &x.UnhealthyAllocationIDs - yym25 := z.DecBinary() - _ = yym25 - if false { - } else { - z.F.DecSliceStringX(yyv24, false, d) - } - } - yyj19++ - if yyhl19 { - yyb19 = yyj19 > l - } else { - yyb19 = r.CheckBreak() - } - if yyb19 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv26 := &x.Region - yym27 := z.DecBinary() - _ = yym27 - if false { - } else { - *((*string)(yyv26)) = r.DecodeString() - } - } - yyj19++ - if yyhl19 { - yyb19 = yyj19 > l - } else { - yyb19 = r.CheckBreak() - } - if yyb19 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv28 := &x.Namespace - yym29 := z.DecBinary() - _ = yym29 - if false { - } else { - *((*string)(yyv28)) = r.DecodeString() - } - } - yyj19++ - if yyhl19 { - yyb19 = yyj19 > l - } else { - yyb19 = r.CheckBreak() - } - if yyb19 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv30 := &x.AuthToken - yym31 := z.DecBinary() - _ = yym31 - if false { - } else { - *((*string)(yyv30)) = r.DecodeString() - } - } - yyj19++ - if yyhl19 { - yyb19 = yyj19 > l - } else { - yyb19 = r.CheckBreak() - } - if yyb19 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.DeploymentUpdate != nil { - x.DeploymentUpdate = nil - } - } else { - if x.DeploymentUpdate == nil { - x.DeploymentUpdate = new(DeploymentStatusUpdate) - } - x.DeploymentUpdate.CodecDecodeSelf(d) - } - yyj19++ - if yyhl19 { - yyb19 = yyj19 > l - } else { - yyb19 = r.CheckBreak() - } - if yyb19 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Job != nil { - x.Job = nil - } - } else { - if x.Job == nil { - x.Job = new(Job) - } - x.Job.CodecDecodeSelf(d) - } - yyj19++ - if yyhl19 { - yyb19 = yyj19 > l - } else { - yyb19 = r.CheckBreak() - } - if yyb19 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Eval != nil { - x.Eval = nil - } - } else { - if x.Eval == nil { - x.Eval = new(Evaluation) - } - x.Eval.CodecDecodeSelf(d) - } - for { - yyj19++ - if yyhl19 { - yyb19 = yyj19 > l - } else { - yyb19 = r.CheckBreak() - } - if yyb19 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj19-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *DeploymentPromoteRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [6]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(6) - } else { - yynn2 = 6 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DeploymentID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeBool(bool(x.All)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("All")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeBool(bool(x.All)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Groups == nil { - r.EncodeNil() - } else { - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - z.F.EncSliceStringV(x.Groups, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Groups")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Groups == nil { - r.EncodeNil() - } else { - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - z.F.EncSliceStringV(x.Groups, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *DeploymentPromoteRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *DeploymentPromoteRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "DeploymentID": - if r.TryDecodeAsNil() { - x.DeploymentID = "" - } else { - yyv4 := &x.DeploymentID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "All": - if r.TryDecodeAsNil() { - x.All = false - } else { - yyv6 := &x.All - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*bool)(yyv6)) = r.DecodeBool() - } - } - case "Groups": - if r.TryDecodeAsNil() { - x.Groups = nil - } else { - yyv8 := &x.Groups - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - z.F.DecSliceStringX(yyv8, false, d) - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv10 := &x.Region - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv12 := &x.Namespace - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv14 := &x.AuthToken - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*string)(yyv14)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *DeploymentPromoteRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj16 int - var yyb16 bool - var yyhl16 bool = l >= 0 - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DeploymentID = "" - } else { - yyv17 := &x.DeploymentID - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.All = false - } else { - yyv19 := &x.All - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*bool)(yyv19)) = r.DecodeBool() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Groups = nil - } else { - yyv21 := &x.Groups - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - z.F.DecSliceStringX(yyv21, false, d) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv23 := &x.Region - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv25 := &x.Namespace - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv27 := &x.AuthToken - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*string)(yyv27)) = r.DecodeString() - } - } - for { - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj16-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ApplyDeploymentPromoteRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [7]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(7) - } else { - yynn2 = 7 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DeploymentID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeBool(bool(x.All)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("All")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeBool(bool(x.All)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Groups == nil { - r.EncodeNil() - } else { - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - z.F.EncSliceStringV(x.Groups, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Groups")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Groups == nil { - r.EncodeNil() - } else { - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - z.F.EncSliceStringV(x.Groups, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Eval == nil { - r.EncodeNil() - } else { - x.Eval.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Eval")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Eval == nil { - r.EncodeNil() - } else { - x.Eval.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ApplyDeploymentPromoteRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ApplyDeploymentPromoteRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "DeploymentID": - if r.TryDecodeAsNil() { - x.DeploymentID = "" - } else { - yyv4 := &x.DeploymentID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "All": - if r.TryDecodeAsNil() { - x.All = false - } else { - yyv6 := &x.All - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*bool)(yyv6)) = r.DecodeBool() - } - } - case "Groups": - if r.TryDecodeAsNil() { - x.Groups = nil - } else { - yyv8 := &x.Groups - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - z.F.DecSliceStringX(yyv8, false, d) - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv10 := &x.Region - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv12 := &x.Namespace - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv14 := &x.AuthToken - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*string)(yyv14)) = r.DecodeString() - } - } - case "Eval": - if r.TryDecodeAsNil() { - if x.Eval != nil { - x.Eval = nil - } - } else { - if x.Eval == nil { - x.Eval = new(Evaluation) - } - x.Eval.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ApplyDeploymentPromoteRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj17 int - var yyb17 bool - var yyhl17 bool = l >= 0 - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DeploymentID = "" - } else { - yyv18 := &x.DeploymentID - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.All = false - } else { - yyv20 := &x.All - yym21 := z.DecBinary() - _ = yym21 - if false { - } else { - *((*bool)(yyv20)) = r.DecodeBool() - } - } - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Groups = nil - } else { - yyv22 := &x.Groups - yym23 := z.DecBinary() - _ = yym23 - if false { - } else { - z.F.DecSliceStringX(yyv22, false, d) - } - } - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv24 := &x.Region - yym25 := z.DecBinary() - _ = yym25 - if false { - } else { - *((*string)(yyv24)) = r.DecodeString() - } - } - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv26 := &x.Namespace - yym27 := z.DecBinary() - _ = yym27 - if false { - } else { - *((*string)(yyv26)) = r.DecodeString() - } - } - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv28 := &x.AuthToken - yym29 := z.DecBinary() - _ = yym29 - if false { - } else { - *((*string)(yyv28)) = r.DecodeString() - } - } - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Eval != nil { - x.Eval = nil - } - } else { - if x.Eval == nil { - x.Eval = new(Evaluation) - } - x.Eval.CodecDecodeSelf(d) - } - for { - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj17-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *DeploymentPauseRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 5 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DeploymentID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeBool(bool(x.Pause)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Pause")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeBool(bool(x.Pause)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *DeploymentPauseRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *DeploymentPauseRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "DeploymentID": - if r.TryDecodeAsNil() { - x.DeploymentID = "" - } else { - yyv4 := &x.DeploymentID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Pause": - if r.TryDecodeAsNil() { - x.Pause = false - } else { - yyv6 := &x.Pause - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*bool)(yyv6)) = r.DecodeBool() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv8 := &x.Region - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv10 := &x.Namespace - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv12 := &x.AuthToken - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *DeploymentPauseRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj14 int - var yyb14 bool - var yyhl14 bool = l >= 0 - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DeploymentID = "" - } else { - yyv15 := &x.DeploymentID - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Pause = false - } else { - yyv17 := &x.Pause - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*bool)(yyv17)) = r.DecodeBool() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv19 := &x.Region - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv21 := &x.Namespace - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv23 := &x.AuthToken - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - for { - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj14-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *DeploymentSpecificRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [8]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(8) - } else { - yynn2 = 8 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DeploymentID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *DeploymentSpecificRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *DeploymentSpecificRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "DeploymentID": - if r.TryDecodeAsNil() { - x.DeploymentID = "" - } else { - yyv4 := &x.DeploymentID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv10 := &x.MinQueryIndex - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv12 := &x.MaxQueryTime - yym13 := z.DecBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.DecExt(yyv12) { - } else { - *((*int64)(yyv12)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv14 := &x.AllowStale - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*bool)(yyv14)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv16 := &x.Prefix - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv18 := &x.AuthToken - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *DeploymentSpecificRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj20 int - var yyb20 bool - var yyhl20 bool = l >= 0 - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DeploymentID = "" - } else { - yyv21 := &x.DeploymentID - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv23 := &x.Region - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv25 := &x.Namespace - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv27 := &x.MinQueryIndex - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv29 := &x.MaxQueryTime - yym30 := z.DecBinary() - _ = yym30 - if false { - } else if z.HasExtensions() && z.DecExt(yyv29) { - } else { - *((*int64)(yyv29)) = int64(r.DecodeInt(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv31 := &x.AllowStale - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*bool)(yyv31)) = r.DecodeBool() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv33 := &x.Prefix - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - *((*string)(yyv33)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv35 := &x.AuthToken - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*string)(yyv35)) = r.DecodeString() - } - } - for { - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj20-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *DeploymentFailRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DeploymentID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *DeploymentFailRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *DeploymentFailRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "DeploymentID": - if r.TryDecodeAsNil() { - x.DeploymentID = "" - } else { - yyv4 := &x.DeploymentID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv10 := &x.AuthToken - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *DeploymentFailRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DeploymentID = "" - } else { - yyv13 := &x.DeploymentID - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*string)(yyv13)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv15 := &x.Region - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv17 := &x.Namespace - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv19 := &x.AuthToken - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *SingleDeploymentResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Deployment == nil { - r.EncodeNil() - } else { - x.Deployment.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Deployment")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Deployment == nil { - r.EncodeNil() - } else { - x.Deployment.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *SingleDeploymentResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *SingleDeploymentResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Deployment": - if r.TryDecodeAsNil() { - if x.Deployment != nil { - x.Deployment = nil - } - } else { - if x.Deployment == nil { - x.Deployment = new(Deployment) - } - x.Deployment.CodecDecodeSelf(d) - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv5 := &x.Index - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv7 := &x.LastContact - yym8 := z.DecBinary() - _ = yym8 - if false { - } else if z.HasExtensions() && z.DecExt(yyv7) { - } else { - *((*int64)(yyv7)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv9 := &x.KnownLeader - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*bool)(yyv9)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *SingleDeploymentResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj11 int - var yyb11 bool - var yyhl11 bool = l >= 0 - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Deployment != nil { - x.Deployment = nil - } - } else { - if x.Deployment == nil { - x.Deployment = new(Deployment) - } - x.Deployment.CodecDecodeSelf(d) - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv13 := &x.Index - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv15 := &x.LastContact - yym16 := z.DecBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.DecExt(yyv15) { - } else { - *((*int64)(yyv15)) = int64(r.DecodeInt(64)) - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv17 := &x.KnownLeader - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*bool)(yyv17)) = r.DecodeBool() - } - } - for { - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj11-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *GenericResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [1]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(1) - } else { - yynn2 = 1 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *GenericResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *GenericResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv4 := &x.Index - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*uint64)(yyv4)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *GenericResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - 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 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv7 := &x.Index - yym8 := z.DecBinary() - _ = yym8 - if false { - } else { - *((*uint64)(yyv7)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj6++ - if yyhl6 { - yyb6 = yyj6 > l - } else { - yyb6 = r.CheckBreak() - } - if yyb6 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj6-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *VersionResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 5 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Build)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Build")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Build)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Versions == nil { - r.EncodeNil() - } else { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - z.F.EncMapStringIntV(x.Versions, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Versions")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Versions == nil { - r.EncodeNil() - } else { - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - z.F.EncMapStringIntV(x.Versions, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *VersionResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *VersionResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Build": - if r.TryDecodeAsNil() { - x.Build = "" - } else { - yyv4 := &x.Build - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Versions": - if r.TryDecodeAsNil() { - x.Versions = nil - } else { - yyv6 := &x.Versions - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - z.F.DecMapStringIntX(yyv6, false, d) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv8 := &x.Index - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv10 := &x.LastContact - yym11 := z.DecBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.DecExt(yyv10) { - } else { - *((*int64)(yyv10)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv12 := &x.KnownLeader - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*bool)(yyv12)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *VersionResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj14 int - var yyb14 bool - var yyhl14 bool = l >= 0 - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Build = "" - } else { - yyv15 := &x.Build - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Versions = nil - } else { - yyv17 := &x.Versions - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - z.F.DecMapStringIntX(yyv17, false, d) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv19 := &x.Index - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv21 := &x.LastContact - yym22 := z.DecBinary() - _ = yym22 - if false { - } else if z.HasExtensions() && z.DecExt(yyv21) { - } else { - *((*int64)(yyv21)) = int64(r.DecodeInt(64)) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv23 := &x.KnownLeader - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*bool)(yyv23)) = r.DecodeBool() - } - } - for { - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj14-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobRegisterResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [7]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(7) - } else { - yynn2 = 7 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.EvalCreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalCreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.EvalCreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.JobModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.JobModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Warnings)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Warnings")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Warnings)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobRegisterResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobRegisterResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "EvalID": - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv4 := &x.EvalID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "EvalCreateIndex": - if r.TryDecodeAsNil() { - x.EvalCreateIndex = 0 - } else { - yyv6 := &x.EvalCreateIndex - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "JobModifyIndex": - if r.TryDecodeAsNil() { - x.JobModifyIndex = 0 - } else { - yyv8 := &x.JobModifyIndex - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) - } - } - case "Warnings": - if r.TryDecodeAsNil() { - x.Warnings = "" - } else { - yyv10 := &x.Warnings - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv12 := &x.Index - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*uint64)(yyv12)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv14 := &x.LastContact - yym15 := z.DecBinary() - _ = yym15 - if false { - } else if z.HasExtensions() && z.DecExt(yyv14) { - } else { - *((*int64)(yyv14)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv16 := &x.KnownLeader - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*bool)(yyv16)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobRegisterResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj18 int - var yyb18 bool - var yyhl18 bool = l >= 0 - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv19 := &x.EvalID - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalCreateIndex = 0 - } else { - yyv21 := &x.EvalCreateIndex - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*uint64)(yyv21)) = uint64(r.DecodeUint(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobModifyIndex = 0 - } else { - yyv23 := &x.JobModifyIndex - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Warnings = "" - } else { - yyv25 := &x.Warnings - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv27 := &x.Index - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv29 := &x.LastContact - yym30 := z.DecBinary() - _ = yym30 - if false { - } else if z.HasExtensions() && z.DecExt(yyv29) { - } else { - *((*int64)(yyv29)) = int64(r.DecodeInt(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv31 := &x.KnownLeader - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*bool)(yyv31)) = r.DecodeBool() - } - } - for { - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj18-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobDeregisterResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [6]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(6) - } else { - yynn2 = 6 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.EvalCreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalCreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.EvalCreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.JobModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.JobModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobDeregisterResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobDeregisterResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "EvalID": - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv4 := &x.EvalID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "EvalCreateIndex": - if r.TryDecodeAsNil() { - x.EvalCreateIndex = 0 - } else { - yyv6 := &x.EvalCreateIndex - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "JobModifyIndex": - if r.TryDecodeAsNil() { - x.JobModifyIndex = 0 - } else { - yyv8 := &x.JobModifyIndex - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv10 := &x.Index - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv12 := &x.LastContact - yym13 := z.DecBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.DecExt(yyv12) { - } else { - *((*int64)(yyv12)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv14 := &x.KnownLeader - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*bool)(yyv14)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobDeregisterResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj16 int - var yyb16 bool - var yyhl16 bool = l >= 0 - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv17 := &x.EvalID - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalCreateIndex = 0 - } else { - yyv19 := &x.EvalCreateIndex - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobModifyIndex = 0 - } else { - yyv21 := &x.JobModifyIndex - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*uint64)(yyv21)) = uint64(r.DecodeUint(64)) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv23 := &x.Index - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv25 := &x.LastContact - yym26 := z.DecBinary() - _ = yym26 - if false { - } else if z.HasExtensions() && z.DecExt(yyv25) { - } else { - *((*int64)(yyv25)) = int64(r.DecodeInt(64)) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv27 := &x.KnownLeader - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*bool)(yyv27)) = r.DecodeBool() - } - } - for { - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj16-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobValidateResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeBool(bool(x.DriverConfigValidated)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DriverConfigValidated")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeBool(bool(x.DriverConfigValidated)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.ValidationErrors == nil { - r.EncodeNil() - } else { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - z.F.EncSliceStringV(x.ValidationErrors, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ValidationErrors")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.ValidationErrors == nil { - r.EncodeNil() - } else { - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - z.F.EncSliceStringV(x.ValidationErrors, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Error)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Error")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Error)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Warnings)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Warnings")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Warnings)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobValidateResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobValidateResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "DriverConfigValidated": - if r.TryDecodeAsNil() { - x.DriverConfigValidated = false - } else { - yyv4 := &x.DriverConfigValidated - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*bool)(yyv4)) = r.DecodeBool() - } - } - case "ValidationErrors": - if r.TryDecodeAsNil() { - x.ValidationErrors = nil - } else { - yyv6 := &x.ValidationErrors - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - z.F.DecSliceStringX(yyv6, false, d) - } - } - case "Error": - if r.TryDecodeAsNil() { - x.Error = "" - } else { - yyv8 := &x.Error - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Warnings": - if r.TryDecodeAsNil() { - x.Warnings = "" - } else { - yyv10 := &x.Warnings - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobValidateResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DriverConfigValidated = false - } else { - yyv13 := &x.DriverConfigValidated - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*bool)(yyv13)) = r.DecodeBool() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ValidationErrors = nil - } else { - yyv15 := &x.ValidationErrors - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - z.F.DecSliceStringX(yyv15, false, d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Error = "" - } else { - yyv17 := &x.Error - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Warnings = "" - } else { - yyv19 := &x.Warnings - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *NodeUpdateResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [10]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(10) - } else { - yynn2 = 10 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else if z.HasExtensions() && z.EncExt(x.HeartbeatTTL) { - } else { - r.EncodeInt(int64(x.HeartbeatTTL)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("HeartbeatTTL")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else if z.HasExtensions() && z.EncExt(x.HeartbeatTTL) { - } else { - r.EncodeInt(int64(x.HeartbeatTTL)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.EvalIDs == nil { - r.EncodeNil() - } else { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - z.F.EncSliceStringV(x.EvalIDs, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalIDs")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.EvalIDs == nil { - r.EncodeNil() - } else { - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - z.F.EncSliceStringV(x.EvalIDs, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.EvalCreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalCreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.EvalCreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeUint(uint64(x.NodeModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodeModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeUint(uint64(x.NodeModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.LeaderRPCAddr)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LeaderRPCAddr")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.LeaderRPCAddr)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeInt(int64(x.NumNodes)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NumNodes")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeInt(int64(x.NumNodes)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Servers == nil { - r.EncodeNil() - } else { - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - h.encSlicePtrtoNodeServerInfo(([]*NodeServerInfo)(x.Servers), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Servers")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Servers == nil { - r.EncodeNil() - } else { - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - h.encSlicePtrtoNodeServerInfo(([]*NodeServerInfo)(x.Servers), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym28 := z.EncBinary() - _ = yym28 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym29 := z.EncBinary() - _ = yym29 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym31 := z.EncBinary() - _ = yym31 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym32 := z.EncBinary() - _ = yym32 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *NodeUpdateResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *NodeUpdateResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "HeartbeatTTL": - if r.TryDecodeAsNil() { - x.HeartbeatTTL = 0 - } else { - yyv4 := &x.HeartbeatTTL - yym5 := z.DecBinary() - _ = yym5 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4) { - } else { - *((*int64)(yyv4)) = int64(r.DecodeInt(64)) - } - } - case "EvalIDs": - if r.TryDecodeAsNil() { - x.EvalIDs = nil - } else { - yyv6 := &x.EvalIDs - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - z.F.DecSliceStringX(yyv6, false, d) - } - } - case "EvalCreateIndex": - if r.TryDecodeAsNil() { - x.EvalCreateIndex = 0 - } else { - yyv8 := &x.EvalCreateIndex - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) - } - } - case "NodeModifyIndex": - if r.TryDecodeAsNil() { - x.NodeModifyIndex = 0 - } else { - yyv10 := &x.NodeModifyIndex - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) - } - } - case "LeaderRPCAddr": - if r.TryDecodeAsNil() { - x.LeaderRPCAddr = "" - } else { - yyv12 := &x.LeaderRPCAddr - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - case "NumNodes": - if r.TryDecodeAsNil() { - x.NumNodes = 0 - } else { - yyv14 := &x.NumNodes - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*int32)(yyv14)) = int32(r.DecodeInt(32)) - } - } - case "Servers": - if r.TryDecodeAsNil() { - x.Servers = nil - } else { - yyv16 := &x.Servers - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - h.decSlicePtrtoNodeServerInfo((*[]*NodeServerInfo)(yyv16), d) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv18 := &x.Index - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*uint64)(yyv18)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv20 := &x.LastContact - yym21 := z.DecBinary() - _ = yym21 - if false { - } else if z.HasExtensions() && z.DecExt(yyv20) { - } else { - *((*int64)(yyv20)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv22 := &x.KnownLeader - yym23 := z.DecBinary() - _ = yym23 - if false { - } else { - *((*bool)(yyv22)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *NodeUpdateResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj24 int - var yyb24 bool - var yyhl24 bool = l >= 0 - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.HeartbeatTTL = 0 - } else { - yyv25 := &x.HeartbeatTTL - yym26 := z.DecBinary() - _ = yym26 - if false { - } else if z.HasExtensions() && z.DecExt(yyv25) { - } else { - *((*int64)(yyv25)) = int64(r.DecodeInt(64)) - } - } - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalIDs = nil - } else { - yyv27 := &x.EvalIDs - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - z.F.DecSliceStringX(yyv27, false, d) - } - } - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalCreateIndex = 0 - } else { - yyv29 := &x.EvalCreateIndex - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*uint64)(yyv29)) = uint64(r.DecodeUint(64)) - } - } - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodeModifyIndex = 0 - } else { - yyv31 := &x.NodeModifyIndex - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*uint64)(yyv31)) = uint64(r.DecodeUint(64)) - } - } - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LeaderRPCAddr = "" - } else { - yyv33 := &x.LeaderRPCAddr - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - *((*string)(yyv33)) = r.DecodeString() - } - } - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NumNodes = 0 - } else { - yyv35 := &x.NumNodes - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*int32)(yyv35)) = int32(r.DecodeInt(32)) - } - } - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Servers = nil - } else { - yyv37 := &x.Servers - yym38 := z.DecBinary() - _ = yym38 - if false { - } else { - h.decSlicePtrtoNodeServerInfo((*[]*NodeServerInfo)(yyv37), d) - } - } - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv39 := &x.Index - yym40 := z.DecBinary() - _ = yym40 - if false { - } else { - *((*uint64)(yyv39)) = uint64(r.DecodeUint(64)) - } - } - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv41 := &x.LastContact - yym42 := z.DecBinary() - _ = yym42 - if false { - } else if z.HasExtensions() && z.DecExt(yyv41) { - } else { - *((*int64)(yyv41)) = int64(r.DecodeInt(64)) - } - } - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv43 := &x.KnownLeader - yym44 := z.DecBinary() - _ = yym44 - if false { - } else { - *((*bool)(yyv43)) = r.DecodeBool() - } - } - for { - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj24-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *NodeDrainUpdateResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [6]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(6) - } else { - yynn2 = 6 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.EvalIDs == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - z.F.EncSliceStringV(x.EvalIDs, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalIDs")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.EvalIDs == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - z.F.EncSliceStringV(x.EvalIDs, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.EvalCreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalCreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.EvalCreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.NodeModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodeModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.NodeModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *NodeDrainUpdateResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *NodeDrainUpdateResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "EvalIDs": - if r.TryDecodeAsNil() { - x.EvalIDs = nil - } else { - yyv4 := &x.EvalIDs - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - z.F.DecSliceStringX(yyv4, false, d) - } - } - case "EvalCreateIndex": - if r.TryDecodeAsNil() { - x.EvalCreateIndex = 0 - } else { - yyv6 := &x.EvalCreateIndex - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "NodeModifyIndex": - if r.TryDecodeAsNil() { - x.NodeModifyIndex = 0 - } else { - yyv8 := &x.NodeModifyIndex - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv10 := &x.Index - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv12 := &x.LastContact - yym13 := z.DecBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.DecExt(yyv12) { - } else { - *((*int64)(yyv12)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv14 := &x.KnownLeader - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*bool)(yyv14)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *NodeDrainUpdateResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj16 int - var yyb16 bool - var yyhl16 bool = l >= 0 - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalIDs = nil - } else { - yyv17 := &x.EvalIDs - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - z.F.DecSliceStringX(yyv17, false, d) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalCreateIndex = 0 - } else { - yyv19 := &x.EvalCreateIndex - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodeModifyIndex = 0 - } else { - yyv21 := &x.NodeModifyIndex - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*uint64)(yyv21)) = uint64(r.DecodeUint(64)) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv23 := &x.Index - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv25 := &x.LastContact - yym26 := z.DecBinary() - _ = yym26 - if false { - } else if z.HasExtensions() && z.DecExt(yyv25) { - } else { - *((*int64)(yyv25)) = int64(r.DecodeInt(64)) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv27 := &x.KnownLeader - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*bool)(yyv27)) = r.DecodeBool() - } - } - for { - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj16-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *NodeAllocsResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Allocs == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encSlicePtrtoAllocation(([]*Allocation)(x.Allocs), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Allocs")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Allocs == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encSlicePtrtoAllocation(([]*Allocation)(x.Allocs), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *NodeAllocsResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *NodeAllocsResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Allocs": - if r.TryDecodeAsNil() { - x.Allocs = nil - } else { - yyv4 := &x.Allocs - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decSlicePtrtoAllocation((*[]*Allocation)(yyv4), d) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv6 := &x.Index - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv8 := &x.LastContact - yym9 := z.DecBinary() - _ = yym9 - if false { - } else if z.HasExtensions() && z.DecExt(yyv8) { - } else { - *((*int64)(yyv8)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv10 := &x.KnownLeader - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*bool)(yyv10)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *NodeAllocsResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Allocs = nil - } else { - yyv13 := &x.Allocs - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - h.decSlicePtrtoAllocation((*[]*Allocation)(yyv13), d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv15 := &x.Index - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv17 := &x.LastContact - yym18 := z.DecBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.DecExt(yyv17) { - } else { - *((*int64)(yyv17)) = int64(r.DecodeInt(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv19 := &x.KnownLeader - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*bool)(yyv19)) = r.DecodeBool() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *NodeClientAllocsResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 5 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Allocs == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - z.F.EncMapStringUint64V(x.Allocs, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Allocs")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Allocs == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - z.F.EncMapStringUint64V(x.Allocs, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.MigrateTokens == nil { - r.EncodeNil() - } else { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - z.F.EncMapStringStringV(x.MigrateTokens, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MigrateTokens")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.MigrateTokens == nil { - r.EncodeNil() - } else { - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - z.F.EncMapStringStringV(x.MigrateTokens, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *NodeClientAllocsResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *NodeClientAllocsResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Allocs": - if r.TryDecodeAsNil() { - x.Allocs = nil - } else { - yyv4 := &x.Allocs - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - z.F.DecMapStringUint64X(yyv4, false, d) - } - } - case "MigrateTokens": - if r.TryDecodeAsNil() { - x.MigrateTokens = nil - } else { - yyv6 := &x.MigrateTokens - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - z.F.DecMapStringStringX(yyv6, false, d) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv8 := &x.Index - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv10 := &x.LastContact - yym11 := z.DecBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.DecExt(yyv10) { - } else { - *((*int64)(yyv10)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv12 := &x.KnownLeader - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*bool)(yyv12)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *NodeClientAllocsResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj14 int - var yyb14 bool - var yyhl14 bool = l >= 0 - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Allocs = nil - } else { - yyv15 := &x.Allocs - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - z.F.DecMapStringUint64X(yyv15, false, d) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MigrateTokens = nil - } else { - yyv17 := &x.MigrateTokens - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - z.F.DecMapStringStringX(yyv17, false, d) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv19 := &x.Index - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv21 := &x.LastContact - yym22 := z.DecBinary() - _ = yym22 - if false { - } else if z.HasExtensions() && z.DecExt(yyv21) { - } else { - *((*int64)(yyv21)) = int64(r.DecodeInt(64)) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv23 := &x.KnownLeader - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*bool)(yyv23)) = r.DecodeBool() - } - } - for { - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj14-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *SingleNodeResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Node == nil { - r.EncodeNil() - } else { - x.Node.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Node")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Node == nil { - r.EncodeNil() - } else { - x.Node.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *SingleNodeResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *SingleNodeResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Node": - if r.TryDecodeAsNil() { - if x.Node != nil { - x.Node = nil - } - } else { - if x.Node == nil { - x.Node = new(Node) - } - x.Node.CodecDecodeSelf(d) - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv5 := &x.Index - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv7 := &x.LastContact - yym8 := z.DecBinary() - _ = yym8 - if false { - } else if z.HasExtensions() && z.DecExt(yyv7) { - } else { - *((*int64)(yyv7)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv9 := &x.KnownLeader - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*bool)(yyv9)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *SingleNodeResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj11 int - var yyb11 bool - var yyhl11 bool = l >= 0 - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Node != nil { - x.Node = nil - } - } else { - if x.Node == nil { - x.Node = new(Node) - } - x.Node.CodecDecodeSelf(d) - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv13 := &x.Index - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv15 := &x.LastContact - yym16 := z.DecBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.DecExt(yyv15) { - } else { - *((*int64)(yyv15)) = int64(r.DecodeInt(64)) - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv17 := &x.KnownLeader - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*bool)(yyv17)) = r.DecodeBool() - } - } - for { - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj11-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *NodeListResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Nodes == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encSlicePtrtoNodeListStub(([]*NodeListStub)(x.Nodes), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Nodes")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Nodes == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encSlicePtrtoNodeListStub(([]*NodeListStub)(x.Nodes), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *NodeListResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *NodeListResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Nodes": - if r.TryDecodeAsNil() { - x.Nodes = nil - } else { - yyv4 := &x.Nodes - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decSlicePtrtoNodeListStub((*[]*NodeListStub)(yyv4), d) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv6 := &x.Index - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv8 := &x.LastContact - yym9 := z.DecBinary() - _ = yym9 - if false { - } else if z.HasExtensions() && z.DecExt(yyv8) { - } else { - *((*int64)(yyv8)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv10 := &x.KnownLeader - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*bool)(yyv10)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *NodeListResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Nodes = nil - } else { - yyv13 := &x.Nodes - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - h.decSlicePtrtoNodeListStub((*[]*NodeListStub)(yyv13), d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv15 := &x.Index - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv17 := &x.LastContact - yym18 := z.DecBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.DecExt(yyv17) { - } else { - *((*int64)(yyv17)) = int64(r.DecodeInt(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv19 := &x.KnownLeader - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*bool)(yyv19)) = r.DecodeBool() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *SingleJobResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Job == nil { - r.EncodeNil() - } else { - x.Job.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Job")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Job == nil { - r.EncodeNil() - } else { - x.Job.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *SingleJobResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *SingleJobResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Job": - if r.TryDecodeAsNil() { - if x.Job != nil { - x.Job = nil - } - } else { - if x.Job == nil { - x.Job = new(Job) - } - x.Job.CodecDecodeSelf(d) - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv5 := &x.Index - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv7 := &x.LastContact - yym8 := z.DecBinary() - _ = yym8 - if false { - } else if z.HasExtensions() && z.DecExt(yyv7) { - } else { - *((*int64)(yyv7)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv9 := &x.KnownLeader - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*bool)(yyv9)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *SingleJobResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj11 int - var yyb11 bool - var yyhl11 bool = l >= 0 - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Job != nil { - x.Job = nil - } - } else { - if x.Job == nil { - x.Job = new(Job) - } - x.Job.CodecDecodeSelf(d) - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv13 := &x.Index - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv15 := &x.LastContact - yym16 := z.DecBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.DecExt(yyv15) { - } else { - *((*int64)(yyv15)) = int64(r.DecodeInt(64)) - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv17 := &x.KnownLeader - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*bool)(yyv17)) = r.DecodeBool() - } - } - for { - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj11-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobSummaryResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.JobSummary == nil { - r.EncodeNil() - } else { - x.JobSummary.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobSummary")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.JobSummary == nil { - r.EncodeNil() - } else { - x.JobSummary.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobSummaryResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobSummaryResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "JobSummary": - if r.TryDecodeAsNil() { - if x.JobSummary != nil { - x.JobSummary = nil - } - } else { - if x.JobSummary == nil { - x.JobSummary = new(JobSummary) - } - x.JobSummary.CodecDecodeSelf(d) - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv5 := &x.Index - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv7 := &x.LastContact - yym8 := z.DecBinary() - _ = yym8 - if false { - } else if z.HasExtensions() && z.DecExt(yyv7) { - } else { - *((*int64)(yyv7)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv9 := &x.KnownLeader - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*bool)(yyv9)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobSummaryResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj11 int - var yyb11 bool - var yyhl11 bool = l >= 0 - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.JobSummary != nil { - x.JobSummary = nil - } - } else { - if x.JobSummary == nil { - x.JobSummary = new(JobSummary) - } - x.JobSummary.CodecDecodeSelf(d) - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv13 := &x.Index - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv15 := &x.LastContact - yym16 := z.DecBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.DecExt(yyv15) { - } else { - *((*int64)(yyv15)) = int64(r.DecodeInt(64)) - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv17 := &x.KnownLeader - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*bool)(yyv17)) = r.DecodeBool() - } - } - for { - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj11-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobDispatchResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 5 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DispatchedJobID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DispatchedJobID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DispatchedJobID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.EvalCreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalCreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.EvalCreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeUint(uint64(x.JobCreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobCreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeUint(uint64(x.JobCreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobDispatchResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobDispatchResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "DispatchedJobID": - if r.TryDecodeAsNil() { - x.DispatchedJobID = "" - } else { - yyv4 := &x.DispatchedJobID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "EvalID": - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv6 := &x.EvalID - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "EvalCreateIndex": - if r.TryDecodeAsNil() { - x.EvalCreateIndex = 0 - } else { - yyv8 := &x.EvalCreateIndex - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) - } - } - case "JobCreateIndex": - if r.TryDecodeAsNil() { - x.JobCreateIndex = 0 - } else { - yyv10 := &x.JobCreateIndex - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv12 := &x.Index - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*uint64)(yyv12)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobDispatchResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj14 int - var yyb14 bool - var yyhl14 bool = l >= 0 - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DispatchedJobID = "" - } else { - yyv15 := &x.DispatchedJobID - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv17 := &x.EvalID - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalCreateIndex = 0 - } else { - yyv19 := &x.EvalCreateIndex - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobCreateIndex = 0 - } else { - yyv21 := &x.JobCreateIndex - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*uint64)(yyv21)) = uint64(r.DecodeUint(64)) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv23 := &x.Index - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj14-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobListResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Jobs == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encSlicePtrtoJobListStub(([]*JobListStub)(x.Jobs), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Jobs")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Jobs == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encSlicePtrtoJobListStub(([]*JobListStub)(x.Jobs), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobListResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobListResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Jobs": - if r.TryDecodeAsNil() { - x.Jobs = nil - } else { - yyv4 := &x.Jobs - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decSlicePtrtoJobListStub((*[]*JobListStub)(yyv4), d) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv6 := &x.Index - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv8 := &x.LastContact - yym9 := z.DecBinary() - _ = yym9 - if false { - } else if z.HasExtensions() && z.DecExt(yyv8) { - } else { - *((*int64)(yyv8)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv10 := &x.KnownLeader - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*bool)(yyv10)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobListResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Jobs = nil - } else { - yyv13 := &x.Jobs - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - h.decSlicePtrtoJobListStub((*[]*JobListStub)(yyv13), d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv15 := &x.Index - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv17 := &x.LastContact - yym18 := z.DecBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.DecExt(yyv17) { - } else { - *((*int64)(yyv17)) = int64(r.DecodeInt(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv19 := &x.KnownLeader - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*bool)(yyv19)) = r.DecodeBool() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobVersionsRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [9]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(9) - } else { - yynn2 = 9 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeBool(bool(x.Diffs)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Diffs")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeBool(bool(x.Diffs)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym28 := z.EncBinary() - _ = yym28 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym29 := z.EncBinary() - _ = yym29 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobVersionsRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobVersionsRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "JobID": - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv4 := &x.JobID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Diffs": - if r.TryDecodeAsNil() { - x.Diffs = false - } else { - yyv6 := &x.Diffs - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*bool)(yyv6)) = r.DecodeBool() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv8 := &x.Region - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv10 := &x.Namespace - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv12 := &x.MinQueryIndex - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*uint64)(yyv12)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv14 := &x.MaxQueryTime - yym15 := z.DecBinary() - _ = yym15 - if false { - } else if z.HasExtensions() && z.DecExt(yyv14) { - } else { - *((*int64)(yyv14)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv16 := &x.AllowStale - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*bool)(yyv16)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv18 := &x.Prefix - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv20 := &x.AuthToken - yym21 := z.DecBinary() - _ = yym21 - if false { - } else { - *((*string)(yyv20)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobVersionsRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj22 int - var yyb22 bool - var yyhl22 bool = l >= 0 - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv23 := &x.JobID - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Diffs = false - } else { - yyv25 := &x.Diffs - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*bool)(yyv25)) = r.DecodeBool() - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv27 := &x.Region - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*string)(yyv27)) = r.DecodeString() - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv29 := &x.Namespace - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*string)(yyv29)) = r.DecodeString() - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv31 := &x.MinQueryIndex - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*uint64)(yyv31)) = uint64(r.DecodeUint(64)) - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv33 := &x.MaxQueryTime - yym34 := z.DecBinary() - _ = yym34 - if false { - } else if z.HasExtensions() && z.DecExt(yyv33) { - } else { - *((*int64)(yyv33)) = int64(r.DecodeInt(64)) - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv35 := &x.AllowStale - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*bool)(yyv35)) = r.DecodeBool() - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv37 := &x.Prefix - yym38 := z.DecBinary() - _ = yym38 - if false { - } else { - *((*string)(yyv37)) = r.DecodeString() - } - } - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv39 := &x.AuthToken - yym40 := z.DecBinary() - _ = yym40 - if false { - } else { - *((*string)(yyv39)) = r.DecodeString() - } - } - for { - yyj22++ - if yyhl22 { - yyb22 = yyj22 > l - } else { - yyb22 = r.CheckBreak() - } - if yyb22 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj22-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobVersionsResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 5 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Versions == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encSlicePtrtoJob(([]*Job)(x.Versions), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Versions")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Versions == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encSlicePtrtoJob(([]*Job)(x.Versions), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Diffs == nil { - r.EncodeNil() - } else { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - h.encSlicePtrtoJobDiff(([]*JobDiff)(x.Diffs), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Diffs")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Diffs == nil { - r.EncodeNil() - } else { - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - h.encSlicePtrtoJobDiff(([]*JobDiff)(x.Diffs), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobVersionsResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobVersionsResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Versions": - if r.TryDecodeAsNil() { - x.Versions = nil - } else { - yyv4 := &x.Versions - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decSlicePtrtoJob((*[]*Job)(yyv4), d) - } - } - case "Diffs": - if r.TryDecodeAsNil() { - x.Diffs = nil - } else { - yyv6 := &x.Diffs - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - h.decSlicePtrtoJobDiff((*[]*JobDiff)(yyv6), d) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv8 := &x.Index - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv10 := &x.LastContact - yym11 := z.DecBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.DecExt(yyv10) { - } else { - *((*int64)(yyv10)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv12 := &x.KnownLeader - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*bool)(yyv12)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobVersionsResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj14 int - var yyb14 bool - var yyhl14 bool = l >= 0 - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Versions = nil - } else { - yyv15 := &x.Versions - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - h.decSlicePtrtoJob((*[]*Job)(yyv15), d) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Diffs = nil - } else { - yyv17 := &x.Diffs - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - h.decSlicePtrtoJobDiff((*[]*JobDiff)(yyv17), d) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv19 := &x.Index - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv21 := &x.LastContact - yym22 := z.DecBinary() - _ = yym22 - if false { - } else if z.HasExtensions() && z.DecExt(yyv21) { - } else { - *((*int64)(yyv21)) = int64(r.DecodeInt(64)) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv23 := &x.KnownLeader - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*bool)(yyv23)) = r.DecodeBool() - } - } - for { - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj14-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobPlanResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [8]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(8) - } else { - yynn2 = 8 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Annotations == nil { - r.EncodeNil() - } else { - x.Annotations.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Annotations")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Annotations == nil { - r.EncodeNil() - } else { - x.Annotations.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.FailedTGAllocs == nil { - r.EncodeNil() - } else { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - h.encMapstringPtrtoAllocMetric((map[string]*AllocMetric)(x.FailedTGAllocs), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("FailedTGAllocs")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.FailedTGAllocs == nil { - r.EncodeNil() - } else { - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - h.encMapstringPtrtoAllocMetric((map[string]*AllocMetric)(x.FailedTGAllocs), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.JobModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.JobModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.CreatedEvals == nil { - r.EncodeNil() - } else { - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - h.encSlicePtrtoEvaluation(([]*Evaluation)(x.CreatedEvals), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CreatedEvals")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.CreatedEvals == nil { - r.EncodeNil() - } else { - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - h.encSlicePtrtoEvaluation(([]*Evaluation)(x.CreatedEvals), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Diff == nil { - r.EncodeNil() - } else { - yym16 := z.EncBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.EncExt(x.Diff) { - } else { - z.EncFallback(x.Diff) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Diff")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Diff == nil { - r.EncodeNil() - } else { - yym17 := z.EncBinary() - _ = yym17 - if false { - } else if z.HasExtensions() && z.EncExt(x.Diff) { - } else { - z.EncFallback(x.Diff) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yy19 := &x.NextPeriodicLaunch - yym20 := z.EncBinary() - _ = yym20 - if false { - } else if yym21 := z.TimeRtidIfBinc(); yym21 != 0 { - r.EncodeBuiltin(yym21, yy19) - } else if z.HasExtensions() && z.EncExt(yy19) { - } else if yym20 { - z.EncBinaryMarshal(yy19) - } else if !yym20 && z.IsJSONHandle() { - z.EncJSONMarshal(yy19) - } else { - z.EncFallback(yy19) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NextPeriodicLaunch")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yy22 := &x.NextPeriodicLaunch - yym23 := z.EncBinary() - _ = yym23 - if false { - } else if yym24 := z.TimeRtidIfBinc(); yym24 != 0 { - r.EncodeBuiltin(yym24, yy22) - } else if z.HasExtensions() && z.EncExt(yy22) { - } else if yym23 { - z.EncBinaryMarshal(yy22) - } else if !yym23 && z.IsJSONHandle() { - z.EncJSONMarshal(yy22) - } else { - z.EncFallback(yy22) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Warnings)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Warnings")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym27 := z.EncBinary() - _ = yym27 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Warnings)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym29 := z.EncBinary() - _ = yym29 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym30 := z.EncBinary() - _ = yym30 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobPlanResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobPlanResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Annotations": - if r.TryDecodeAsNil() { - if x.Annotations != nil { - x.Annotations = nil - } - } else { - if x.Annotations == nil { - x.Annotations = new(PlanAnnotations) - } - x.Annotations.CodecDecodeSelf(d) - } - case "FailedTGAllocs": - if r.TryDecodeAsNil() { - x.FailedTGAllocs = nil - } else { - yyv5 := &x.FailedTGAllocs - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - h.decMapstringPtrtoAllocMetric((*map[string]*AllocMetric)(yyv5), d) - } - } - case "JobModifyIndex": - if r.TryDecodeAsNil() { - x.JobModifyIndex = 0 - } else { - yyv7 := &x.JobModifyIndex - yym8 := z.DecBinary() - _ = yym8 - if false { - } else { - *((*uint64)(yyv7)) = uint64(r.DecodeUint(64)) - } - } - case "CreatedEvals": - if r.TryDecodeAsNil() { - x.CreatedEvals = nil - } else { - yyv9 := &x.CreatedEvals - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - h.decSlicePtrtoEvaluation((*[]*Evaluation)(yyv9), d) - } - } - case "Diff": - if r.TryDecodeAsNil() { - if x.Diff != nil { - x.Diff = nil - } - } else { - if x.Diff == nil { - x.Diff = new(JobDiff) - } - yym12 := z.DecBinary() - _ = yym12 - if false { - } else if z.HasExtensions() && z.DecExt(x.Diff) { - } else { - z.DecFallback(x.Diff, false) - } - } - case "NextPeriodicLaunch": - if r.TryDecodeAsNil() { - x.NextPeriodicLaunch = time.Time{} - } else { - yyv13 := &x.NextPeriodicLaunch - yym14 := z.DecBinary() - _ = yym14 - if false { - } else if yym15 := z.TimeRtidIfBinc(); yym15 != 0 { - r.DecodeBuiltin(yym15, yyv13) - } else if z.HasExtensions() && z.DecExt(yyv13) { - } else if yym14 { - z.DecBinaryUnmarshal(yyv13) - } else if !yym14 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv13) - } else { - z.DecFallback(yyv13, false) - } - } - case "Warnings": - if r.TryDecodeAsNil() { - x.Warnings = "" - } else { - yyv16 := &x.Warnings - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv18 := &x.Index - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*uint64)(yyv18)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobPlanResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj20 int - var yyb20 bool - var yyhl20 bool = l >= 0 - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Annotations != nil { - x.Annotations = nil - } - } else { - if x.Annotations == nil { - x.Annotations = new(PlanAnnotations) - } - x.Annotations.CodecDecodeSelf(d) - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.FailedTGAllocs = nil - } else { - yyv22 := &x.FailedTGAllocs - yym23 := z.DecBinary() - _ = yym23 - if false { - } else { - h.decMapstringPtrtoAllocMetric((*map[string]*AllocMetric)(yyv22), d) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobModifyIndex = 0 - } else { - yyv24 := &x.JobModifyIndex - yym25 := z.DecBinary() - _ = yym25 - if false { - } else { - *((*uint64)(yyv24)) = uint64(r.DecodeUint(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CreatedEvals = nil - } else { - yyv26 := &x.CreatedEvals - yym27 := z.DecBinary() - _ = yym27 - if false { - } else { - h.decSlicePtrtoEvaluation((*[]*Evaluation)(yyv26), d) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Diff != nil { - x.Diff = nil - } - } else { - if x.Diff == nil { - x.Diff = new(JobDiff) - } - yym29 := z.DecBinary() - _ = yym29 - if false { - } else if z.HasExtensions() && z.DecExt(x.Diff) { - } else { - z.DecFallback(x.Diff, false) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NextPeriodicLaunch = time.Time{} - } else { - yyv30 := &x.NextPeriodicLaunch - yym31 := z.DecBinary() - _ = yym31 - if false { - } else if yym32 := z.TimeRtidIfBinc(); yym32 != 0 { - r.DecodeBuiltin(yym32, yyv30) - } else if z.HasExtensions() && z.DecExt(yyv30) { - } else if yym31 { - z.DecBinaryUnmarshal(yyv30) - } else if !yym31 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv30) - } else { - z.DecFallback(yyv30, false) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Warnings = "" - } else { - yyv33 := &x.Warnings - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - *((*string)(yyv33)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv35 := &x.Index - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*uint64)(yyv35)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj20-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *SingleAllocResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Alloc == nil { - r.EncodeNil() - } else { - x.Alloc.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Alloc")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Alloc == nil { - r.EncodeNil() - } else { - x.Alloc.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *SingleAllocResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *SingleAllocResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Alloc": - if r.TryDecodeAsNil() { - if x.Alloc != nil { - x.Alloc = nil - } - } else { - if x.Alloc == nil { - x.Alloc = new(Allocation) - } - x.Alloc.CodecDecodeSelf(d) - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv5 := &x.Index - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv7 := &x.LastContact - yym8 := z.DecBinary() - _ = yym8 - if false { - } else if z.HasExtensions() && z.DecExt(yyv7) { - } else { - *((*int64)(yyv7)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv9 := &x.KnownLeader - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*bool)(yyv9)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *SingleAllocResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj11 int - var yyb11 bool - var yyhl11 bool = l >= 0 - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Alloc != nil { - x.Alloc = nil - } - } else { - if x.Alloc == nil { - x.Alloc = new(Allocation) - } - x.Alloc.CodecDecodeSelf(d) - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv13 := &x.Index - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv15 := &x.LastContact - yym16 := z.DecBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.DecExt(yyv15) { - } else { - *((*int64)(yyv15)) = int64(r.DecodeInt(64)) - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv17 := &x.KnownLeader - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*bool)(yyv17)) = r.DecodeBool() - } - } - for { - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj11-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *AllocsGetResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Allocs == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encSlicePtrtoAllocation(([]*Allocation)(x.Allocs), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Allocs")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Allocs == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encSlicePtrtoAllocation(([]*Allocation)(x.Allocs), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *AllocsGetResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *AllocsGetResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Allocs": - if r.TryDecodeAsNil() { - x.Allocs = nil - } else { - yyv4 := &x.Allocs - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decSlicePtrtoAllocation((*[]*Allocation)(yyv4), d) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv6 := &x.Index - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv8 := &x.LastContact - yym9 := z.DecBinary() - _ = yym9 - if false { - } else if z.HasExtensions() && z.DecExt(yyv8) { - } else { - *((*int64)(yyv8)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv10 := &x.KnownLeader - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*bool)(yyv10)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *AllocsGetResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Allocs = nil - } else { - yyv13 := &x.Allocs - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - h.decSlicePtrtoAllocation((*[]*Allocation)(yyv13), d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv15 := &x.Index - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv17 := &x.LastContact - yym18 := z.DecBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.DecExt(yyv17) { - } else { - *((*int64)(yyv17)) = int64(r.DecodeInt(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv19 := &x.KnownLeader - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*bool)(yyv19)) = r.DecodeBool() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobAllocationsResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Allocations == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encSlicePtrtoAllocListStub(([]*AllocListStub)(x.Allocations), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Allocations")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Allocations == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encSlicePtrtoAllocListStub(([]*AllocListStub)(x.Allocations), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobAllocationsResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobAllocationsResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Allocations": - if r.TryDecodeAsNil() { - x.Allocations = nil - } else { - yyv4 := &x.Allocations - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decSlicePtrtoAllocListStub((*[]*AllocListStub)(yyv4), d) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv6 := &x.Index - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv8 := &x.LastContact - yym9 := z.DecBinary() - _ = yym9 - if false { - } else if z.HasExtensions() && z.DecExt(yyv8) { - } else { - *((*int64)(yyv8)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv10 := &x.KnownLeader - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*bool)(yyv10)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobAllocationsResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Allocations = nil - } else { - yyv13 := &x.Allocations - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - h.decSlicePtrtoAllocListStub((*[]*AllocListStub)(yyv13), d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv15 := &x.Index - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv17 := &x.LastContact - yym18 := z.DecBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.DecExt(yyv17) { - } else { - *((*int64)(yyv17)) = int64(r.DecodeInt(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv19 := &x.KnownLeader - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*bool)(yyv19)) = r.DecodeBool() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobEvaluationsResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Evaluations == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encSlicePtrtoEvaluation(([]*Evaluation)(x.Evaluations), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Evaluations")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Evaluations == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encSlicePtrtoEvaluation(([]*Evaluation)(x.Evaluations), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobEvaluationsResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobEvaluationsResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Evaluations": - if r.TryDecodeAsNil() { - x.Evaluations = nil - } else { - yyv4 := &x.Evaluations - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decSlicePtrtoEvaluation((*[]*Evaluation)(yyv4), d) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv6 := &x.Index - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv8 := &x.LastContact - yym9 := z.DecBinary() - _ = yym9 - if false { - } else if z.HasExtensions() && z.DecExt(yyv8) { - } else { - *((*int64)(yyv8)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv10 := &x.KnownLeader - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*bool)(yyv10)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobEvaluationsResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Evaluations = nil - } else { - yyv13 := &x.Evaluations - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - h.decSlicePtrtoEvaluation((*[]*Evaluation)(yyv13), d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv15 := &x.Index - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv17 := &x.LastContact - yym18 := z.DecBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.DecExt(yyv17) { - } else { - *((*int64)(yyv17)) = int64(r.DecodeInt(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv19 := &x.KnownLeader - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*bool)(yyv19)) = r.DecodeBool() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *SingleEvalResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Eval == nil { - r.EncodeNil() - } else { - x.Eval.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Eval")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Eval == nil { - r.EncodeNil() - } else { - x.Eval.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *SingleEvalResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *SingleEvalResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Eval": - if r.TryDecodeAsNil() { - if x.Eval != nil { - x.Eval = nil - } - } else { - if x.Eval == nil { - x.Eval = new(Evaluation) - } - x.Eval.CodecDecodeSelf(d) - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv5 := &x.Index - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv7 := &x.LastContact - yym8 := z.DecBinary() - _ = yym8 - if false { - } else if z.HasExtensions() && z.DecExt(yyv7) { - } else { - *((*int64)(yyv7)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv9 := &x.KnownLeader - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*bool)(yyv9)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *SingleEvalResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj11 int - var yyb11 bool - var yyhl11 bool = l >= 0 - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Eval != nil { - x.Eval = nil - } - } else { - if x.Eval == nil { - x.Eval = new(Evaluation) - } - x.Eval.CodecDecodeSelf(d) - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv13 := &x.Index - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv15 := &x.LastContact - yym16 := z.DecBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.DecExt(yyv15) { - } else { - *((*int64)(yyv15)) = int64(r.DecodeInt(64)) - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv17 := &x.KnownLeader - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*bool)(yyv17)) = r.DecodeBool() - } - } - for { - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj11-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *EvalDequeueResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [6]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(6) - } else { - yynn2 = 6 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Eval == nil { - r.EncodeNil() - } else { - x.Eval.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Eval")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Eval == nil { - r.EncodeNil() - } else { - x.Eval.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Token)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Token")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Token)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.WaitIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("WaitIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.WaitIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *EvalDequeueResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *EvalDequeueResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Eval": - if r.TryDecodeAsNil() { - if x.Eval != nil { - x.Eval = nil - } - } else { - if x.Eval == nil { - x.Eval = new(Evaluation) - } - x.Eval.CodecDecodeSelf(d) - } - case "Token": - if r.TryDecodeAsNil() { - x.Token = "" - } else { - yyv5 := &x.Token - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*string)(yyv5)) = r.DecodeString() - } - } - case "WaitIndex": - if r.TryDecodeAsNil() { - x.WaitIndex = 0 - } else { - yyv7 := &x.WaitIndex - yym8 := z.DecBinary() - _ = yym8 - if false { - } else { - *((*uint64)(yyv7)) = uint64(r.DecodeUint(64)) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv9 := &x.Index - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*uint64)(yyv9)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv11 := &x.LastContact - yym12 := z.DecBinary() - _ = yym12 - if false { - } else if z.HasExtensions() && z.DecExt(yyv11) { - } else { - *((*int64)(yyv11)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv13 := &x.KnownLeader - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*bool)(yyv13)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *EvalDequeueResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj15 int - var yyb15 bool - var yyhl15 bool = l >= 0 - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Eval != nil { - x.Eval = nil - } - } else { - if x.Eval == nil { - x.Eval = new(Evaluation) - } - x.Eval.CodecDecodeSelf(d) - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Token = "" - } else { - yyv17 := &x.Token - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.WaitIndex = 0 - } else { - yyv19 := &x.WaitIndex - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) - } - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv21 := &x.Index - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*uint64)(yyv21)) = uint64(r.DecodeUint(64)) - } - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv23 := &x.LastContact - yym24 := z.DecBinary() - _ = yym24 - if false { - } else if z.HasExtensions() && z.DecExt(yyv23) { - } else { - *((*int64)(yyv23)) = int64(r.DecodeInt(64)) - } - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv25 := &x.KnownLeader - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*bool)(yyv25)) = r.DecodeBool() - } - } - for { - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj15-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *PlanResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [2]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(2) - } else { - yynn2 = 2 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Result == nil { - r.EncodeNil() - } else { - x.Result.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Result")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Result == nil { - r.EncodeNil() - } else { - x.Result.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *PlanResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *PlanResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Result": - if r.TryDecodeAsNil() { - if x.Result != nil { - x.Result = nil - } - } else { - if x.Result == nil { - x.Result = new(PlanResult) - } - x.Result.CodecDecodeSelf(d) - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv5 := &x.Index - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *PlanResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj7 int - var yyb7 bool - var yyhl7 bool = l >= 0 - yyj7++ - if yyhl7 { - yyb7 = yyj7 > l - } else { - yyb7 = r.CheckBreak() - } - if yyb7 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Result != nil { - x.Result = nil - } - } else { - if x.Result == nil { - x.Result = new(PlanResult) - } - x.Result.CodecDecodeSelf(d) - } - yyj7++ - if yyhl7 { - yyb7 = yyj7 > l - } else { - yyb7 = r.CheckBreak() - } - if yyb7 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv9 := &x.Index - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*uint64)(yyv9)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj7++ - if yyhl7 { - yyb7 = yyj7 > l - } else { - yyb7 = r.CheckBreak() - } - if yyb7 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj7-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *AllocListResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Allocations == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encSlicePtrtoAllocListStub(([]*AllocListStub)(x.Allocations), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Allocations")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Allocations == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encSlicePtrtoAllocListStub(([]*AllocListStub)(x.Allocations), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *AllocListResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *AllocListResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Allocations": - if r.TryDecodeAsNil() { - x.Allocations = nil - } else { - yyv4 := &x.Allocations - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decSlicePtrtoAllocListStub((*[]*AllocListStub)(yyv4), d) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv6 := &x.Index - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv8 := &x.LastContact - yym9 := z.DecBinary() - _ = yym9 - if false { - } else if z.HasExtensions() && z.DecExt(yyv8) { - } else { - *((*int64)(yyv8)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv10 := &x.KnownLeader - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*bool)(yyv10)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *AllocListResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Allocations = nil - } else { - yyv13 := &x.Allocations - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - h.decSlicePtrtoAllocListStub((*[]*AllocListStub)(yyv13), d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv15 := &x.Index - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv17 := &x.LastContact - yym18 := z.DecBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.DecExt(yyv17) { - } else { - *((*int64)(yyv17)) = int64(r.DecodeInt(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv19 := &x.KnownLeader - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*bool)(yyv19)) = r.DecodeBool() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *DeploymentListResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Deployments == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encSlicePtrtoDeployment(([]*Deployment)(x.Deployments), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Deployments")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Deployments == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encSlicePtrtoDeployment(([]*Deployment)(x.Deployments), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *DeploymentListResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *DeploymentListResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Deployments": - if r.TryDecodeAsNil() { - x.Deployments = nil - } else { - yyv4 := &x.Deployments - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decSlicePtrtoDeployment((*[]*Deployment)(yyv4), d) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv6 := &x.Index - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv8 := &x.LastContact - yym9 := z.DecBinary() - _ = yym9 - if false { - } else if z.HasExtensions() && z.DecExt(yyv8) { - } else { - *((*int64)(yyv8)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv10 := &x.KnownLeader - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*bool)(yyv10)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *DeploymentListResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Deployments = nil - } else { - yyv13 := &x.Deployments - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - h.decSlicePtrtoDeployment((*[]*Deployment)(yyv13), d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv15 := &x.Index - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv17 := &x.LastContact - yym18 := z.DecBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.DecExt(yyv17) { - } else { - *((*int64)(yyv17)) = int64(r.DecodeInt(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv19 := &x.KnownLeader - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*bool)(yyv19)) = r.DecodeBool() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *EvalListResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Evaluations == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encSlicePtrtoEvaluation(([]*Evaluation)(x.Evaluations), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Evaluations")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Evaluations == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encSlicePtrtoEvaluation(([]*Evaluation)(x.Evaluations), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *EvalListResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *EvalListResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Evaluations": - if r.TryDecodeAsNil() { - x.Evaluations = nil - } else { - yyv4 := &x.Evaluations - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decSlicePtrtoEvaluation((*[]*Evaluation)(yyv4), d) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv6 := &x.Index - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv8 := &x.LastContact - yym9 := z.DecBinary() - _ = yym9 - if false { - } else if z.HasExtensions() && z.DecExt(yyv8) { - } else { - *((*int64)(yyv8)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv10 := &x.KnownLeader - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*bool)(yyv10)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *EvalListResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Evaluations = nil - } else { - yyv13 := &x.Evaluations - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - h.decSlicePtrtoEvaluation((*[]*Evaluation)(yyv13), d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv15 := &x.Index - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv17 := &x.LastContact - yym18 := z.DecBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.DecExt(yyv17) { - } else { - *((*int64)(yyv17)) = int64(r.DecodeInt(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv19 := &x.KnownLeader - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*bool)(yyv19)) = r.DecodeBool() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *EvalAllocationsResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Allocations == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encSlicePtrtoAllocListStub(([]*AllocListStub)(x.Allocations), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Allocations")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Allocations == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encSlicePtrtoAllocListStub(([]*AllocListStub)(x.Allocations), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *EvalAllocationsResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *EvalAllocationsResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Allocations": - if r.TryDecodeAsNil() { - x.Allocations = nil - } else { - yyv4 := &x.Allocations - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decSlicePtrtoAllocListStub((*[]*AllocListStub)(yyv4), d) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv6 := &x.Index - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv8 := &x.LastContact - yym9 := z.DecBinary() - _ = yym9 - if false { - } else if z.HasExtensions() && z.DecExt(yyv8) { - } else { - *((*int64)(yyv8)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv10 := &x.KnownLeader - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*bool)(yyv10)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *EvalAllocationsResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Allocations = nil - } else { - yyv13 := &x.Allocations - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - h.decSlicePtrtoAllocListStub((*[]*AllocListStub)(yyv13), d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv15 := &x.Index - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv17 := &x.LastContact - yym18 := z.DecBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.DecExt(yyv17) { - } else { - *((*int64)(yyv17)) = int64(r.DecodeInt(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv19 := &x.KnownLeader - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*bool)(yyv19)) = r.DecodeBool() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *PeriodicForceResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [3]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(3) - } else { - yynn2 = 3 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.EvalCreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalCreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.EvalCreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *PeriodicForceResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *PeriodicForceResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "EvalID": - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv4 := &x.EvalID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "EvalCreateIndex": - if r.TryDecodeAsNil() { - x.EvalCreateIndex = 0 - } else { - yyv6 := &x.EvalCreateIndex - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv8 := &x.Index - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *PeriodicForceResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj10 int - var yyb10 bool - var yyhl10 bool = l >= 0 - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv11 := &x.EvalID - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*string)(yyv11)) = r.DecodeString() - } - } - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalCreateIndex = 0 - } else { - yyv13 := &x.EvalCreateIndex - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) - } - } - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv15 := &x.Index - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj10-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *DeploymentUpdateResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 5 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.EvalCreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalCreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.EvalCreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.DeploymentModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DeploymentModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.DeploymentModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.RevertedJobVersion == nil { - r.EncodeNil() - } else { - yy13 := *x.RevertedJobVersion - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeUint(uint64(yy13)) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("RevertedJobVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.RevertedJobVersion == nil { - r.EncodeNil() - } else { - yy15 := *x.RevertedJobVersion - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeUint(uint64(yy15)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym18 := z.EncBinary() - _ = yym18 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *DeploymentUpdateResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *DeploymentUpdateResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "EvalID": - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv4 := &x.EvalID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "EvalCreateIndex": - if r.TryDecodeAsNil() { - x.EvalCreateIndex = 0 - } else { - yyv6 := &x.EvalCreateIndex - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "DeploymentModifyIndex": - if r.TryDecodeAsNil() { - x.DeploymentModifyIndex = 0 - } else { - yyv8 := &x.DeploymentModifyIndex - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) - } - } - case "RevertedJobVersion": - if r.TryDecodeAsNil() { - if x.RevertedJobVersion != nil { - x.RevertedJobVersion = nil - } - } else { - if x.RevertedJobVersion == nil { - x.RevertedJobVersion = new(uint64) - } - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*uint64)(x.RevertedJobVersion)) = uint64(r.DecodeUint(64)) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv12 := &x.Index - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*uint64)(yyv12)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *DeploymentUpdateResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj14 int - var yyb14 bool - var yyhl14 bool = l >= 0 - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv15 := &x.EvalID - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalCreateIndex = 0 - } else { - yyv17 := &x.EvalCreateIndex - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*uint64)(yyv17)) = uint64(r.DecodeUint(64)) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DeploymentModifyIndex = 0 - } else { - yyv19 := &x.DeploymentModifyIndex - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.RevertedJobVersion != nil { - x.RevertedJobVersion = nil - } - } else { - if x.RevertedJobVersion == nil { - x.RevertedJobVersion = new(uint64) - } - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*uint64)(x.RevertedJobVersion)) = uint64(r.DecodeUint(64)) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv23 := &x.Index - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj14-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *Node) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [19]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(19) - } else { - yynn2 = 19 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.SecretID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("SecretID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.SecretID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Datacenter)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Datacenter")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Datacenter)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Name")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.HTTPAddr)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("HTTPAddr")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.HTTPAddr)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeBool(bool(x.TLSEnabled)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("TLSEnabled")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeBool(bool(x.TLSEnabled)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Attributes == nil { - r.EncodeNil() - } else { - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - z.F.EncMapStringStringV(x.Attributes, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Attributes")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Attributes == nil { - r.EncodeNil() - } else { - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - z.F.EncMapStringStringV(x.Attributes, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Resources == nil { - r.EncodeNil() - } else { - x.Resources.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Resources")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Resources == nil { - r.EncodeNil() - } else { - x.Resources.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Reserved == nil { - r.EncodeNil() - } else { - x.Reserved.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Reserved")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Reserved == nil { - r.EncodeNil() - } else { - x.Reserved.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Links == nil { - r.EncodeNil() - } else { - yym31 := z.EncBinary() - _ = yym31 - if false { - } else { - z.F.EncMapStringStringV(x.Links, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Links")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Links == nil { - r.EncodeNil() - } else { - yym32 := z.EncBinary() - _ = yym32 - if false { - } else { - z.F.EncMapStringStringV(x.Links, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Meta == nil { - r.EncodeNil() - } else { - yym34 := z.EncBinary() - _ = yym34 - if false { - } else { - z.F.EncMapStringStringV(x.Meta, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Meta")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Meta == nil { - r.EncodeNil() - } else { - yym35 := z.EncBinary() - _ = yym35 - if false { - } else { - z.F.EncMapStringStringV(x.Meta, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym37 := z.EncBinary() - _ = yym37 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeClass)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodeClass")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym38 := z.EncBinary() - _ = yym38 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeClass)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym40 := z.EncBinary() - _ = yym40 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ComputedClass)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ComputedClass")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym41 := z.EncBinary() - _ = yym41 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ComputedClass)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym43 := z.EncBinary() - _ = yym43 - if false { - } else { - r.EncodeBool(bool(x.Drain)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Drain")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym44 := z.EncBinary() - _ = yym44 - if false { - } else { - r.EncodeBool(bool(x.Drain)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym46 := z.EncBinary() - _ = yym46 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Status)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Status")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym47 := z.EncBinary() - _ = yym47 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Status)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym49 := z.EncBinary() - _ = yym49 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("StatusDescription")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym50 := z.EncBinary() - _ = yym50 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym52 := z.EncBinary() - _ = yym52 - if false { - } else { - r.EncodeInt(int64(x.StatusUpdatedAt)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("StatusUpdatedAt")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym53 := z.EncBinary() - _ = yym53 - if false { - } else { - r.EncodeInt(int64(x.StatusUpdatedAt)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym55 := z.EncBinary() - _ = yym55 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym56 := z.EncBinary() - _ = yym56 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym58 := z.EncBinary() - _ = yym58 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym59 := z.EncBinary() - _ = yym59 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *Node) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *Node) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "ID": - if r.TryDecodeAsNil() { - x.ID = "" - } else { - yyv4 := &x.ID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "SecretID": - if r.TryDecodeAsNil() { - x.SecretID = "" - } else { - yyv6 := &x.SecretID - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Datacenter": - if r.TryDecodeAsNil() { - x.Datacenter = "" - } else { - yyv8 := &x.Datacenter - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv10 := &x.Name - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "HTTPAddr": - if r.TryDecodeAsNil() { - x.HTTPAddr = "" - } else { - yyv12 := &x.HTTPAddr - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - case "TLSEnabled": - if r.TryDecodeAsNil() { - x.TLSEnabled = false - } else { - yyv14 := &x.TLSEnabled - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*bool)(yyv14)) = r.DecodeBool() - } - } - case "Attributes": - if r.TryDecodeAsNil() { - x.Attributes = nil - } else { - yyv16 := &x.Attributes - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - z.F.DecMapStringStringX(yyv16, false, d) - } - } - case "Resources": - if r.TryDecodeAsNil() { - if x.Resources != nil { - x.Resources = nil - } - } else { - if x.Resources == nil { - x.Resources = new(Resources) - } - x.Resources.CodecDecodeSelf(d) - } - case "Reserved": - if r.TryDecodeAsNil() { - if x.Reserved != nil { - x.Reserved = nil - } - } else { - if x.Reserved == nil { - x.Reserved = new(Resources) - } - x.Reserved.CodecDecodeSelf(d) - } - case "Links": - if r.TryDecodeAsNil() { - x.Links = nil - } else { - yyv20 := &x.Links - yym21 := z.DecBinary() - _ = yym21 - if false { - } else { - z.F.DecMapStringStringX(yyv20, false, d) - } - } - case "Meta": - if r.TryDecodeAsNil() { - x.Meta = nil - } else { - yyv22 := &x.Meta - yym23 := z.DecBinary() - _ = yym23 - if false { - } else { - z.F.DecMapStringStringX(yyv22, false, d) - } - } - case "NodeClass": - if r.TryDecodeAsNil() { - x.NodeClass = "" - } else { - yyv24 := &x.NodeClass - yym25 := z.DecBinary() - _ = yym25 - if false { - } else { - *((*string)(yyv24)) = r.DecodeString() - } - } - case "ComputedClass": - if r.TryDecodeAsNil() { - x.ComputedClass = "" - } else { - yyv26 := &x.ComputedClass - yym27 := z.DecBinary() - _ = yym27 - if false { - } else { - *((*string)(yyv26)) = r.DecodeString() - } - } - case "Drain": - if r.TryDecodeAsNil() { - x.Drain = false - } else { - yyv28 := &x.Drain - yym29 := z.DecBinary() - _ = yym29 - if false { - } else { - *((*bool)(yyv28)) = r.DecodeBool() - } - } - case "Status": - if r.TryDecodeAsNil() { - x.Status = "" - } else { - yyv30 := &x.Status - yym31 := z.DecBinary() - _ = yym31 - if false { - } else { - *((*string)(yyv30)) = r.DecodeString() - } - } - case "StatusDescription": - if r.TryDecodeAsNil() { - x.StatusDescription = "" - } else { - yyv32 := &x.StatusDescription - yym33 := z.DecBinary() - _ = yym33 - if false { - } else { - *((*string)(yyv32)) = r.DecodeString() - } - } - case "StatusUpdatedAt": - if r.TryDecodeAsNil() { - x.StatusUpdatedAt = 0 - } else { - yyv34 := &x.StatusUpdatedAt - yym35 := z.DecBinary() - _ = yym35 - if false { - } else { - *((*int64)(yyv34)) = int64(r.DecodeInt(64)) - } - } - case "CreateIndex": - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv36 := &x.CreateIndex - yym37 := z.DecBinary() - _ = yym37 - if false { - } else { - *((*uint64)(yyv36)) = uint64(r.DecodeUint(64)) - } - } - case "ModifyIndex": - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv38 := &x.ModifyIndex - yym39 := z.DecBinary() - _ = yym39 - if false { - } else { - *((*uint64)(yyv38)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *Node) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj40 int - var yyb40 bool - var yyhl40 bool = l >= 0 - yyj40++ - if yyhl40 { - yyb40 = yyj40 > l - } else { - yyb40 = r.CheckBreak() - } - if yyb40 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ID = "" - } else { - yyv41 := &x.ID - yym42 := z.DecBinary() - _ = yym42 - if false { - } else { - *((*string)(yyv41)) = r.DecodeString() - } - } - yyj40++ - if yyhl40 { - yyb40 = yyj40 > l - } else { - yyb40 = r.CheckBreak() - } - if yyb40 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.SecretID = "" - } else { - yyv43 := &x.SecretID - yym44 := z.DecBinary() - _ = yym44 - if false { - } else { - *((*string)(yyv43)) = r.DecodeString() - } - } - yyj40++ - if yyhl40 { - yyb40 = yyj40 > l - } else { - yyb40 = r.CheckBreak() - } - if yyb40 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Datacenter = "" - } else { - yyv45 := &x.Datacenter - yym46 := z.DecBinary() - _ = yym46 - if false { - } else { - *((*string)(yyv45)) = r.DecodeString() - } - } - yyj40++ - if yyhl40 { - yyb40 = yyj40 > l - } else { - yyb40 = r.CheckBreak() - } - if yyb40 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv47 := &x.Name - yym48 := z.DecBinary() - _ = yym48 - if false { - } else { - *((*string)(yyv47)) = r.DecodeString() - } - } - yyj40++ - if yyhl40 { - yyb40 = yyj40 > l - } else { - yyb40 = r.CheckBreak() - } - if yyb40 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.HTTPAddr = "" - } else { - yyv49 := &x.HTTPAddr - yym50 := z.DecBinary() - _ = yym50 - if false { - } else { - *((*string)(yyv49)) = r.DecodeString() - } - } - yyj40++ - if yyhl40 { - yyb40 = yyj40 > l - } else { - yyb40 = r.CheckBreak() - } - if yyb40 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.TLSEnabled = false - } else { - yyv51 := &x.TLSEnabled - yym52 := z.DecBinary() - _ = yym52 - if false { - } else { - *((*bool)(yyv51)) = r.DecodeBool() - } - } - yyj40++ - if yyhl40 { - yyb40 = yyj40 > l - } else { - yyb40 = r.CheckBreak() - } - if yyb40 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Attributes = nil - } else { - yyv53 := &x.Attributes - yym54 := z.DecBinary() - _ = yym54 - if false { - } else { - z.F.DecMapStringStringX(yyv53, false, d) - } - } - yyj40++ - if yyhl40 { - yyb40 = yyj40 > l - } else { - yyb40 = r.CheckBreak() - } - if yyb40 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Resources != nil { - x.Resources = nil - } - } else { - if x.Resources == nil { - x.Resources = new(Resources) - } - x.Resources.CodecDecodeSelf(d) - } - yyj40++ - if yyhl40 { - yyb40 = yyj40 > l - } else { - yyb40 = r.CheckBreak() - } - if yyb40 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Reserved != nil { - x.Reserved = nil - } - } else { - if x.Reserved == nil { - x.Reserved = new(Resources) - } - x.Reserved.CodecDecodeSelf(d) - } - yyj40++ - if yyhl40 { - yyb40 = yyj40 > l - } else { - yyb40 = r.CheckBreak() - } - if yyb40 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Links = nil - } else { - yyv57 := &x.Links - yym58 := z.DecBinary() - _ = yym58 - if false { - } else { - z.F.DecMapStringStringX(yyv57, false, d) - } - } - yyj40++ - if yyhl40 { - yyb40 = yyj40 > l - } else { - yyb40 = r.CheckBreak() - } - if yyb40 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Meta = nil - } else { - yyv59 := &x.Meta - yym60 := z.DecBinary() - _ = yym60 - if false { - } else { - z.F.DecMapStringStringX(yyv59, false, d) - } - } - yyj40++ - if yyhl40 { - yyb40 = yyj40 > l - } else { - yyb40 = r.CheckBreak() - } - if yyb40 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodeClass = "" - } else { - yyv61 := &x.NodeClass - yym62 := z.DecBinary() - _ = yym62 - if false { - } else { - *((*string)(yyv61)) = r.DecodeString() - } - } - yyj40++ - if yyhl40 { - yyb40 = yyj40 > l - } else { - yyb40 = r.CheckBreak() - } - if yyb40 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ComputedClass = "" - } else { - yyv63 := &x.ComputedClass - yym64 := z.DecBinary() - _ = yym64 - if false { - } else { - *((*string)(yyv63)) = r.DecodeString() - } - } - yyj40++ - if yyhl40 { - yyb40 = yyj40 > l - } else { - yyb40 = r.CheckBreak() - } - if yyb40 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Drain = false - } else { - yyv65 := &x.Drain - yym66 := z.DecBinary() - _ = yym66 - if false { - } else { - *((*bool)(yyv65)) = r.DecodeBool() - } - } - yyj40++ - if yyhl40 { - yyb40 = yyj40 > l - } else { - yyb40 = r.CheckBreak() - } - if yyb40 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - yyv67 := &x.Status - yym68 := z.DecBinary() - _ = yym68 - if false { - } else { - *((*string)(yyv67)) = r.DecodeString() - } - } - yyj40++ - if yyhl40 { - yyb40 = yyj40 > l - } else { - yyb40 = r.CheckBreak() - } - if yyb40 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.StatusDescription = "" - } else { - yyv69 := &x.StatusDescription - yym70 := z.DecBinary() - _ = yym70 - if false { - } else { - *((*string)(yyv69)) = r.DecodeString() - } - } - yyj40++ - if yyhl40 { - yyb40 = yyj40 > l - } else { - yyb40 = r.CheckBreak() - } - if yyb40 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.StatusUpdatedAt = 0 - } else { - yyv71 := &x.StatusUpdatedAt - yym72 := z.DecBinary() - _ = yym72 - if false { - } else { - *((*int64)(yyv71)) = int64(r.DecodeInt(64)) - } - } - yyj40++ - if yyhl40 { - yyb40 = yyj40 > l - } else { - yyb40 = r.CheckBreak() - } - if yyb40 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv73 := &x.CreateIndex - yym74 := z.DecBinary() - _ = yym74 - if false { - } else { - *((*uint64)(yyv73)) = uint64(r.DecodeUint(64)) - } - } - yyj40++ - if yyhl40 { - yyb40 = yyj40 > l - } else { - yyb40 = r.CheckBreak() - } - if yyb40 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv75 := &x.ModifyIndex - yym76 := z.DecBinary() - _ = yym76 - if false { - } else { - *((*uint64)(yyv75)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj40++ - if yyhl40 { - yyb40 = yyj40 > l - } else { - yyb40 = r.CheckBreak() - } - if yyb40 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj40-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *NodeListStub) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [10]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(10) - } else { - yynn2 = 10 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Datacenter)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Datacenter")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Datacenter)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Name")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeClass)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodeClass")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeClass)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Version)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Version")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Version)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeBool(bool(x.Drain)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Drain")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeBool(bool(x.Drain)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Status)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Status")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Status)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("StatusDescription")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym28 := z.EncBinary() - _ = yym28 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym29 := z.EncBinary() - _ = yym29 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym31 := z.EncBinary() - _ = yym31 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym32 := z.EncBinary() - _ = yym32 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *NodeListStub) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *NodeListStub) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "ID": - if r.TryDecodeAsNil() { - x.ID = "" - } else { - yyv4 := &x.ID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Datacenter": - if r.TryDecodeAsNil() { - x.Datacenter = "" - } else { - yyv6 := &x.Datacenter - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv8 := &x.Name - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "NodeClass": - if r.TryDecodeAsNil() { - x.NodeClass = "" - } else { - yyv10 := &x.NodeClass - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "Version": - if r.TryDecodeAsNil() { - x.Version = "" - } else { - yyv12 := &x.Version - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - case "Drain": - if r.TryDecodeAsNil() { - x.Drain = false - } else { - yyv14 := &x.Drain - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*bool)(yyv14)) = r.DecodeBool() - } - } - case "Status": - if r.TryDecodeAsNil() { - x.Status = "" - } else { - yyv16 := &x.Status - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - case "StatusDescription": - if r.TryDecodeAsNil() { - x.StatusDescription = "" - } else { - yyv18 := &x.StatusDescription - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - case "CreateIndex": - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv20 := &x.CreateIndex - yym21 := z.DecBinary() - _ = yym21 - if false { - } else { - *((*uint64)(yyv20)) = uint64(r.DecodeUint(64)) - } - } - case "ModifyIndex": - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv22 := &x.ModifyIndex - yym23 := z.DecBinary() - _ = yym23 - if false { - } else { - *((*uint64)(yyv22)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *NodeListStub) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj24 int - var yyb24 bool - var yyhl24 bool = l >= 0 - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ID = "" - } else { - yyv25 := &x.ID - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Datacenter = "" - } else { - yyv27 := &x.Datacenter - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*string)(yyv27)) = r.DecodeString() - } - } - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv29 := &x.Name - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*string)(yyv29)) = r.DecodeString() - } - } - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodeClass = "" - } else { - yyv31 := &x.NodeClass - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*string)(yyv31)) = r.DecodeString() - } - } - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Version = "" - } else { - yyv33 := &x.Version - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - *((*string)(yyv33)) = r.DecodeString() - } - } - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Drain = false - } else { - yyv35 := &x.Drain - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*bool)(yyv35)) = r.DecodeBool() - } - } - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - yyv37 := &x.Status - yym38 := z.DecBinary() - _ = yym38 - if false { - } else { - *((*string)(yyv37)) = r.DecodeString() - } - } - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.StatusDescription = "" - } else { - yyv39 := &x.StatusDescription - yym40 := z.DecBinary() - _ = yym40 - if false { - } else { - *((*string)(yyv39)) = r.DecodeString() - } - } - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv41 := &x.CreateIndex - yym42 := z.DecBinary() - _ = yym42 - if false { - } else { - *((*uint64)(yyv41)) = uint64(r.DecodeUint(64)) - } - } - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv43 := &x.ModifyIndex - yym44 := z.DecBinary() - _ = yym44 - if false { - } else { - *((*uint64)(yyv43)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj24++ - if yyhl24 { - yyb24 = yyj24 > l - } else { - yyb24 = r.CheckBreak() - } - if yyb24 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj24-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x Networks) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - h.encNetworks((Networks)(x), e) - } - } -} - -func (x *Networks) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - h.decNetworks((*Networks)(x), d) - } -} - -func (x *Resources) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 5 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeInt(int64(x.CPU)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CPU")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeInt(int64(x.CPU)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeInt(int64(x.MemoryMB)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MemoryMB")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeInt(int64(x.MemoryMB)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeInt(int64(x.DiskMB)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DiskMB")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeInt(int64(x.DiskMB)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeInt(int64(x.IOPS)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("IOPS")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeInt(int64(x.IOPS)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Networks == nil { - r.EncodeNil() - } else { - x.Networks.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Networks")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Networks == nil { - r.EncodeNil() - } else { - x.Networks.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *Resources) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *Resources) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "CPU": - if r.TryDecodeAsNil() { - x.CPU = 0 - } else { - yyv4 := &x.CPU - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*int)(yyv4)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "MemoryMB": - if r.TryDecodeAsNil() { - x.MemoryMB = 0 - } else { - yyv6 := &x.MemoryMB - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*int)(yyv6)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "DiskMB": - if r.TryDecodeAsNil() { - x.DiskMB = 0 - } else { - yyv8 := &x.DiskMB - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*int)(yyv8)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "IOPS": - if r.TryDecodeAsNil() { - x.IOPS = 0 - } else { - yyv10 := &x.IOPS - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*int)(yyv10)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "Networks": - if r.TryDecodeAsNil() { - x.Networks = nil - } else { - yyv12 := &x.Networks - yyv12.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *Resources) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj13 int - var yyb13 bool - var yyhl13 bool = l >= 0 - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CPU = 0 - } else { - yyv14 := &x.CPU - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*int)(yyv14)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MemoryMB = 0 - } else { - yyv16 := &x.MemoryMB - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*int)(yyv16)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DiskMB = 0 - } else { - yyv18 := &x.DiskMB - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*int)(yyv18)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.IOPS = 0 - } else { - yyv20 := &x.IOPS - yym21 := z.DecBinary() - _ = yym21 - if false { - } else { - *((*int)(yyv20)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Networks = nil - } else { - yyv22 := &x.Networks - yyv22.CodecDecodeSelf(d) - } - for { - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj13-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *Port) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [2]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(2) - } else { - yynn2 = 2 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Label)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Label")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Label)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeInt(int64(x.Value)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Value")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeInt(int64(x.Value)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *Port) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *Port) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Label": - if r.TryDecodeAsNil() { - x.Label = "" - } else { - yyv4 := &x.Label - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Value": - if r.TryDecodeAsNil() { - x.Value = 0 - } else { - yyv6 := &x.Value - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*int)(yyv6)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *Port) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj8 int - var yyb8 bool - var yyhl8 bool = l >= 0 - yyj8++ - if yyhl8 { - yyb8 = yyj8 > l - } else { - yyb8 = r.CheckBreak() - } - if yyb8 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Label = "" - } else { - yyv9 := &x.Label - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*string)(yyv9)) = r.DecodeString() - } - } - yyj8++ - if yyhl8 { - yyb8 = yyj8 > l - } else { - yyb8 = r.CheckBreak() - } - if yyb8 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Value = 0 - } else { - yyv11 := &x.Value - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*int)(yyv11)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - for { - yyj8++ - if yyhl8 { - yyb8 = yyj8 > l - } else { - yyb8 = r.CheckBreak() - } - if yyb8 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj8-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *NetworkResource) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [6]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(6) - } else { - yynn2 = 6 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Device)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Device")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Device)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.CIDR)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CIDR")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.CIDR)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.IP)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("IP")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.IP)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeInt(int64(x.MBits)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MBits")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeInt(int64(x.MBits)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.ReservedPorts == nil { - r.EncodeNil() - } else { - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - h.encSlicePort(([]Port)(x.ReservedPorts), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ReservedPorts")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.ReservedPorts == nil { - r.EncodeNil() - } else { - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - h.encSlicePort(([]Port)(x.ReservedPorts), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.DynamicPorts == nil { - r.EncodeNil() - } else { - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - h.encSlicePort(([]Port)(x.DynamicPorts), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DynamicPorts")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.DynamicPorts == nil { - r.EncodeNil() - } else { - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - h.encSlicePort(([]Port)(x.DynamicPorts), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *NetworkResource) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *NetworkResource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Device": - if r.TryDecodeAsNil() { - x.Device = "" - } else { - yyv4 := &x.Device - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "CIDR": - if r.TryDecodeAsNil() { - x.CIDR = "" - } else { - yyv6 := &x.CIDR - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "IP": - if r.TryDecodeAsNil() { - x.IP = "" - } else { - yyv8 := &x.IP - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "MBits": - if r.TryDecodeAsNil() { - x.MBits = 0 - } else { - yyv10 := &x.MBits - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*int)(yyv10)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "ReservedPorts": - if r.TryDecodeAsNil() { - x.ReservedPorts = nil - } else { - yyv12 := &x.ReservedPorts - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - h.decSlicePort((*[]Port)(yyv12), d) - } - } - case "DynamicPorts": - if r.TryDecodeAsNil() { - x.DynamicPorts = nil - } else { - yyv14 := &x.DynamicPorts - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - h.decSlicePort((*[]Port)(yyv14), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *NetworkResource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj16 int - var yyb16 bool - var yyhl16 bool = l >= 0 - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Device = "" - } else { - yyv17 := &x.Device - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CIDR = "" - } else { - yyv19 := &x.CIDR - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.IP = "" - } else { - yyv21 := &x.IP - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MBits = 0 - } else { - yyv23 := &x.MBits - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*int)(yyv23)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ReservedPorts = nil - } else { - yyv25 := &x.ReservedPorts - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - h.decSlicePort((*[]Port)(yyv25), d) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DynamicPorts = nil - } else { - yyv27 := &x.DynamicPorts - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - h.decSlicePort((*[]Port)(yyv27), d) - } - } - for { - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj16-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *Job) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [26]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(26) - } else { - yynn2 = 26 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeBool(bool(x.Stop)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Stop")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeBool(bool(x.Stop)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ParentID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ParentID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ParentID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Name")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Type)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Type")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Type)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeInt(int64(x.Priority)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Priority")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeInt(int64(x.Priority)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym28 := z.EncBinary() - _ = yym28 - if false { - } else { - r.EncodeBool(bool(x.AllAtOnce)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllAtOnce")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym29 := z.EncBinary() - _ = yym29 - if false { - } else { - r.EncodeBool(bool(x.AllAtOnce)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Datacenters == nil { - r.EncodeNil() - } else { - yym31 := z.EncBinary() - _ = yym31 - if false { - } else { - z.F.EncSliceStringV(x.Datacenters, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Datacenters")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Datacenters == nil { - r.EncodeNil() - } else { - yym32 := z.EncBinary() - _ = yym32 - if false { - } else { - z.F.EncSliceStringV(x.Datacenters, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Constraints == nil { - r.EncodeNil() - } else { - yym34 := z.EncBinary() - _ = yym34 - if false { - } else { - h.encSlicePtrtoConstraint(([]*Constraint)(x.Constraints), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Constraints")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Constraints == nil { - r.EncodeNil() - } else { - yym35 := z.EncBinary() - _ = yym35 - if false { - } else { - h.encSlicePtrtoConstraint(([]*Constraint)(x.Constraints), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.TaskGroups == nil { - r.EncodeNil() - } else { - yym37 := z.EncBinary() - _ = yym37 - if false { - } else { - h.encSlicePtrtoTaskGroup(([]*TaskGroup)(x.TaskGroups), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("TaskGroups")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.TaskGroups == nil { - r.EncodeNil() - } else { - yym38 := z.EncBinary() - _ = yym38 - if false { - } else { - h.encSlicePtrtoTaskGroup(([]*TaskGroup)(x.TaskGroups), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yy40 := &x.Update - yy40.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Update")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yy42 := &x.Update - yy42.CodecEncodeSelf(e) - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Periodic == nil { - r.EncodeNil() - } else { - x.Periodic.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Periodic")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Periodic == nil { - r.EncodeNil() - } else { - x.Periodic.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.ParameterizedJob == nil { - r.EncodeNil() - } else { - x.ParameterizedJob.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ParameterizedJob")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.ParameterizedJob == nil { - r.EncodeNil() - } else { - x.ParameterizedJob.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Payload == nil { - r.EncodeNil() - } else { - yym51 := z.EncBinary() - _ = yym51 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Payload)) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Payload")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Payload == nil { - r.EncodeNil() - } else { - yym52 := z.EncBinary() - _ = yym52 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Payload)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Meta == nil { - r.EncodeNil() - } else { - yym54 := z.EncBinary() - _ = yym54 - if false { - } else { - z.F.EncMapStringStringV(x.Meta, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Meta")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Meta == nil { - r.EncodeNil() - } else { - yym55 := z.EncBinary() - _ = yym55 - if false { - } else { - z.F.EncMapStringStringV(x.Meta, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym57 := z.EncBinary() - _ = yym57 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.VaultToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("VaultToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym58 := z.EncBinary() - _ = yym58 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.VaultToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym60 := z.EncBinary() - _ = yym60 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Status)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Status")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym61 := z.EncBinary() - _ = yym61 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Status)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym63 := z.EncBinary() - _ = yym63 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("StatusDescription")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym64 := z.EncBinary() - _ = yym64 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym66 := z.EncBinary() - _ = yym66 - if false { - } else { - r.EncodeBool(bool(x.Stable)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Stable")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym67 := z.EncBinary() - _ = yym67 - if false { - } else { - r.EncodeBool(bool(x.Stable)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym69 := z.EncBinary() - _ = yym69 - if false { - } else { - r.EncodeUint(uint64(x.Version)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Version")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym70 := z.EncBinary() - _ = yym70 - if false { - } else { - r.EncodeUint(uint64(x.Version)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym72 := z.EncBinary() - _ = yym72 - if false { - } else { - r.EncodeInt(int64(x.SubmitTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("SubmitTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym73 := z.EncBinary() - _ = yym73 - if false { - } else { - r.EncodeInt(int64(x.SubmitTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym75 := z.EncBinary() - _ = yym75 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym76 := z.EncBinary() - _ = yym76 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym78 := z.EncBinary() - _ = yym78 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym79 := z.EncBinary() - _ = yym79 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym81 := z.EncBinary() - _ = yym81 - if false { - } else { - r.EncodeUint(uint64(x.JobModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym82 := z.EncBinary() - _ = yym82 - if false { - } else { - r.EncodeUint(uint64(x.JobModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *Job) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *Job) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Stop": - if r.TryDecodeAsNil() { - x.Stop = false - } else { - yyv4 := &x.Stop - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*bool)(yyv4)) = r.DecodeBool() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "ID": - if r.TryDecodeAsNil() { - x.ID = "" - } else { - yyv10 := &x.ID - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "ParentID": - if r.TryDecodeAsNil() { - x.ParentID = "" - } else { - yyv12 := &x.ParentID - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - case "Name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv14 := &x.Name - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*string)(yyv14)) = r.DecodeString() - } - } - case "Type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - yyv16 := &x.Type - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - case "Priority": - if r.TryDecodeAsNil() { - x.Priority = 0 - } else { - yyv18 := &x.Priority - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*int)(yyv18)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "AllAtOnce": - if r.TryDecodeAsNil() { - x.AllAtOnce = false - } else { - yyv20 := &x.AllAtOnce - yym21 := z.DecBinary() - _ = yym21 - if false { - } else { - *((*bool)(yyv20)) = r.DecodeBool() - } - } - case "Datacenters": - if r.TryDecodeAsNil() { - x.Datacenters = nil - } else { - yyv22 := &x.Datacenters - yym23 := z.DecBinary() - _ = yym23 - if false { - } else { - z.F.DecSliceStringX(yyv22, false, d) - } - } - case "Constraints": - if r.TryDecodeAsNil() { - x.Constraints = nil - } else { - yyv24 := &x.Constraints - yym25 := z.DecBinary() - _ = yym25 - if false { - } else { - h.decSlicePtrtoConstraint((*[]*Constraint)(yyv24), d) - } - } - case "TaskGroups": - if r.TryDecodeAsNil() { - x.TaskGroups = nil - } else { - yyv26 := &x.TaskGroups - yym27 := z.DecBinary() - _ = yym27 - if false { - } else { - h.decSlicePtrtoTaskGroup((*[]*TaskGroup)(yyv26), d) - } - } - case "Update": - if r.TryDecodeAsNil() { - x.Update = UpdateStrategy{} - } else { - yyv28 := &x.Update - yyv28.CodecDecodeSelf(d) - } - case "Periodic": - if r.TryDecodeAsNil() { - if x.Periodic != nil { - x.Periodic = nil - } - } else { - if x.Periodic == nil { - x.Periodic = new(PeriodicConfig) - } - x.Periodic.CodecDecodeSelf(d) - } - case "ParameterizedJob": - if r.TryDecodeAsNil() { - if x.ParameterizedJob != nil { - x.ParameterizedJob = nil - } - } else { - if x.ParameterizedJob == nil { - x.ParameterizedJob = new(ParameterizedJobConfig) - } - x.ParameterizedJob.CodecDecodeSelf(d) - } - case "Payload": - if r.TryDecodeAsNil() { - x.Payload = nil - } else { - yyv31 := &x.Payload - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *yyv31 = r.DecodeBytes(*(*[]byte)(yyv31), false, false) - } - } - case "Meta": - if r.TryDecodeAsNil() { - x.Meta = nil - } else { - yyv33 := &x.Meta - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - z.F.DecMapStringStringX(yyv33, false, d) - } - } - case "VaultToken": - if r.TryDecodeAsNil() { - x.VaultToken = "" - } else { - yyv35 := &x.VaultToken - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*string)(yyv35)) = r.DecodeString() - } - } - case "Status": - if r.TryDecodeAsNil() { - x.Status = "" - } else { - yyv37 := &x.Status - yym38 := z.DecBinary() - _ = yym38 - if false { - } else { - *((*string)(yyv37)) = r.DecodeString() - } - } - case "StatusDescription": - if r.TryDecodeAsNil() { - x.StatusDescription = "" - } else { - yyv39 := &x.StatusDescription - yym40 := z.DecBinary() - _ = yym40 - if false { - } else { - *((*string)(yyv39)) = r.DecodeString() - } - } - case "Stable": - if r.TryDecodeAsNil() { - x.Stable = false - } else { - yyv41 := &x.Stable - yym42 := z.DecBinary() - _ = yym42 - if false { - } else { - *((*bool)(yyv41)) = r.DecodeBool() - } - } - case "Version": - if r.TryDecodeAsNil() { - x.Version = 0 - } else { - yyv43 := &x.Version - yym44 := z.DecBinary() - _ = yym44 - if false { - } else { - *((*uint64)(yyv43)) = uint64(r.DecodeUint(64)) - } - } - case "SubmitTime": - if r.TryDecodeAsNil() { - x.SubmitTime = 0 - } else { - yyv45 := &x.SubmitTime - yym46 := z.DecBinary() - _ = yym46 - if false { - } else { - *((*int64)(yyv45)) = int64(r.DecodeInt(64)) - } - } - case "CreateIndex": - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv47 := &x.CreateIndex - yym48 := z.DecBinary() - _ = yym48 - if false { - } else { - *((*uint64)(yyv47)) = uint64(r.DecodeUint(64)) - } - } - case "ModifyIndex": - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv49 := &x.ModifyIndex - yym50 := z.DecBinary() - _ = yym50 - if false { - } else { - *((*uint64)(yyv49)) = uint64(r.DecodeUint(64)) - } - } - case "JobModifyIndex": - if r.TryDecodeAsNil() { - x.JobModifyIndex = 0 - } else { - yyv51 := &x.JobModifyIndex - yym52 := z.DecBinary() - _ = yym52 - if false { - } else { - *((*uint64)(yyv51)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *Job) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj53 int - var yyb53 bool - var yyhl53 bool = l >= 0 - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Stop = false - } else { - yyv54 := &x.Stop - yym55 := z.DecBinary() - _ = yym55 - if false { - } else { - *((*bool)(yyv54)) = r.DecodeBool() - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv56 := &x.Region - yym57 := z.DecBinary() - _ = yym57 - if false { - } else { - *((*string)(yyv56)) = r.DecodeString() - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv58 := &x.Namespace - yym59 := z.DecBinary() - _ = yym59 - if false { - } else { - *((*string)(yyv58)) = r.DecodeString() - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ID = "" - } else { - yyv60 := &x.ID - yym61 := z.DecBinary() - _ = yym61 - if false { - } else { - *((*string)(yyv60)) = r.DecodeString() - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ParentID = "" - } else { - yyv62 := &x.ParentID - yym63 := z.DecBinary() - _ = yym63 - if false { - } else { - *((*string)(yyv62)) = r.DecodeString() - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv64 := &x.Name - yym65 := z.DecBinary() - _ = yym65 - if false { - } else { - *((*string)(yyv64)) = r.DecodeString() - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - yyv66 := &x.Type - yym67 := z.DecBinary() - _ = yym67 - if false { - } else { - *((*string)(yyv66)) = r.DecodeString() - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Priority = 0 - } else { - yyv68 := &x.Priority - yym69 := z.DecBinary() - _ = yym69 - if false { - } else { - *((*int)(yyv68)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllAtOnce = false - } else { - yyv70 := &x.AllAtOnce - yym71 := z.DecBinary() - _ = yym71 - if false { - } else { - *((*bool)(yyv70)) = r.DecodeBool() - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Datacenters = nil - } else { - yyv72 := &x.Datacenters - yym73 := z.DecBinary() - _ = yym73 - if false { - } else { - z.F.DecSliceStringX(yyv72, false, d) - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Constraints = nil - } else { - yyv74 := &x.Constraints - yym75 := z.DecBinary() - _ = yym75 - if false { - } else { - h.decSlicePtrtoConstraint((*[]*Constraint)(yyv74), d) - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.TaskGroups = nil - } else { - yyv76 := &x.TaskGroups - yym77 := z.DecBinary() - _ = yym77 - if false { - } else { - h.decSlicePtrtoTaskGroup((*[]*TaskGroup)(yyv76), d) - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Update = UpdateStrategy{} - } else { - yyv78 := &x.Update - yyv78.CodecDecodeSelf(d) - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Periodic != nil { - x.Periodic = nil - } - } else { - if x.Periodic == nil { - x.Periodic = new(PeriodicConfig) - } - x.Periodic.CodecDecodeSelf(d) - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.ParameterizedJob != nil { - x.ParameterizedJob = nil - } - } else { - if x.ParameterizedJob == nil { - x.ParameterizedJob = new(ParameterizedJobConfig) - } - x.ParameterizedJob.CodecDecodeSelf(d) - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Payload = nil - } else { - yyv81 := &x.Payload - yym82 := z.DecBinary() - _ = yym82 - if false { - } else { - *yyv81 = r.DecodeBytes(*(*[]byte)(yyv81), false, false) - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Meta = nil - } else { - yyv83 := &x.Meta - yym84 := z.DecBinary() - _ = yym84 - if false { - } else { - z.F.DecMapStringStringX(yyv83, false, d) - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.VaultToken = "" - } else { - yyv85 := &x.VaultToken - yym86 := z.DecBinary() - _ = yym86 - if false { - } else { - *((*string)(yyv85)) = r.DecodeString() - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - yyv87 := &x.Status - yym88 := z.DecBinary() - _ = yym88 - if false { - } else { - *((*string)(yyv87)) = r.DecodeString() - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.StatusDescription = "" - } else { - yyv89 := &x.StatusDescription - yym90 := z.DecBinary() - _ = yym90 - if false { - } else { - *((*string)(yyv89)) = r.DecodeString() - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Stable = false - } else { - yyv91 := &x.Stable - yym92 := z.DecBinary() - _ = yym92 - if false { - } else { - *((*bool)(yyv91)) = r.DecodeBool() - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Version = 0 - } else { - yyv93 := &x.Version - yym94 := z.DecBinary() - _ = yym94 - if false { - } else { - *((*uint64)(yyv93)) = uint64(r.DecodeUint(64)) - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.SubmitTime = 0 - } else { - yyv95 := &x.SubmitTime - yym96 := z.DecBinary() - _ = yym96 - if false { - } else { - *((*int64)(yyv95)) = int64(r.DecodeInt(64)) - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv97 := &x.CreateIndex - yym98 := z.DecBinary() - _ = yym98 - if false { - } else { - *((*uint64)(yyv97)) = uint64(r.DecodeUint(64)) - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv99 := &x.ModifyIndex - yym100 := z.DecBinary() - _ = yym100 - if false { - } else { - *((*uint64)(yyv99)) = uint64(r.DecodeUint(64)) - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobModifyIndex = 0 - } else { - yyv101 := &x.JobModifyIndex - yym102 := z.DecBinary() - _ = yym102 - if false { - } else { - *((*uint64)(yyv101)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj53-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobListStub) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [15]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(15) - } else { - yynn2 = 15 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ParentID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ParentID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ParentID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Name")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Type)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Type")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Type)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeInt(int64(x.Priority)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Priority")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeInt(int64(x.Priority)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeBool(bool(x.Periodic)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Periodic")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeBool(bool(x.Periodic)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeBool(bool(x.ParameterizedJob)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ParameterizedJob")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeBool(bool(x.ParameterizedJob)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeBool(bool(x.Stop)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Stop")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeBool(bool(x.Stop)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym28 := z.EncBinary() - _ = yym28 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Status)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Status")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym29 := z.EncBinary() - _ = yym29 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Status)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym31 := z.EncBinary() - _ = yym31 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("StatusDescription")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym32 := z.EncBinary() - _ = yym32 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.JobSummary == nil { - r.EncodeNil() - } else { - x.JobSummary.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobSummary")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.JobSummary == nil { - r.EncodeNil() - } else { - x.JobSummary.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym37 := z.EncBinary() - _ = yym37 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym38 := z.EncBinary() - _ = yym38 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym40 := z.EncBinary() - _ = yym40 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym41 := z.EncBinary() - _ = yym41 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym43 := z.EncBinary() - _ = yym43 - if false { - } else { - r.EncodeUint(uint64(x.JobModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym44 := z.EncBinary() - _ = yym44 - if false { - } else { - r.EncodeUint(uint64(x.JobModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym46 := z.EncBinary() - _ = yym46 - if false { - } else { - r.EncodeInt(int64(x.SubmitTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("SubmitTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym47 := z.EncBinary() - _ = yym47 - if false { - } else { - r.EncodeInt(int64(x.SubmitTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobListStub) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobListStub) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "ID": - if r.TryDecodeAsNil() { - x.ID = "" - } else { - yyv4 := &x.ID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "ParentID": - if r.TryDecodeAsNil() { - x.ParentID = "" - } else { - yyv6 := &x.ParentID - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv8 := &x.Name - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - yyv10 := &x.Type - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "Priority": - if r.TryDecodeAsNil() { - x.Priority = 0 - } else { - yyv12 := &x.Priority - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*int)(yyv12)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "Periodic": - if r.TryDecodeAsNil() { - x.Periodic = false - } else { - yyv14 := &x.Periodic - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*bool)(yyv14)) = r.DecodeBool() - } - } - case "ParameterizedJob": - if r.TryDecodeAsNil() { - x.ParameterizedJob = false - } else { - yyv16 := &x.ParameterizedJob - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*bool)(yyv16)) = r.DecodeBool() - } - } - case "Stop": - if r.TryDecodeAsNil() { - x.Stop = false - } else { - yyv18 := &x.Stop - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*bool)(yyv18)) = r.DecodeBool() - } - } - case "Status": - if r.TryDecodeAsNil() { - x.Status = "" - } else { - yyv20 := &x.Status - yym21 := z.DecBinary() - _ = yym21 - if false { - } else { - *((*string)(yyv20)) = r.DecodeString() - } - } - case "StatusDescription": - if r.TryDecodeAsNil() { - x.StatusDescription = "" - } else { - yyv22 := &x.StatusDescription - yym23 := z.DecBinary() - _ = yym23 - if false { - } else { - *((*string)(yyv22)) = r.DecodeString() - } - } - case "JobSummary": - if r.TryDecodeAsNil() { - if x.JobSummary != nil { - x.JobSummary = nil - } - } else { - if x.JobSummary == nil { - x.JobSummary = new(JobSummary) - } - x.JobSummary.CodecDecodeSelf(d) - } - case "CreateIndex": - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv25 := &x.CreateIndex - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*uint64)(yyv25)) = uint64(r.DecodeUint(64)) - } - } - case "ModifyIndex": - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv27 := &x.ModifyIndex - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) - } - } - case "JobModifyIndex": - if r.TryDecodeAsNil() { - x.JobModifyIndex = 0 - } else { - yyv29 := &x.JobModifyIndex - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*uint64)(yyv29)) = uint64(r.DecodeUint(64)) - } - } - case "SubmitTime": - if r.TryDecodeAsNil() { - x.SubmitTime = 0 - } else { - yyv31 := &x.SubmitTime - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*int64)(yyv31)) = int64(r.DecodeInt(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobListStub) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj33 int - var yyb33 bool - var yyhl33 bool = l >= 0 - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ID = "" - } else { - yyv34 := &x.ID - yym35 := z.DecBinary() - _ = yym35 - if false { - } else { - *((*string)(yyv34)) = r.DecodeString() - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ParentID = "" - } else { - yyv36 := &x.ParentID - yym37 := z.DecBinary() - _ = yym37 - if false { - } else { - *((*string)(yyv36)) = r.DecodeString() - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv38 := &x.Name - yym39 := z.DecBinary() - _ = yym39 - if false { - } else { - *((*string)(yyv38)) = r.DecodeString() - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - yyv40 := &x.Type - yym41 := z.DecBinary() - _ = yym41 - if false { - } else { - *((*string)(yyv40)) = r.DecodeString() - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Priority = 0 - } else { - yyv42 := &x.Priority - yym43 := z.DecBinary() - _ = yym43 - if false { - } else { - *((*int)(yyv42)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Periodic = false - } else { - yyv44 := &x.Periodic - yym45 := z.DecBinary() - _ = yym45 - if false { - } else { - *((*bool)(yyv44)) = r.DecodeBool() - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ParameterizedJob = false - } else { - yyv46 := &x.ParameterizedJob - yym47 := z.DecBinary() - _ = yym47 - if false { - } else { - *((*bool)(yyv46)) = r.DecodeBool() - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Stop = false - } else { - yyv48 := &x.Stop - yym49 := z.DecBinary() - _ = yym49 - if false { - } else { - *((*bool)(yyv48)) = r.DecodeBool() - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - yyv50 := &x.Status - yym51 := z.DecBinary() - _ = yym51 - if false { - } else { - *((*string)(yyv50)) = r.DecodeString() - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.StatusDescription = "" - } else { - yyv52 := &x.StatusDescription - yym53 := z.DecBinary() - _ = yym53 - if false { - } else { - *((*string)(yyv52)) = r.DecodeString() - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.JobSummary != nil { - x.JobSummary = nil - } - } else { - if x.JobSummary == nil { - x.JobSummary = new(JobSummary) - } - x.JobSummary.CodecDecodeSelf(d) - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv55 := &x.CreateIndex - yym56 := z.DecBinary() - _ = yym56 - if false { - } else { - *((*uint64)(yyv55)) = uint64(r.DecodeUint(64)) - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv57 := &x.ModifyIndex - yym58 := z.DecBinary() - _ = yym58 - if false { - } else { - *((*uint64)(yyv57)) = uint64(r.DecodeUint(64)) - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobModifyIndex = 0 - } else { - yyv59 := &x.JobModifyIndex - yym60 := z.DecBinary() - _ = yym60 - if false { - } else { - *((*uint64)(yyv59)) = uint64(r.DecodeUint(64)) - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.SubmitTime = 0 - } else { - yyv61 := &x.SubmitTime - yym62 := z.DecBinary() - _ = yym62 - if false { - } else { - *((*int64)(yyv61)) = int64(r.DecodeInt(64)) - } - } - for { - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj33-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobSummary) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [6]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(6) - } else { - yynn2 = 6 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Summary == nil { - r.EncodeNil() - } else { - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - h.encMapstringTaskGroupSummary((map[string]TaskGroupSummary)(x.Summary), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Summary")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Summary == nil { - r.EncodeNil() - } else { - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - h.encMapstringTaskGroupSummary((map[string]TaskGroupSummary)(x.Summary), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Children == nil { - r.EncodeNil() - } else { - x.Children.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Children")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Children == nil { - r.EncodeNil() - } else { - x.Children.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobSummary) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobSummary) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "JobID": - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv4 := &x.JobID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv6 := &x.Namespace - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Summary": - if r.TryDecodeAsNil() { - x.Summary = nil - } else { - yyv8 := &x.Summary - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - h.decMapstringTaskGroupSummary((*map[string]TaskGroupSummary)(yyv8), d) - } - } - case "Children": - if r.TryDecodeAsNil() { - if x.Children != nil { - x.Children = nil - } - } else { - if x.Children == nil { - x.Children = new(JobChildrenSummary) - } - x.Children.CodecDecodeSelf(d) - } - case "CreateIndex": - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv11 := &x.CreateIndex - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*uint64)(yyv11)) = uint64(r.DecodeUint(64)) - } - } - case "ModifyIndex": - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv13 := &x.ModifyIndex - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobSummary) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj15 int - var yyb15 bool - var yyhl15 bool = l >= 0 - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv16 := &x.JobID - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv18 := &x.Namespace - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Summary = nil - } else { - yyv20 := &x.Summary - yym21 := z.DecBinary() - _ = yym21 - if false { - } else { - h.decMapstringTaskGroupSummary((*map[string]TaskGroupSummary)(yyv20), d) - } - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Children != nil { - x.Children = nil - } - } else { - if x.Children == nil { - x.Children = new(JobChildrenSummary) - } - x.Children.CodecDecodeSelf(d) - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv23 := &x.CreateIndex - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) - } - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv25 := &x.ModifyIndex - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*uint64)(yyv25)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj15-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *JobChildrenSummary) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [3]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(3) - } else { - yynn2 = 3 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeInt(int64(x.Pending)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Pending")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeInt(int64(x.Pending)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeInt(int64(x.Running)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Running")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeInt(int64(x.Running)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeInt(int64(x.Dead)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Dead")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeInt(int64(x.Dead)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *JobChildrenSummary) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *JobChildrenSummary) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Pending": - if r.TryDecodeAsNil() { - x.Pending = 0 - } else { - yyv4 := &x.Pending - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*int64)(yyv4)) = int64(r.DecodeInt(64)) - } - } - case "Running": - if r.TryDecodeAsNil() { - x.Running = 0 - } else { - yyv6 := &x.Running - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*int64)(yyv6)) = int64(r.DecodeInt(64)) - } - } - case "Dead": - if r.TryDecodeAsNil() { - x.Dead = 0 - } else { - yyv8 := &x.Dead - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*int64)(yyv8)) = int64(r.DecodeInt(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *JobChildrenSummary) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj10 int - var yyb10 bool - var yyhl10 bool = l >= 0 - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Pending = 0 - } else { - yyv11 := &x.Pending - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*int64)(yyv11)) = int64(r.DecodeInt(64)) - } - } - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Running = 0 - } else { - yyv13 := &x.Running - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*int64)(yyv13)) = int64(r.DecodeInt(64)) - } - } - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Dead = 0 - } else { - yyv15 := &x.Dead - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*int64)(yyv15)) = int64(r.DecodeInt(64)) - } - } - for { - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj10-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *TaskGroupSummary) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [6]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(6) - } else { - yynn2 = 6 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeInt(int64(x.Queued)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Queued")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeInt(int64(x.Queued)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeInt(int64(x.Complete)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Complete")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeInt(int64(x.Complete)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeInt(int64(x.Failed)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Failed")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeInt(int64(x.Failed)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeInt(int64(x.Running)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Running")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeInt(int64(x.Running)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeInt(int64(x.Starting)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Starting")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeInt(int64(x.Starting)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeInt(int64(x.Lost)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Lost")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeInt(int64(x.Lost)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *TaskGroupSummary) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *TaskGroupSummary) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Queued": - if r.TryDecodeAsNil() { - x.Queued = 0 - } else { - yyv4 := &x.Queued - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*int)(yyv4)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "Complete": - if r.TryDecodeAsNil() { - x.Complete = 0 - } else { - yyv6 := &x.Complete - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*int)(yyv6)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "Failed": - if r.TryDecodeAsNil() { - x.Failed = 0 - } else { - yyv8 := &x.Failed - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*int)(yyv8)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "Running": - if r.TryDecodeAsNil() { - x.Running = 0 - } else { - yyv10 := &x.Running - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*int)(yyv10)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "Starting": - if r.TryDecodeAsNil() { - x.Starting = 0 - } else { - yyv12 := &x.Starting - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*int)(yyv12)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "Lost": - if r.TryDecodeAsNil() { - x.Lost = 0 - } else { - yyv14 := &x.Lost - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*int)(yyv14)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *TaskGroupSummary) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj16 int - var yyb16 bool - var yyhl16 bool = l >= 0 - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Queued = 0 - } else { - yyv17 := &x.Queued - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*int)(yyv17)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Complete = 0 - } else { - yyv19 := &x.Complete - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*int)(yyv19)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Failed = 0 - } else { - yyv21 := &x.Failed - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*int)(yyv21)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Running = 0 - } else { - yyv23 := &x.Running - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*int)(yyv23)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Starting = 0 - } else { - yyv25 := &x.Starting - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*int)(yyv25)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Lost = 0 - } else { - yyv27 := &x.Lost - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*int)(yyv27)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - for { - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj16-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *UpdateStrategy) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [7]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(7) - } else { - yynn2 = 7 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else if z.HasExtensions() && z.EncExt(x.Stagger) { - } else { - r.EncodeInt(int64(x.Stagger)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Stagger")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else if z.HasExtensions() && z.EncExt(x.Stagger) { - } else { - r.EncodeInt(int64(x.Stagger)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeInt(int64(x.MaxParallel)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxParallel")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeInt(int64(x.MaxParallel)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.HealthCheck)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("HealthCheck")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.HealthCheck)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.EncExt(x.MinHealthyTime) { - } else { - r.EncodeInt(int64(x.MinHealthyTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinHealthyTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else if z.HasExtensions() && z.EncExt(x.MinHealthyTime) { - } else { - r.EncodeInt(int64(x.MinHealthyTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.EncExt(x.HealthyDeadline) { - } else { - r.EncodeInt(int64(x.HealthyDeadline)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("HealthyDeadline")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else if z.HasExtensions() && z.EncExt(x.HealthyDeadline) { - } else { - r.EncodeInt(int64(x.HealthyDeadline)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeBool(bool(x.AutoRevert)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AutoRevert")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeBool(bool(x.AutoRevert)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeInt(int64(x.Canary)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Canary")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeInt(int64(x.Canary)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *UpdateStrategy) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *UpdateStrategy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Stagger": - if r.TryDecodeAsNil() { - x.Stagger = 0 - } else { - yyv4 := &x.Stagger - yym5 := z.DecBinary() - _ = yym5 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4) { - } else { - *((*int64)(yyv4)) = int64(r.DecodeInt(64)) - } - } - case "MaxParallel": - if r.TryDecodeAsNil() { - x.MaxParallel = 0 - } else { - yyv6 := &x.MaxParallel - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*int)(yyv6)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "HealthCheck": - if r.TryDecodeAsNil() { - x.HealthCheck = "" - } else { - yyv8 := &x.HealthCheck - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "MinHealthyTime": - if r.TryDecodeAsNil() { - x.MinHealthyTime = 0 - } else { - yyv10 := &x.MinHealthyTime - yym11 := z.DecBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.DecExt(yyv10) { - } else { - *((*int64)(yyv10)) = int64(r.DecodeInt(64)) - } - } - case "HealthyDeadline": - if r.TryDecodeAsNil() { - x.HealthyDeadline = 0 - } else { - yyv12 := &x.HealthyDeadline - yym13 := z.DecBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.DecExt(yyv12) { - } else { - *((*int64)(yyv12)) = int64(r.DecodeInt(64)) - } - } - case "AutoRevert": - if r.TryDecodeAsNil() { - x.AutoRevert = false - } else { - yyv14 := &x.AutoRevert - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*bool)(yyv14)) = r.DecodeBool() - } - } - case "Canary": - if r.TryDecodeAsNil() { - x.Canary = 0 - } else { - yyv16 := &x.Canary - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*int)(yyv16)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *UpdateStrategy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj18 int - var yyb18 bool - var yyhl18 bool = l >= 0 - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Stagger = 0 - } else { - yyv19 := &x.Stagger - yym20 := z.DecBinary() - _ = yym20 - if false { - } else if z.HasExtensions() && z.DecExt(yyv19) { - } else { - *((*int64)(yyv19)) = int64(r.DecodeInt(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxParallel = 0 - } else { - yyv21 := &x.MaxParallel - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*int)(yyv21)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.HealthCheck = "" - } else { - yyv23 := &x.HealthCheck - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinHealthyTime = 0 - } else { - yyv25 := &x.MinHealthyTime - yym26 := z.DecBinary() - _ = yym26 - if false { - } else if z.HasExtensions() && z.DecExt(yyv25) { - } else { - *((*int64)(yyv25)) = int64(r.DecodeInt(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.HealthyDeadline = 0 - } else { - yyv27 := &x.HealthyDeadline - yym28 := z.DecBinary() - _ = yym28 - if false { - } else if z.HasExtensions() && z.DecExt(yyv27) { - } else { - *((*int64)(yyv27)) = int64(r.DecodeInt(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AutoRevert = false - } else { - yyv29 := &x.AutoRevert - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*bool)(yyv29)) = r.DecodeBool() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Canary = 0 - } else { - yyv31 := &x.Canary - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*int)(yyv31)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - for { - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj18-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *PeriodicConfig) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 5 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeBool(bool(x.Enabled)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Enabled")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeBool(bool(x.Enabled)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Spec)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Spec")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Spec)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.SpecType)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("SpecType")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.SpecType)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.ProhibitOverlap)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ProhibitOverlap")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.ProhibitOverlap)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.TimeZone)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("TimeZone")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.TimeZone)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *PeriodicConfig) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *PeriodicConfig) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Enabled": - if r.TryDecodeAsNil() { - x.Enabled = false - } else { - yyv4 := &x.Enabled - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*bool)(yyv4)) = r.DecodeBool() - } - } - case "Spec": - if r.TryDecodeAsNil() { - x.Spec = "" - } else { - yyv6 := &x.Spec - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "SpecType": - if r.TryDecodeAsNil() { - x.SpecType = "" - } else { - yyv8 := &x.SpecType - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "ProhibitOverlap": - if r.TryDecodeAsNil() { - x.ProhibitOverlap = false - } else { - yyv10 := &x.ProhibitOverlap - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*bool)(yyv10)) = r.DecodeBool() - } - } - case "TimeZone": - if r.TryDecodeAsNil() { - x.TimeZone = "" - } else { - yyv12 := &x.TimeZone - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *PeriodicConfig) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj14 int - var yyb14 bool - var yyhl14 bool = l >= 0 - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Enabled = false - } else { - yyv15 := &x.Enabled - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*bool)(yyv15)) = r.DecodeBool() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Spec = "" - } else { - yyv17 := &x.Spec - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.SpecType = "" - } else { - yyv19 := &x.SpecType - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ProhibitOverlap = false - } else { - yyv21 := &x.ProhibitOverlap - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*bool)(yyv21)) = r.DecodeBool() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.TimeZone = "" - } else { - yyv23 := &x.TimeZone - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - for { - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj14-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *PeriodicLaunch) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 5 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yy10 := &x.Launch - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if yym12 := z.TimeRtidIfBinc(); yym12 != 0 { - r.EncodeBuiltin(yym12, yy10) - } else if z.HasExtensions() && z.EncExt(yy10) { - } else if yym11 { - z.EncBinaryMarshal(yy10) - } else if !yym11 && z.IsJSONHandle() { - z.EncJSONMarshal(yy10) - } else { - z.EncFallback(yy10) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Launch")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yy13 := &x.Launch - yym14 := z.EncBinary() - _ = yym14 - if false { - } else if yym15 := z.TimeRtidIfBinc(); yym15 != 0 { - r.EncodeBuiltin(yym15, yy13) - } else if z.HasExtensions() && z.EncExt(yy13) { - } else if yym14 { - z.EncBinaryMarshal(yy13) - } else if !yym14 && z.IsJSONHandle() { - z.EncJSONMarshal(yy13) - } else { - z.EncFallback(yy13) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym18 := z.EncBinary() - _ = yym18 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym21 := z.EncBinary() - _ = yym21 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *PeriodicLaunch) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *PeriodicLaunch) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "ID": - if r.TryDecodeAsNil() { - x.ID = "" - } else { - yyv4 := &x.ID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv6 := &x.Namespace - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Launch": - if r.TryDecodeAsNil() { - x.Launch = time.Time{} - } else { - yyv8 := &x.Launch - yym9 := z.DecBinary() - _ = yym9 - if false { - } else if yym10 := z.TimeRtidIfBinc(); yym10 != 0 { - r.DecodeBuiltin(yym10, yyv8) - } else if z.HasExtensions() && z.DecExt(yyv8) { - } else if yym9 { - z.DecBinaryUnmarshal(yyv8) - } else if !yym9 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv8) - } else { - z.DecFallback(yyv8, false) - } - } - case "CreateIndex": - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv11 := &x.CreateIndex - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*uint64)(yyv11)) = uint64(r.DecodeUint(64)) - } - } - case "ModifyIndex": - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv13 := &x.ModifyIndex - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *PeriodicLaunch) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj15 int - var yyb15 bool - var yyhl15 bool = l >= 0 - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ID = "" - } else { - yyv16 := &x.ID - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv18 := &x.Namespace - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Launch = time.Time{} - } else { - yyv20 := &x.Launch - yym21 := z.DecBinary() - _ = yym21 - if false { - } else if yym22 := z.TimeRtidIfBinc(); yym22 != 0 { - r.DecodeBuiltin(yym22, yyv20) - } else if z.HasExtensions() && z.DecExt(yyv20) { - } else if yym21 { - z.DecBinaryUnmarshal(yyv20) - } else if !yym21 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv20) - } else { - z.DecFallback(yyv20, false) - } - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv23 := &x.CreateIndex - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) - } - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv25 := &x.ModifyIndex - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*uint64)(yyv25)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj15-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ParameterizedJobConfig) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [3]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(3) - } else { - yynn2 = 3 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Payload)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Payload")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Payload)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.MetaRequired == nil { - r.EncodeNil() - } else { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - z.F.EncSliceStringV(x.MetaRequired, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MetaRequired")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.MetaRequired == nil { - r.EncodeNil() - } else { - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - z.F.EncSliceStringV(x.MetaRequired, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.MetaOptional == nil { - r.EncodeNil() - } else { - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - z.F.EncSliceStringV(x.MetaOptional, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MetaOptional")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.MetaOptional == nil { - r.EncodeNil() - } else { - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - z.F.EncSliceStringV(x.MetaOptional, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ParameterizedJobConfig) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ParameterizedJobConfig) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Payload": - if r.TryDecodeAsNil() { - x.Payload = "" - } else { - yyv4 := &x.Payload - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "MetaRequired": - if r.TryDecodeAsNil() { - x.MetaRequired = nil - } else { - yyv6 := &x.MetaRequired - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - z.F.DecSliceStringX(yyv6, false, d) - } - } - case "MetaOptional": - if r.TryDecodeAsNil() { - x.MetaOptional = nil - } else { - yyv8 := &x.MetaOptional - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - z.F.DecSliceStringX(yyv8, false, d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ParameterizedJobConfig) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj10 int - var yyb10 bool - var yyhl10 bool = l >= 0 - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Payload = "" - } else { - yyv11 := &x.Payload - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*string)(yyv11)) = r.DecodeString() - } - } - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MetaRequired = nil - } else { - yyv13 := &x.MetaRequired - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - z.F.DecSliceStringX(yyv13, false, d) - } - } - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MetaOptional = nil - } else { - yyv15 := &x.MetaOptional - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - z.F.DecSliceStringX(yyv15, false, d) - } - } - for { - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj10-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *DispatchPayloadConfig) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [1]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(1) - } else { - yynn2 = 1 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.File)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("File")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.File)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *DispatchPayloadConfig) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *DispatchPayloadConfig) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "File": - if r.TryDecodeAsNil() { - x.File = "" - } else { - yyv4 := &x.File - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *DispatchPayloadConfig) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - 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 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.File = "" - } else { - yyv7 := &x.File - yym8 := z.DecBinary() - _ = yym8 - if false { - } else { - *((*string)(yyv7)) = r.DecodeString() - } - } - for { - yyj6++ - if yyhl6 { - yyb6 = yyj6 > l - } else { - yyb6 = r.CheckBreak() - } - if yyb6 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj6-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *RestartPolicy) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeInt(int64(x.Attempts)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Attempts")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeInt(int64(x.Attempts)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else if z.HasExtensions() && z.EncExt(x.Interval) { - } else { - r.EncodeInt(int64(x.Interval)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Interval")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else if z.HasExtensions() && z.EncExt(x.Interval) { - } else { - r.EncodeInt(int64(x.Interval)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.Delay) { - } else { - r.EncodeInt(int64(x.Delay)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Delay")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.Delay) { - } else { - r.EncodeInt(int64(x.Delay)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Mode)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Mode")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Mode)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *RestartPolicy) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *RestartPolicy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Attempts": - if r.TryDecodeAsNil() { - x.Attempts = 0 - } else { - yyv4 := &x.Attempts - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*int)(yyv4)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "Interval": - if r.TryDecodeAsNil() { - x.Interval = 0 - } else { - yyv6 := &x.Interval - yym7 := z.DecBinary() - _ = yym7 - if false { - } else if z.HasExtensions() && z.DecExt(yyv6) { - } else { - *((*int64)(yyv6)) = int64(r.DecodeInt(64)) - } - } - case "Delay": - if r.TryDecodeAsNil() { - x.Delay = 0 - } else { - yyv8 := &x.Delay - yym9 := z.DecBinary() - _ = yym9 - if false { - } else if z.HasExtensions() && z.DecExt(yyv8) { - } else { - *((*int64)(yyv8)) = int64(r.DecodeInt(64)) - } - } - case "Mode": - if r.TryDecodeAsNil() { - x.Mode = "" - } else { - yyv10 := &x.Mode - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *RestartPolicy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Attempts = 0 - } else { - yyv13 := &x.Attempts - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*int)(yyv13)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Interval = 0 - } else { - yyv15 := &x.Interval - yym16 := z.DecBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.DecExt(yyv15) { - } else { - *((*int64)(yyv15)) = int64(r.DecodeInt(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Delay = 0 - } else { - yyv17 := &x.Delay - yym18 := z.DecBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.DecExt(yyv17) { - } else { - *((*int64)(yyv17)) = int64(r.DecodeInt(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Mode = "" - } else { - yyv19 := &x.Mode - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *TaskGroup) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [8]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(8) - } else { - yynn2 = 8 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Name")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeInt(int64(x.Count)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Count")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeInt(int64(x.Count)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Update == nil { - r.EncodeNil() - } else { - x.Update.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Update")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Update == nil { - r.EncodeNil() - } else { - x.Update.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Constraints == nil { - r.EncodeNil() - } else { - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - h.encSlicePtrtoConstraint(([]*Constraint)(x.Constraints), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Constraints")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Constraints == nil { - r.EncodeNil() - } else { - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - h.encSlicePtrtoConstraint(([]*Constraint)(x.Constraints), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.RestartPolicy == nil { - r.EncodeNil() - } else { - x.RestartPolicy.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("RestartPolicy")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.RestartPolicy == nil { - r.EncodeNil() - } else { - x.RestartPolicy.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Tasks == nil { - r.EncodeNil() - } else { - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - h.encSlicePtrtoTask(([]*Task)(x.Tasks), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Tasks")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Tasks == nil { - r.EncodeNil() - } else { - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - h.encSlicePtrtoTask(([]*Task)(x.Tasks), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.EphemeralDisk == nil { - r.EncodeNil() - } else { - x.EphemeralDisk.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EphemeralDisk")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.EphemeralDisk == nil { - r.EncodeNil() - } else { - x.EphemeralDisk.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Meta == nil { - r.EncodeNil() - } else { - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - z.F.EncMapStringStringV(x.Meta, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Meta")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Meta == nil { - r.EncodeNil() - } else { - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - z.F.EncMapStringStringV(x.Meta, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *TaskGroup) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *TaskGroup) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv4 := &x.Name - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Count": - if r.TryDecodeAsNil() { - x.Count = 0 - } else { - yyv6 := &x.Count - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*int)(yyv6)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "Update": - if r.TryDecodeAsNil() { - if x.Update != nil { - x.Update = nil - } - } else { - if x.Update == nil { - x.Update = new(UpdateStrategy) - } - x.Update.CodecDecodeSelf(d) - } - case "Constraints": - if r.TryDecodeAsNil() { - x.Constraints = nil - } else { - yyv9 := &x.Constraints - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - h.decSlicePtrtoConstraint((*[]*Constraint)(yyv9), d) - } - } - case "RestartPolicy": - if r.TryDecodeAsNil() { - if x.RestartPolicy != nil { - x.RestartPolicy = nil - } - } else { - if x.RestartPolicy == nil { - x.RestartPolicy = new(RestartPolicy) - } - x.RestartPolicy.CodecDecodeSelf(d) - } - case "Tasks": - if r.TryDecodeAsNil() { - x.Tasks = nil - } else { - yyv12 := &x.Tasks - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - h.decSlicePtrtoTask((*[]*Task)(yyv12), d) - } - } - case "EphemeralDisk": - if r.TryDecodeAsNil() { - if x.EphemeralDisk != nil { - x.EphemeralDisk = nil - } - } else { - if x.EphemeralDisk == nil { - x.EphemeralDisk = new(EphemeralDisk) - } - x.EphemeralDisk.CodecDecodeSelf(d) - } - case "Meta": - if r.TryDecodeAsNil() { - x.Meta = nil - } else { - yyv15 := &x.Meta - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - z.F.DecMapStringStringX(yyv15, false, d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *TaskGroup) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj17 int - var yyb17 bool - var yyhl17 bool = l >= 0 - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv18 := &x.Name - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Count = 0 - } else { - yyv20 := &x.Count - yym21 := z.DecBinary() - _ = yym21 - if false { - } else { - *((*int)(yyv20)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Update != nil { - x.Update = nil - } - } else { - if x.Update == nil { - x.Update = new(UpdateStrategy) - } - x.Update.CodecDecodeSelf(d) - } - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Constraints = nil - } else { - yyv23 := &x.Constraints - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - h.decSlicePtrtoConstraint((*[]*Constraint)(yyv23), d) - } - } - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.RestartPolicy != nil { - x.RestartPolicy = nil - } - } else { - if x.RestartPolicy == nil { - x.RestartPolicy = new(RestartPolicy) - } - x.RestartPolicy.CodecDecodeSelf(d) - } - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Tasks = nil - } else { - yyv26 := &x.Tasks - yym27 := z.DecBinary() - _ = yym27 - if false { - } else { - h.decSlicePtrtoTask((*[]*Task)(yyv26), d) - } - } - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.EphemeralDisk != nil { - x.EphemeralDisk = nil - } - } else { - if x.EphemeralDisk == nil { - x.EphemeralDisk = new(EphemeralDisk) - } - x.EphemeralDisk.CodecDecodeSelf(d) - } - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Meta = nil - } else { - yyv29 := &x.Meta - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - z.F.DecMapStringStringX(yyv29, false, d) - } - } - for { - yyj17++ - if yyhl17 { - yyb17 = yyj17 > l - } else { - yyb17 = r.CheckBreak() - } - if yyb17 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj17-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *CheckRestart) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [3]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(3) - } else { - yynn2 = 3 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeInt(int64(x.Limit)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Limit")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeInt(int64(x.Limit)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else if z.HasExtensions() && z.EncExt(x.Grace) { - } else { - r.EncodeInt(int64(x.Grace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Grace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else if z.HasExtensions() && z.EncExt(x.Grace) { - } else { - r.EncodeInt(int64(x.Grace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeBool(bool(x.IgnoreWarnings)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("IgnoreWarnings")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeBool(bool(x.IgnoreWarnings)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *CheckRestart) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *CheckRestart) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Limit": - if r.TryDecodeAsNil() { - x.Limit = 0 - } else { - yyv4 := &x.Limit - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*int)(yyv4)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "Grace": - if r.TryDecodeAsNil() { - x.Grace = 0 - } else { - yyv6 := &x.Grace - yym7 := z.DecBinary() - _ = yym7 - if false { - } else if z.HasExtensions() && z.DecExt(yyv6) { - } else { - *((*int64)(yyv6)) = int64(r.DecodeInt(64)) - } - } - case "IgnoreWarnings": - if r.TryDecodeAsNil() { - x.IgnoreWarnings = false - } else { - yyv8 := &x.IgnoreWarnings - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*bool)(yyv8)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *CheckRestart) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj10 int - var yyb10 bool - var yyhl10 bool = l >= 0 - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Limit = 0 - } else { - yyv11 := &x.Limit - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*int)(yyv11)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Grace = 0 - } else { - yyv13 := &x.Grace - yym14 := z.DecBinary() - _ = yym14 - if false { - } else if z.HasExtensions() && z.DecExt(yyv13) { - } else { - *((*int64)(yyv13)) = int64(r.DecodeInt(64)) - } - } - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.IgnoreWarnings = false - } else { - yyv15 := &x.IgnoreWarnings - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*bool)(yyv15)) = r.DecodeBool() - } - } - for { - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj10-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ServiceCheck) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [15]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(15) - } else { - yynn2 = 15 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Name")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Type)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Type")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Type)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Command)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Command")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Command)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Args == nil { - r.EncodeNil() - } else { - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - z.F.EncSliceStringV(x.Args, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Args")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Args == nil { - r.EncodeNil() - } else { - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - z.F.EncSliceStringV(x.Args, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Path)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Path")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Path)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Protocol)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Protocol")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Protocol)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.PortLabel)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("PortLabel")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.PortLabel)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AddressMode)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AddressMode")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AddressMode)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym28 := z.EncBinary() - _ = yym28 - if false { - } else if z.HasExtensions() && z.EncExt(x.Interval) { - } else { - r.EncodeInt(int64(x.Interval)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Interval")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym29 := z.EncBinary() - _ = yym29 - if false { - } else if z.HasExtensions() && z.EncExt(x.Interval) { - } else { - r.EncodeInt(int64(x.Interval)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym31 := z.EncBinary() - _ = yym31 - if false { - } else if z.HasExtensions() && z.EncExt(x.Timeout) { - } else { - r.EncodeInt(int64(x.Timeout)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Timeout")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym32 := z.EncBinary() - _ = yym32 - if false { - } else if z.HasExtensions() && z.EncExt(x.Timeout) { - } else { - r.EncodeInt(int64(x.Timeout)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym34 := z.EncBinary() - _ = yym34 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.InitialStatus)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("InitialStatus")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym35 := z.EncBinary() - _ = yym35 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.InitialStatus)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym37 := z.EncBinary() - _ = yym37 - if false { - } else { - r.EncodeBool(bool(x.TLSSkipVerify)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("TLSSkipVerify")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym38 := z.EncBinary() - _ = yym38 - if false { - } else { - r.EncodeBool(bool(x.TLSSkipVerify)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym40 := z.EncBinary() - _ = yym40 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Method)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Method")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym41 := z.EncBinary() - _ = yym41 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Method)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Header == nil { - r.EncodeNil() - } else { - yym43 := z.EncBinary() - _ = yym43 - if false { - } else { - h.encMapstringSlicestring((map[string][]string)(x.Header), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Header")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Header == nil { - r.EncodeNil() - } else { - yym44 := z.EncBinary() - _ = yym44 - if false { - } else { - h.encMapstringSlicestring((map[string][]string)(x.Header), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.CheckRestart == nil { - r.EncodeNil() - } else { - x.CheckRestart.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CheckRestart")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.CheckRestart == nil { - r.EncodeNil() - } else { - x.CheckRestart.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ServiceCheck) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ServiceCheck) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv4 := &x.Name - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - yyv6 := &x.Type - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Command": - if r.TryDecodeAsNil() { - x.Command = "" - } else { - yyv8 := &x.Command - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Args": - if r.TryDecodeAsNil() { - x.Args = nil - } else { - yyv10 := &x.Args - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - z.F.DecSliceStringX(yyv10, false, d) - } - } - case "Path": - if r.TryDecodeAsNil() { - x.Path = "" - } else { - yyv12 := &x.Path - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - case "Protocol": - if r.TryDecodeAsNil() { - x.Protocol = "" - } else { - yyv14 := &x.Protocol - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*string)(yyv14)) = r.DecodeString() - } - } - case "PortLabel": - if r.TryDecodeAsNil() { - x.PortLabel = "" - } else { - yyv16 := &x.PortLabel - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - case "AddressMode": - if r.TryDecodeAsNil() { - x.AddressMode = "" - } else { - yyv18 := &x.AddressMode - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - case "Interval": - if r.TryDecodeAsNil() { - x.Interval = 0 - } else { - yyv20 := &x.Interval - yym21 := z.DecBinary() - _ = yym21 - if false { - } else if z.HasExtensions() && z.DecExt(yyv20) { - } else { - *((*int64)(yyv20)) = int64(r.DecodeInt(64)) - } - } - case "Timeout": - if r.TryDecodeAsNil() { - x.Timeout = 0 - } else { - yyv22 := &x.Timeout - yym23 := z.DecBinary() - _ = yym23 - if false { - } else if z.HasExtensions() && z.DecExt(yyv22) { - } else { - *((*int64)(yyv22)) = int64(r.DecodeInt(64)) - } - } - case "InitialStatus": - if r.TryDecodeAsNil() { - x.InitialStatus = "" - } else { - yyv24 := &x.InitialStatus - yym25 := z.DecBinary() - _ = yym25 - if false { - } else { - *((*string)(yyv24)) = r.DecodeString() - } - } - case "TLSSkipVerify": - if r.TryDecodeAsNil() { - x.TLSSkipVerify = false - } else { - yyv26 := &x.TLSSkipVerify - yym27 := z.DecBinary() - _ = yym27 - if false { - } else { - *((*bool)(yyv26)) = r.DecodeBool() - } - } - case "Method": - if r.TryDecodeAsNil() { - x.Method = "" - } else { - yyv28 := &x.Method - yym29 := z.DecBinary() - _ = yym29 - if false { - } else { - *((*string)(yyv28)) = r.DecodeString() - } - } - case "Header": - if r.TryDecodeAsNil() { - x.Header = nil - } else { - yyv30 := &x.Header - yym31 := z.DecBinary() - _ = yym31 - if false { - } else { - h.decMapstringSlicestring((*map[string][]string)(yyv30), d) - } - } - case "CheckRestart": - if r.TryDecodeAsNil() { - if x.CheckRestart != nil { - x.CheckRestart = nil - } - } else { - if x.CheckRestart == nil { - x.CheckRestart = new(CheckRestart) - } - x.CheckRestart.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ServiceCheck) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj33 int - var yyb33 bool - var yyhl33 bool = l >= 0 - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv34 := &x.Name - yym35 := z.DecBinary() - _ = yym35 - if false { - } else { - *((*string)(yyv34)) = r.DecodeString() - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - yyv36 := &x.Type - yym37 := z.DecBinary() - _ = yym37 - if false { - } else { - *((*string)(yyv36)) = r.DecodeString() - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Command = "" - } else { - yyv38 := &x.Command - yym39 := z.DecBinary() - _ = yym39 - if false { - } else { - *((*string)(yyv38)) = r.DecodeString() - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Args = nil - } else { - yyv40 := &x.Args - yym41 := z.DecBinary() - _ = yym41 - if false { - } else { - z.F.DecSliceStringX(yyv40, false, d) - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - yyv42 := &x.Path - yym43 := z.DecBinary() - _ = yym43 - if false { - } else { - *((*string)(yyv42)) = r.DecodeString() - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Protocol = "" - } else { - yyv44 := &x.Protocol - yym45 := z.DecBinary() - _ = yym45 - if false { - } else { - *((*string)(yyv44)) = r.DecodeString() - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.PortLabel = "" - } else { - yyv46 := &x.PortLabel - yym47 := z.DecBinary() - _ = yym47 - if false { - } else { - *((*string)(yyv46)) = r.DecodeString() - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AddressMode = "" - } else { - yyv48 := &x.AddressMode - yym49 := z.DecBinary() - _ = yym49 - if false { - } else { - *((*string)(yyv48)) = r.DecodeString() - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Interval = 0 - } else { - yyv50 := &x.Interval - yym51 := z.DecBinary() - _ = yym51 - if false { - } else if z.HasExtensions() && z.DecExt(yyv50) { - } else { - *((*int64)(yyv50)) = int64(r.DecodeInt(64)) - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Timeout = 0 - } else { - yyv52 := &x.Timeout - yym53 := z.DecBinary() - _ = yym53 - if false { - } else if z.HasExtensions() && z.DecExt(yyv52) { - } else { - *((*int64)(yyv52)) = int64(r.DecodeInt(64)) - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.InitialStatus = "" - } else { - yyv54 := &x.InitialStatus - yym55 := z.DecBinary() - _ = yym55 - if false { - } else { - *((*string)(yyv54)) = r.DecodeString() - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.TLSSkipVerify = false - } else { - yyv56 := &x.TLSSkipVerify - yym57 := z.DecBinary() - _ = yym57 - if false { - } else { - *((*bool)(yyv56)) = r.DecodeBool() - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Method = "" - } else { - yyv58 := &x.Method - yym59 := z.DecBinary() - _ = yym59 - if false { - } else { - *((*string)(yyv58)) = r.DecodeString() - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Header = nil - } else { - yyv60 := &x.Header - yym61 := z.DecBinary() - _ = yym61 - if false { - } else { - h.decMapstringSlicestring((*map[string][]string)(yyv60), d) - } - } - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.CheckRestart != nil { - x.CheckRestart = nil - } - } else { - if x.CheckRestart == nil { - x.CheckRestart = new(CheckRestart) - } - x.CheckRestart.CodecDecodeSelf(d) - } - for { - yyj33++ - if yyhl33 { - yyb33 = yyj33 > l - } else { - yyb33 = r.CheckBreak() - } - if yyb33 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj33-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *Service) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 5 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Name")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.PortLabel)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("PortLabel")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.PortLabel)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AddressMode)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AddressMode")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AddressMode)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Tags == nil { - r.EncodeNil() - } else { - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - z.F.EncSliceStringV(x.Tags, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Tags")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Tags == nil { - r.EncodeNil() - } else { - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - z.F.EncSliceStringV(x.Tags, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Checks == nil { - r.EncodeNil() - } else { - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - h.encSlicePtrtoServiceCheck(([]*ServiceCheck)(x.Checks), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Checks")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Checks == nil { - r.EncodeNil() - } else { - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - h.encSlicePtrtoServiceCheck(([]*ServiceCheck)(x.Checks), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *Service) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *Service) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv4 := &x.Name - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "PortLabel": - if r.TryDecodeAsNil() { - x.PortLabel = "" - } else { - yyv6 := &x.PortLabel - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "AddressMode": - if r.TryDecodeAsNil() { - x.AddressMode = "" - } else { - yyv8 := &x.AddressMode - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Tags": - if r.TryDecodeAsNil() { - x.Tags = nil - } else { - yyv10 := &x.Tags - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - z.F.DecSliceStringX(yyv10, false, d) - } - } - case "Checks": - if r.TryDecodeAsNil() { - x.Checks = nil - } else { - yyv12 := &x.Checks - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - h.decSlicePtrtoServiceCheck((*[]*ServiceCheck)(yyv12), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *Service) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj14 int - var yyb14 bool - var yyhl14 bool = l >= 0 - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv15 := &x.Name - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.PortLabel = "" - } else { - yyv17 := &x.PortLabel - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AddressMode = "" - } else { - yyv19 := &x.AddressMode - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Tags = nil - } else { - yyv21 := &x.Tags - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - z.F.DecSliceStringX(yyv21, false, d) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Checks = nil - } else { - yyv23 := &x.Checks - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - h.decSlicePtrtoServiceCheck((*[]*ServiceCheck)(yyv23), d) - } - } - for { - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj14-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *LogConfig) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [2]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(2) - } else { - yynn2 = 2 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeInt(int64(x.MaxFiles)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxFiles")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeInt(int64(x.MaxFiles)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeInt(int64(x.MaxFileSizeMB)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxFileSizeMB")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeInt(int64(x.MaxFileSizeMB)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *LogConfig) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *LogConfig) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "MaxFiles": - if r.TryDecodeAsNil() { - x.MaxFiles = 0 - } else { - yyv4 := &x.MaxFiles - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*int)(yyv4)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "MaxFileSizeMB": - if r.TryDecodeAsNil() { - x.MaxFileSizeMB = 0 - } else { - yyv6 := &x.MaxFileSizeMB - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*int)(yyv6)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *LogConfig) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj8 int - var yyb8 bool - var yyhl8 bool = l >= 0 - yyj8++ - if yyhl8 { - yyb8 = yyj8 > l - } else { - yyb8 = r.CheckBreak() - } - if yyb8 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxFiles = 0 - } else { - yyv9 := &x.MaxFiles - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*int)(yyv9)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj8++ - if yyhl8 { - yyb8 = yyj8 > l - } else { - yyb8 = r.CheckBreak() - } - if yyb8 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxFileSizeMB = 0 - } else { - yyv11 := &x.MaxFileSizeMB - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*int)(yyv11)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - for { - yyj8++ - if yyhl8 { - yyb8 = yyj8 > l - } else { - yyb8 = r.CheckBreak() - } - if yyb8 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj8-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *Task) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [18]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(18) - } else { - yynn2 = 18 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Name")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Driver)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Driver")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Driver)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.User)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("User")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.User)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Config == nil { - r.EncodeNil() - } else { - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - z.F.EncMapStringIntfV(x.Config, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Config")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Config == nil { - r.EncodeNil() - } else { - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - z.F.EncMapStringIntfV(x.Config, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Env == nil { - r.EncodeNil() - } else { - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - z.F.EncMapStringStringV(x.Env, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Env")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Env == nil { - r.EncodeNil() - } else { - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - z.F.EncMapStringStringV(x.Env, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Services == nil { - r.EncodeNil() - } else { - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - h.encSlicePtrtoService(([]*Service)(x.Services), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Services")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Services == nil { - r.EncodeNil() - } else { - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - h.encSlicePtrtoService(([]*Service)(x.Services), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Vault == nil { - r.EncodeNil() - } else { - x.Vault.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Vault")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Vault == nil { - r.EncodeNil() - } else { - x.Vault.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Templates == nil { - r.EncodeNil() - } else { - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - h.encSlicePtrtoTemplate(([]*Template)(x.Templates), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Templates")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Templates == nil { - r.EncodeNil() - } else { - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - h.encSlicePtrtoTemplate(([]*Template)(x.Templates), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Constraints == nil { - r.EncodeNil() - } else { - yym28 := z.EncBinary() - _ = yym28 - if false { - } else { - h.encSlicePtrtoConstraint(([]*Constraint)(x.Constraints), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Constraints")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Constraints == nil { - r.EncodeNil() - } else { - yym29 := z.EncBinary() - _ = yym29 - if false { - } else { - h.encSlicePtrtoConstraint(([]*Constraint)(x.Constraints), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Resources == nil { - r.EncodeNil() - } else { - x.Resources.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Resources")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Resources == nil { - r.EncodeNil() - } else { - x.Resources.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.DispatchPayload == nil { - r.EncodeNil() - } else { - x.DispatchPayload.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DispatchPayload")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.DispatchPayload == nil { - r.EncodeNil() - } else { - x.DispatchPayload.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Meta == nil { - r.EncodeNil() - } else { - yym37 := z.EncBinary() - _ = yym37 - if false { - } else { - z.F.EncMapStringStringV(x.Meta, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Meta")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Meta == nil { - r.EncodeNil() - } else { - yym38 := z.EncBinary() - _ = yym38 - if false { - } else { - z.F.EncMapStringStringV(x.Meta, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym40 := z.EncBinary() - _ = yym40 - if false { - } else if z.HasExtensions() && z.EncExt(x.KillTimeout) { - } else { - r.EncodeInt(int64(x.KillTimeout)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KillTimeout")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym41 := z.EncBinary() - _ = yym41 - if false { - } else if z.HasExtensions() && z.EncExt(x.KillTimeout) { - } else { - r.EncodeInt(int64(x.KillTimeout)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.LogConfig == nil { - r.EncodeNil() - } else { - x.LogConfig.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LogConfig")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.LogConfig == nil { - r.EncodeNil() - } else { - x.LogConfig.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Artifacts == nil { - r.EncodeNil() - } else { - yym46 := z.EncBinary() - _ = yym46 - if false { - } else { - h.encSlicePtrtoTaskArtifact(([]*TaskArtifact)(x.Artifacts), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Artifacts")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Artifacts == nil { - r.EncodeNil() - } else { - yym47 := z.EncBinary() - _ = yym47 - if false { - } else { - h.encSlicePtrtoTaskArtifact(([]*TaskArtifact)(x.Artifacts), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym49 := z.EncBinary() - _ = yym49 - if false { - } else { - r.EncodeBool(bool(x.Leader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Leader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym50 := z.EncBinary() - _ = yym50 - if false { - } else { - r.EncodeBool(bool(x.Leader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym52 := z.EncBinary() - _ = yym52 - if false { - } else if z.HasExtensions() && z.EncExt(x.ShutdownDelay) { - } else { - r.EncodeInt(int64(x.ShutdownDelay)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ShutdownDelay")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym53 := z.EncBinary() - _ = yym53 - if false { - } else if z.HasExtensions() && z.EncExt(x.ShutdownDelay) { - } else { - r.EncodeInt(int64(x.ShutdownDelay)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym55 := z.EncBinary() - _ = yym55 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.KillSignal)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KillSignal")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym56 := z.EncBinary() - _ = yym56 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.KillSignal)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *Task) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *Task) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv4 := &x.Name - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Driver": - if r.TryDecodeAsNil() { - x.Driver = "" - } else { - yyv6 := &x.Driver - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "User": - if r.TryDecodeAsNil() { - x.User = "" - } else { - yyv8 := &x.User - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Config": - if r.TryDecodeAsNil() { - x.Config = nil - } else { - yyv10 := &x.Config - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - z.F.DecMapStringIntfX(yyv10, false, d) - } - } - case "Env": - if r.TryDecodeAsNil() { - x.Env = nil - } else { - yyv12 := &x.Env - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - z.F.DecMapStringStringX(yyv12, false, d) - } - } - case "Services": - if r.TryDecodeAsNil() { - x.Services = nil - } else { - yyv14 := &x.Services - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - h.decSlicePtrtoService((*[]*Service)(yyv14), d) - } - } - case "Vault": - if r.TryDecodeAsNil() { - if x.Vault != nil { - x.Vault = nil - } - } else { - if x.Vault == nil { - x.Vault = new(Vault) - } - x.Vault.CodecDecodeSelf(d) - } - case "Templates": - if r.TryDecodeAsNil() { - x.Templates = nil - } else { - yyv17 := &x.Templates - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - h.decSlicePtrtoTemplate((*[]*Template)(yyv17), d) - } - } - case "Constraints": - if r.TryDecodeAsNil() { - x.Constraints = nil - } else { - yyv19 := &x.Constraints - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - h.decSlicePtrtoConstraint((*[]*Constraint)(yyv19), d) - } - } - case "Resources": - if r.TryDecodeAsNil() { - if x.Resources != nil { - x.Resources = nil - } - } else { - if x.Resources == nil { - x.Resources = new(Resources) - } - x.Resources.CodecDecodeSelf(d) - } - case "DispatchPayload": - if r.TryDecodeAsNil() { - if x.DispatchPayload != nil { - x.DispatchPayload = nil - } - } else { - if x.DispatchPayload == nil { - x.DispatchPayload = new(DispatchPayloadConfig) - } - x.DispatchPayload.CodecDecodeSelf(d) - } - case "Meta": - if r.TryDecodeAsNil() { - x.Meta = nil - } else { - yyv23 := &x.Meta - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - z.F.DecMapStringStringX(yyv23, false, d) - } - } - case "KillTimeout": - if r.TryDecodeAsNil() { - x.KillTimeout = 0 - } else { - yyv25 := &x.KillTimeout - yym26 := z.DecBinary() - _ = yym26 - if false { - } else if z.HasExtensions() && z.DecExt(yyv25) { - } else { - *((*int64)(yyv25)) = int64(r.DecodeInt(64)) - } - } - case "LogConfig": - if r.TryDecodeAsNil() { - if x.LogConfig != nil { - x.LogConfig = nil - } - } else { - if x.LogConfig == nil { - x.LogConfig = new(LogConfig) - } - x.LogConfig.CodecDecodeSelf(d) - } - case "Artifacts": - if r.TryDecodeAsNil() { - x.Artifacts = nil - } else { - yyv28 := &x.Artifacts - yym29 := z.DecBinary() - _ = yym29 - if false { - } else { - h.decSlicePtrtoTaskArtifact((*[]*TaskArtifact)(yyv28), d) - } - } - case "Leader": - if r.TryDecodeAsNil() { - x.Leader = false - } else { - yyv30 := &x.Leader - yym31 := z.DecBinary() - _ = yym31 - if false { - } else { - *((*bool)(yyv30)) = r.DecodeBool() - } - } - case "ShutdownDelay": - if r.TryDecodeAsNil() { - x.ShutdownDelay = 0 - } else { - yyv32 := &x.ShutdownDelay - yym33 := z.DecBinary() - _ = yym33 - if false { - } else if z.HasExtensions() && z.DecExt(yyv32) { - } else { - *((*int64)(yyv32)) = int64(r.DecodeInt(64)) - } - } - case "KillSignal": - if r.TryDecodeAsNil() { - x.KillSignal = "" - } else { - yyv34 := &x.KillSignal - yym35 := z.DecBinary() - _ = yym35 - if false { - } else { - *((*string)(yyv34)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *Task) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj36 int - var yyb36 bool - var yyhl36 bool = l >= 0 - yyj36++ - if yyhl36 { - yyb36 = yyj36 > l - } else { - yyb36 = r.CheckBreak() - } - if yyb36 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv37 := &x.Name - yym38 := z.DecBinary() - _ = yym38 - if false { - } else { - *((*string)(yyv37)) = r.DecodeString() - } - } - yyj36++ - if yyhl36 { - yyb36 = yyj36 > l - } else { - yyb36 = r.CheckBreak() - } - if yyb36 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Driver = "" - } else { - yyv39 := &x.Driver - yym40 := z.DecBinary() - _ = yym40 - if false { - } else { - *((*string)(yyv39)) = r.DecodeString() - } - } - yyj36++ - if yyhl36 { - yyb36 = yyj36 > l - } else { - yyb36 = r.CheckBreak() - } - if yyb36 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.User = "" - } else { - yyv41 := &x.User - yym42 := z.DecBinary() - _ = yym42 - if false { - } else { - *((*string)(yyv41)) = r.DecodeString() - } - } - yyj36++ - if yyhl36 { - yyb36 = yyj36 > l - } else { - yyb36 = r.CheckBreak() - } - if yyb36 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Config = nil - } else { - yyv43 := &x.Config - yym44 := z.DecBinary() - _ = yym44 - if false { - } else { - z.F.DecMapStringIntfX(yyv43, false, d) - } - } - yyj36++ - if yyhl36 { - yyb36 = yyj36 > l - } else { - yyb36 = r.CheckBreak() - } - if yyb36 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Env = nil - } else { - yyv45 := &x.Env - yym46 := z.DecBinary() - _ = yym46 - if false { - } else { - z.F.DecMapStringStringX(yyv45, false, d) - } - } - yyj36++ - if yyhl36 { - yyb36 = yyj36 > l - } else { - yyb36 = r.CheckBreak() - } - if yyb36 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Services = nil - } else { - yyv47 := &x.Services - yym48 := z.DecBinary() - _ = yym48 - if false { - } else { - h.decSlicePtrtoService((*[]*Service)(yyv47), d) - } - } - yyj36++ - if yyhl36 { - yyb36 = yyj36 > l - } else { - yyb36 = r.CheckBreak() - } - if yyb36 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Vault != nil { - x.Vault = nil - } - } else { - if x.Vault == nil { - x.Vault = new(Vault) - } - x.Vault.CodecDecodeSelf(d) - } - yyj36++ - if yyhl36 { - yyb36 = yyj36 > l - } else { - yyb36 = r.CheckBreak() - } - if yyb36 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Templates = nil - } else { - yyv50 := &x.Templates - yym51 := z.DecBinary() - _ = yym51 - if false { - } else { - h.decSlicePtrtoTemplate((*[]*Template)(yyv50), d) - } - } - yyj36++ - if yyhl36 { - yyb36 = yyj36 > l - } else { - yyb36 = r.CheckBreak() - } - if yyb36 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Constraints = nil - } else { - yyv52 := &x.Constraints - yym53 := z.DecBinary() - _ = yym53 - if false { - } else { - h.decSlicePtrtoConstraint((*[]*Constraint)(yyv52), d) - } - } - yyj36++ - if yyhl36 { - yyb36 = yyj36 > l - } else { - yyb36 = r.CheckBreak() - } - if yyb36 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Resources != nil { - x.Resources = nil - } - } else { - if x.Resources == nil { - x.Resources = new(Resources) - } - x.Resources.CodecDecodeSelf(d) - } - yyj36++ - if yyhl36 { - yyb36 = yyj36 > l - } else { - yyb36 = r.CheckBreak() - } - if yyb36 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.DispatchPayload != nil { - x.DispatchPayload = nil - } - } else { - if x.DispatchPayload == nil { - x.DispatchPayload = new(DispatchPayloadConfig) - } - x.DispatchPayload.CodecDecodeSelf(d) - } - yyj36++ - if yyhl36 { - yyb36 = yyj36 > l - } else { - yyb36 = r.CheckBreak() - } - if yyb36 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Meta = nil - } else { - yyv56 := &x.Meta - yym57 := z.DecBinary() - _ = yym57 - if false { - } else { - z.F.DecMapStringStringX(yyv56, false, d) - } - } - yyj36++ - if yyhl36 { - yyb36 = yyj36 > l - } else { - yyb36 = r.CheckBreak() - } - if yyb36 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KillTimeout = 0 - } else { - yyv58 := &x.KillTimeout - yym59 := z.DecBinary() - _ = yym59 - if false { - } else if z.HasExtensions() && z.DecExt(yyv58) { - } else { - *((*int64)(yyv58)) = int64(r.DecodeInt(64)) - } - } - yyj36++ - if yyhl36 { - yyb36 = yyj36 > l - } else { - yyb36 = r.CheckBreak() - } - if yyb36 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.LogConfig != nil { - x.LogConfig = nil - } - } else { - if x.LogConfig == nil { - x.LogConfig = new(LogConfig) - } - x.LogConfig.CodecDecodeSelf(d) - } - yyj36++ - if yyhl36 { - yyb36 = yyj36 > l - } else { - yyb36 = r.CheckBreak() - } - if yyb36 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Artifacts = nil - } else { - yyv61 := &x.Artifacts - yym62 := z.DecBinary() - _ = yym62 - if false { - } else { - h.decSlicePtrtoTaskArtifact((*[]*TaskArtifact)(yyv61), d) - } - } - yyj36++ - if yyhl36 { - yyb36 = yyj36 > l - } else { - yyb36 = r.CheckBreak() - } - if yyb36 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Leader = false - } else { - yyv63 := &x.Leader - yym64 := z.DecBinary() - _ = yym64 - if false { - } else { - *((*bool)(yyv63)) = r.DecodeBool() - } - } - yyj36++ - if yyhl36 { - yyb36 = yyj36 > l - } else { - yyb36 = r.CheckBreak() - } - if yyb36 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ShutdownDelay = 0 - } else { - yyv65 := &x.ShutdownDelay - yym66 := z.DecBinary() - _ = yym66 - if false { - } else if z.HasExtensions() && z.DecExt(yyv65) { - } else { - *((*int64)(yyv65)) = int64(r.DecodeInt(64)) - } - } - yyj36++ - if yyhl36 { - yyb36 = yyj36 > l - } else { - yyb36 = r.CheckBreak() - } - if yyb36 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KillSignal = "" - } else { - yyv67 := &x.KillSignal - yym68 := z.DecBinary() - _ = yym68 - if false { - } else { - *((*string)(yyv67)) = r.DecodeString() - } - } - for { - yyj36++ - if yyhl36 { - yyb36 = yyj36 > l - } else { - yyb36 = r.CheckBreak() - } - if yyb36 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj36-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *Template) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [11]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(11) - } else { - yynn2 = 11 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.SourcePath)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("SourcePath")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.SourcePath)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DestPath)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DestPath")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DestPath)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EmbeddedTmpl)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EmbeddedTmpl")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EmbeddedTmpl)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ChangeMode)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ChangeMode")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ChangeMode)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ChangeSignal)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ChangeSignal")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ChangeSignal)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else if z.HasExtensions() && z.EncExt(x.Splay) { - } else { - r.EncodeInt(int64(x.Splay)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Splay")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else if z.HasExtensions() && z.EncExt(x.Splay) { - } else { - r.EncodeInt(int64(x.Splay)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Perms)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Perms")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Perms)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.LeftDelim)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LeftDelim")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.LeftDelim)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym28 := z.EncBinary() - _ = yym28 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.RightDelim)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("RightDelim")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym29 := z.EncBinary() - _ = yym29 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.RightDelim)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym31 := z.EncBinary() - _ = yym31 - if false { - } else { - r.EncodeBool(bool(x.Envvars)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Envvars")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym32 := z.EncBinary() - _ = yym32 - if false { - } else { - r.EncodeBool(bool(x.Envvars)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym34 := z.EncBinary() - _ = yym34 - if false { - } else if z.HasExtensions() && z.EncExt(x.VaultGrace) { - } else { - r.EncodeInt(int64(x.VaultGrace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("VaultGrace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym35 := z.EncBinary() - _ = yym35 - if false { - } else if z.HasExtensions() && z.EncExt(x.VaultGrace) { - } else { - r.EncodeInt(int64(x.VaultGrace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *Template) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *Template) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "SourcePath": - if r.TryDecodeAsNil() { - x.SourcePath = "" - } else { - yyv4 := &x.SourcePath - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "DestPath": - if r.TryDecodeAsNil() { - x.DestPath = "" - } else { - yyv6 := &x.DestPath - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "EmbeddedTmpl": - if r.TryDecodeAsNil() { - x.EmbeddedTmpl = "" - } else { - yyv8 := &x.EmbeddedTmpl - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "ChangeMode": - if r.TryDecodeAsNil() { - x.ChangeMode = "" - } else { - yyv10 := &x.ChangeMode - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "ChangeSignal": - if r.TryDecodeAsNil() { - x.ChangeSignal = "" - } else { - yyv12 := &x.ChangeSignal - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - case "Splay": - if r.TryDecodeAsNil() { - x.Splay = 0 - } else { - yyv14 := &x.Splay - yym15 := z.DecBinary() - _ = yym15 - if false { - } else if z.HasExtensions() && z.DecExt(yyv14) { - } else { - *((*int64)(yyv14)) = int64(r.DecodeInt(64)) - } - } - case "Perms": - if r.TryDecodeAsNil() { - x.Perms = "" - } else { - yyv16 := &x.Perms - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - case "LeftDelim": - if r.TryDecodeAsNil() { - x.LeftDelim = "" - } else { - yyv18 := &x.LeftDelim - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - case "RightDelim": - if r.TryDecodeAsNil() { - x.RightDelim = "" - } else { - yyv20 := &x.RightDelim - yym21 := z.DecBinary() - _ = yym21 - if false { - } else { - *((*string)(yyv20)) = r.DecodeString() - } - } - case "Envvars": - if r.TryDecodeAsNil() { - x.Envvars = false - } else { - yyv22 := &x.Envvars - yym23 := z.DecBinary() - _ = yym23 - if false { - } else { - *((*bool)(yyv22)) = r.DecodeBool() - } - } - case "VaultGrace": - if r.TryDecodeAsNil() { - x.VaultGrace = 0 - } else { - yyv24 := &x.VaultGrace - yym25 := z.DecBinary() - _ = yym25 - if false { - } else if z.HasExtensions() && z.DecExt(yyv24) { - } else { - *((*int64)(yyv24)) = int64(r.DecodeInt(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *Template) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj26 int - var yyb26 bool - var yyhl26 bool = l >= 0 - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.SourcePath = "" - } else { - yyv27 := &x.SourcePath - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*string)(yyv27)) = r.DecodeString() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DestPath = "" - } else { - yyv29 := &x.DestPath - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*string)(yyv29)) = r.DecodeString() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EmbeddedTmpl = "" - } else { - yyv31 := &x.EmbeddedTmpl - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*string)(yyv31)) = r.DecodeString() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ChangeMode = "" - } else { - yyv33 := &x.ChangeMode - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - *((*string)(yyv33)) = r.DecodeString() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ChangeSignal = "" - } else { - yyv35 := &x.ChangeSignal - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*string)(yyv35)) = r.DecodeString() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Splay = 0 - } else { - yyv37 := &x.Splay - yym38 := z.DecBinary() - _ = yym38 - if false { - } else if z.HasExtensions() && z.DecExt(yyv37) { - } else { - *((*int64)(yyv37)) = int64(r.DecodeInt(64)) - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Perms = "" - } else { - yyv39 := &x.Perms - yym40 := z.DecBinary() - _ = yym40 - if false { - } else { - *((*string)(yyv39)) = r.DecodeString() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LeftDelim = "" - } else { - yyv41 := &x.LeftDelim - yym42 := z.DecBinary() - _ = yym42 - if false { - } else { - *((*string)(yyv41)) = r.DecodeString() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.RightDelim = "" - } else { - yyv43 := &x.RightDelim - yym44 := z.DecBinary() - _ = yym44 - if false { - } else { - *((*string)(yyv43)) = r.DecodeString() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Envvars = false - } else { - yyv45 := &x.Envvars - yym46 := z.DecBinary() - _ = yym46 - if false { - } else { - *((*bool)(yyv45)) = r.DecodeBool() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.VaultGrace = 0 - } else { - yyv47 := &x.VaultGrace - yym48 := z.DecBinary() - _ = yym48 - if false { - } else if z.HasExtensions() && z.DecExt(yyv47) { - } else { - *((*int64)(yyv47)) = int64(r.DecodeInt(64)) - } - } - for { - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj26-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *TaskState) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [7]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(7) - } else { - yynn2 = 7 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.State)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("State")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.State)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeBool(bool(x.Failed)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Failed")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeBool(bool(x.Failed)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.Restarts)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Restarts")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.Restarts)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yy13 := &x.LastRestart - yym14 := z.EncBinary() - _ = yym14 - if false { - } else if yym15 := z.TimeRtidIfBinc(); yym15 != 0 { - r.EncodeBuiltin(yym15, yy13) - } else if z.HasExtensions() && z.EncExt(yy13) { - } else if yym14 { - z.EncBinaryMarshal(yy13) - } else if !yym14 && z.IsJSONHandle() { - z.EncJSONMarshal(yy13) - } else { - z.EncFallback(yy13) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastRestart")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yy16 := &x.LastRestart - yym17 := z.EncBinary() - _ = yym17 - if false { - } else if yym18 := z.TimeRtidIfBinc(); yym18 != 0 { - r.EncodeBuiltin(yym18, yy16) - } else if z.HasExtensions() && z.EncExt(yy16) { - } else if yym17 { - z.EncBinaryMarshal(yy16) - } else if !yym17 && z.IsJSONHandle() { - z.EncJSONMarshal(yy16) - } else { - z.EncFallback(yy16) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yy20 := &x.StartedAt - yym21 := z.EncBinary() - _ = yym21 - if false { - } else if yym22 := z.TimeRtidIfBinc(); yym22 != 0 { - r.EncodeBuiltin(yym22, yy20) - } else if z.HasExtensions() && z.EncExt(yy20) { - } else if yym21 { - z.EncBinaryMarshal(yy20) - } else if !yym21 && z.IsJSONHandle() { - z.EncJSONMarshal(yy20) - } else { - z.EncFallback(yy20) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("StartedAt")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yy23 := &x.StartedAt - yym24 := z.EncBinary() - _ = yym24 - if false { - } else if yym25 := z.TimeRtidIfBinc(); yym25 != 0 { - r.EncodeBuiltin(yym25, yy23) - } else if z.HasExtensions() && z.EncExt(yy23) { - } else if yym24 { - z.EncBinaryMarshal(yy23) - } else if !yym24 && z.IsJSONHandle() { - z.EncJSONMarshal(yy23) - } else { - z.EncFallback(yy23) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yy27 := &x.FinishedAt - yym28 := z.EncBinary() - _ = yym28 - if false { - } else if yym29 := z.TimeRtidIfBinc(); yym29 != 0 { - r.EncodeBuiltin(yym29, yy27) - } else if z.HasExtensions() && z.EncExt(yy27) { - } else if yym28 { - z.EncBinaryMarshal(yy27) - } else if !yym28 && z.IsJSONHandle() { - z.EncJSONMarshal(yy27) - } else { - z.EncFallback(yy27) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("FinishedAt")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yy30 := &x.FinishedAt - yym31 := z.EncBinary() - _ = yym31 - if false { - } else if yym32 := z.TimeRtidIfBinc(); yym32 != 0 { - r.EncodeBuiltin(yym32, yy30) - } else if z.HasExtensions() && z.EncExt(yy30) { - } else if yym31 { - z.EncBinaryMarshal(yy30) - } else if !yym31 && z.IsJSONHandle() { - z.EncJSONMarshal(yy30) - } else { - z.EncFallback(yy30) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Events == nil { - r.EncodeNil() - } else { - yym34 := z.EncBinary() - _ = yym34 - if false { - } else { - h.encSlicePtrtoTaskEvent(([]*TaskEvent)(x.Events), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Events")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Events == nil { - r.EncodeNil() - } else { - yym35 := z.EncBinary() - _ = yym35 - if false { - } else { - h.encSlicePtrtoTaskEvent(([]*TaskEvent)(x.Events), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *TaskState) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *TaskState) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "State": - if r.TryDecodeAsNil() { - x.State = "" - } else { - yyv4 := &x.State - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Failed": - if r.TryDecodeAsNil() { - x.Failed = false - } else { - yyv6 := &x.Failed - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*bool)(yyv6)) = r.DecodeBool() - } - } - case "Restarts": - if r.TryDecodeAsNil() { - x.Restarts = 0 - } else { - yyv8 := &x.Restarts - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) - } - } - case "LastRestart": - if r.TryDecodeAsNil() { - x.LastRestart = time.Time{} - } else { - yyv10 := &x.LastRestart - yym11 := z.DecBinary() - _ = yym11 - if false { - } else if yym12 := z.TimeRtidIfBinc(); yym12 != 0 { - r.DecodeBuiltin(yym12, yyv10) - } else if z.HasExtensions() && z.DecExt(yyv10) { - } else if yym11 { - z.DecBinaryUnmarshal(yyv10) - } else if !yym11 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv10) - } else { - z.DecFallback(yyv10, false) - } - } - case "StartedAt": - if r.TryDecodeAsNil() { - x.StartedAt = time.Time{} - } else { - yyv13 := &x.StartedAt - yym14 := z.DecBinary() - _ = yym14 - if false { - } else if yym15 := z.TimeRtidIfBinc(); yym15 != 0 { - r.DecodeBuiltin(yym15, yyv13) - } else if z.HasExtensions() && z.DecExt(yyv13) { - } else if yym14 { - z.DecBinaryUnmarshal(yyv13) - } else if !yym14 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv13) - } else { - z.DecFallback(yyv13, false) - } - } - case "FinishedAt": - if r.TryDecodeAsNil() { - x.FinishedAt = time.Time{} - } else { - yyv16 := &x.FinishedAt - yym17 := z.DecBinary() - _ = yym17 - if false { - } else if yym18 := z.TimeRtidIfBinc(); yym18 != 0 { - r.DecodeBuiltin(yym18, yyv16) - } else if z.HasExtensions() && z.DecExt(yyv16) { - } else if yym17 { - z.DecBinaryUnmarshal(yyv16) - } else if !yym17 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv16) - } else { - z.DecFallback(yyv16, false) - } - } - case "Events": - if r.TryDecodeAsNil() { - x.Events = nil - } else { - yyv19 := &x.Events - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - h.decSlicePtrtoTaskEvent((*[]*TaskEvent)(yyv19), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *TaskState) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj21 int - var yyb21 bool - var yyhl21 bool = l >= 0 - yyj21++ - if yyhl21 { - yyb21 = yyj21 > l - } else { - yyb21 = r.CheckBreak() - } - if yyb21 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.State = "" - } else { - yyv22 := &x.State - yym23 := z.DecBinary() - _ = yym23 - if false { - } else { - *((*string)(yyv22)) = r.DecodeString() - } - } - yyj21++ - if yyhl21 { - yyb21 = yyj21 > l - } else { - yyb21 = r.CheckBreak() - } - if yyb21 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Failed = false - } else { - yyv24 := &x.Failed - yym25 := z.DecBinary() - _ = yym25 - if false { - } else { - *((*bool)(yyv24)) = r.DecodeBool() - } - } - yyj21++ - if yyhl21 { - yyb21 = yyj21 > l - } else { - yyb21 = r.CheckBreak() - } - if yyb21 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Restarts = 0 - } else { - yyv26 := &x.Restarts - yym27 := z.DecBinary() - _ = yym27 - if false { - } else { - *((*uint64)(yyv26)) = uint64(r.DecodeUint(64)) - } - } - yyj21++ - if yyhl21 { - yyb21 = yyj21 > l - } else { - yyb21 = r.CheckBreak() - } - if yyb21 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastRestart = time.Time{} - } else { - yyv28 := &x.LastRestart - yym29 := z.DecBinary() - _ = yym29 - if false { - } else if yym30 := z.TimeRtidIfBinc(); yym30 != 0 { - r.DecodeBuiltin(yym30, yyv28) - } else if z.HasExtensions() && z.DecExt(yyv28) { - } else if yym29 { - z.DecBinaryUnmarshal(yyv28) - } else if !yym29 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv28) - } else { - z.DecFallback(yyv28, false) - } - } - yyj21++ - if yyhl21 { - yyb21 = yyj21 > l - } else { - yyb21 = r.CheckBreak() - } - if yyb21 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.StartedAt = time.Time{} - } else { - yyv31 := &x.StartedAt - yym32 := z.DecBinary() - _ = yym32 - if false { - } else if yym33 := z.TimeRtidIfBinc(); yym33 != 0 { - r.DecodeBuiltin(yym33, yyv31) - } else if z.HasExtensions() && z.DecExt(yyv31) { - } else if yym32 { - z.DecBinaryUnmarshal(yyv31) - } else if !yym32 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv31) - } else { - z.DecFallback(yyv31, false) - } - } - yyj21++ - if yyhl21 { - yyb21 = yyj21 > l - } else { - yyb21 = r.CheckBreak() - } - if yyb21 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.FinishedAt = time.Time{} - } else { - yyv34 := &x.FinishedAt - yym35 := z.DecBinary() - _ = yym35 - if false { - } else if yym36 := z.TimeRtidIfBinc(); yym36 != 0 { - r.DecodeBuiltin(yym36, yyv34) - } else if z.HasExtensions() && z.DecExt(yyv34) { - } else if yym35 { - z.DecBinaryUnmarshal(yyv34) - } else if !yym35 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv34) - } else { - z.DecFallback(yyv34, false) - } - } - yyj21++ - if yyhl21 { - yyb21 = yyj21 > l - } else { - yyb21 = r.CheckBreak() - } - if yyb21 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Events = nil - } else { - yyv37 := &x.Events - yym38 := z.DecBinary() - _ = yym38 - if false { - } else { - h.decSlicePtrtoTaskEvent((*[]*TaskEvent)(yyv37), d) - } - } - for { - yyj21++ - if yyhl21 { - yyb21 = yyj21 > l - } else { - yyb21 = r.CheckBreak() - } - if yyb21 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj21-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *TaskEvent) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [24]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(24) - } else { - yynn2 = 24 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Type)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Type")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Type)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeInt(int64(x.Time)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Time")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeInt(int64(x.Time)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Message)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Message")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Message)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DisplayMessage)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DisplayMessage")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DisplayMessage)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Details == nil { - r.EncodeNil() - } else { - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - z.F.EncMapStringStringV(x.Details, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Details")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Details == nil { - r.EncodeNil() - } else { - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - z.F.EncMapStringStringV(x.Details, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeBool(bool(x.FailsTask)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("FailsTask")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeBool(bool(x.FailsTask)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.RestartReason)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("RestartReason")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.RestartReason)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.SetupError)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("SetupError")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.SetupError)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym28 := z.EncBinary() - _ = yym28 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DriverError)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DriverError")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym29 := z.EncBinary() - _ = yym29 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DriverError)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym31 := z.EncBinary() - _ = yym31 - if false { - } else { - r.EncodeInt(int64(x.ExitCode)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ExitCode")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym32 := z.EncBinary() - _ = yym32 - if false { - } else { - r.EncodeInt(int64(x.ExitCode)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym34 := z.EncBinary() - _ = yym34 - if false { - } else { - r.EncodeInt(int64(x.Signal)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Signal")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym35 := z.EncBinary() - _ = yym35 - if false { - } else { - r.EncodeInt(int64(x.Signal)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym37 := z.EncBinary() - _ = yym37 - if false { - } else if z.HasExtensions() && z.EncExt(x.KillTimeout) { - } else { - r.EncodeInt(int64(x.KillTimeout)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KillTimeout")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym38 := z.EncBinary() - _ = yym38 - if false { - } else if z.HasExtensions() && z.EncExt(x.KillTimeout) { - } else { - r.EncodeInt(int64(x.KillTimeout)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym40 := z.EncBinary() - _ = yym40 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.KillError)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KillError")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym41 := z.EncBinary() - _ = yym41 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.KillError)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym43 := z.EncBinary() - _ = yym43 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.KillReason)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KillReason")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym44 := z.EncBinary() - _ = yym44 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.KillReason)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym46 := z.EncBinary() - _ = yym46 - if false { - } else { - r.EncodeInt(int64(x.StartDelay)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("StartDelay")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym47 := z.EncBinary() - _ = yym47 - if false { - } else { - r.EncodeInt(int64(x.StartDelay)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym49 := z.EncBinary() - _ = yym49 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DownloadError)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DownloadError")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym50 := z.EncBinary() - _ = yym50 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DownloadError)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym52 := z.EncBinary() - _ = yym52 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ValidationError)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ValidationError")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym53 := z.EncBinary() - _ = yym53 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ValidationError)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym55 := z.EncBinary() - _ = yym55 - if false { - } else { - r.EncodeInt(int64(x.DiskLimit)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DiskLimit")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym56 := z.EncBinary() - _ = yym56 - if false { - } else { - r.EncodeInt(int64(x.DiskLimit)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym58 := z.EncBinary() - _ = yym58 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.FailedSibling)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("FailedSibling")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym59 := z.EncBinary() - _ = yym59 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.FailedSibling)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym61 := z.EncBinary() - _ = yym61 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.VaultError)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("VaultError")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym62 := z.EncBinary() - _ = yym62 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.VaultError)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym64 := z.EncBinary() - _ = yym64 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.TaskSignalReason)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("TaskSignalReason")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym65 := z.EncBinary() - _ = yym65 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.TaskSignalReason)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym67 := z.EncBinary() - _ = yym67 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.TaskSignal)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("TaskSignal")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym68 := z.EncBinary() - _ = yym68 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.TaskSignal)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym70 := z.EncBinary() - _ = yym70 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DriverMessage)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DriverMessage")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym71 := z.EncBinary() - _ = yym71 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DriverMessage)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym73 := z.EncBinary() - _ = yym73 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.GenericSource)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("GenericSource")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym74 := z.EncBinary() - _ = yym74 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.GenericSource)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *TaskEvent) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *TaskEvent) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - yyv4 := &x.Type - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Time": - if r.TryDecodeAsNil() { - x.Time = 0 - } else { - yyv6 := &x.Time - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*int64)(yyv6)) = int64(r.DecodeInt(64)) - } - } - case "Message": - if r.TryDecodeAsNil() { - x.Message = "" - } else { - yyv8 := &x.Message - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "DisplayMessage": - if r.TryDecodeAsNil() { - x.DisplayMessage = "" - } else { - yyv10 := &x.DisplayMessage - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "Details": - if r.TryDecodeAsNil() { - x.Details = nil - } else { - yyv12 := &x.Details - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - z.F.DecMapStringStringX(yyv12, false, d) - } - } - case "FailsTask": - if r.TryDecodeAsNil() { - x.FailsTask = false - } else { - yyv14 := &x.FailsTask - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*bool)(yyv14)) = r.DecodeBool() - } - } - case "RestartReason": - if r.TryDecodeAsNil() { - x.RestartReason = "" - } else { - yyv16 := &x.RestartReason - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - case "SetupError": - if r.TryDecodeAsNil() { - x.SetupError = "" - } else { - yyv18 := &x.SetupError - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - case "DriverError": - if r.TryDecodeAsNil() { - x.DriverError = "" - } else { - yyv20 := &x.DriverError - yym21 := z.DecBinary() - _ = yym21 - if false { - } else { - *((*string)(yyv20)) = r.DecodeString() - } - } - case "ExitCode": - if r.TryDecodeAsNil() { - x.ExitCode = 0 - } else { - yyv22 := &x.ExitCode - yym23 := z.DecBinary() - _ = yym23 - if false { - } else { - *((*int)(yyv22)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "Signal": - if r.TryDecodeAsNil() { - x.Signal = 0 - } else { - yyv24 := &x.Signal - yym25 := z.DecBinary() - _ = yym25 - if false { - } else { - *((*int)(yyv24)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "KillTimeout": - if r.TryDecodeAsNil() { - x.KillTimeout = 0 - } else { - yyv26 := &x.KillTimeout - yym27 := z.DecBinary() - _ = yym27 - if false { - } else if z.HasExtensions() && z.DecExt(yyv26) { - } else { - *((*int64)(yyv26)) = int64(r.DecodeInt(64)) - } - } - case "KillError": - if r.TryDecodeAsNil() { - x.KillError = "" - } else { - yyv28 := &x.KillError - yym29 := z.DecBinary() - _ = yym29 - if false { - } else { - *((*string)(yyv28)) = r.DecodeString() - } - } - case "KillReason": - if r.TryDecodeAsNil() { - x.KillReason = "" - } else { - yyv30 := &x.KillReason - yym31 := z.DecBinary() - _ = yym31 - if false { - } else { - *((*string)(yyv30)) = r.DecodeString() - } - } - case "StartDelay": - if r.TryDecodeAsNil() { - x.StartDelay = 0 - } else { - yyv32 := &x.StartDelay - yym33 := z.DecBinary() - _ = yym33 - if false { - } else { - *((*int64)(yyv32)) = int64(r.DecodeInt(64)) - } - } - case "DownloadError": - if r.TryDecodeAsNil() { - x.DownloadError = "" - } else { - yyv34 := &x.DownloadError - yym35 := z.DecBinary() - _ = yym35 - if false { - } else { - *((*string)(yyv34)) = r.DecodeString() - } - } - case "ValidationError": - if r.TryDecodeAsNil() { - x.ValidationError = "" - } else { - yyv36 := &x.ValidationError - yym37 := z.DecBinary() - _ = yym37 - if false { - } else { - *((*string)(yyv36)) = r.DecodeString() - } - } - case "DiskLimit": - if r.TryDecodeAsNil() { - x.DiskLimit = 0 - } else { - yyv38 := &x.DiskLimit - yym39 := z.DecBinary() - _ = yym39 - if false { - } else { - *((*int64)(yyv38)) = int64(r.DecodeInt(64)) - } - } - case "FailedSibling": - if r.TryDecodeAsNil() { - x.FailedSibling = "" - } else { - yyv40 := &x.FailedSibling - yym41 := z.DecBinary() - _ = yym41 - if false { - } else { - *((*string)(yyv40)) = r.DecodeString() - } - } - case "VaultError": - if r.TryDecodeAsNil() { - x.VaultError = "" - } else { - yyv42 := &x.VaultError - yym43 := z.DecBinary() - _ = yym43 - if false { - } else { - *((*string)(yyv42)) = r.DecodeString() - } - } - case "TaskSignalReason": - if r.TryDecodeAsNil() { - x.TaskSignalReason = "" - } else { - yyv44 := &x.TaskSignalReason - yym45 := z.DecBinary() - _ = yym45 - if false { - } else { - *((*string)(yyv44)) = r.DecodeString() - } - } - case "TaskSignal": - if r.TryDecodeAsNil() { - x.TaskSignal = "" - } else { - yyv46 := &x.TaskSignal - yym47 := z.DecBinary() - _ = yym47 - if false { - } else { - *((*string)(yyv46)) = r.DecodeString() - } - } - case "DriverMessage": - if r.TryDecodeAsNil() { - x.DriverMessage = "" - } else { - yyv48 := &x.DriverMessage - yym49 := z.DecBinary() - _ = yym49 - if false { - } else { - *((*string)(yyv48)) = r.DecodeString() - } - } - case "GenericSource": - if r.TryDecodeAsNil() { - x.GenericSource = "" - } else { - yyv50 := &x.GenericSource - yym51 := z.DecBinary() - _ = yym51 - if false { - } else { - *((*string)(yyv50)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *TaskEvent) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj52 int - var yyb52 bool - var yyhl52 bool = l >= 0 - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - yyv53 := &x.Type - yym54 := z.DecBinary() - _ = yym54 - if false { - } else { - *((*string)(yyv53)) = r.DecodeString() - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Time = 0 - } else { - yyv55 := &x.Time - yym56 := z.DecBinary() - _ = yym56 - if false { - } else { - *((*int64)(yyv55)) = int64(r.DecodeInt(64)) - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - yyv57 := &x.Message - yym58 := z.DecBinary() - _ = yym58 - if false { - } else { - *((*string)(yyv57)) = r.DecodeString() - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DisplayMessage = "" - } else { - yyv59 := &x.DisplayMessage - yym60 := z.DecBinary() - _ = yym60 - if false { - } else { - *((*string)(yyv59)) = r.DecodeString() - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Details = nil - } else { - yyv61 := &x.Details - yym62 := z.DecBinary() - _ = yym62 - if false { - } else { - z.F.DecMapStringStringX(yyv61, false, d) - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.FailsTask = false - } else { - yyv63 := &x.FailsTask - yym64 := z.DecBinary() - _ = yym64 - if false { - } else { - *((*bool)(yyv63)) = r.DecodeBool() - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.RestartReason = "" - } else { - yyv65 := &x.RestartReason - yym66 := z.DecBinary() - _ = yym66 - if false { - } else { - *((*string)(yyv65)) = r.DecodeString() - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.SetupError = "" - } else { - yyv67 := &x.SetupError - yym68 := z.DecBinary() - _ = yym68 - if false { - } else { - *((*string)(yyv67)) = r.DecodeString() - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DriverError = "" - } else { - yyv69 := &x.DriverError - yym70 := z.DecBinary() - _ = yym70 - if false { - } else { - *((*string)(yyv69)) = r.DecodeString() - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ExitCode = 0 - } else { - yyv71 := &x.ExitCode - yym72 := z.DecBinary() - _ = yym72 - if false { - } else { - *((*int)(yyv71)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Signal = 0 - } else { - yyv73 := &x.Signal - yym74 := z.DecBinary() - _ = yym74 - if false { - } else { - *((*int)(yyv73)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KillTimeout = 0 - } else { - yyv75 := &x.KillTimeout - yym76 := z.DecBinary() - _ = yym76 - if false { - } else if z.HasExtensions() && z.DecExt(yyv75) { - } else { - *((*int64)(yyv75)) = int64(r.DecodeInt(64)) - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KillError = "" - } else { - yyv77 := &x.KillError - yym78 := z.DecBinary() - _ = yym78 - if false { - } else { - *((*string)(yyv77)) = r.DecodeString() - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KillReason = "" - } else { - yyv79 := &x.KillReason - yym80 := z.DecBinary() - _ = yym80 - if false { - } else { - *((*string)(yyv79)) = r.DecodeString() - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.StartDelay = 0 - } else { - yyv81 := &x.StartDelay - yym82 := z.DecBinary() - _ = yym82 - if false { - } else { - *((*int64)(yyv81)) = int64(r.DecodeInt(64)) - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DownloadError = "" - } else { - yyv83 := &x.DownloadError - yym84 := z.DecBinary() - _ = yym84 - if false { - } else { - *((*string)(yyv83)) = r.DecodeString() - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ValidationError = "" - } else { - yyv85 := &x.ValidationError - yym86 := z.DecBinary() - _ = yym86 - if false { - } else { - *((*string)(yyv85)) = r.DecodeString() - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DiskLimit = 0 - } else { - yyv87 := &x.DiskLimit - yym88 := z.DecBinary() - _ = yym88 - if false { - } else { - *((*int64)(yyv87)) = int64(r.DecodeInt(64)) - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.FailedSibling = "" - } else { - yyv89 := &x.FailedSibling - yym90 := z.DecBinary() - _ = yym90 - if false { - } else { - *((*string)(yyv89)) = r.DecodeString() - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.VaultError = "" - } else { - yyv91 := &x.VaultError - yym92 := z.DecBinary() - _ = yym92 - if false { - } else { - *((*string)(yyv91)) = r.DecodeString() - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.TaskSignalReason = "" - } else { - yyv93 := &x.TaskSignalReason - yym94 := z.DecBinary() - _ = yym94 - if false { - } else { - *((*string)(yyv93)) = r.DecodeString() - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.TaskSignal = "" - } else { - yyv95 := &x.TaskSignal - yym96 := z.DecBinary() - _ = yym96 - if false { - } else { - *((*string)(yyv95)) = r.DecodeString() - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DriverMessage = "" - } else { - yyv97 := &x.DriverMessage - yym98 := z.DecBinary() - _ = yym98 - if false { - } else { - *((*string)(yyv97)) = r.DecodeString() - } - } - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.GenericSource = "" - } else { - yyv99 := &x.GenericSource - yym100 := z.DecBinary() - _ = yym100 - if false { - } else { - *((*string)(yyv99)) = r.DecodeString() - } - } - for { - yyj52++ - if yyhl52 { - yyb52 = yyj52 > l - } else { - yyb52 = r.CheckBreak() - } - if yyb52 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj52-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *TaskArtifact) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.GetterSource)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("GetterSource")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.GetterSource)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.GetterOptions == nil { - r.EncodeNil() - } else { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - z.F.EncMapStringStringV(x.GetterOptions, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("GetterOptions")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.GetterOptions == nil { - r.EncodeNil() - } else { - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - z.F.EncMapStringStringV(x.GetterOptions, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.GetterMode)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("GetterMode")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.GetterMode)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.RelativeDest)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("RelativeDest")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.RelativeDest)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *TaskArtifact) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *TaskArtifact) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "GetterSource": - if r.TryDecodeAsNil() { - x.GetterSource = "" - } else { - yyv4 := &x.GetterSource - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "GetterOptions": - if r.TryDecodeAsNil() { - x.GetterOptions = nil - } else { - yyv6 := &x.GetterOptions - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - z.F.DecMapStringStringX(yyv6, false, d) - } - } - case "GetterMode": - if r.TryDecodeAsNil() { - x.GetterMode = "" - } else { - yyv8 := &x.GetterMode - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "RelativeDest": - if r.TryDecodeAsNil() { - x.RelativeDest = "" - } else { - yyv10 := &x.RelativeDest - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *TaskArtifact) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.GetterSource = "" - } else { - yyv13 := &x.GetterSource - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*string)(yyv13)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.GetterOptions = nil - } else { - yyv15 := &x.GetterOptions - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - z.F.DecMapStringStringX(yyv15, false, d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.GetterMode = "" - } else { - yyv17 := &x.GetterMode - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.RelativeDest = "" - } else { - yyv19 := &x.RelativeDest - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *Constraint) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [3]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(3) - } else { - yynn2 = 3 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.LTarget)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LTarget")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.LTarget)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.RTarget)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("RTarget")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.RTarget)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Operand)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Operand")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Operand)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *Constraint) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *Constraint) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "LTarget": - if r.TryDecodeAsNil() { - x.LTarget = "" - } else { - yyv4 := &x.LTarget - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "RTarget": - if r.TryDecodeAsNil() { - x.RTarget = "" - } else { - yyv6 := &x.RTarget - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Operand": - if r.TryDecodeAsNil() { - x.Operand = "" - } else { - yyv8 := &x.Operand - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *Constraint) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj10 int - var yyb10 bool - var yyhl10 bool = l >= 0 - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LTarget = "" - } else { - yyv11 := &x.LTarget - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*string)(yyv11)) = r.DecodeString() - } - } - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.RTarget = "" - } else { - yyv13 := &x.RTarget - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*string)(yyv13)) = r.DecodeString() - } - } - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Operand = "" - } else { - yyv15 := &x.Operand - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - for { - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj10-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *EphemeralDisk) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [3]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(3) - } else { - yynn2 = 3 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeBool(bool(x.Sticky)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Sticky")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeBool(bool(x.Sticky)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeInt(int64(x.SizeMB)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("SizeMB")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeInt(int64(x.SizeMB)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeBool(bool(x.Migrate)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Migrate")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeBool(bool(x.Migrate)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *EphemeralDisk) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *EphemeralDisk) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Sticky": - if r.TryDecodeAsNil() { - x.Sticky = false - } else { - yyv4 := &x.Sticky - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*bool)(yyv4)) = r.DecodeBool() - } - } - case "SizeMB": - if r.TryDecodeAsNil() { - x.SizeMB = 0 - } else { - yyv6 := &x.SizeMB - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*int)(yyv6)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "Migrate": - if r.TryDecodeAsNil() { - x.Migrate = false - } else { - yyv8 := &x.Migrate - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*bool)(yyv8)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *EphemeralDisk) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj10 int - var yyb10 bool - var yyhl10 bool = l >= 0 - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Sticky = false - } else { - yyv11 := &x.Sticky - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*bool)(yyv11)) = r.DecodeBool() - } - } - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.SizeMB = 0 - } else { - yyv13 := &x.SizeMB - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*int)(yyv13)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Migrate = false - } else { - yyv15 := &x.Migrate - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*bool)(yyv15)) = r.DecodeBool() - } - } - for { - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj10-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *Vault) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Policies == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - z.F.EncSliceStringV(x.Policies, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Policies")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Policies == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - z.F.EncSliceStringV(x.Policies, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeBool(bool(x.Env)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Env")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeBool(bool(x.Env)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ChangeMode)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ChangeMode")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ChangeMode)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ChangeSignal)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ChangeSignal")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ChangeSignal)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *Vault) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *Vault) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Policies": - if r.TryDecodeAsNil() { - x.Policies = nil - } else { - yyv4 := &x.Policies - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - z.F.DecSliceStringX(yyv4, false, d) - } - } - case "Env": - if r.TryDecodeAsNil() { - x.Env = false - } else { - yyv6 := &x.Env - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*bool)(yyv6)) = r.DecodeBool() - } - } - case "ChangeMode": - if r.TryDecodeAsNil() { - x.ChangeMode = "" - } else { - yyv8 := &x.ChangeMode - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "ChangeSignal": - if r.TryDecodeAsNil() { - x.ChangeSignal = "" - } else { - yyv10 := &x.ChangeSignal - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *Vault) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Policies = nil - } else { - yyv13 := &x.Policies - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - z.F.DecSliceStringX(yyv13, false, d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Env = false - } else { - yyv15 := &x.Env - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*bool)(yyv15)) = r.DecodeBool() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ChangeMode = "" - } else { - yyv17 := &x.ChangeMode - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ChangeSignal = "" - } else { - yyv19 := &x.ChangeSignal - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *Deployment) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [11]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(11) - } else { - yynn2 = 11 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeUint(uint64(x.JobVersion)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeUint(uint64(x.JobVersion)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeUint(uint64(x.JobModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeUint(uint64(x.JobModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeUint(uint64(x.JobCreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobCreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeUint(uint64(x.JobCreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.TaskGroups == nil { - r.EncodeNil() - } else { - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - h.encMapstringPtrtoDeploymentState((map[string]*DeploymentState)(x.TaskGroups), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("TaskGroups")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.TaskGroups == nil { - r.EncodeNil() - } else { - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - h.encMapstringPtrtoDeploymentState((map[string]*DeploymentState)(x.TaskGroups), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Status)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Status")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Status)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym28 := z.EncBinary() - _ = yym28 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("StatusDescription")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym29 := z.EncBinary() - _ = yym29 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym31 := z.EncBinary() - _ = yym31 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym32 := z.EncBinary() - _ = yym32 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym34 := z.EncBinary() - _ = yym34 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym35 := z.EncBinary() - _ = yym35 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *Deployment) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *Deployment) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "ID": - if r.TryDecodeAsNil() { - x.ID = "" - } else { - yyv4 := &x.ID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv6 := &x.Namespace - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "JobID": - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv8 := &x.JobID - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "JobVersion": - if r.TryDecodeAsNil() { - x.JobVersion = 0 - } else { - yyv10 := &x.JobVersion - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) - } - } - case "JobModifyIndex": - if r.TryDecodeAsNil() { - x.JobModifyIndex = 0 - } else { - yyv12 := &x.JobModifyIndex - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*uint64)(yyv12)) = uint64(r.DecodeUint(64)) - } - } - case "JobCreateIndex": - if r.TryDecodeAsNil() { - x.JobCreateIndex = 0 - } else { - yyv14 := &x.JobCreateIndex - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*uint64)(yyv14)) = uint64(r.DecodeUint(64)) - } - } - case "TaskGroups": - if r.TryDecodeAsNil() { - x.TaskGroups = nil - } else { - yyv16 := &x.TaskGroups - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - h.decMapstringPtrtoDeploymentState((*map[string]*DeploymentState)(yyv16), d) - } - } - case "Status": - if r.TryDecodeAsNil() { - x.Status = "" - } else { - yyv18 := &x.Status - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - case "StatusDescription": - if r.TryDecodeAsNil() { - x.StatusDescription = "" - } else { - yyv20 := &x.StatusDescription - yym21 := z.DecBinary() - _ = yym21 - if false { - } else { - *((*string)(yyv20)) = r.DecodeString() - } - } - case "CreateIndex": - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv22 := &x.CreateIndex - yym23 := z.DecBinary() - _ = yym23 - if false { - } else { - *((*uint64)(yyv22)) = uint64(r.DecodeUint(64)) - } - } - case "ModifyIndex": - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv24 := &x.ModifyIndex - yym25 := z.DecBinary() - _ = yym25 - if false { - } else { - *((*uint64)(yyv24)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *Deployment) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj26 int - var yyb26 bool - var yyhl26 bool = l >= 0 - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ID = "" - } else { - yyv27 := &x.ID - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*string)(yyv27)) = r.DecodeString() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv29 := &x.Namespace - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*string)(yyv29)) = r.DecodeString() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv31 := &x.JobID - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*string)(yyv31)) = r.DecodeString() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobVersion = 0 - } else { - yyv33 := &x.JobVersion - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - *((*uint64)(yyv33)) = uint64(r.DecodeUint(64)) - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobModifyIndex = 0 - } else { - yyv35 := &x.JobModifyIndex - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*uint64)(yyv35)) = uint64(r.DecodeUint(64)) - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobCreateIndex = 0 - } else { - yyv37 := &x.JobCreateIndex - yym38 := z.DecBinary() - _ = yym38 - if false { - } else { - *((*uint64)(yyv37)) = uint64(r.DecodeUint(64)) - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.TaskGroups = nil - } else { - yyv39 := &x.TaskGroups - yym40 := z.DecBinary() - _ = yym40 - if false { - } else { - h.decMapstringPtrtoDeploymentState((*map[string]*DeploymentState)(yyv39), d) - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - yyv41 := &x.Status - yym42 := z.DecBinary() - _ = yym42 - if false { - } else { - *((*string)(yyv41)) = r.DecodeString() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.StatusDescription = "" - } else { - yyv43 := &x.StatusDescription - yym44 := z.DecBinary() - _ = yym44 - if false { - } else { - *((*string)(yyv43)) = r.DecodeString() - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv45 := &x.CreateIndex - yym46 := z.DecBinary() - _ = yym46 - if false { - } else { - *((*uint64)(yyv45)) = uint64(r.DecodeUint(64)) - } - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv47 := &x.ModifyIndex - yym48 := z.DecBinary() - _ = yym48 - if false { - } else { - *((*uint64)(yyv47)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj26-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *DeploymentState) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [8]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(8) - } else { - yynn2 = 8 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeBool(bool(x.AutoRevert)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AutoRevert")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeBool(bool(x.AutoRevert)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeBool(bool(x.Promoted)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Promoted")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeBool(bool(x.Promoted)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.PlacedCanaries == nil { - r.EncodeNil() - } else { - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - z.F.EncSliceStringV(x.PlacedCanaries, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("PlacedCanaries")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.PlacedCanaries == nil { - r.EncodeNil() - } else { - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - z.F.EncSliceStringV(x.PlacedCanaries, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeInt(int64(x.DesiredCanaries)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DesiredCanaries")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeInt(int64(x.DesiredCanaries)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeInt(int64(x.DesiredTotal)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DesiredTotal")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeInt(int64(x.DesiredTotal)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeInt(int64(x.PlacedAllocs)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("PlacedAllocs")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeInt(int64(x.PlacedAllocs)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeInt(int64(x.HealthyAllocs)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("HealthyAllocs")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeInt(int64(x.HealthyAllocs)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeInt(int64(x.UnhealthyAllocs)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("UnhealthyAllocs")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeInt(int64(x.UnhealthyAllocs)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *DeploymentState) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *DeploymentState) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "AutoRevert": - if r.TryDecodeAsNil() { - x.AutoRevert = false - } else { - yyv4 := &x.AutoRevert - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*bool)(yyv4)) = r.DecodeBool() - } - } - case "Promoted": - if r.TryDecodeAsNil() { - x.Promoted = false - } else { - yyv6 := &x.Promoted - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*bool)(yyv6)) = r.DecodeBool() - } - } - case "PlacedCanaries": - if r.TryDecodeAsNil() { - x.PlacedCanaries = nil - } else { - yyv8 := &x.PlacedCanaries - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - z.F.DecSliceStringX(yyv8, false, d) - } - } - case "DesiredCanaries": - if r.TryDecodeAsNil() { - x.DesiredCanaries = 0 - } else { - yyv10 := &x.DesiredCanaries - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*int)(yyv10)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "DesiredTotal": - if r.TryDecodeAsNil() { - x.DesiredTotal = 0 - } else { - yyv12 := &x.DesiredTotal - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*int)(yyv12)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "PlacedAllocs": - if r.TryDecodeAsNil() { - x.PlacedAllocs = 0 - } else { - yyv14 := &x.PlacedAllocs - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*int)(yyv14)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "HealthyAllocs": - if r.TryDecodeAsNil() { - x.HealthyAllocs = 0 - } else { - yyv16 := &x.HealthyAllocs - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*int)(yyv16)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "UnhealthyAllocs": - if r.TryDecodeAsNil() { - x.UnhealthyAllocs = 0 - } else { - yyv18 := &x.UnhealthyAllocs - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*int)(yyv18)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *DeploymentState) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj20 int - var yyb20 bool - var yyhl20 bool = l >= 0 - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AutoRevert = false - } else { - yyv21 := &x.AutoRevert - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*bool)(yyv21)) = r.DecodeBool() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Promoted = false - } else { - yyv23 := &x.Promoted - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*bool)(yyv23)) = r.DecodeBool() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.PlacedCanaries = nil - } else { - yyv25 := &x.PlacedCanaries - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - z.F.DecSliceStringX(yyv25, false, d) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DesiredCanaries = 0 - } else { - yyv27 := &x.DesiredCanaries - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*int)(yyv27)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DesiredTotal = 0 - } else { - yyv29 := &x.DesiredTotal - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*int)(yyv29)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.PlacedAllocs = 0 - } else { - yyv31 := &x.PlacedAllocs - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*int)(yyv31)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.HealthyAllocs = 0 - } else { - yyv33 := &x.HealthyAllocs - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - *((*int)(yyv33)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.UnhealthyAllocs = 0 - } else { - yyv35 := &x.UnhealthyAllocs - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*int)(yyv35)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - for { - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj20-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *DeploymentStatusUpdate) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [3]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(3) - } else { - yynn2 = 3 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DeploymentID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Status)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Status")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Status)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("StatusDescription")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *DeploymentStatusUpdate) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *DeploymentStatusUpdate) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "DeploymentID": - if r.TryDecodeAsNil() { - x.DeploymentID = "" - } else { - yyv4 := &x.DeploymentID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Status": - if r.TryDecodeAsNil() { - x.Status = "" - } else { - yyv6 := &x.Status - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "StatusDescription": - if r.TryDecodeAsNil() { - x.StatusDescription = "" - } else { - yyv8 := &x.StatusDescription - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *DeploymentStatusUpdate) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj10 int - var yyb10 bool - var yyhl10 bool = l >= 0 - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DeploymentID = "" - } else { - yyv11 := &x.DeploymentID - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*string)(yyv11)) = r.DecodeString() - } - } - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - yyv13 := &x.Status - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*string)(yyv13)) = r.DecodeString() - } - } - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.StatusDescription = "" - } else { - yyv15 := &x.StatusDescription - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - for { - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj10-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *Allocation) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [25]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(25) - } else { - yynn2 = 25 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Name")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodeID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Job == nil { - r.EncodeNil() - } else { - x.Job.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Job")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Job == nil { - r.EncodeNil() - } else { - x.Job.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.TaskGroup)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("TaskGroup")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.TaskGroup)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Resources == nil { - r.EncodeNil() - } else { - x.Resources.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Resources")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Resources == nil { - r.EncodeNil() - } else { - x.Resources.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.SharedResources == nil { - r.EncodeNil() - } else { - x.SharedResources.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("SharedResources")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.SharedResources == nil { - r.EncodeNil() - } else { - x.SharedResources.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.TaskResources == nil { - r.EncodeNil() - } else { - yym34 := z.EncBinary() - _ = yym34 - if false { - } else { - h.encMapstringPtrtoResources((map[string]*Resources)(x.TaskResources), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("TaskResources")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.TaskResources == nil { - r.EncodeNil() - } else { - yym35 := z.EncBinary() - _ = yym35 - if false { - } else { - h.encMapstringPtrtoResources((map[string]*Resources)(x.TaskResources), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Metrics == nil { - r.EncodeNil() - } else { - x.Metrics.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Metrics")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Metrics == nil { - r.EncodeNil() - } else { - x.Metrics.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym40 := z.EncBinary() - _ = yym40 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DesiredStatus)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DesiredStatus")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym41 := z.EncBinary() - _ = yym41 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DesiredStatus)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym43 := z.EncBinary() - _ = yym43 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DesiredDescription)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DesiredDescription")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym44 := z.EncBinary() - _ = yym44 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DesiredDescription)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym46 := z.EncBinary() - _ = yym46 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ClientStatus)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ClientStatus")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym47 := z.EncBinary() - _ = yym47 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ClientStatus)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym49 := z.EncBinary() - _ = yym49 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ClientDescription)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ClientDescription")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym50 := z.EncBinary() - _ = yym50 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ClientDescription)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.TaskStates == nil { - r.EncodeNil() - } else { - yym52 := z.EncBinary() - _ = yym52 - if false { - } else { - h.encMapstringPtrtoTaskState((map[string]*TaskState)(x.TaskStates), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("TaskStates")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.TaskStates == nil { - r.EncodeNil() - } else { - yym53 := z.EncBinary() - _ = yym53 - if false { - } else { - h.encMapstringPtrtoTaskState((map[string]*TaskState)(x.TaskStates), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym55 := z.EncBinary() - _ = yym55 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.PreviousAllocation)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("PreviousAllocation")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym56 := z.EncBinary() - _ = yym56 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.PreviousAllocation)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym58 := z.EncBinary() - _ = yym58 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DeploymentID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym59 := z.EncBinary() - _ = yym59 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.DeploymentStatus == nil { - r.EncodeNil() - } else { - x.DeploymentStatus.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DeploymentStatus")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.DeploymentStatus == nil { - r.EncodeNil() - } else { - x.DeploymentStatus.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym64 := z.EncBinary() - _ = yym64 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym65 := z.EncBinary() - _ = yym65 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym67 := z.EncBinary() - _ = yym67 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym68 := z.EncBinary() - _ = yym68 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym70 := z.EncBinary() - _ = yym70 - if false { - } else { - r.EncodeUint(uint64(x.AllocModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllocModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym71 := z.EncBinary() - _ = yym71 - if false { - } else { - r.EncodeUint(uint64(x.AllocModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym73 := z.EncBinary() - _ = yym73 - if false { - } else { - r.EncodeInt(int64(x.CreateTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CreateTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym74 := z.EncBinary() - _ = yym74 - if false { - } else { - r.EncodeInt(int64(x.CreateTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym76 := z.EncBinary() - _ = yym76 - if false { - } else { - r.EncodeInt(int64(x.ModifyTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ModifyTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym77 := z.EncBinary() - _ = yym77 - if false { - } else { - r.EncodeInt(int64(x.ModifyTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *Allocation) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *Allocation) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "ID": - if r.TryDecodeAsNil() { - x.ID = "" - } else { - yyv4 := &x.ID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv6 := &x.Namespace - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "EvalID": - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv8 := &x.EvalID - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv10 := &x.Name - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "NodeID": - if r.TryDecodeAsNil() { - x.NodeID = "" - } else { - yyv12 := &x.NodeID - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - case "JobID": - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv14 := &x.JobID - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*string)(yyv14)) = r.DecodeString() - } - } - case "Job": - if r.TryDecodeAsNil() { - if x.Job != nil { - x.Job = nil - } - } else { - if x.Job == nil { - x.Job = new(Job) - } - x.Job.CodecDecodeSelf(d) - } - case "TaskGroup": - if r.TryDecodeAsNil() { - x.TaskGroup = "" - } else { - yyv17 := &x.TaskGroup - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - case "Resources": - if r.TryDecodeAsNil() { - if x.Resources != nil { - x.Resources = nil - } - } else { - if x.Resources == nil { - x.Resources = new(Resources) - } - x.Resources.CodecDecodeSelf(d) - } - case "SharedResources": - if r.TryDecodeAsNil() { - if x.SharedResources != nil { - x.SharedResources = nil - } - } else { - if x.SharedResources == nil { - x.SharedResources = new(Resources) - } - x.SharedResources.CodecDecodeSelf(d) - } - case "TaskResources": - if r.TryDecodeAsNil() { - x.TaskResources = nil - } else { - yyv21 := &x.TaskResources - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - h.decMapstringPtrtoResources((*map[string]*Resources)(yyv21), d) - } - } - case "Metrics": - if r.TryDecodeAsNil() { - if x.Metrics != nil { - x.Metrics = nil - } - } else { - if x.Metrics == nil { - x.Metrics = new(AllocMetric) - } - x.Metrics.CodecDecodeSelf(d) - } - case "DesiredStatus": - if r.TryDecodeAsNil() { - x.DesiredStatus = "" - } else { - yyv24 := &x.DesiredStatus - yym25 := z.DecBinary() - _ = yym25 - if false { - } else { - *((*string)(yyv24)) = r.DecodeString() - } - } - case "DesiredDescription": - if r.TryDecodeAsNil() { - x.DesiredDescription = "" - } else { - yyv26 := &x.DesiredDescription - yym27 := z.DecBinary() - _ = yym27 - if false { - } else { - *((*string)(yyv26)) = r.DecodeString() - } - } - case "ClientStatus": - if r.TryDecodeAsNil() { - x.ClientStatus = "" - } else { - yyv28 := &x.ClientStatus - yym29 := z.DecBinary() - _ = yym29 - if false { - } else { - *((*string)(yyv28)) = r.DecodeString() - } - } - case "ClientDescription": - if r.TryDecodeAsNil() { - x.ClientDescription = "" - } else { - yyv30 := &x.ClientDescription - yym31 := z.DecBinary() - _ = yym31 - if false { - } else { - *((*string)(yyv30)) = r.DecodeString() - } - } - case "TaskStates": - if r.TryDecodeAsNil() { - x.TaskStates = nil - } else { - yyv32 := &x.TaskStates - yym33 := z.DecBinary() - _ = yym33 - if false { - } else { - h.decMapstringPtrtoTaskState((*map[string]*TaskState)(yyv32), d) - } - } - case "PreviousAllocation": - if r.TryDecodeAsNil() { - x.PreviousAllocation = "" - } else { - yyv34 := &x.PreviousAllocation - yym35 := z.DecBinary() - _ = yym35 - if false { - } else { - *((*string)(yyv34)) = r.DecodeString() - } - } - case "DeploymentID": - if r.TryDecodeAsNil() { - x.DeploymentID = "" - } else { - yyv36 := &x.DeploymentID - yym37 := z.DecBinary() - _ = yym37 - if false { - } else { - *((*string)(yyv36)) = r.DecodeString() - } - } - case "DeploymentStatus": - if r.TryDecodeAsNil() { - if x.DeploymentStatus != nil { - x.DeploymentStatus = nil - } - } else { - if x.DeploymentStatus == nil { - x.DeploymentStatus = new(AllocDeploymentStatus) - } - x.DeploymentStatus.CodecDecodeSelf(d) - } - case "CreateIndex": - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv39 := &x.CreateIndex - yym40 := z.DecBinary() - _ = yym40 - if false { - } else { - *((*uint64)(yyv39)) = uint64(r.DecodeUint(64)) - } - } - case "ModifyIndex": - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv41 := &x.ModifyIndex - yym42 := z.DecBinary() - _ = yym42 - if false { - } else { - *((*uint64)(yyv41)) = uint64(r.DecodeUint(64)) - } - } - case "AllocModifyIndex": - if r.TryDecodeAsNil() { - x.AllocModifyIndex = 0 - } else { - yyv43 := &x.AllocModifyIndex - yym44 := z.DecBinary() - _ = yym44 - if false { - } else { - *((*uint64)(yyv43)) = uint64(r.DecodeUint(64)) - } - } - case "CreateTime": - if r.TryDecodeAsNil() { - x.CreateTime = 0 - } else { - yyv45 := &x.CreateTime - yym46 := z.DecBinary() - _ = yym46 - if false { - } else { - *((*int64)(yyv45)) = int64(r.DecodeInt(64)) - } - } - case "ModifyTime": - if r.TryDecodeAsNil() { - x.ModifyTime = 0 - } else { - yyv47 := &x.ModifyTime - yym48 := z.DecBinary() - _ = yym48 - if false { - } else { - *((*int64)(yyv47)) = int64(r.DecodeInt(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *Allocation) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj49 int - var yyb49 bool - var yyhl49 bool = l >= 0 - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ID = "" - } else { - yyv50 := &x.ID - yym51 := z.DecBinary() - _ = yym51 - if false { - } else { - *((*string)(yyv50)) = r.DecodeString() - } - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv52 := &x.Namespace - yym53 := z.DecBinary() - _ = yym53 - if false { - } else { - *((*string)(yyv52)) = r.DecodeString() - } - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv54 := &x.EvalID - yym55 := z.DecBinary() - _ = yym55 - if false { - } else { - *((*string)(yyv54)) = r.DecodeString() - } - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv56 := &x.Name - yym57 := z.DecBinary() - _ = yym57 - if false { - } else { - *((*string)(yyv56)) = r.DecodeString() - } - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodeID = "" - } else { - yyv58 := &x.NodeID - yym59 := z.DecBinary() - _ = yym59 - if false { - } else { - *((*string)(yyv58)) = r.DecodeString() - } - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv60 := &x.JobID - yym61 := z.DecBinary() - _ = yym61 - if false { - } else { - *((*string)(yyv60)) = r.DecodeString() - } - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Job != nil { - x.Job = nil - } - } else { - if x.Job == nil { - x.Job = new(Job) - } - x.Job.CodecDecodeSelf(d) - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.TaskGroup = "" - } else { - yyv63 := &x.TaskGroup - yym64 := z.DecBinary() - _ = yym64 - if false { - } else { - *((*string)(yyv63)) = r.DecodeString() - } - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Resources != nil { - x.Resources = nil - } - } else { - if x.Resources == nil { - x.Resources = new(Resources) - } - x.Resources.CodecDecodeSelf(d) - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.SharedResources != nil { - x.SharedResources = nil - } - } else { - if x.SharedResources == nil { - x.SharedResources = new(Resources) - } - x.SharedResources.CodecDecodeSelf(d) - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.TaskResources = nil - } else { - yyv67 := &x.TaskResources - yym68 := z.DecBinary() - _ = yym68 - if false { - } else { - h.decMapstringPtrtoResources((*map[string]*Resources)(yyv67), d) - } - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Metrics != nil { - x.Metrics = nil - } - } else { - if x.Metrics == nil { - x.Metrics = new(AllocMetric) - } - x.Metrics.CodecDecodeSelf(d) - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DesiredStatus = "" - } else { - yyv70 := &x.DesiredStatus - yym71 := z.DecBinary() - _ = yym71 - if false { - } else { - *((*string)(yyv70)) = r.DecodeString() - } - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DesiredDescription = "" - } else { - yyv72 := &x.DesiredDescription - yym73 := z.DecBinary() - _ = yym73 - if false { - } else { - *((*string)(yyv72)) = r.DecodeString() - } - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ClientStatus = "" - } else { - yyv74 := &x.ClientStatus - yym75 := z.DecBinary() - _ = yym75 - if false { - } else { - *((*string)(yyv74)) = r.DecodeString() - } - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ClientDescription = "" - } else { - yyv76 := &x.ClientDescription - yym77 := z.DecBinary() - _ = yym77 - if false { - } else { - *((*string)(yyv76)) = r.DecodeString() - } - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.TaskStates = nil - } else { - yyv78 := &x.TaskStates - yym79 := z.DecBinary() - _ = yym79 - if false { - } else { - h.decMapstringPtrtoTaskState((*map[string]*TaskState)(yyv78), d) - } - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.PreviousAllocation = "" - } else { - yyv80 := &x.PreviousAllocation - yym81 := z.DecBinary() - _ = yym81 - if false { - } else { - *((*string)(yyv80)) = r.DecodeString() - } - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DeploymentID = "" - } else { - yyv82 := &x.DeploymentID - yym83 := z.DecBinary() - _ = yym83 - if false { - } else { - *((*string)(yyv82)) = r.DecodeString() - } - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.DeploymentStatus != nil { - x.DeploymentStatus = nil - } - } else { - if x.DeploymentStatus == nil { - x.DeploymentStatus = new(AllocDeploymentStatus) - } - x.DeploymentStatus.CodecDecodeSelf(d) - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv85 := &x.CreateIndex - yym86 := z.DecBinary() - _ = yym86 - if false { - } else { - *((*uint64)(yyv85)) = uint64(r.DecodeUint(64)) - } - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv87 := &x.ModifyIndex - yym88 := z.DecBinary() - _ = yym88 - if false { - } else { - *((*uint64)(yyv87)) = uint64(r.DecodeUint(64)) - } - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllocModifyIndex = 0 - } else { - yyv89 := &x.AllocModifyIndex - yym90 := z.DecBinary() - _ = yym90 - if false { - } else { - *((*uint64)(yyv89)) = uint64(r.DecodeUint(64)) - } - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CreateTime = 0 - } else { - yyv91 := &x.CreateTime - yym92 := z.DecBinary() - _ = yym92 - if false { - } else { - *((*int64)(yyv91)) = int64(r.DecodeInt(64)) - } - } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ModifyTime = 0 - } else { - yyv93 := &x.ModifyTime - yym94 := z.DecBinary() - _ = yym94 - if false { - } else { - *((*int64)(yyv93)) = int64(r.DecodeInt(64)) - } - } - for { - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l - } else { - yyb49 = r.CheckBreak() - } - if yyb49 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj49-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *AllocListStub) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [17]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(17) - } else { - yynn2 = 17 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Name")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodeID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeUint(uint64(x.JobVersion)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeUint(uint64(x.JobVersion)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.TaskGroup)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("TaskGroup")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.TaskGroup)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DesiredStatus)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DesiredStatus")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DesiredStatus)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym28 := z.EncBinary() - _ = yym28 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DesiredDescription)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DesiredDescription")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym29 := z.EncBinary() - _ = yym29 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DesiredDescription)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym31 := z.EncBinary() - _ = yym31 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ClientStatus)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ClientStatus")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym32 := z.EncBinary() - _ = yym32 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ClientStatus)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym34 := z.EncBinary() - _ = yym34 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ClientDescription)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ClientDescription")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym35 := z.EncBinary() - _ = yym35 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ClientDescription)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.TaskStates == nil { - r.EncodeNil() - } else { - yym37 := z.EncBinary() - _ = yym37 - if false { - } else { - h.encMapstringPtrtoTaskState((map[string]*TaskState)(x.TaskStates), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("TaskStates")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.TaskStates == nil { - r.EncodeNil() - } else { - yym38 := z.EncBinary() - _ = yym38 - if false { - } else { - h.encMapstringPtrtoTaskState((map[string]*TaskState)(x.TaskStates), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.DeploymentStatus == nil { - r.EncodeNil() - } else { - x.DeploymentStatus.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DeploymentStatus")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.DeploymentStatus == nil { - r.EncodeNil() - } else { - x.DeploymentStatus.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym43 := z.EncBinary() - _ = yym43 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym44 := z.EncBinary() - _ = yym44 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym46 := z.EncBinary() - _ = yym46 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym47 := z.EncBinary() - _ = yym47 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym49 := z.EncBinary() - _ = yym49 - if false { - } else { - r.EncodeInt(int64(x.CreateTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CreateTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym50 := z.EncBinary() - _ = yym50 - if false { - } else { - r.EncodeInt(int64(x.CreateTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym52 := z.EncBinary() - _ = yym52 - if false { - } else { - r.EncodeInt(int64(x.ModifyTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ModifyTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym53 := z.EncBinary() - _ = yym53 - if false { - } else { - r.EncodeInt(int64(x.ModifyTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *AllocListStub) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *AllocListStub) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "ID": - if r.TryDecodeAsNil() { - x.ID = "" - } else { - yyv4 := &x.ID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "EvalID": - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv6 := &x.EvalID - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv8 := &x.Name - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "NodeID": - if r.TryDecodeAsNil() { - x.NodeID = "" - } else { - yyv10 := &x.NodeID - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "JobID": - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv12 := &x.JobID - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - case "JobVersion": - if r.TryDecodeAsNil() { - x.JobVersion = 0 - } else { - yyv14 := &x.JobVersion - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*uint64)(yyv14)) = uint64(r.DecodeUint(64)) - } - } - case "TaskGroup": - if r.TryDecodeAsNil() { - x.TaskGroup = "" - } else { - yyv16 := &x.TaskGroup - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - case "DesiredStatus": - if r.TryDecodeAsNil() { - x.DesiredStatus = "" - } else { - yyv18 := &x.DesiredStatus - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - case "DesiredDescription": - if r.TryDecodeAsNil() { - x.DesiredDescription = "" - } else { - yyv20 := &x.DesiredDescription - yym21 := z.DecBinary() - _ = yym21 - if false { - } else { - *((*string)(yyv20)) = r.DecodeString() - } - } - case "ClientStatus": - if r.TryDecodeAsNil() { - x.ClientStatus = "" - } else { - yyv22 := &x.ClientStatus - yym23 := z.DecBinary() - _ = yym23 - if false { - } else { - *((*string)(yyv22)) = r.DecodeString() - } - } - case "ClientDescription": - if r.TryDecodeAsNil() { - x.ClientDescription = "" - } else { - yyv24 := &x.ClientDescription - yym25 := z.DecBinary() - _ = yym25 - if false { - } else { - *((*string)(yyv24)) = r.DecodeString() - } - } - case "TaskStates": - if r.TryDecodeAsNil() { - x.TaskStates = nil - } else { - yyv26 := &x.TaskStates - yym27 := z.DecBinary() - _ = yym27 - if false { - } else { - h.decMapstringPtrtoTaskState((*map[string]*TaskState)(yyv26), d) - } - } - case "DeploymentStatus": - if r.TryDecodeAsNil() { - if x.DeploymentStatus != nil { - x.DeploymentStatus = nil - } - } else { - if x.DeploymentStatus == nil { - x.DeploymentStatus = new(AllocDeploymentStatus) - } - x.DeploymentStatus.CodecDecodeSelf(d) - } - case "CreateIndex": - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv29 := &x.CreateIndex - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*uint64)(yyv29)) = uint64(r.DecodeUint(64)) - } - } - case "ModifyIndex": - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv31 := &x.ModifyIndex - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*uint64)(yyv31)) = uint64(r.DecodeUint(64)) - } - } - case "CreateTime": - if r.TryDecodeAsNil() { - x.CreateTime = 0 - } else { - yyv33 := &x.CreateTime - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - *((*int64)(yyv33)) = int64(r.DecodeInt(64)) - } - } - case "ModifyTime": - if r.TryDecodeAsNil() { - x.ModifyTime = 0 - } else { - yyv35 := &x.ModifyTime - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*int64)(yyv35)) = int64(r.DecodeInt(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *AllocListStub) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj37 int - var yyb37 bool - var yyhl37 bool = l >= 0 - yyj37++ - if yyhl37 { - yyb37 = yyj37 > l - } else { - yyb37 = r.CheckBreak() - } - if yyb37 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ID = "" - } else { - yyv38 := &x.ID - yym39 := z.DecBinary() - _ = yym39 - if false { - } else { - *((*string)(yyv38)) = r.DecodeString() - } - } - yyj37++ - if yyhl37 { - yyb37 = yyj37 > l - } else { - yyb37 = r.CheckBreak() - } - if yyb37 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv40 := &x.EvalID - yym41 := z.DecBinary() - _ = yym41 - if false { - } else { - *((*string)(yyv40)) = r.DecodeString() - } - } - yyj37++ - if yyhl37 { - yyb37 = yyj37 > l - } else { - yyb37 = r.CheckBreak() - } - if yyb37 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv42 := &x.Name - yym43 := z.DecBinary() - _ = yym43 - if false { - } else { - *((*string)(yyv42)) = r.DecodeString() - } - } - yyj37++ - if yyhl37 { - yyb37 = yyj37 > l - } else { - yyb37 = r.CheckBreak() - } - if yyb37 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodeID = "" - } else { - yyv44 := &x.NodeID - yym45 := z.DecBinary() - _ = yym45 - if false { - } else { - *((*string)(yyv44)) = r.DecodeString() - } - } - yyj37++ - if yyhl37 { - yyb37 = yyj37 > l - } else { - yyb37 = r.CheckBreak() - } - if yyb37 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv46 := &x.JobID - yym47 := z.DecBinary() - _ = yym47 - if false { - } else { - *((*string)(yyv46)) = r.DecodeString() - } - } - yyj37++ - if yyhl37 { - yyb37 = yyj37 > l - } else { - yyb37 = r.CheckBreak() - } - if yyb37 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobVersion = 0 - } else { - yyv48 := &x.JobVersion - yym49 := z.DecBinary() - _ = yym49 - if false { - } else { - *((*uint64)(yyv48)) = uint64(r.DecodeUint(64)) - } - } - yyj37++ - if yyhl37 { - yyb37 = yyj37 > l - } else { - yyb37 = r.CheckBreak() - } - if yyb37 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.TaskGroup = "" - } else { - yyv50 := &x.TaskGroup - yym51 := z.DecBinary() - _ = yym51 - if false { - } else { - *((*string)(yyv50)) = r.DecodeString() - } - } - yyj37++ - if yyhl37 { - yyb37 = yyj37 > l - } else { - yyb37 = r.CheckBreak() - } - if yyb37 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DesiredStatus = "" - } else { - yyv52 := &x.DesiredStatus - yym53 := z.DecBinary() - _ = yym53 - if false { - } else { - *((*string)(yyv52)) = r.DecodeString() - } - } - yyj37++ - if yyhl37 { - yyb37 = yyj37 > l - } else { - yyb37 = r.CheckBreak() - } - if yyb37 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DesiredDescription = "" - } else { - yyv54 := &x.DesiredDescription - yym55 := z.DecBinary() - _ = yym55 - if false { - } else { - *((*string)(yyv54)) = r.DecodeString() - } - } - yyj37++ - if yyhl37 { - yyb37 = yyj37 > l - } else { - yyb37 = r.CheckBreak() - } - if yyb37 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ClientStatus = "" - } else { - yyv56 := &x.ClientStatus - yym57 := z.DecBinary() - _ = yym57 - if false { - } else { - *((*string)(yyv56)) = r.DecodeString() - } - } - yyj37++ - if yyhl37 { - yyb37 = yyj37 > l - } else { - yyb37 = r.CheckBreak() - } - if yyb37 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ClientDescription = "" - } else { - yyv58 := &x.ClientDescription - yym59 := z.DecBinary() - _ = yym59 - if false { - } else { - *((*string)(yyv58)) = r.DecodeString() - } - } - yyj37++ - if yyhl37 { - yyb37 = yyj37 > l - } else { - yyb37 = r.CheckBreak() - } - if yyb37 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.TaskStates = nil - } else { - yyv60 := &x.TaskStates - yym61 := z.DecBinary() - _ = yym61 - if false { - } else { - h.decMapstringPtrtoTaskState((*map[string]*TaskState)(yyv60), d) - } - } - yyj37++ - if yyhl37 { - yyb37 = yyj37 > l - } else { - yyb37 = r.CheckBreak() - } - if yyb37 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.DeploymentStatus != nil { - x.DeploymentStatus = nil - } - } else { - if x.DeploymentStatus == nil { - x.DeploymentStatus = new(AllocDeploymentStatus) - } - x.DeploymentStatus.CodecDecodeSelf(d) - } - yyj37++ - if yyhl37 { - yyb37 = yyj37 > l - } else { - yyb37 = r.CheckBreak() - } - if yyb37 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv63 := &x.CreateIndex - yym64 := z.DecBinary() - _ = yym64 - if false { - } else { - *((*uint64)(yyv63)) = uint64(r.DecodeUint(64)) - } - } - yyj37++ - if yyhl37 { - yyb37 = yyj37 > l - } else { - yyb37 = r.CheckBreak() - } - if yyb37 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv65 := &x.ModifyIndex - yym66 := z.DecBinary() - _ = yym66 - if false { - } else { - *((*uint64)(yyv65)) = uint64(r.DecodeUint(64)) - } - } - yyj37++ - if yyhl37 { - yyb37 = yyj37 > l - } else { - yyb37 = r.CheckBreak() - } - if yyb37 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CreateTime = 0 - } else { - yyv67 := &x.CreateTime - yym68 := z.DecBinary() - _ = yym68 - if false { - } else { - *((*int64)(yyv67)) = int64(r.DecodeInt(64)) - } - } - yyj37++ - if yyhl37 { - yyb37 = yyj37 > l - } else { - yyb37 = r.CheckBreak() - } - if yyb37 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ModifyTime = 0 - } else { - yyv69 := &x.ModifyTime - yym70 := z.DecBinary() - _ = yym70 - if false { - } else { - *((*int64)(yyv69)) = int64(r.DecodeInt(64)) - } - } - for { - yyj37++ - if yyhl37 { - yyb37 = yyj37 > l - } else { - yyb37 = r.CheckBreak() - } - if yyb37 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj37-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *AllocMetric) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [12]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(12) - } else { - yynn2 = 12 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeInt(int64(x.NodesEvaluated)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodesEvaluated")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeInt(int64(x.NodesEvaluated)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeInt(int64(x.NodesFiltered)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodesFiltered")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeInt(int64(x.NodesFiltered)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.NodesAvailable == nil { - r.EncodeNil() - } else { - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - z.F.EncMapStringIntV(x.NodesAvailable, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodesAvailable")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.NodesAvailable == nil { - r.EncodeNil() - } else { - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - z.F.EncMapStringIntV(x.NodesAvailable, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.ClassFiltered == nil { - r.EncodeNil() - } else { - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - z.F.EncMapStringIntV(x.ClassFiltered, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ClassFiltered")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.ClassFiltered == nil { - r.EncodeNil() - } else { - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - z.F.EncMapStringIntV(x.ClassFiltered, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.ConstraintFiltered == nil { - r.EncodeNil() - } else { - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - z.F.EncMapStringIntV(x.ConstraintFiltered, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ConstraintFiltered")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.ConstraintFiltered == nil { - r.EncodeNil() - } else { - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - z.F.EncMapStringIntV(x.ConstraintFiltered, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeInt(int64(x.NodesExhausted)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodesExhausted")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeInt(int64(x.NodesExhausted)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.ClassExhausted == nil { - r.EncodeNil() - } else { - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - z.F.EncMapStringIntV(x.ClassExhausted, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ClassExhausted")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.ClassExhausted == nil { - r.EncodeNil() - } else { - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - z.F.EncMapStringIntV(x.ClassExhausted, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.DimensionExhausted == nil { - r.EncodeNil() - } else { - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - z.F.EncMapStringIntV(x.DimensionExhausted, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DimensionExhausted")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.DimensionExhausted == nil { - r.EncodeNil() - } else { - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - z.F.EncMapStringIntV(x.DimensionExhausted, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.QuotaExhausted == nil { - r.EncodeNil() - } else { - yym28 := z.EncBinary() - _ = yym28 - if false { - } else { - z.F.EncSliceStringV(x.QuotaExhausted, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("QuotaExhausted")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.QuotaExhausted == nil { - r.EncodeNil() - } else { - yym29 := z.EncBinary() - _ = yym29 - if false { - } else { - z.F.EncSliceStringV(x.QuotaExhausted, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Scores == nil { - r.EncodeNil() - } else { - yym31 := z.EncBinary() - _ = yym31 - if false { - } else { - z.F.EncMapStringFloat64V(x.Scores, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Scores")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Scores == nil { - r.EncodeNil() - } else { - yym32 := z.EncBinary() - _ = yym32 - if false { - } else { - z.F.EncMapStringFloat64V(x.Scores, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym34 := z.EncBinary() - _ = yym34 - if false { - } else if z.HasExtensions() && z.EncExt(x.AllocationTime) { - } else { - r.EncodeInt(int64(x.AllocationTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllocationTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym35 := z.EncBinary() - _ = yym35 - if false { - } else if z.HasExtensions() && z.EncExt(x.AllocationTime) { - } else { - r.EncodeInt(int64(x.AllocationTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym37 := z.EncBinary() - _ = yym37 - if false { - } else { - r.EncodeInt(int64(x.CoalescedFailures)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CoalescedFailures")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym38 := z.EncBinary() - _ = yym38 - if false { - } else { - r.EncodeInt(int64(x.CoalescedFailures)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *AllocMetric) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *AllocMetric) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "NodesEvaluated": - if r.TryDecodeAsNil() { - x.NodesEvaluated = 0 - } else { - yyv4 := &x.NodesEvaluated - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*int)(yyv4)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "NodesFiltered": - if r.TryDecodeAsNil() { - x.NodesFiltered = 0 - } else { - yyv6 := &x.NodesFiltered - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*int)(yyv6)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "NodesAvailable": - if r.TryDecodeAsNil() { - x.NodesAvailable = nil - } else { - yyv8 := &x.NodesAvailable - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - z.F.DecMapStringIntX(yyv8, false, d) - } - } - case "ClassFiltered": - if r.TryDecodeAsNil() { - x.ClassFiltered = nil - } else { - yyv10 := &x.ClassFiltered - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - z.F.DecMapStringIntX(yyv10, false, d) - } - } - case "ConstraintFiltered": - if r.TryDecodeAsNil() { - x.ConstraintFiltered = nil - } else { - yyv12 := &x.ConstraintFiltered - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - z.F.DecMapStringIntX(yyv12, false, d) - } - } - case "NodesExhausted": - if r.TryDecodeAsNil() { - x.NodesExhausted = 0 - } else { - yyv14 := &x.NodesExhausted - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*int)(yyv14)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "ClassExhausted": - if r.TryDecodeAsNil() { - x.ClassExhausted = nil - } else { - yyv16 := &x.ClassExhausted - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - z.F.DecMapStringIntX(yyv16, false, d) - } - } - case "DimensionExhausted": - if r.TryDecodeAsNil() { - x.DimensionExhausted = nil - } else { - yyv18 := &x.DimensionExhausted - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - z.F.DecMapStringIntX(yyv18, false, d) - } - } - case "QuotaExhausted": - if r.TryDecodeAsNil() { - x.QuotaExhausted = nil - } else { - yyv20 := &x.QuotaExhausted - yym21 := z.DecBinary() - _ = yym21 - if false { - } else { - z.F.DecSliceStringX(yyv20, false, d) - } - } - case "Scores": - if r.TryDecodeAsNil() { - x.Scores = nil - } else { - yyv22 := &x.Scores - yym23 := z.DecBinary() - _ = yym23 - if false { - } else { - z.F.DecMapStringFloat64X(yyv22, false, d) - } - } - case "AllocationTime": - if r.TryDecodeAsNil() { - x.AllocationTime = 0 - } else { - yyv24 := &x.AllocationTime - yym25 := z.DecBinary() - _ = yym25 - if false { - } else if z.HasExtensions() && z.DecExt(yyv24) { - } else { - *((*int64)(yyv24)) = int64(r.DecodeInt(64)) - } - } - case "CoalescedFailures": - if r.TryDecodeAsNil() { - x.CoalescedFailures = 0 - } else { - yyv26 := &x.CoalescedFailures - yym27 := z.DecBinary() - _ = yym27 - if false { - } else { - *((*int)(yyv26)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *AllocMetric) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj28 int - var yyb28 bool - var yyhl28 bool = l >= 0 - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l - } else { - yyb28 = r.CheckBreak() - } - if yyb28 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodesEvaluated = 0 - } else { - yyv29 := &x.NodesEvaluated - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*int)(yyv29)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l - } else { - yyb28 = r.CheckBreak() - } - if yyb28 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodesFiltered = 0 - } else { - yyv31 := &x.NodesFiltered - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*int)(yyv31)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l - } else { - yyb28 = r.CheckBreak() - } - if yyb28 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodesAvailable = nil - } else { - yyv33 := &x.NodesAvailable - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - z.F.DecMapStringIntX(yyv33, false, d) - } - } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l - } else { - yyb28 = r.CheckBreak() - } - if yyb28 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ClassFiltered = nil - } else { - yyv35 := &x.ClassFiltered - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - z.F.DecMapStringIntX(yyv35, false, d) - } - } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l - } else { - yyb28 = r.CheckBreak() - } - if yyb28 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ConstraintFiltered = nil - } else { - yyv37 := &x.ConstraintFiltered - yym38 := z.DecBinary() - _ = yym38 - if false { - } else { - z.F.DecMapStringIntX(yyv37, false, d) - } - } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l - } else { - yyb28 = r.CheckBreak() - } - if yyb28 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodesExhausted = 0 - } else { - yyv39 := &x.NodesExhausted - yym40 := z.DecBinary() - _ = yym40 - if false { - } else { - *((*int)(yyv39)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l - } else { - yyb28 = r.CheckBreak() - } - if yyb28 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ClassExhausted = nil - } else { - yyv41 := &x.ClassExhausted - yym42 := z.DecBinary() - _ = yym42 - if false { - } else { - z.F.DecMapStringIntX(yyv41, false, d) - } - } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l - } else { - yyb28 = r.CheckBreak() - } - if yyb28 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DimensionExhausted = nil - } else { - yyv43 := &x.DimensionExhausted - yym44 := z.DecBinary() - _ = yym44 - if false { - } else { - z.F.DecMapStringIntX(yyv43, false, d) - } - } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l - } else { - yyb28 = r.CheckBreak() - } - if yyb28 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.QuotaExhausted = nil - } else { - yyv45 := &x.QuotaExhausted - yym46 := z.DecBinary() - _ = yym46 - if false { - } else { - z.F.DecSliceStringX(yyv45, false, d) - } - } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l - } else { - yyb28 = r.CheckBreak() - } - if yyb28 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Scores = nil - } else { - yyv47 := &x.Scores - yym48 := z.DecBinary() - _ = yym48 - if false { - } else { - z.F.DecMapStringFloat64X(yyv47, false, d) - } - } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l - } else { - yyb28 = r.CheckBreak() - } - if yyb28 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllocationTime = 0 - } else { - yyv49 := &x.AllocationTime - yym50 := z.DecBinary() - _ = yym50 - if false { - } else if z.HasExtensions() && z.DecExt(yyv49) { - } else { - *((*int64)(yyv49)) = int64(r.DecodeInt(64)) - } - } - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l - } else { - yyb28 = r.CheckBreak() - } - if yyb28 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CoalescedFailures = 0 - } else { - yyv51 := &x.CoalescedFailures - yym52 := z.DecBinary() - _ = yym52 - if false { - } else { - *((*int)(yyv51)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - for { - yyj28++ - if yyhl28 { - yyb28 = yyj28 > l - } else { - yyb28 = r.CheckBreak() - } - if yyb28 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj28-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *AllocDeploymentStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [2]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(2) - } else { - yynn2 = 2 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Healthy == nil { - r.EncodeNil() - } else { - yy4 := *x.Healthy - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeBool(bool(yy4)) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Healthy")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Healthy == nil { - r.EncodeNil() - } else { - yy6 := *x.Healthy - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeBool(bool(yy6)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym9 := z.EncBinary() - _ = yym9 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *AllocDeploymentStatus) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *AllocDeploymentStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Healthy": - if r.TryDecodeAsNil() { - if x.Healthy != nil { - x.Healthy = nil - } - } else { - if x.Healthy == nil { - x.Healthy = new(bool) - } - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*bool)(x.Healthy)) = r.DecodeBool() - } - } - case "ModifyIndex": - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv6 := &x.ModifyIndex - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *AllocDeploymentStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj8 int - var yyb8 bool - var yyhl8 bool = l >= 0 - yyj8++ - if yyhl8 { - yyb8 = yyj8 > l - } else { - yyb8 = r.CheckBreak() - } - if yyb8 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Healthy != nil { - x.Healthy = nil - } - } else { - if x.Healthy == nil { - x.Healthy = new(bool) - } - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*bool)(x.Healthy)) = r.DecodeBool() - } - } - yyj8++ - if yyhl8 { - yyb8 = yyj8 > l - } else { - yyb8 = r.CheckBreak() - } - if yyb8 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv11 := &x.ModifyIndex - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*uint64)(yyv11)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj8++ - if yyhl8 { - yyb8 = yyj8 > l - } else { - yyb8 = r.CheckBreak() - } - if yyb8 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj8-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *Evaluation) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [26]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(26) - } else { - yynn2 = 26 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.ID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeInt(int64(x.Priority)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Priority")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeInt(int64(x.Priority)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Type)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Type")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Type)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.TriggeredBy)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("TriggeredBy")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.TriggeredBy)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.JobID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeUint(uint64(x.JobModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("JobModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeUint(uint64(x.JobModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodeID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NodeID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym28 := z.EncBinary() - _ = yym28 - if false { - } else { - r.EncodeUint(uint64(x.NodeModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodeModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym29 := z.EncBinary() - _ = yym29 - if false { - } else { - r.EncodeUint(uint64(x.NodeModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym31 := z.EncBinary() - _ = yym31 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DeploymentID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym32 := z.EncBinary() - _ = yym32 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.DeploymentID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym34 := z.EncBinary() - _ = yym34 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Status)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Status")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym35 := z.EncBinary() - _ = yym35 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Status)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym37 := z.EncBinary() - _ = yym37 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("StatusDescription")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym38 := z.EncBinary() - _ = yym38 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.StatusDescription)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym40 := z.EncBinary() - _ = yym40 - if false { - } else if z.HasExtensions() && z.EncExt(x.Wait) { - } else { - r.EncodeInt(int64(x.Wait)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Wait")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym41 := z.EncBinary() - _ = yym41 - if false { - } else if z.HasExtensions() && z.EncExt(x.Wait) { - } else { - r.EncodeInt(int64(x.Wait)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym43 := z.EncBinary() - _ = yym43 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NextEval)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NextEval")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym44 := z.EncBinary() - _ = yym44 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.NextEval)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym46 := z.EncBinary() - _ = yym46 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.PreviousEval)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("PreviousEval")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym47 := z.EncBinary() - _ = yym47 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.PreviousEval)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym49 := z.EncBinary() - _ = yym49 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.BlockedEval)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("BlockedEval")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym50 := z.EncBinary() - _ = yym50 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.BlockedEval)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.FailedTGAllocs == nil { - r.EncodeNil() - } else { - yym52 := z.EncBinary() - _ = yym52 - if false { - } else { - h.encMapstringPtrtoAllocMetric((map[string]*AllocMetric)(x.FailedTGAllocs), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("FailedTGAllocs")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.FailedTGAllocs == nil { - r.EncodeNil() - } else { - yym53 := z.EncBinary() - _ = yym53 - if false { - } else { - h.encMapstringPtrtoAllocMetric((map[string]*AllocMetric)(x.FailedTGAllocs), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.ClassEligibility == nil { - r.EncodeNil() - } else { - yym55 := z.EncBinary() - _ = yym55 - if false { - } else { - z.F.EncMapStringBoolV(x.ClassEligibility, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ClassEligibility")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.ClassEligibility == nil { - r.EncodeNil() - } else { - yym56 := z.EncBinary() - _ = yym56 - if false { - } else { - z.F.EncMapStringBoolV(x.ClassEligibility, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym58 := z.EncBinary() - _ = yym58 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.QuotaLimitReached)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("QuotaLimitReached")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym59 := z.EncBinary() - _ = yym59 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.QuotaLimitReached)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym61 := z.EncBinary() - _ = yym61 - if false { - } else { - r.EncodeBool(bool(x.EscapedComputedClass)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EscapedComputedClass")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym62 := z.EncBinary() - _ = yym62 - if false { - } else { - r.EncodeBool(bool(x.EscapedComputedClass)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym64 := z.EncBinary() - _ = yym64 - if false { - } else { - r.EncodeBool(bool(x.AnnotatePlan)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AnnotatePlan")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym65 := z.EncBinary() - _ = yym65 - if false { - } else { - r.EncodeBool(bool(x.AnnotatePlan)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.QueuedAllocations == nil { - r.EncodeNil() - } else { - yym67 := z.EncBinary() - _ = yym67 - if false { - } else { - z.F.EncMapStringIntV(x.QueuedAllocations, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("QueuedAllocations")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.QueuedAllocations == nil { - r.EncodeNil() - } else { - yym68 := z.EncBinary() - _ = yym68 - if false { - } else { - z.F.EncMapStringIntV(x.QueuedAllocations, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym70 := z.EncBinary() - _ = yym70 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.LeaderACL)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LeaderACL")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym71 := z.EncBinary() - _ = yym71 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.LeaderACL)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym73 := z.EncBinary() - _ = yym73 - if false { - } else { - r.EncodeUint(uint64(x.SnapshotIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("SnapshotIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym74 := z.EncBinary() - _ = yym74 - if false { - } else { - r.EncodeUint(uint64(x.SnapshotIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym76 := z.EncBinary() - _ = yym76 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym77 := z.EncBinary() - _ = yym77 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym79 := z.EncBinary() - _ = yym79 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym80 := z.EncBinary() - _ = yym80 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *Evaluation) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *Evaluation) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "ID": - if r.TryDecodeAsNil() { - x.ID = "" - } else { - yyv4 := &x.ID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv6 := &x.Namespace - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Priority": - if r.TryDecodeAsNil() { - x.Priority = 0 - } else { - yyv8 := &x.Priority - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*int)(yyv8)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "Type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - yyv10 := &x.Type - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "TriggeredBy": - if r.TryDecodeAsNil() { - x.TriggeredBy = "" - } else { - yyv12 := &x.TriggeredBy - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*string)(yyv12)) = r.DecodeString() - } - } - case "JobID": - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv14 := &x.JobID - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*string)(yyv14)) = r.DecodeString() - } - } - case "JobModifyIndex": - if r.TryDecodeAsNil() { - x.JobModifyIndex = 0 - } else { - yyv16 := &x.JobModifyIndex - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*uint64)(yyv16)) = uint64(r.DecodeUint(64)) - } - } - case "NodeID": - if r.TryDecodeAsNil() { - x.NodeID = "" - } else { - yyv18 := &x.NodeID - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - case "NodeModifyIndex": - if r.TryDecodeAsNil() { - x.NodeModifyIndex = 0 - } else { - yyv20 := &x.NodeModifyIndex - yym21 := z.DecBinary() - _ = yym21 - if false { - } else { - *((*uint64)(yyv20)) = uint64(r.DecodeUint(64)) - } - } - case "DeploymentID": - if r.TryDecodeAsNil() { - x.DeploymentID = "" - } else { - yyv22 := &x.DeploymentID - yym23 := z.DecBinary() - _ = yym23 - if false { - } else { - *((*string)(yyv22)) = r.DecodeString() - } - } - case "Status": - if r.TryDecodeAsNil() { - x.Status = "" - } else { - yyv24 := &x.Status - yym25 := z.DecBinary() - _ = yym25 - if false { - } else { - *((*string)(yyv24)) = r.DecodeString() - } - } - case "StatusDescription": - if r.TryDecodeAsNil() { - x.StatusDescription = "" - } else { - yyv26 := &x.StatusDescription - yym27 := z.DecBinary() - _ = yym27 - if false { - } else { - *((*string)(yyv26)) = r.DecodeString() - } - } - case "Wait": - if r.TryDecodeAsNil() { - x.Wait = 0 - } else { - yyv28 := &x.Wait - yym29 := z.DecBinary() - _ = yym29 - if false { - } else if z.HasExtensions() && z.DecExt(yyv28) { - } else { - *((*int64)(yyv28)) = int64(r.DecodeInt(64)) - } - } - case "NextEval": - if r.TryDecodeAsNil() { - x.NextEval = "" - } else { - yyv30 := &x.NextEval - yym31 := z.DecBinary() - _ = yym31 - if false { - } else { - *((*string)(yyv30)) = r.DecodeString() - } - } - case "PreviousEval": - if r.TryDecodeAsNil() { - x.PreviousEval = "" - } else { - yyv32 := &x.PreviousEval - yym33 := z.DecBinary() - _ = yym33 - if false { - } else { - *((*string)(yyv32)) = r.DecodeString() - } - } - case "BlockedEval": - if r.TryDecodeAsNil() { - x.BlockedEval = "" - } else { - yyv34 := &x.BlockedEval - yym35 := z.DecBinary() - _ = yym35 - if false { - } else { - *((*string)(yyv34)) = r.DecodeString() - } - } - case "FailedTGAllocs": - if r.TryDecodeAsNil() { - x.FailedTGAllocs = nil - } else { - yyv36 := &x.FailedTGAllocs - yym37 := z.DecBinary() - _ = yym37 - if false { - } else { - h.decMapstringPtrtoAllocMetric((*map[string]*AllocMetric)(yyv36), d) - } - } - case "ClassEligibility": - if r.TryDecodeAsNil() { - x.ClassEligibility = nil - } else { - yyv38 := &x.ClassEligibility - yym39 := z.DecBinary() - _ = yym39 - if false { - } else { - z.F.DecMapStringBoolX(yyv38, false, d) - } - } - case "QuotaLimitReached": - if r.TryDecodeAsNil() { - x.QuotaLimitReached = "" - } else { - yyv40 := &x.QuotaLimitReached - yym41 := z.DecBinary() - _ = yym41 - if false { - } else { - *((*string)(yyv40)) = r.DecodeString() - } - } - case "EscapedComputedClass": - if r.TryDecodeAsNil() { - x.EscapedComputedClass = false - } else { - yyv42 := &x.EscapedComputedClass - yym43 := z.DecBinary() - _ = yym43 - if false { - } else { - *((*bool)(yyv42)) = r.DecodeBool() - } - } - case "AnnotatePlan": - if r.TryDecodeAsNil() { - x.AnnotatePlan = false - } else { - yyv44 := &x.AnnotatePlan - yym45 := z.DecBinary() - _ = yym45 - if false { - } else { - *((*bool)(yyv44)) = r.DecodeBool() - } - } - case "QueuedAllocations": - if r.TryDecodeAsNil() { - x.QueuedAllocations = nil - } else { - yyv46 := &x.QueuedAllocations - yym47 := z.DecBinary() - _ = yym47 - if false { - } else { - z.F.DecMapStringIntX(yyv46, false, d) - } - } - case "LeaderACL": - if r.TryDecodeAsNil() { - x.LeaderACL = "" - } else { - yyv48 := &x.LeaderACL - yym49 := z.DecBinary() - _ = yym49 - if false { - } else { - *((*string)(yyv48)) = r.DecodeString() - } - } - case "SnapshotIndex": - if r.TryDecodeAsNil() { - x.SnapshotIndex = 0 - } else { - yyv50 := &x.SnapshotIndex - yym51 := z.DecBinary() - _ = yym51 - if false { - } else { - *((*uint64)(yyv50)) = uint64(r.DecodeUint(64)) - } - } - case "CreateIndex": - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv52 := &x.CreateIndex - yym53 := z.DecBinary() - _ = yym53 - if false { - } else { - *((*uint64)(yyv52)) = uint64(r.DecodeUint(64)) - } - } - case "ModifyIndex": - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv54 := &x.ModifyIndex - yym55 := z.DecBinary() - _ = yym55 - if false { - } else { - *((*uint64)(yyv54)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *Evaluation) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj56 int - var yyb56 bool - var yyhl56 bool = l >= 0 - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ID = "" - } else { - yyv57 := &x.ID - yym58 := z.DecBinary() - _ = yym58 - if false { - } else { - *((*string)(yyv57)) = r.DecodeString() - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv59 := &x.Namespace - yym60 := z.DecBinary() - _ = yym60 - if false { - } else { - *((*string)(yyv59)) = r.DecodeString() - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Priority = 0 - } else { - yyv61 := &x.Priority - yym62 := z.DecBinary() - _ = yym62 - if false { - } else { - *((*int)(yyv61)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - yyv63 := &x.Type - yym64 := z.DecBinary() - _ = yym64 - if false { - } else { - *((*string)(yyv63)) = r.DecodeString() - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.TriggeredBy = "" - } else { - yyv65 := &x.TriggeredBy - yym66 := z.DecBinary() - _ = yym66 - if false { - } else { - *((*string)(yyv65)) = r.DecodeString() - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobID = "" - } else { - yyv67 := &x.JobID - yym68 := z.DecBinary() - _ = yym68 - if false { - } else { - *((*string)(yyv67)) = r.DecodeString() - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.JobModifyIndex = 0 - } else { - yyv69 := &x.JobModifyIndex - yym70 := z.DecBinary() - _ = yym70 - if false { - } else { - *((*uint64)(yyv69)) = uint64(r.DecodeUint(64)) - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodeID = "" - } else { - yyv71 := &x.NodeID - yym72 := z.DecBinary() - _ = yym72 - if false { - } else { - *((*string)(yyv71)) = r.DecodeString() - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodeModifyIndex = 0 - } else { - yyv73 := &x.NodeModifyIndex - yym74 := z.DecBinary() - _ = yym74 - if false { - } else { - *((*uint64)(yyv73)) = uint64(r.DecodeUint(64)) - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DeploymentID = "" - } else { - yyv75 := &x.DeploymentID - yym76 := z.DecBinary() - _ = yym76 - if false { - } else { - *((*string)(yyv75)) = r.DecodeString() - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - yyv77 := &x.Status - yym78 := z.DecBinary() - _ = yym78 - if false { - } else { - *((*string)(yyv77)) = r.DecodeString() - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.StatusDescription = "" - } else { - yyv79 := &x.StatusDescription - yym80 := z.DecBinary() - _ = yym80 - if false { - } else { - *((*string)(yyv79)) = r.DecodeString() - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Wait = 0 - } else { - yyv81 := &x.Wait - yym82 := z.DecBinary() - _ = yym82 - if false { - } else if z.HasExtensions() && z.DecExt(yyv81) { - } else { - *((*int64)(yyv81)) = int64(r.DecodeInt(64)) - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NextEval = "" - } else { - yyv83 := &x.NextEval - yym84 := z.DecBinary() - _ = yym84 - if false { - } else { - *((*string)(yyv83)) = r.DecodeString() - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.PreviousEval = "" - } else { - yyv85 := &x.PreviousEval - yym86 := z.DecBinary() - _ = yym86 - if false { - } else { - *((*string)(yyv85)) = r.DecodeString() - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.BlockedEval = "" - } else { - yyv87 := &x.BlockedEval - yym88 := z.DecBinary() - _ = yym88 - if false { - } else { - *((*string)(yyv87)) = r.DecodeString() - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.FailedTGAllocs = nil - } else { - yyv89 := &x.FailedTGAllocs - yym90 := z.DecBinary() - _ = yym90 - if false { - } else { - h.decMapstringPtrtoAllocMetric((*map[string]*AllocMetric)(yyv89), d) - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ClassEligibility = nil - } else { - yyv91 := &x.ClassEligibility - yym92 := z.DecBinary() - _ = yym92 - if false { - } else { - z.F.DecMapStringBoolX(yyv91, false, d) - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.QuotaLimitReached = "" - } else { - yyv93 := &x.QuotaLimitReached - yym94 := z.DecBinary() - _ = yym94 - if false { - } else { - *((*string)(yyv93)) = r.DecodeString() - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EscapedComputedClass = false - } else { - yyv95 := &x.EscapedComputedClass - yym96 := z.DecBinary() - _ = yym96 - if false { - } else { - *((*bool)(yyv95)) = r.DecodeBool() - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AnnotatePlan = false - } else { - yyv97 := &x.AnnotatePlan - yym98 := z.DecBinary() - _ = yym98 - if false { - } else { - *((*bool)(yyv97)) = r.DecodeBool() - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.QueuedAllocations = nil - } else { - yyv99 := &x.QueuedAllocations - yym100 := z.DecBinary() - _ = yym100 - if false { - } else { - z.F.DecMapStringIntX(yyv99, false, d) - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LeaderACL = "" - } else { - yyv101 := &x.LeaderACL - yym102 := z.DecBinary() - _ = yym102 - if false { - } else { - *((*string)(yyv101)) = r.DecodeString() - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.SnapshotIndex = 0 - } else { - yyv103 := &x.SnapshotIndex - yym104 := z.DecBinary() - _ = yym104 - if false { - } else { - *((*uint64)(yyv103)) = uint64(r.DecodeUint(64)) - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv105 := &x.CreateIndex - yym106 := z.DecBinary() - _ = yym106 - if false { - } else { - *((*uint64)(yyv105)) = uint64(r.DecodeUint(64)) - } - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv107 := &x.ModifyIndex - yym108 := z.DecBinary() - _ = yym108 - if false { - } else { - *((*uint64)(yyv107)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj56-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *Plan) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [10]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(10) - } else { - yynn2 = 10 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("EvalToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.EvalToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeInt(int64(x.Priority)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Priority")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeInt(int64(x.Priority)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.AllAtOnce)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllAtOnce")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.AllAtOnce)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Job == nil { - r.EncodeNil() - } else { - x.Job.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Job")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Job == nil { - r.EncodeNil() - } else { - x.Job.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.NodeUpdate == nil { - r.EncodeNil() - } else { - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - h.encMapstringSlicePtrtoAllocation((map[string][]*Allocation)(x.NodeUpdate), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodeUpdate")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.NodeUpdate == nil { - r.EncodeNil() - } else { - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - h.encMapstringSlicePtrtoAllocation((map[string][]*Allocation)(x.NodeUpdate), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.NodeAllocation == nil { - r.EncodeNil() - } else { - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - h.encMapstringSlicePtrtoAllocation((map[string][]*Allocation)(x.NodeAllocation), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodeAllocation")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.NodeAllocation == nil { - r.EncodeNil() - } else { - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - h.encMapstringSlicePtrtoAllocation((map[string][]*Allocation)(x.NodeAllocation), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Annotations == nil { - r.EncodeNil() - } else { - x.Annotations.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Annotations")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Annotations == nil { - r.EncodeNil() - } else { - x.Annotations.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Deployment == nil { - r.EncodeNil() - } else { - x.Deployment.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Deployment")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Deployment == nil { - r.EncodeNil() - } else { - x.Deployment.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.DeploymentUpdates == nil { - r.EncodeNil() - } else { - yym31 := z.EncBinary() - _ = yym31 - if false { - } else { - h.encSlicePtrtoDeploymentStatusUpdate(([]*DeploymentStatusUpdate)(x.DeploymentUpdates), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DeploymentUpdates")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.DeploymentUpdates == nil { - r.EncodeNil() - } else { - yym32 := z.EncBinary() - _ = yym32 - if false { - } else { - h.encSlicePtrtoDeploymentStatusUpdate(([]*DeploymentStatusUpdate)(x.DeploymentUpdates), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *Plan) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *Plan) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "EvalID": - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv4 := &x.EvalID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "EvalToken": - if r.TryDecodeAsNil() { - x.EvalToken = "" - } else { - yyv6 := &x.EvalToken - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Priority": - if r.TryDecodeAsNil() { - x.Priority = 0 - } else { - yyv8 := &x.Priority - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*int)(yyv8)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - case "AllAtOnce": - if r.TryDecodeAsNil() { - x.AllAtOnce = false - } else { - yyv10 := &x.AllAtOnce - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*bool)(yyv10)) = r.DecodeBool() - } - } - case "Job": - if r.TryDecodeAsNil() { - if x.Job != nil { - x.Job = nil - } - } else { - if x.Job == nil { - x.Job = new(Job) - } - x.Job.CodecDecodeSelf(d) - } - case "NodeUpdate": - if r.TryDecodeAsNil() { - x.NodeUpdate = nil - } else { - yyv13 := &x.NodeUpdate - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - h.decMapstringSlicePtrtoAllocation((*map[string][]*Allocation)(yyv13), d) - } - } - case "NodeAllocation": - if r.TryDecodeAsNil() { - x.NodeAllocation = nil - } else { - yyv15 := &x.NodeAllocation - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - h.decMapstringSlicePtrtoAllocation((*map[string][]*Allocation)(yyv15), d) - } - } - case "Annotations": - if r.TryDecodeAsNil() { - if x.Annotations != nil { - x.Annotations = nil - } - } else { - if x.Annotations == nil { - x.Annotations = new(PlanAnnotations) - } - x.Annotations.CodecDecodeSelf(d) - } - case "Deployment": - if r.TryDecodeAsNil() { - if x.Deployment != nil { - x.Deployment = nil - } - } else { - if x.Deployment == nil { - x.Deployment = new(Deployment) - } - x.Deployment.CodecDecodeSelf(d) - } - case "DeploymentUpdates": - if r.TryDecodeAsNil() { - x.DeploymentUpdates = nil - } else { - yyv19 := &x.DeploymentUpdates - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - h.decSlicePtrtoDeploymentStatusUpdate((*[]*DeploymentStatusUpdate)(yyv19), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *Plan) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj21 int - var yyb21 bool - var yyhl21 bool = l >= 0 - yyj21++ - if yyhl21 { - yyb21 = yyj21 > l - } else { - yyb21 = r.CheckBreak() - } - if yyb21 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalID = "" - } else { - yyv22 := &x.EvalID - yym23 := z.DecBinary() - _ = yym23 - if false { - } else { - *((*string)(yyv22)) = r.DecodeString() - } - } - yyj21++ - if yyhl21 { - yyb21 = yyj21 > l - } else { - yyb21 = r.CheckBreak() - } - if yyb21 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.EvalToken = "" - } else { - yyv24 := &x.EvalToken - yym25 := z.DecBinary() - _ = yym25 - if false { - } else { - *((*string)(yyv24)) = r.DecodeString() - } - } - yyj21++ - if yyhl21 { - yyb21 = yyj21 > l - } else { - yyb21 = r.CheckBreak() - } - if yyb21 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Priority = 0 - } else { - yyv26 := &x.Priority - yym27 := z.DecBinary() - _ = yym27 - if false { - } else { - *((*int)(yyv26)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - yyj21++ - if yyhl21 { - yyb21 = yyj21 > l - } else { - yyb21 = r.CheckBreak() - } - if yyb21 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllAtOnce = false - } else { - yyv28 := &x.AllAtOnce - yym29 := z.DecBinary() - _ = yym29 - if false { - } else { - *((*bool)(yyv28)) = r.DecodeBool() - } - } - yyj21++ - if yyhl21 { - yyb21 = yyj21 > l - } else { - yyb21 = r.CheckBreak() - } - if yyb21 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Job != nil { - x.Job = nil - } - } else { - if x.Job == nil { - x.Job = new(Job) - } - x.Job.CodecDecodeSelf(d) - } - yyj21++ - if yyhl21 { - yyb21 = yyj21 > l - } else { - yyb21 = r.CheckBreak() - } - if yyb21 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodeUpdate = nil - } else { - yyv31 := &x.NodeUpdate - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - h.decMapstringSlicePtrtoAllocation((*map[string][]*Allocation)(yyv31), d) - } - } - yyj21++ - if yyhl21 { - yyb21 = yyj21 > l - } else { - yyb21 = r.CheckBreak() - } - if yyb21 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodeAllocation = nil - } else { - yyv33 := &x.NodeAllocation - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - h.decMapstringSlicePtrtoAllocation((*map[string][]*Allocation)(yyv33), d) - } - } - yyj21++ - if yyhl21 { - yyb21 = yyj21 > l - } else { - yyb21 = r.CheckBreak() - } - if yyb21 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Annotations != nil { - x.Annotations = nil - } - } else { - if x.Annotations == nil { - x.Annotations = new(PlanAnnotations) - } - x.Annotations.CodecDecodeSelf(d) - } - yyj21++ - if yyhl21 { - yyb21 = yyj21 > l - } else { - yyb21 = r.CheckBreak() - } - if yyb21 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Deployment != nil { - x.Deployment = nil - } - } else { - if x.Deployment == nil { - x.Deployment = new(Deployment) - } - x.Deployment.CodecDecodeSelf(d) - } - yyj21++ - if yyhl21 { - yyb21 = yyj21 > l - } else { - yyb21 = r.CheckBreak() - } - if yyb21 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DeploymentUpdates = nil - } else { - yyv37 := &x.DeploymentUpdates - yym38 := z.DecBinary() - _ = yym38 - if false { - } else { - h.decSlicePtrtoDeploymentStatusUpdate((*[]*DeploymentStatusUpdate)(yyv37), d) - } - } - for { - yyj21++ - if yyhl21 { - yyb21 = yyj21 > l - } else { - yyb21 = r.CheckBreak() - } - if yyb21 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj21-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *PlanResult) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [6]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(6) - } else { - yynn2 = 6 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.NodeUpdate == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encMapstringSlicePtrtoAllocation((map[string][]*Allocation)(x.NodeUpdate), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodeUpdate")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.NodeUpdate == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encMapstringSlicePtrtoAllocation((map[string][]*Allocation)(x.NodeUpdate), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.NodeAllocation == nil { - r.EncodeNil() - } else { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - h.encMapstringSlicePtrtoAllocation((map[string][]*Allocation)(x.NodeAllocation), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NodeAllocation")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.NodeAllocation == nil { - r.EncodeNil() - } else { - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - h.encMapstringSlicePtrtoAllocation((map[string][]*Allocation)(x.NodeAllocation), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Deployment == nil { - r.EncodeNil() - } else { - x.Deployment.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Deployment")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Deployment == nil { - r.EncodeNil() - } else { - x.Deployment.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.DeploymentUpdates == nil { - r.EncodeNil() - } else { - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - h.encSlicePtrtoDeploymentStatusUpdate(([]*DeploymentStatusUpdate)(x.DeploymentUpdates), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DeploymentUpdates")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.DeploymentUpdates == nil { - r.EncodeNil() - } else { - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - h.encSlicePtrtoDeploymentStatusUpdate(([]*DeploymentStatusUpdate)(x.DeploymentUpdates), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeUint(uint64(x.RefreshIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("RefreshIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeUint(uint64(x.RefreshIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeUint(uint64(x.AllocIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllocIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeUint(uint64(x.AllocIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *PlanResult) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *PlanResult) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "NodeUpdate": - if r.TryDecodeAsNil() { - x.NodeUpdate = nil - } else { - yyv4 := &x.NodeUpdate - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decMapstringSlicePtrtoAllocation((*map[string][]*Allocation)(yyv4), d) - } - } - case "NodeAllocation": - if r.TryDecodeAsNil() { - x.NodeAllocation = nil - } else { - yyv6 := &x.NodeAllocation - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - h.decMapstringSlicePtrtoAllocation((*map[string][]*Allocation)(yyv6), d) - } - } - case "Deployment": - if r.TryDecodeAsNil() { - if x.Deployment != nil { - x.Deployment = nil - } - } else { - if x.Deployment == nil { - x.Deployment = new(Deployment) - } - x.Deployment.CodecDecodeSelf(d) - } - case "DeploymentUpdates": - if r.TryDecodeAsNil() { - x.DeploymentUpdates = nil - } else { - yyv9 := &x.DeploymentUpdates - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - h.decSlicePtrtoDeploymentStatusUpdate((*[]*DeploymentStatusUpdate)(yyv9), d) - } - } - case "RefreshIndex": - if r.TryDecodeAsNil() { - x.RefreshIndex = 0 - } else { - yyv11 := &x.RefreshIndex - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*uint64)(yyv11)) = uint64(r.DecodeUint(64)) - } - } - case "AllocIndex": - if r.TryDecodeAsNil() { - x.AllocIndex = 0 - } else { - yyv13 := &x.AllocIndex - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *PlanResult) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj15 int - var yyb15 bool - var yyhl15 bool = l >= 0 - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodeUpdate = nil - } else { - yyv16 := &x.NodeUpdate - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - h.decMapstringSlicePtrtoAllocation((*map[string][]*Allocation)(yyv16), d) - } - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NodeAllocation = nil - } else { - yyv18 := &x.NodeAllocation - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - h.decMapstringSlicePtrtoAllocation((*map[string][]*Allocation)(yyv18), d) - } - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Deployment != nil { - x.Deployment = nil - } - } else { - if x.Deployment == nil { - x.Deployment = new(Deployment) - } - x.Deployment.CodecDecodeSelf(d) - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DeploymentUpdates = nil - } else { - yyv21 := &x.DeploymentUpdates - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - h.decSlicePtrtoDeploymentStatusUpdate((*[]*DeploymentStatusUpdate)(yyv21), d) - } - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.RefreshIndex = 0 - } else { - yyv23 := &x.RefreshIndex - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) - } - } - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllocIndex = 0 - } else { - yyv25 := &x.AllocIndex - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*uint64)(yyv25)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj15++ - if yyhl15 { - yyb15 = yyj15 > l - } else { - yyb15 = r.CheckBreak() - } - if yyb15 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj15-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *PlanAnnotations) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [1]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(1) - } else { - yynn2 = 1 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.DesiredTGUpdates == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encMapstringPtrtoDesiredUpdates((map[string]*DesiredUpdates)(x.DesiredTGUpdates), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DesiredTGUpdates")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.DesiredTGUpdates == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encMapstringPtrtoDesiredUpdates((map[string]*DesiredUpdates)(x.DesiredTGUpdates), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *PlanAnnotations) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *PlanAnnotations) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "DesiredTGUpdates": - if r.TryDecodeAsNil() { - x.DesiredTGUpdates = nil - } else { - yyv4 := &x.DesiredTGUpdates - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decMapstringPtrtoDesiredUpdates((*map[string]*DesiredUpdates)(yyv4), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *PlanAnnotations) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - 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 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DesiredTGUpdates = nil - } else { - yyv7 := &x.DesiredTGUpdates - yym8 := z.DecBinary() - _ = yym8 - if false { - } else { - h.decMapstringPtrtoDesiredUpdates((*map[string]*DesiredUpdates)(yyv7), d) - } - } - for { - yyj6++ - if yyhl6 { - yyb6 = yyj6 > l - } else { - yyb6 = r.CheckBreak() - } - if yyb6 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj6-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *DesiredUpdates) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [7]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(7) - } else { - yynn2 = 7 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeUint(uint64(x.Ignore)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Ignore")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeUint(uint64(x.Ignore)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Place)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Place")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Place)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.Migrate)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Migrate")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.Migrate)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeUint(uint64(x.Stop)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Stop")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeUint(uint64(x.Stop)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeUint(uint64(x.InPlaceUpdate)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("InPlaceUpdate")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeUint(uint64(x.InPlaceUpdate)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeUint(uint64(x.DestructiveUpdate)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("DestructiveUpdate")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeUint(uint64(x.DestructiveUpdate)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeUint(uint64(x.Canary)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Canary")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeUint(uint64(x.Canary)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *DesiredUpdates) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *DesiredUpdates) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Ignore": - if r.TryDecodeAsNil() { - x.Ignore = 0 - } else { - yyv4 := &x.Ignore - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*uint64)(yyv4)) = uint64(r.DecodeUint(64)) - } - } - case "Place": - if r.TryDecodeAsNil() { - x.Place = 0 - } else { - yyv6 := &x.Place - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "Migrate": - if r.TryDecodeAsNil() { - x.Migrate = 0 - } else { - yyv8 := &x.Migrate - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) - } - } - case "Stop": - if r.TryDecodeAsNil() { - x.Stop = 0 - } else { - yyv10 := &x.Stop - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) - } - } - case "InPlaceUpdate": - if r.TryDecodeAsNil() { - x.InPlaceUpdate = 0 - } else { - yyv12 := &x.InPlaceUpdate - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*uint64)(yyv12)) = uint64(r.DecodeUint(64)) - } - } - case "DestructiveUpdate": - if r.TryDecodeAsNil() { - x.DestructiveUpdate = 0 - } else { - yyv14 := &x.DestructiveUpdate - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*uint64)(yyv14)) = uint64(r.DecodeUint(64)) - } - } - case "Canary": - if r.TryDecodeAsNil() { - x.Canary = 0 - } else { - yyv16 := &x.Canary - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*uint64)(yyv16)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *DesiredUpdates) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj18 int - var yyb18 bool - var yyhl18 bool = l >= 0 - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Ignore = 0 - } else { - yyv19 := &x.Ignore - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Place = 0 - } else { - yyv21 := &x.Place - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*uint64)(yyv21)) = uint64(r.DecodeUint(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Migrate = 0 - } else { - yyv23 := &x.Migrate - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Stop = 0 - } else { - yyv25 := &x.Stop - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*uint64)(yyv25)) = uint64(r.DecodeUint(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.InPlaceUpdate = 0 - } else { - yyv27 := &x.InPlaceUpdate - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.DestructiveUpdate = 0 - } else { - yyv29 := &x.DestructiveUpdate - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*uint64)(yyv29)) = uint64(r.DecodeUint(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Canary = 0 - } else { - yyv31 := &x.Canary - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*uint64)(yyv31)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj18-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *KeyringResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [3]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(3) - } else { - yynn2 = 3 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Messages == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - z.F.EncMapStringStringV(x.Messages, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Messages")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Messages == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - z.F.EncMapStringStringV(x.Messages, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Keys == nil { - r.EncodeNil() - } else { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - z.F.EncMapStringIntV(x.Keys, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Keys")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Keys == nil { - r.EncodeNil() - } else { - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - z.F.EncMapStringIntV(x.Keys, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeInt(int64(x.NumNodes)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("NumNodes")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeInt(int64(x.NumNodes)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *KeyringResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *KeyringResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Messages": - if r.TryDecodeAsNil() { - x.Messages = nil - } else { - yyv4 := &x.Messages - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - z.F.DecMapStringStringX(yyv4, false, d) - } - } - case "Keys": - if r.TryDecodeAsNil() { - x.Keys = nil - } else { - yyv6 := &x.Keys - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - z.F.DecMapStringIntX(yyv6, false, d) - } - } - case "NumNodes": - if r.TryDecodeAsNil() { - x.NumNodes = 0 - } else { - yyv8 := &x.NumNodes - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*int)(yyv8)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *KeyringResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj10 int - var yyb10 bool - var yyhl10 bool = l >= 0 - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Messages = nil - } else { - yyv11 := &x.Messages - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - z.F.DecMapStringStringX(yyv11, false, d) - } - } - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Keys = nil - } else { - yyv13 := &x.Keys - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - z.F.DecMapStringIntX(yyv13, false, d) - } - } - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.NumNodes = 0 - } else { - yyv15 := &x.NumNodes - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*int)(yyv15)) = int(r.DecodeInt(codecSelferBitsize100)) - } - } - for { - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj10-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *KeyringRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [1]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(1) - } else { - yynn2 = 1 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Key)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Key")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Key)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *KeyringRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *KeyringRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Key": - if r.TryDecodeAsNil() { - x.Key = "" - } else { - yyv4 := &x.Key - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *KeyringRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - 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 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Key = "" - } else { - yyv7 := &x.Key - yym8 := z.DecBinary() - _ = yym8 - if false { - } else { - *((*string)(yyv7)) = r.DecodeString() - } - } - for { - yyj6++ - if yyhl6 { - yyb6 = yyj6 > l - } else { - yyb6 = r.CheckBreak() - } - if yyb6 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj6-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *RecoverableError) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [2]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(2) - } else { - yynn2 = 2 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Err)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Err")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Err)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeBool(bool(x.Recoverable)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Recoverable")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeBool(bool(x.Recoverable)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *RecoverableError) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *RecoverableError) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Err": - if r.TryDecodeAsNil() { - x.Err = "" - } else { - yyv4 := &x.Err - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Recoverable": - if r.TryDecodeAsNil() { - x.Recoverable = false - } else { - yyv6 := &x.Recoverable - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*bool)(yyv6)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *RecoverableError) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj8 int - var yyb8 bool - var yyhl8 bool = l >= 0 - yyj8++ - if yyhl8 { - yyb8 = yyj8 > l - } else { - yyb8 = r.CheckBreak() - } - if yyb8 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Err = "" - } else { - yyv9 := &x.Err - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*string)(yyv9)) = r.DecodeString() - } - } - yyj8++ - if yyhl8 { - yyb8 = yyj8 > l - } else { - yyb8 = r.CheckBreak() - } - if yyb8 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Recoverable = false - } else { - yyv11 := &x.Recoverable - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*bool)(yyv11)) = r.DecodeBool() - } - } - for { - yyj8++ - if yyhl8 { - yyb8 = yyj8 > l - } else { - yyb8 = r.CheckBreak() - } - if yyb8 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj8-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ACLPolicy) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [6]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(6) - } else { - yynn2 = 6 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Name")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Description)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Description")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Description)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Rules)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Rules")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Rules)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Hash == nil { - r.EncodeNil() - } else { - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Hash)) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Hash")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Hash == nil { - r.EncodeNil() - } else { - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Hash)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ACLPolicy) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ACLPolicy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv4 := &x.Name - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Description": - if r.TryDecodeAsNil() { - x.Description = "" - } else { - yyv6 := &x.Description - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Rules": - if r.TryDecodeAsNil() { - x.Rules = "" - } else { - yyv8 := &x.Rules - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Hash": - if r.TryDecodeAsNil() { - x.Hash = nil - } else { - yyv10 := &x.Hash - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *yyv10 = r.DecodeBytes(*(*[]byte)(yyv10), false, false) - } - } - case "CreateIndex": - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv12 := &x.CreateIndex - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*uint64)(yyv12)) = uint64(r.DecodeUint(64)) - } - } - case "ModifyIndex": - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv14 := &x.ModifyIndex - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*uint64)(yyv14)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ACLPolicy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj16 int - var yyb16 bool - var yyhl16 bool = l >= 0 - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv17 := &x.Name - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Description = "" - } else { - yyv19 := &x.Description - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Rules = "" - } else { - yyv21 := &x.Rules - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Hash = nil - } else { - yyv23 := &x.Hash - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *yyv23 = r.DecodeBytes(*(*[]byte)(yyv23), false, false) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv25 := &x.CreateIndex - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*uint64)(yyv25)) = uint64(r.DecodeUint(64)) - } - } - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv27 := &x.ModifyIndex - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj16++ - if yyhl16 { - yyb16 = yyj16 > l - } else { - yyb16 = r.CheckBreak() - } - if yyb16 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj16-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ACLPolicyListStub) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 5 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Name")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Description)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Description")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Description)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Hash == nil { - r.EncodeNil() - } else { - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Hash)) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Hash")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Hash == nil { - r.EncodeNil() - } else { - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Hash)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ACLPolicyListStub) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ACLPolicyListStub) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv4 := &x.Name - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Description": - if r.TryDecodeAsNil() { - x.Description = "" - } else { - yyv6 := &x.Description - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Hash": - if r.TryDecodeAsNil() { - x.Hash = nil - } else { - yyv8 := &x.Hash - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *yyv8 = r.DecodeBytes(*(*[]byte)(yyv8), false, false) - } - } - case "CreateIndex": - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv10 := &x.CreateIndex - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) - } - } - case "ModifyIndex": - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv12 := &x.ModifyIndex - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*uint64)(yyv12)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ACLPolicyListStub) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj14 int - var yyb14 bool - var yyhl14 bool = l >= 0 - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv15 := &x.Name - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Description = "" - } else { - yyv17 := &x.Description - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Hash = nil - } else { - yyv19 := &x.Hash - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *yyv19 = r.DecodeBytes(*(*[]byte)(yyv19), false, false) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv21 := &x.CreateIndex - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*uint64)(yyv21)) = uint64(r.DecodeUint(64)) - } - } - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv23 := &x.ModifyIndex - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj14++ - if yyhl14 { - yyb14 = yyj14 > l - } else { - yyb14 = r.CheckBreak() - } - if yyb14 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj14-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ACLPolicyListRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [7]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(7) - } else { - yynn2 = 7 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ACLPolicyListRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ACLPolicyListRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv4 := &x.Region - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv6 := &x.Namespace - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv8 := &x.MinQueryIndex - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*uint64)(yyv8)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv10 := &x.MaxQueryTime - yym11 := z.DecBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.DecExt(yyv10) { - } else { - *((*int64)(yyv10)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv12 := &x.AllowStale - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*bool)(yyv12)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv14 := &x.Prefix - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*string)(yyv14)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv16 := &x.AuthToken - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ACLPolicyListRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj18 int - var yyb18 bool - var yyhl18 bool = l >= 0 - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv19 := &x.Region - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv21 := &x.Namespace - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv23 := &x.MinQueryIndex - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv25 := &x.MaxQueryTime - yym26 := z.DecBinary() - _ = yym26 - if false { - } else if z.HasExtensions() && z.DecExt(yyv25) { - } else { - *((*int64)(yyv25)) = int64(r.DecodeInt(64)) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv27 := &x.AllowStale - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*bool)(yyv27)) = r.DecodeBool() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv29 := &x.Prefix - yym30 := z.DecBinary() - _ = yym30 - if false { - } else { - *((*string)(yyv29)) = r.DecodeString() - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv31 := &x.AuthToken - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*string)(yyv31)) = r.DecodeString() - } - } - for { - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj18-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ACLPolicySpecificRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [8]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(8) - } else { - yynn2 = 8 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Name")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ACLPolicySpecificRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ACLPolicySpecificRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv4 := &x.Name - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv10 := &x.MinQueryIndex - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv12 := &x.MaxQueryTime - yym13 := z.DecBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.DecExt(yyv12) { - } else { - *((*int64)(yyv12)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv14 := &x.AllowStale - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*bool)(yyv14)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv16 := &x.Prefix - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv18 := &x.AuthToken - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ACLPolicySpecificRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj20 int - var yyb20 bool - var yyhl20 bool = l >= 0 - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv21 := &x.Name - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv23 := &x.Region - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv25 := &x.Namespace - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv27 := &x.MinQueryIndex - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv29 := &x.MaxQueryTime - yym30 := z.DecBinary() - _ = yym30 - if false { - } else if z.HasExtensions() && z.DecExt(yyv29) { - } else { - *((*int64)(yyv29)) = int64(r.DecodeInt(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv31 := &x.AllowStale - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*bool)(yyv31)) = r.DecodeBool() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv33 := &x.Prefix - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - *((*string)(yyv33)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv35 := &x.AuthToken - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*string)(yyv35)) = r.DecodeString() - } - } - for { - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj20-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ACLPolicySetRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [8]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(8) - } else { - yynn2 = 8 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Names == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - z.F.EncSliceStringV(x.Names, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Names")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Names == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - z.F.EncSliceStringV(x.Names, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ACLPolicySetRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ACLPolicySetRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Names": - if r.TryDecodeAsNil() { - x.Names = nil - } else { - yyv4 := &x.Names - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - z.F.DecSliceStringX(yyv4, false, d) - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv10 := &x.MinQueryIndex - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv12 := &x.MaxQueryTime - yym13 := z.DecBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.DecExt(yyv12) { - } else { - *((*int64)(yyv12)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv14 := &x.AllowStale - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*bool)(yyv14)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv16 := &x.Prefix - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv18 := &x.AuthToken - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ACLPolicySetRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj20 int - var yyb20 bool - var yyhl20 bool = l >= 0 - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Names = nil - } else { - yyv21 := &x.Names - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - z.F.DecSliceStringX(yyv21, false, d) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv23 := &x.Region - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv25 := &x.Namespace - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv27 := &x.MinQueryIndex - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv29 := &x.MaxQueryTime - yym30 := z.DecBinary() - _ = yym30 - if false { - } else if z.HasExtensions() && z.DecExt(yyv29) { - } else { - *((*int64)(yyv29)) = int64(r.DecodeInt(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv31 := &x.AllowStale - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*bool)(yyv31)) = r.DecodeBool() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv33 := &x.Prefix - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - *((*string)(yyv33)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv35 := &x.AuthToken - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*string)(yyv35)) = r.DecodeString() - } - } - for { - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj20-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ACLPolicyListResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Policies == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encSlicePtrtoACLPolicyListStub(([]*ACLPolicyListStub)(x.Policies), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Policies")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Policies == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encSlicePtrtoACLPolicyListStub(([]*ACLPolicyListStub)(x.Policies), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ACLPolicyListResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ACLPolicyListResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Policies": - if r.TryDecodeAsNil() { - x.Policies = nil - } else { - yyv4 := &x.Policies - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decSlicePtrtoACLPolicyListStub((*[]*ACLPolicyListStub)(yyv4), d) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv6 := &x.Index - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv8 := &x.LastContact - yym9 := z.DecBinary() - _ = yym9 - if false { - } else if z.HasExtensions() && z.DecExt(yyv8) { - } else { - *((*int64)(yyv8)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv10 := &x.KnownLeader - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*bool)(yyv10)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ACLPolicyListResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Policies = nil - } else { - yyv13 := &x.Policies - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - h.decSlicePtrtoACLPolicyListStub((*[]*ACLPolicyListStub)(yyv13), d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv15 := &x.Index - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv17 := &x.LastContact - yym18 := z.DecBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.DecExt(yyv17) { - } else { - *((*int64)(yyv17)) = int64(r.DecodeInt(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv19 := &x.KnownLeader - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*bool)(yyv19)) = r.DecodeBool() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *SingleACLPolicyResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Policy == nil { - r.EncodeNil() - } else { - x.Policy.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Policy")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Policy == nil { - r.EncodeNil() - } else { - x.Policy.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *SingleACLPolicyResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *SingleACLPolicyResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Policy": - if r.TryDecodeAsNil() { - if x.Policy != nil { - x.Policy = nil - } - } else { - if x.Policy == nil { - x.Policy = new(ACLPolicy) - } - x.Policy.CodecDecodeSelf(d) - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv5 := &x.Index - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv7 := &x.LastContact - yym8 := z.DecBinary() - _ = yym8 - if false { - } else if z.HasExtensions() && z.DecExt(yyv7) { - } else { - *((*int64)(yyv7)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv9 := &x.KnownLeader - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*bool)(yyv9)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *SingleACLPolicyResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj11 int - var yyb11 bool - var yyhl11 bool = l >= 0 - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Policy != nil { - x.Policy = nil - } - } else { - if x.Policy == nil { - x.Policy = new(ACLPolicy) - } - x.Policy.CodecDecodeSelf(d) - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv13 := &x.Index - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv15 := &x.LastContact - yym16 := z.DecBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.DecExt(yyv15) { - } else { - *((*int64)(yyv15)) = int64(r.DecodeInt(64)) - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv17 := &x.KnownLeader - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*bool)(yyv17)) = r.DecodeBool() - } - } - for { - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj11-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ACLPolicySetResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Policies == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encMapstringPtrtoACLPolicy((map[string]*ACLPolicy)(x.Policies), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Policies")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Policies == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encMapstringPtrtoACLPolicy((map[string]*ACLPolicy)(x.Policies), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ACLPolicySetResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ACLPolicySetResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Policies": - if r.TryDecodeAsNil() { - x.Policies = nil - } else { - yyv4 := &x.Policies - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decMapstringPtrtoACLPolicy((*map[string]*ACLPolicy)(yyv4), d) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv6 := &x.Index - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv8 := &x.LastContact - yym9 := z.DecBinary() - _ = yym9 - if false { - } else if z.HasExtensions() && z.DecExt(yyv8) { - } else { - *((*int64)(yyv8)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv10 := &x.KnownLeader - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*bool)(yyv10)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ACLPolicySetResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Policies = nil - } else { - yyv13 := &x.Policies - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - h.decMapstringPtrtoACLPolicy((*map[string]*ACLPolicy)(yyv13), d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv15 := &x.Index - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv17 := &x.LastContact - yym18 := z.DecBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.DecExt(yyv17) { - } else { - *((*int64)(yyv17)) = int64(r.DecodeInt(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv19 := &x.KnownLeader - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*bool)(yyv19)) = r.DecodeBool() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ACLPolicyDeleteRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Names == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - z.F.EncSliceStringV(x.Names, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Names")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Names == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - z.F.EncSliceStringV(x.Names, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ACLPolicyDeleteRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ACLPolicyDeleteRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Names": - if r.TryDecodeAsNil() { - x.Names = nil - } else { - yyv4 := &x.Names - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - z.F.DecSliceStringX(yyv4, false, d) - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv10 := &x.AuthToken - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ACLPolicyDeleteRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Names = nil - } else { - yyv13 := &x.Names - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - z.F.DecSliceStringX(yyv13, false, d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv15 := &x.Region - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv17 := &x.Namespace - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv19 := &x.AuthToken - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ACLPolicyUpsertRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Policies == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encSlicePtrtoACLPolicy(([]*ACLPolicy)(x.Policies), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Policies")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Policies == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encSlicePtrtoACLPolicy(([]*ACLPolicy)(x.Policies), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ACLPolicyUpsertRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ACLPolicyUpsertRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Policies": - if r.TryDecodeAsNil() { - x.Policies = nil - } else { - yyv4 := &x.Policies - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decSlicePtrtoACLPolicy((*[]*ACLPolicy)(yyv4), d) - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv10 := &x.AuthToken - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ACLPolicyUpsertRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Policies = nil - } else { - yyv13 := &x.Policies - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - h.decSlicePtrtoACLPolicy((*[]*ACLPolicy)(yyv13), d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv15 := &x.Region - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv17 := &x.Namespace - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv19 := &x.AuthToken - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ACLToken) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [10]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(10) - } else { - yynn2 = 10 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AccessorID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AccessorID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AccessorID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.SecretID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("SecretID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.SecretID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Name")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Type)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Type")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Type)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Policies == nil { - r.EncodeNil() - } else { - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - z.F.EncSliceStringV(x.Policies, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Policies")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Policies == nil { - r.EncodeNil() - } else { - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - z.F.EncSliceStringV(x.Policies, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeBool(bool(x.Global)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Global")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeBool(bool(x.Global)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Hash == nil { - r.EncodeNil() - } else { - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Hash)) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Hash")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Hash == nil { - r.EncodeNil() - } else { - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Hash)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yy25 := &x.CreateTime - yym26 := z.EncBinary() - _ = yym26 - if false { - } else if yym27 := z.TimeRtidIfBinc(); yym27 != 0 { - r.EncodeBuiltin(yym27, yy25) - } else if z.HasExtensions() && z.EncExt(yy25) { - } else if yym26 { - z.EncBinaryMarshal(yy25) - } else if !yym26 && z.IsJSONHandle() { - z.EncJSONMarshal(yy25) - } else { - z.EncFallback(yy25) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CreateTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yy28 := &x.CreateTime - yym29 := z.EncBinary() - _ = yym29 - if false { - } else if yym30 := z.TimeRtidIfBinc(); yym30 != 0 { - r.EncodeBuiltin(yym30, yy28) - } else if z.HasExtensions() && z.EncExt(yy28) { - } else if yym29 { - z.EncBinaryMarshal(yy28) - } else if !yym29 && z.IsJSONHandle() { - z.EncJSONMarshal(yy28) - } else { - z.EncFallback(yy28) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym32 := z.EncBinary() - _ = yym32 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym33 := z.EncBinary() - _ = yym33 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym35 := z.EncBinary() - _ = yym35 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym36 := z.EncBinary() - _ = yym36 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ACLToken) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ACLToken) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "AccessorID": - if r.TryDecodeAsNil() { - x.AccessorID = "" - } else { - yyv4 := &x.AccessorID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "SecretID": - if r.TryDecodeAsNil() { - x.SecretID = "" - } else { - yyv6 := &x.SecretID - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv8 := &x.Name - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - yyv10 := &x.Type - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - case "Policies": - if r.TryDecodeAsNil() { - x.Policies = nil - } else { - yyv12 := &x.Policies - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - z.F.DecSliceStringX(yyv12, false, d) - } - } - case "Global": - if r.TryDecodeAsNil() { - x.Global = false - } else { - yyv14 := &x.Global - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*bool)(yyv14)) = r.DecodeBool() - } - } - case "Hash": - if r.TryDecodeAsNil() { - x.Hash = nil - } else { - yyv16 := &x.Hash - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *yyv16 = r.DecodeBytes(*(*[]byte)(yyv16), false, false) - } - } - case "CreateTime": - if r.TryDecodeAsNil() { - x.CreateTime = time.Time{} - } else { - yyv18 := &x.CreateTime - yym19 := z.DecBinary() - _ = yym19 - if false { - } else if yym20 := z.TimeRtidIfBinc(); yym20 != 0 { - r.DecodeBuiltin(yym20, yyv18) - } else if z.HasExtensions() && z.DecExt(yyv18) { - } else if yym19 { - z.DecBinaryUnmarshal(yyv18) - } else if !yym19 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv18) - } else { - z.DecFallback(yyv18, false) - } - } - case "CreateIndex": - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv21 := &x.CreateIndex - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*uint64)(yyv21)) = uint64(r.DecodeUint(64)) - } - } - case "ModifyIndex": - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv23 := &x.ModifyIndex - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*uint64)(yyv23)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ACLToken) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj25 int - var yyb25 bool - var yyhl25 bool = l >= 0 - yyj25++ - if yyhl25 { - yyb25 = yyj25 > l - } else { - yyb25 = r.CheckBreak() - } - if yyb25 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AccessorID = "" - } else { - yyv26 := &x.AccessorID - yym27 := z.DecBinary() - _ = yym27 - if false { - } else { - *((*string)(yyv26)) = r.DecodeString() - } - } - yyj25++ - if yyhl25 { - yyb25 = yyj25 > l - } else { - yyb25 = r.CheckBreak() - } - if yyb25 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.SecretID = "" - } else { - yyv28 := &x.SecretID - yym29 := z.DecBinary() - _ = yym29 - if false { - } else { - *((*string)(yyv28)) = r.DecodeString() - } - } - yyj25++ - if yyhl25 { - yyb25 = yyj25 > l - } else { - yyb25 = r.CheckBreak() - } - if yyb25 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv30 := &x.Name - yym31 := z.DecBinary() - _ = yym31 - if false { - } else { - *((*string)(yyv30)) = r.DecodeString() - } - } - yyj25++ - if yyhl25 { - yyb25 = yyj25 > l - } else { - yyb25 = r.CheckBreak() - } - if yyb25 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - yyv32 := &x.Type - yym33 := z.DecBinary() - _ = yym33 - if false { - } else { - *((*string)(yyv32)) = r.DecodeString() - } - } - yyj25++ - if yyhl25 { - yyb25 = yyj25 > l - } else { - yyb25 = r.CheckBreak() - } - if yyb25 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Policies = nil - } else { - yyv34 := &x.Policies - yym35 := z.DecBinary() - _ = yym35 - if false { - } else { - z.F.DecSliceStringX(yyv34, false, d) - } - } - yyj25++ - if yyhl25 { - yyb25 = yyj25 > l - } else { - yyb25 = r.CheckBreak() - } - if yyb25 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Global = false - } else { - yyv36 := &x.Global - yym37 := z.DecBinary() - _ = yym37 - if false { - } else { - *((*bool)(yyv36)) = r.DecodeBool() - } - } - yyj25++ - if yyhl25 { - yyb25 = yyj25 > l - } else { - yyb25 = r.CheckBreak() - } - if yyb25 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Hash = nil - } else { - yyv38 := &x.Hash - yym39 := z.DecBinary() - _ = yym39 - if false { - } else { - *yyv38 = r.DecodeBytes(*(*[]byte)(yyv38), false, false) - } - } - yyj25++ - if yyhl25 { - yyb25 = yyj25 > l - } else { - yyb25 = r.CheckBreak() - } - if yyb25 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CreateTime = time.Time{} - } else { - yyv40 := &x.CreateTime - yym41 := z.DecBinary() - _ = yym41 - if false { - } else if yym42 := z.TimeRtidIfBinc(); yym42 != 0 { - r.DecodeBuiltin(yym42, yyv40) - } else if z.HasExtensions() && z.DecExt(yyv40) { - } else if yym41 { - z.DecBinaryUnmarshal(yyv40) - } else if !yym41 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv40) - } else { - z.DecFallback(yyv40, false) - } - } - yyj25++ - if yyhl25 { - yyb25 = yyj25 > l - } else { - yyb25 = r.CheckBreak() - } - if yyb25 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv43 := &x.CreateIndex - yym44 := z.DecBinary() - _ = yym44 - if false { - } else { - *((*uint64)(yyv43)) = uint64(r.DecodeUint(64)) - } - } - yyj25++ - if yyhl25 { - yyb25 = yyj25 > l - } else { - yyb25 = r.CheckBreak() - } - if yyb25 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv45 := &x.ModifyIndex - yym46 := z.DecBinary() - _ = yym46 - if false { - } else { - *((*uint64)(yyv45)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj25++ - if yyhl25 { - yyb25 = yyj25 > l - } else { - yyb25 = r.CheckBreak() - } - if yyb25 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj25-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ACLTokenListStub) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [9]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(9) - } else { - yynn2 = 9 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AccessorID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AccessorID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AccessorID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Name")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Name)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Type)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Type")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Type)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Policies == nil { - r.EncodeNil() - } else { - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - z.F.EncSliceStringV(x.Policies, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Policies")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Policies == nil { - r.EncodeNil() - } else { - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - z.F.EncSliceStringV(x.Policies, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeBool(bool(x.Global)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Global")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeBool(bool(x.Global)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Hash == nil { - r.EncodeNil() - } else { - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Hash)) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Hash")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Hash == nil { - r.EncodeNil() - } else { - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW100, []byte(x.Hash)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yy22 := &x.CreateTime - yym23 := z.EncBinary() - _ = yym23 - if false { - } else if yym24 := z.TimeRtidIfBinc(); yym24 != 0 { - r.EncodeBuiltin(yym24, yy22) - } else if z.HasExtensions() && z.EncExt(yy22) { - } else if yym23 { - z.EncBinaryMarshal(yy22) - } else if !yym23 && z.IsJSONHandle() { - z.EncJSONMarshal(yy22) - } else { - z.EncFallback(yy22) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CreateTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yy25 := &x.CreateTime - yym26 := z.EncBinary() - _ = yym26 - if false { - } else if yym27 := z.TimeRtidIfBinc(); yym27 != 0 { - r.EncodeBuiltin(yym27, yy25) - } else if z.HasExtensions() && z.EncExt(yy25) { - } else if yym26 { - z.EncBinaryMarshal(yy25) - } else if !yym26 && z.IsJSONHandle() { - z.EncJSONMarshal(yy25) - } else { - z.EncFallback(yy25) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym29 := z.EncBinary() - _ = yym29 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("CreateIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym30 := z.EncBinary() - _ = yym30 - if false { - } else { - r.EncodeUint(uint64(x.CreateIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym32 := z.EncBinary() - _ = yym32 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ModifyIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym33 := z.EncBinary() - _ = yym33 - if false { - } else { - r.EncodeUint(uint64(x.ModifyIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ACLTokenListStub) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ACLTokenListStub) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "AccessorID": - if r.TryDecodeAsNil() { - x.AccessorID = "" - } else { - yyv4 := &x.AccessorID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv6 := &x.Name - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - yyv8 := &x.Type - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "Policies": - if r.TryDecodeAsNil() { - x.Policies = nil - } else { - yyv10 := &x.Policies - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - z.F.DecSliceStringX(yyv10, false, d) - } - } - case "Global": - if r.TryDecodeAsNil() { - x.Global = false - } else { - yyv12 := &x.Global - yym13 := z.DecBinary() - _ = yym13 - if false { - } else { - *((*bool)(yyv12)) = r.DecodeBool() - } - } - case "Hash": - if r.TryDecodeAsNil() { - x.Hash = nil - } else { - yyv14 := &x.Hash - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *yyv14 = r.DecodeBytes(*(*[]byte)(yyv14), false, false) - } - } - case "CreateTime": - if r.TryDecodeAsNil() { - x.CreateTime = time.Time{} - } else { - yyv16 := &x.CreateTime - yym17 := z.DecBinary() - _ = yym17 - if false { - } else if yym18 := z.TimeRtidIfBinc(); yym18 != 0 { - r.DecodeBuiltin(yym18, yyv16) - } else if z.HasExtensions() && z.DecExt(yyv16) { - } else if yym17 { - z.DecBinaryUnmarshal(yyv16) - } else if !yym17 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv16) - } else { - z.DecFallback(yyv16, false) - } - } - case "CreateIndex": - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv19 := &x.CreateIndex - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*uint64)(yyv19)) = uint64(r.DecodeUint(64)) - } - } - case "ModifyIndex": - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv21 := &x.ModifyIndex - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*uint64)(yyv21)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ACLTokenListStub) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj23 int - var yyb23 bool - var yyhl23 bool = l >= 0 - yyj23++ - if yyhl23 { - yyb23 = yyj23 > l - } else { - yyb23 = r.CheckBreak() - } - if yyb23 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AccessorID = "" - } else { - yyv24 := &x.AccessorID - yym25 := z.DecBinary() - _ = yym25 - if false { - } else { - *((*string)(yyv24)) = r.DecodeString() - } - } - yyj23++ - if yyhl23 { - yyb23 = yyj23 > l - } else { - yyb23 = r.CheckBreak() - } - if yyb23 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - yyv26 := &x.Name - yym27 := z.DecBinary() - _ = yym27 - if false { - } else { - *((*string)(yyv26)) = r.DecodeString() - } - } - yyj23++ - if yyhl23 { - yyb23 = yyj23 > l - } else { - yyb23 = r.CheckBreak() - } - if yyb23 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - yyv28 := &x.Type - yym29 := z.DecBinary() - _ = yym29 - if false { - } else { - *((*string)(yyv28)) = r.DecodeString() - } - } - yyj23++ - if yyhl23 { - yyb23 = yyj23 > l - } else { - yyb23 = r.CheckBreak() - } - if yyb23 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Policies = nil - } else { - yyv30 := &x.Policies - yym31 := z.DecBinary() - _ = yym31 - if false { - } else { - z.F.DecSliceStringX(yyv30, false, d) - } - } - yyj23++ - if yyhl23 { - yyb23 = yyj23 > l - } else { - yyb23 = r.CheckBreak() - } - if yyb23 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Global = false - } else { - yyv32 := &x.Global - yym33 := z.DecBinary() - _ = yym33 - if false { - } else { - *((*bool)(yyv32)) = r.DecodeBool() - } - } - yyj23++ - if yyhl23 { - yyb23 = yyj23 > l - } else { - yyb23 = r.CheckBreak() - } - if yyb23 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Hash = nil - } else { - yyv34 := &x.Hash - yym35 := z.DecBinary() - _ = yym35 - if false { - } else { - *yyv34 = r.DecodeBytes(*(*[]byte)(yyv34), false, false) - } - } - yyj23++ - if yyhl23 { - yyb23 = yyj23 > l - } else { - yyb23 = r.CheckBreak() - } - if yyb23 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CreateTime = time.Time{} - } else { - yyv36 := &x.CreateTime - yym37 := z.DecBinary() - _ = yym37 - if false { - } else if yym38 := z.TimeRtidIfBinc(); yym38 != 0 { - r.DecodeBuiltin(yym38, yyv36) - } else if z.HasExtensions() && z.DecExt(yyv36) { - } else if yym37 { - z.DecBinaryUnmarshal(yyv36) - } else if !yym37 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv36) - } else { - z.DecFallback(yyv36, false) - } - } - yyj23++ - if yyhl23 { - yyb23 = yyj23 > l - } else { - yyb23 = r.CheckBreak() - } - if yyb23 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.CreateIndex = 0 - } else { - yyv39 := &x.CreateIndex - yym40 := z.DecBinary() - _ = yym40 - if false { - } else { - *((*uint64)(yyv39)) = uint64(r.DecodeUint(64)) - } - } - yyj23++ - if yyhl23 { - yyb23 = yyj23 > l - } else { - yyb23 = r.CheckBreak() - } - if yyb23 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ModifyIndex = 0 - } else { - yyv41 := &x.ModifyIndex - yym42 := z.DecBinary() - _ = yym42 - if false { - } else { - *((*uint64)(yyv41)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj23++ - if yyhl23 { - yyb23 = yyj23 > l - } else { - yyb23 = r.CheckBreak() - } - if yyb23 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj23-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ACLTokenListRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [8]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(8) - } else { - yynn2 = 8 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeBool(bool(x.GlobalOnly)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("GlobalOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeBool(bool(x.GlobalOnly)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ACLTokenListRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ACLTokenListRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "GlobalOnly": - if r.TryDecodeAsNil() { - x.GlobalOnly = false - } else { - yyv4 := &x.GlobalOnly - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*bool)(yyv4)) = r.DecodeBool() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv10 := &x.MinQueryIndex - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv12 := &x.MaxQueryTime - yym13 := z.DecBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.DecExt(yyv12) { - } else { - *((*int64)(yyv12)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv14 := &x.AllowStale - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*bool)(yyv14)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv16 := &x.Prefix - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv18 := &x.AuthToken - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ACLTokenListRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj20 int - var yyb20 bool - var yyhl20 bool = l >= 0 - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.GlobalOnly = false - } else { - yyv21 := &x.GlobalOnly - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*bool)(yyv21)) = r.DecodeBool() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv23 := &x.Region - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv25 := &x.Namespace - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv27 := &x.MinQueryIndex - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv29 := &x.MaxQueryTime - yym30 := z.DecBinary() - _ = yym30 - if false { - } else if z.HasExtensions() && z.DecExt(yyv29) { - } else { - *((*int64)(yyv29)) = int64(r.DecodeInt(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv31 := &x.AllowStale - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*bool)(yyv31)) = r.DecodeBool() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv33 := &x.Prefix - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - *((*string)(yyv33)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv35 := &x.AuthToken - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*string)(yyv35)) = r.DecodeString() - } - } - for { - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj20-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ACLTokenSpecificRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [8]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(8) - } else { - yynn2 = 8 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AccessorID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AccessorID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AccessorID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ACLTokenSpecificRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ACLTokenSpecificRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "AccessorID": - if r.TryDecodeAsNil() { - x.AccessorID = "" - } else { - yyv4 := &x.AccessorID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv10 := &x.MinQueryIndex - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv12 := &x.MaxQueryTime - yym13 := z.DecBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.DecExt(yyv12) { - } else { - *((*int64)(yyv12)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv14 := &x.AllowStale - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*bool)(yyv14)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv16 := &x.Prefix - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv18 := &x.AuthToken - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ACLTokenSpecificRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj20 int - var yyb20 bool - var yyhl20 bool = l >= 0 - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AccessorID = "" - } else { - yyv21 := &x.AccessorID - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv23 := &x.Region - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv25 := &x.Namespace - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv27 := &x.MinQueryIndex - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv29 := &x.MaxQueryTime - yym30 := z.DecBinary() - _ = yym30 - if false { - } else if z.HasExtensions() && z.DecExt(yyv29) { - } else { - *((*int64)(yyv29)) = int64(r.DecodeInt(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv31 := &x.AllowStale - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*bool)(yyv31)) = r.DecodeBool() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv33 := &x.Prefix - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - *((*string)(yyv33)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv35 := &x.AuthToken - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*string)(yyv35)) = r.DecodeString() - } - } - for { - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj20-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ACLTokenSetRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [8]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(8) - } else { - yynn2 = 8 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.AccessorIDS == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - z.F.EncSliceStringV(x.AccessorIDS, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AccessorIDS")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.AccessorIDS == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - z.F.EncSliceStringV(x.AccessorIDS, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ACLTokenSetRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ACLTokenSetRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "AccessorIDS": - if r.TryDecodeAsNil() { - x.AccessorIDS = nil - } else { - yyv4 := &x.AccessorIDS - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - z.F.DecSliceStringX(yyv4, false, d) - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv10 := &x.MinQueryIndex - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv12 := &x.MaxQueryTime - yym13 := z.DecBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.DecExt(yyv12) { - } else { - *((*int64)(yyv12)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv14 := &x.AllowStale - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*bool)(yyv14)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv16 := &x.Prefix - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv18 := &x.AuthToken - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ACLTokenSetRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj20 int - var yyb20 bool - var yyhl20 bool = l >= 0 - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AccessorIDS = nil - } else { - yyv21 := &x.AccessorIDS - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - z.F.DecSliceStringX(yyv21, false, d) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv23 := &x.Region - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv25 := &x.Namespace - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv27 := &x.MinQueryIndex - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv29 := &x.MaxQueryTime - yym30 := z.DecBinary() - _ = yym30 - if false { - } else if z.HasExtensions() && z.DecExt(yyv29) { - } else { - *((*int64)(yyv29)) = int64(r.DecodeInt(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv31 := &x.AllowStale - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*bool)(yyv31)) = r.DecodeBool() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv33 := &x.Prefix - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - *((*string)(yyv33)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv35 := &x.AuthToken - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*string)(yyv35)) = r.DecodeString() - } - } - for { - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj20-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ACLTokenListResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Tokens == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encSlicePtrtoACLTokenListStub(([]*ACLTokenListStub)(x.Tokens), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Tokens")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Tokens == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encSlicePtrtoACLTokenListStub(([]*ACLTokenListStub)(x.Tokens), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ACLTokenListResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ACLTokenListResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Tokens": - if r.TryDecodeAsNil() { - x.Tokens = nil - } else { - yyv4 := &x.Tokens - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decSlicePtrtoACLTokenListStub((*[]*ACLTokenListStub)(yyv4), d) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv6 := &x.Index - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv8 := &x.LastContact - yym9 := z.DecBinary() - _ = yym9 - if false { - } else if z.HasExtensions() && z.DecExt(yyv8) { - } else { - *((*int64)(yyv8)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv10 := &x.KnownLeader - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*bool)(yyv10)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ACLTokenListResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Tokens = nil - } else { - yyv13 := &x.Tokens - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - h.decSlicePtrtoACLTokenListStub((*[]*ACLTokenListStub)(yyv13), d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv15 := &x.Index - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv17 := &x.LastContact - yym18 := z.DecBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.DecExt(yyv17) { - } else { - *((*int64)(yyv17)) = int64(r.DecodeInt(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv19 := &x.KnownLeader - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*bool)(yyv19)) = r.DecodeBool() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *SingleACLTokenResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Token == nil { - r.EncodeNil() - } else { - x.Token.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Token")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Token == nil { - r.EncodeNil() - } else { - x.Token.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *SingleACLTokenResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *SingleACLTokenResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Token": - if r.TryDecodeAsNil() { - if x.Token != nil { - x.Token = nil - } - } else { - if x.Token == nil { - x.Token = new(ACLToken) - } - x.Token.CodecDecodeSelf(d) - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv5 := &x.Index - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv7 := &x.LastContact - yym8 := z.DecBinary() - _ = yym8 - if false { - } else if z.HasExtensions() && z.DecExt(yyv7) { - } else { - *((*int64)(yyv7)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv9 := &x.KnownLeader - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*bool)(yyv9)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *SingleACLTokenResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj11 int - var yyb11 bool - var yyhl11 bool = l >= 0 - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Token != nil { - x.Token = nil - } - } else { - if x.Token == nil { - x.Token = new(ACLToken) - } - x.Token.CodecDecodeSelf(d) - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv13 := &x.Index - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv15 := &x.LastContact - yym16 := z.DecBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.DecExt(yyv15) { - } else { - *((*int64)(yyv15)) = int64(r.DecodeInt(64)) - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv17 := &x.KnownLeader - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*bool)(yyv17)) = r.DecodeBool() - } - } - for { - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj11-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ACLTokenSetResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Tokens == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encMapstringPtrtoACLToken((map[string]*ACLToken)(x.Tokens), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Tokens")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Tokens == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encMapstringPtrtoACLToken((map[string]*ACLToken)(x.Tokens), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ACLTokenSetResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ACLTokenSetResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Tokens": - if r.TryDecodeAsNil() { - x.Tokens = nil - } else { - yyv4 := &x.Tokens - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decMapstringPtrtoACLToken((*map[string]*ACLToken)(yyv4), d) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv6 := &x.Index - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv8 := &x.LastContact - yym9 := z.DecBinary() - _ = yym9 - if false { - } else if z.HasExtensions() && z.DecExt(yyv8) { - } else { - *((*int64)(yyv8)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv10 := &x.KnownLeader - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*bool)(yyv10)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ACLTokenSetResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Tokens = nil - } else { - yyv13 := &x.Tokens - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - h.decMapstringPtrtoACLToken((*map[string]*ACLToken)(yyv13), d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv15 := &x.Index - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv17 := &x.LastContact - yym18 := z.DecBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.DecExt(yyv17) { - } else { - *((*int64)(yyv17)) = int64(r.DecodeInt(64)) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv19 := &x.KnownLeader - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*bool)(yyv19)) = r.DecodeBool() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ResolveACLTokenRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [8]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(8) - } else { - yynn2 = 8 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.SecretID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("SecretID")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.SecretID)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MinQueryIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeUint(uint64(x.MinQueryIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("MaxQueryTime")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxQueryTime) { - } else { - r.EncodeInt(int64(x.MaxQueryTime)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AllowStale")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeBool(bool(x.AllowStale)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym22 := z.EncBinary() - _ = yym22 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Prefix")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym23 := z.EncBinary() - _ = yym23 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Prefix)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ResolveACLTokenRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ResolveACLTokenRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "SecretID": - if r.TryDecodeAsNil() { - x.SecretID = "" - } else { - yyv4 := &x.SecretID - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "MinQueryIndex": - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv10 := &x.MinQueryIndex - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*uint64)(yyv10)) = uint64(r.DecodeUint(64)) - } - } - case "MaxQueryTime": - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv12 := &x.MaxQueryTime - yym13 := z.DecBinary() - _ = yym13 - if false { - } else if z.HasExtensions() && z.DecExt(yyv12) { - } else { - *((*int64)(yyv12)) = int64(r.DecodeInt(64)) - } - } - case "AllowStale": - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv14 := &x.AllowStale - yym15 := z.DecBinary() - _ = yym15 - if false { - } else { - *((*bool)(yyv14)) = r.DecodeBool() - } - } - case "Prefix": - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv16 := &x.Prefix - yym17 := z.DecBinary() - _ = yym17 - if false { - } else { - *((*string)(yyv16)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv18 := &x.AuthToken - yym19 := z.DecBinary() - _ = yym19 - if false { - } else { - *((*string)(yyv18)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ResolveACLTokenRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj20 int - var yyb20 bool - var yyhl20 bool = l >= 0 - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.SecretID = "" - } else { - yyv21 := &x.SecretID - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv23 := &x.Region - yym24 := z.DecBinary() - _ = yym24 - if false { - } else { - *((*string)(yyv23)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv25 := &x.Namespace - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - *((*string)(yyv25)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MinQueryIndex = 0 - } else { - yyv27 := &x.MinQueryIndex - yym28 := z.DecBinary() - _ = yym28 - if false { - } else { - *((*uint64)(yyv27)) = uint64(r.DecodeUint(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.MaxQueryTime = 0 - } else { - yyv29 := &x.MaxQueryTime - yym30 := z.DecBinary() - _ = yym30 - if false { - } else if z.HasExtensions() && z.DecExt(yyv29) { - } else { - *((*int64)(yyv29)) = int64(r.DecodeInt(64)) - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AllowStale = false - } else { - yyv31 := &x.AllowStale - yym32 := z.DecBinary() - _ = yym32 - if false { - } else { - *((*bool)(yyv31)) = r.DecodeBool() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Prefix = "" - } else { - yyv33 := &x.Prefix - yym34 := z.DecBinary() - _ = yym34 - if false { - } else { - *((*string)(yyv33)) = r.DecodeString() - } - } - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv35 := &x.AuthToken - yym36 := z.DecBinary() - _ = yym36 - if false { - } else { - *((*string)(yyv35)) = r.DecodeString() - } - } - for { - yyj20++ - if yyhl20 { - yyb20 = yyj20 > l - } else { - yyb20 = r.CheckBreak() - } - if yyb20 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj20-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ResolveACLTokenResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Token == nil { - r.EncodeNil() - } else { - x.Token.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Token")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Token == nil { - r.EncodeNil() - } else { - x.Token.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("LastContact")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastContact) { - } else { - r.EncodeInt(int64(x.LastContact)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("KnownLeader")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeBool(bool(x.KnownLeader)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ResolveACLTokenResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ResolveACLTokenResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Token": - if r.TryDecodeAsNil() { - if x.Token != nil { - x.Token = nil - } - } else { - if x.Token == nil { - x.Token = new(ACLToken) - } - x.Token.CodecDecodeSelf(d) - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv5 := &x.Index - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) - } - } - case "LastContact": - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv7 := &x.LastContact - yym8 := z.DecBinary() - _ = yym8 - if false { - } else if z.HasExtensions() && z.DecExt(yyv7) { - } else { - *((*int64)(yyv7)) = int64(r.DecodeInt(64)) - } - } - case "KnownLeader": - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv9 := &x.KnownLeader - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*bool)(yyv9)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ResolveACLTokenResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj11 int - var yyb11 bool - var yyhl11 bool = l >= 0 - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Token != nil { - x.Token = nil - } - } else { - if x.Token == nil { - x.Token = new(ACLToken) - } - x.Token.CodecDecodeSelf(d) - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv13 := &x.Index - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - *((*uint64)(yyv13)) = uint64(r.DecodeUint(64)) - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.LastContact = 0 - } else { - yyv15 := &x.LastContact - yym16 := z.DecBinary() - _ = yym16 - if false { - } else if z.HasExtensions() && z.DecExt(yyv15) { - } else { - *((*int64)(yyv15)) = int64(r.DecodeInt(64)) - } - } - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.KnownLeader = false - } else { - yyv17 := &x.KnownLeader - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*bool)(yyv17)) = r.DecodeBool() - } - } - for { - yyj11++ - if yyhl11 { - yyb11 = yyj11 > l - } else { - yyb11 = r.CheckBreak() - } - if yyb11 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj11-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ACLTokenDeleteRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.AccessorIDs == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - z.F.EncSliceStringV(x.AccessorIDs, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AccessorIDs")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.AccessorIDs == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - z.F.EncSliceStringV(x.AccessorIDs, false, e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ACLTokenDeleteRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ACLTokenDeleteRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "AccessorIDs": - if r.TryDecodeAsNil() { - x.AccessorIDs = nil - } else { - yyv4 := &x.AccessorIDs - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - z.F.DecSliceStringX(yyv4, false, d) - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv10 := &x.AuthToken - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ACLTokenDeleteRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AccessorIDs = nil - } else { - yyv13 := &x.AccessorIDs - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - z.F.DecSliceStringX(yyv13, false, d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv15 := &x.Region - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv17 := &x.Namespace - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv19 := &x.AuthToken - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ACLTokenBootstrapRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 5 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Token == nil { - r.EncodeNil() - } else { - x.Token.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Token")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Token == nil { - r.EncodeNil() - } else { - x.Token.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.ResetIndex)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("ResetIndex")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.ResetIndex)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ACLTokenBootstrapRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ACLTokenBootstrapRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Token": - if r.TryDecodeAsNil() { - if x.Token != nil { - x.Token = nil - } - } else { - if x.Token == nil { - x.Token = new(ACLToken) - } - x.Token.CodecDecodeSelf(d) - } - case "ResetIndex": - if r.TryDecodeAsNil() { - x.ResetIndex = 0 - } else { - yyv5 := &x.ResetIndex - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*uint64)(yyv5)) = uint64(r.DecodeUint(64)) - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv7 := &x.Region - yym8 := z.DecBinary() - _ = yym8 - if false { - } else { - *((*string)(yyv7)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv9 := &x.Namespace - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - *((*string)(yyv9)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv11 := &x.AuthToken - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*string)(yyv11)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ACLTokenBootstrapRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj13 int - var yyb13 bool - var yyhl13 bool = l >= 0 - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - if x.Token != nil { - x.Token = nil - } - } else { - if x.Token == nil { - x.Token = new(ACLToken) - } - x.Token.CodecDecodeSelf(d) - } - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.ResetIndex = 0 - } else { - yyv15 := &x.ResetIndex - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*uint64)(yyv15)) = uint64(r.DecodeUint(64)) - } - } - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv17 := &x.Region - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv19 := &x.Namespace - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv21 := &x.AuthToken - yym22 := z.DecBinary() - _ = yym22 - if false { - } else { - *((*string)(yyv21)) = r.DecodeString() - } - } - for { - yyj13++ - if yyhl13 { - yyb13 = yyj13 > l - } else { - yyb13 = r.CheckBreak() - } - if yyb13 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj13-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ACLTokenUpsertRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [4]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(4) - } else { - yynn2 = 4 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Tokens == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encSlicePtrtoACLToken(([]*ACLToken)(x.Tokens), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Tokens")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Tokens == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encSlicePtrtoACLToken(([]*ACLToken)(x.Tokens), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Region")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Region)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.Namespace)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("AuthToken")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(x.AuthToken)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ACLTokenUpsertRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ACLTokenUpsertRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Tokens": - if r.TryDecodeAsNil() { - x.Tokens = nil - } else { - yyv4 := &x.Tokens - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decSlicePtrtoACLToken((*[]*ACLToken)(yyv4), d) - } - } - case "Region": - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv6 := &x.Region - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv8 := &x.Namespace - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - *((*string)(yyv8)) = r.DecodeString() - } - } - case "AuthToken": - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv10 := &x.AuthToken - yym11 := z.DecBinary() - _ = yym11 - if false { - } else { - *((*string)(yyv10)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ACLTokenUpsertRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj12 int - var yyb12 bool - var yyhl12 bool = l >= 0 - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Tokens = nil - } else { - yyv13 := &x.Tokens - yym14 := z.DecBinary() - _ = yym14 - if false { - } else { - h.decSlicePtrtoACLToken((*[]*ACLToken)(yyv13), d) - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Region = "" - } else { - yyv15 := &x.Region - yym16 := z.DecBinary() - _ = yym16 - if false { - } else { - *((*string)(yyv15)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - yyv17 := &x.Namespace - yym18 := z.DecBinary() - _ = yym18 - if false { - } else { - *((*string)(yyv17)) = r.DecodeString() - } - } - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.AuthToken = "" - } else { - yyv19 := &x.AuthToken - yym20 := z.DecBinary() - _ = yym20 - if false { - } else { - *((*string)(yyv19)) = r.DecodeString() - } - } - for { - yyj12++ - if yyhl12 { - yyb12 = yyj12 > l - } else { - yyb12 = r.CheckBreak() - } - if yyb12 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj12-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x *ACLTokenUpsertResponse) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [2]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(2) - } else { - yynn2 = 2 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if x.Tokens == nil { - r.EncodeNil() - } else { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - h.encSlicePtrtoACLToken(([]*ACLToken)(x.Tokens), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Tokens")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if x.Tokens == nil { - r.EncodeNil() - } else { - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - h.encSlicePtrtoACLToken(([]*ACLToken)(x.Tokens), e) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey100) - r.EncodeString(codecSelferC_UTF8100, string("Index")) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeUint(uint64(x.Index)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd100) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd100) - } - } - } -} - -func (x *ACLTokenUpsertResponse) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1 := z.DecBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2 := r.ContainerType() - if yyct2 == codecSelferValueTypeMap100 { - yyl2 := r.ReadMapStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd100) - } else { - x.codecDecodeSelfFromMap(yyl2, d) - } - } else if yyct2 == codecSelferValueTypeArray100 { - yyl2 := r.ReadArrayStart() - if yyl2 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - } else { - x.codecDecodeSelfFromArray(yyl2, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr100) - } - } -} - -func (x *ACLTokenUpsertResponse) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3Slc - var yyhl3 bool = l >= 0 - for yyj3 := 0; ; yyj3++ { - if yyhl3 { - if yyj3 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey100) - yys3Slc = r.DecodeBytes(yys3Slc, true, true) - yys3 := string(yys3Slc) - z.DecSendContainerState(codecSelfer_containerMapValue100) - switch yys3 { - case "Tokens": - if r.TryDecodeAsNil() { - x.Tokens = nil - } else { - yyv4 := &x.Tokens - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decSlicePtrtoACLToken((*[]*ACLToken)(yyv4), d) - } - } - case "Index": - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv6 := &x.Index - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*uint64)(yyv6)) = uint64(r.DecodeUint(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3) - } // end switch yys3 - } // end for yyj3 - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x *ACLTokenUpsertResponse) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj8 int - var yyb8 bool - var yyhl8 bool = l >= 0 - yyj8++ - if yyhl8 { - yyb8 = yyj8 > l - } else { - yyb8 = r.CheckBreak() - } - if yyb8 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Tokens = nil - } else { - yyv9 := &x.Tokens - yym10 := z.DecBinary() - _ = yym10 - if false { - } else { - h.decSlicePtrtoACLToken((*[]*ACLToken)(yyv9), d) - } - } - yyj8++ - if yyhl8 { - yyb8 = yyj8 > l - } else { - yyb8 = r.CheckBreak() - } - if yyb8 { - z.DecSendContainerState(codecSelfer_containerArrayEnd100) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - if r.TryDecodeAsNil() { - x.Index = 0 - } else { - yyv11 := &x.Index - yym12 := z.DecBinary() - _ = yym12 - if false { - } else { - *((*uint64)(yyv11)) = uint64(r.DecodeUint(64)) - } - } - for { - yyj8++ - if yyhl8 { - yyb8 = yyj8 > l - } else { - yyb8 = r.CheckBreak() - } - if yyb8 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem100) - z.DecStructFieldNotFound(yyj8-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) encMapContextSlicestring(v map[Context][]string, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeMapStart(len(v)) - for yyk1, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerMapKey100) - yyk1.CodecEncodeSelf(e) - z.EncSendContainerState(codecSelfer_containerMapValue100) - if yyv1 == nil { - r.EncodeNil() - } else { - yym3 := z.EncBinary() - _ = yym3 - if false { - } else { - z.F.EncSliceStringV(yyv1, false, e) - } - } - } - z.EncSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) decMapContextSlicestring(v *map[Context][]string, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyl1 := r.ReadMapStart() - yybh1 := z.DecBasicHandle() - if yyv1 == nil { - yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 40) - yyv1 = make(map[Context][]string, yyrl1) - *v = yyv1 - } - var yymk1 Context - var yymv1 []string - var yymg1 bool - if yybh1.MapValueReset { - yymg1 = true - } - if yyl1 > 0 { - for yyj1 := 0; yyj1 < yyl1; yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv2 := &yymk1 - yyv2.CodecDecodeSelf(d) - } - - if yymg1 { - yymv1 = yyv1[yymk1] - } else { - yymv1 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - yymv1 = nil - } else { - yyv3 := &yymv1 - yym4 := z.DecBinary() - _ = yym4 - if false { - } else { - z.F.DecSliceStringX(yyv3, false, d) - } - } - - if yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } else if yyl1 < 0 { - for yyj1 := 0; !r.CheckBreak(); yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv5 := &yymk1 - yyv5.CodecDecodeSelf(d) - } - - if yymg1 { - yymv1 = yyv1[yymk1] - } else { - yymv1 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - yymv1 = nil - } else { - yyv6 := &yymv1 - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - z.F.DecSliceStringX(yyv6, false, d) - } - } - - if yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } // else len==0: TODO: Should we clear map entries? - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) encSlicestring(v []string, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yym2 := z.EncBinary() - _ = yym2 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(yyv1)) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicestring(v *[]string, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []string{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]string, yyrl1) - } - } else { - yyv1 = make([]string, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - yyv1[yyj1] = "" - } else { - yyv2 := &yyv1[yyj1] - yym3 := z.DecBinary() - _ = yym3 - if false { - } else { - *((*string)(yyv2)) = r.DecodeString() - } - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, "") - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - yyv1[yyj1] = "" - } else { - yyv4 := &yyv1[yyj1] - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - *((*string)(yyv4)) = r.DecodeString() - } - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, "") // var yyz1 string - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - yyv1[yyj1] = "" - } else { - yyv6 := &yyv1[yyj1] - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []string{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encMapContextbool(v map[Context]bool, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeMapStart(len(v)) - for yyk1, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerMapKey100) - yyk1.CodecEncodeSelf(e) - z.EncSendContainerState(codecSelfer_containerMapValue100) - yym3 := z.EncBinary() - _ = yym3 - if false { - } else { - r.EncodeBool(bool(yyv1)) - } - } - z.EncSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) decMapContextbool(v *map[Context]bool, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyl1 := r.ReadMapStart() - yybh1 := z.DecBasicHandle() - if yyv1 == nil { - yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 17) - yyv1 = make(map[Context]bool, yyrl1) - *v = yyv1 - } - var yymk1 Context - var yymv1 bool - var yymg1 bool - if yybh1.MapValueReset { - } - if yyl1 > 0 { - for yyj1 := 0; yyj1 < yyl1; yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv2 := &yymk1 - yyv2.CodecDecodeSelf(d) - } - - if yymg1 { - yymv1 = yyv1[yymk1] - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - yymv1 = false - } else { - yyv3 := &yymv1 - yym4 := z.DecBinary() - _ = yym4 - if false { - } else { - *((*bool)(yyv3)) = r.DecodeBool() - } - } - - if yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } else if yyl1 < 0 { - for yyj1 := 0; !r.CheckBreak(); yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv5 := &yymk1 - yyv5.CodecDecodeSelf(d) - } - - if yymg1 { - yymv1 = yyv1[yymk1] - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - yymv1 = false - } else { - yyv6 := &yymv1 - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*bool)(yyv6)) = r.DecodeBool() - } - } - - if yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } // else len==0: TODO: Should we clear map entries? - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) encSlicePtrtoEvaluation(v []*Evaluation, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoEvaluation(v *[]*Evaluation, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*Evaluation{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*Evaluation, yyrl1) - } - } else { - yyv1 = make([]*Evaluation, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Evaluation{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Evaluation) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Evaluation{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Evaluation) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *Evaluation - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Evaluation{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Evaluation) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*Evaluation{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encSlicePtrtoAllocation(v []*Allocation, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoAllocation(v *[]*Allocation, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*Allocation{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*Allocation, yyrl1) - } - } else { - yyv1 = make([]*Allocation, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Allocation{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Allocation) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Allocation{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Allocation) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *Allocation - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Allocation{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Allocation) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*Allocation{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encSlicePtrtoDeploymentStatusUpdate(v []*DeploymentStatusUpdate, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoDeploymentStatusUpdate(v *[]*DeploymentStatusUpdate, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*DeploymentStatusUpdate{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*DeploymentStatusUpdate, yyrl1) - } - } else { - yyv1 = make([]*DeploymentStatusUpdate, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = DeploymentStatusUpdate{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(DeploymentStatusUpdate) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = DeploymentStatusUpdate{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(DeploymentStatusUpdate) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *DeploymentStatusUpdate - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = DeploymentStatusUpdate{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(DeploymentStatusUpdate) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*DeploymentStatusUpdate{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encSlicePtrtoServerMember(v []*ServerMember, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoServerMember(v *[]*ServerMember, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*ServerMember{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*ServerMember, yyrl1) - } - } else { - yyv1 = make([]*ServerMember, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = ServerMember{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(ServerMember) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = ServerMember{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(ServerMember) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *ServerMember - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = ServerMember{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(ServerMember) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*ServerMember{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encnet_IP(v net.IP, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeStringBytes(codecSelferC_RAW100, []byte(v)) -} - -func (x codecSelfer100) decnet_IP(v *net.IP, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - *v = r.DecodeBytes(*((*[]byte)(v)), false, false) -} - -func (x codecSelfer100) encSlicePtrtoVaultAccessor(v []*VaultAccessor, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoVaultAccessor(v *[]*VaultAccessor, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*VaultAccessor{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*VaultAccessor, yyrl1) - } - } else { - yyv1 = make([]*VaultAccessor, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = VaultAccessor{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(VaultAccessor) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = VaultAccessor{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(VaultAccessor) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *VaultAccessor - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = VaultAccessor{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(VaultAccessor) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*VaultAccessor{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encSlicePtrtoNodeServerInfo(v []*NodeServerInfo, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoNodeServerInfo(v *[]*NodeServerInfo, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*NodeServerInfo{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*NodeServerInfo, yyrl1) - } - } else { - yyv1 = make([]*NodeServerInfo, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = NodeServerInfo{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(NodeServerInfo) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = NodeServerInfo{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(NodeServerInfo) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *NodeServerInfo - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = NodeServerInfo{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(NodeServerInfo) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*NodeServerInfo{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encSlicePtrtoNodeListStub(v []*NodeListStub, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoNodeListStub(v *[]*NodeListStub, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*NodeListStub{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*NodeListStub, yyrl1) - } - } else { - yyv1 = make([]*NodeListStub, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = NodeListStub{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(NodeListStub) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = NodeListStub{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(NodeListStub) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *NodeListStub - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = NodeListStub{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(NodeListStub) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*NodeListStub{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encSlicePtrtoJobListStub(v []*JobListStub, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoJobListStub(v *[]*JobListStub, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*JobListStub{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*JobListStub, yyrl1) - } - } else { - yyv1 = make([]*JobListStub, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = JobListStub{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(JobListStub) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = JobListStub{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(JobListStub) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *JobListStub - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = JobListStub{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(JobListStub) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*JobListStub{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encSlicePtrtoJob(v []*Job, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoJob(v *[]*Job, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*Job{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*Job, yyrl1) - } - } else { - yyv1 = make([]*Job, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Job{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Job) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Job{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Job) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *Job - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Job{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Job) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*Job{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encSlicePtrtoJobDiff(v []*JobDiff, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yym2 := z.EncBinary() - _ = yym2 - if false { - } else if z.HasExtensions() && z.EncExt(yyv1) { - } else { - z.EncFallback(yyv1) - } - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoJobDiff(v *[]*JobDiff, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*JobDiff{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*JobDiff, yyrl1) - } - } else { - yyv1 = make([]*JobDiff, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = JobDiff{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(JobDiff) - } - yyw2 := yyv1[yyj1] - yym3 := z.DecBinary() - _ = yym3 - if false { - } else if z.HasExtensions() && z.DecExt(yyw2) { - } else { - z.DecFallback(yyw2, false) - } - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = JobDiff{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(JobDiff) - } - yyw4 := yyv1[yyj1] - yym5 := z.DecBinary() - _ = yym5 - if false { - } else if z.HasExtensions() && z.DecExt(yyw4) { - } else { - z.DecFallback(yyw4, false) - } - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *JobDiff - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = JobDiff{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(JobDiff) - } - yyw6 := yyv1[yyj1] - yym7 := z.DecBinary() - _ = yym7 - if false { - } else if z.HasExtensions() && z.DecExt(yyw6) { - } else { - z.DecFallback(yyw6, false) - } - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*JobDiff{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encMapstringPtrtoAllocMetric(v map[string]*AllocMetric, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeMapStart(len(v)) - for yyk1, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerMapKey100) - yym2 := z.EncBinary() - _ = yym2 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(yyk1)) - } - z.EncSendContainerState(codecSelfer_containerMapValue100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) decMapstringPtrtoAllocMetric(v *map[string]*AllocMetric, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyl1 := r.ReadMapStart() - yybh1 := z.DecBasicHandle() - if yyv1 == nil { - yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 24) - yyv1 = make(map[string]*AllocMetric, yyrl1) - *v = yyv1 - } - var yymk1 string - var yymv1 *AllocMetric - var yymg1, yyms1, yymok1 bool - if yybh1.MapValueReset { - yymg1 = true - } - if yyl1 > 0 { - for yyj1 := 0; yyj1 < yyl1; yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv2 := &yymk1 - yym3 := z.DecBinary() - _ = yym3 - if false { - } else { - *((*string)(yyv2)) = r.DecodeString() - } - } - - yyms1 = true - if yymg1 { - yymv1, yymok1 = yyv1[yymk1] - if yymok1 { - yyms1 = false - } - } else { - yymv1 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - if yymv1 != nil { - *yymv1 = AllocMetric{} - } - } else { - if yymv1 == nil { - yymv1 = new(AllocMetric) - } - yymv1.CodecDecodeSelf(d) - } - - if yyms1 && yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } else if yyl1 < 0 { - for yyj1 := 0; !r.CheckBreak(); yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv5 := &yymk1 - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*string)(yyv5)) = r.DecodeString() - } - } - - yyms1 = true - if yymg1 { - yymv1, yymok1 = yyv1[yymk1] - if yymok1 { - yyms1 = false - } - } else { - yymv1 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - if yymv1 != nil { - *yymv1 = AllocMetric{} - } - } else { - if yymv1 == nil { - yymv1 = new(AllocMetric) - } - yymv1.CodecDecodeSelf(d) - } - - if yyms1 && yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } // else len==0: TODO: Should we clear map entries? - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) encSlicePtrtoAllocListStub(v []*AllocListStub, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoAllocListStub(v *[]*AllocListStub, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*AllocListStub{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*AllocListStub, yyrl1) - } - } else { - yyv1 = make([]*AllocListStub, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = AllocListStub{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(AllocListStub) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = AllocListStub{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(AllocListStub) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *AllocListStub - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = AllocListStub{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(AllocListStub) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*AllocListStub{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encSlicePtrtoDeployment(v []*Deployment, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoDeployment(v *[]*Deployment, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*Deployment{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*Deployment, yyrl1) - } - } else { - yyv1 = make([]*Deployment, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Deployment{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Deployment) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Deployment{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Deployment) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *Deployment - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Deployment{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Deployment) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*Deployment{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encNetworks(v Networks, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decNetworks(v *Networks, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*NetworkResource{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*NetworkResource, yyrl1) - } - } else { - yyv1 = make([]*NetworkResource, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = NetworkResource{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(NetworkResource) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = NetworkResource{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(NetworkResource) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *NetworkResource - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = NetworkResource{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(NetworkResource) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*NetworkResource{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encSlicePort(v []Port, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - yy2 := &yyv1 - yy2.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePort(v *[]Port, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []Port{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 24) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]Port, yyrl1) - } - } else { - yyv1 = make([]Port, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - yyv1[yyj1] = Port{} - } else { - yyv2 := &yyv1[yyj1] - yyv2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, Port{}) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - yyv1[yyj1] = Port{} - } else { - yyv3 := &yyv1[yyj1] - yyv3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, Port{}) // var yyz1 Port - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - yyv1[yyj1] = Port{} - } else { - yyv4 := &yyv1[yyj1] - yyv4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []Port{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encSlicePtrtoConstraint(v []*Constraint, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoConstraint(v *[]*Constraint, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*Constraint{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*Constraint, yyrl1) - } - } else { - yyv1 = make([]*Constraint, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Constraint{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Constraint) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Constraint{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Constraint) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *Constraint - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Constraint{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Constraint) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*Constraint{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encSlicePtrtoTaskGroup(v []*TaskGroup, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoTaskGroup(v *[]*TaskGroup, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*TaskGroup{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*TaskGroup, yyrl1) - } - } else { - yyv1 = make([]*TaskGroup, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = TaskGroup{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(TaskGroup) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = TaskGroup{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(TaskGroup) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *TaskGroup - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = TaskGroup{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(TaskGroup) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*TaskGroup{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encMapstringTaskGroupSummary(v map[string]TaskGroupSummary, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeMapStart(len(v)) - for yyk1, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerMapKey100) - yym2 := z.EncBinary() - _ = yym2 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(yyk1)) - } - z.EncSendContainerState(codecSelfer_containerMapValue100) - yy3 := &yyv1 - yy3.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) decMapstringTaskGroupSummary(v *map[string]TaskGroupSummary, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyl1 := r.ReadMapStart() - yybh1 := z.DecBasicHandle() - if yyv1 == nil { - yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 64) - yyv1 = make(map[string]TaskGroupSummary, yyrl1) - *v = yyv1 - } - var yymk1 string - var yymv1 TaskGroupSummary - var yymg1 bool - if yybh1.MapValueReset { - yymg1 = true - } - if yyl1 > 0 { - for yyj1 := 0; yyj1 < yyl1; yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv2 := &yymk1 - yym3 := z.DecBinary() - _ = yym3 - if false { - } else { - *((*string)(yyv2)) = r.DecodeString() - } - } - - if yymg1 { - yymv1 = yyv1[yymk1] - } else { - yymv1 = TaskGroupSummary{} - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - yymv1 = TaskGroupSummary{} - } else { - yyv4 := &yymv1 - yyv4.CodecDecodeSelf(d) - } - - if yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } else if yyl1 < 0 { - for yyj1 := 0; !r.CheckBreak(); yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv5 := &yymk1 - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*string)(yyv5)) = r.DecodeString() - } - } - - if yymg1 { - yymv1 = yyv1[yymk1] - } else { - yymv1 = TaskGroupSummary{} - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - yymv1 = TaskGroupSummary{} - } else { - yyv7 := &yymv1 - yyv7.CodecDecodeSelf(d) - } - - if yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } // else len==0: TODO: Should we clear map entries? - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) encSlicePtrtoTask(v []*Task, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoTask(v *[]*Task, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*Task{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*Task, yyrl1) - } - } else { - yyv1 = make([]*Task, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Task{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Task) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Task{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Task) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *Task - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Task{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Task) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*Task{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encMapstringSlicestring(v map[string][]string, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeMapStart(len(v)) - for yyk1, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerMapKey100) - yym2 := z.EncBinary() - _ = yym2 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(yyk1)) - } - z.EncSendContainerState(codecSelfer_containerMapValue100) - if yyv1 == nil { - r.EncodeNil() - } else { - yym3 := z.EncBinary() - _ = yym3 - if false { - } else { - z.F.EncSliceStringV(yyv1, false, e) - } - } - } - z.EncSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) decMapstringSlicestring(v *map[string][]string, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyl1 := r.ReadMapStart() - yybh1 := z.DecBasicHandle() - if yyv1 == nil { - yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 40) - yyv1 = make(map[string][]string, yyrl1) - *v = yyv1 - } - var yymk1 string - var yymv1 []string - var yymg1 bool - if yybh1.MapValueReset { - yymg1 = true - } - if yyl1 > 0 { - for yyj1 := 0; yyj1 < yyl1; yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv2 := &yymk1 - yym3 := z.DecBinary() - _ = yym3 - if false { - } else { - *((*string)(yyv2)) = r.DecodeString() - } - } - - if yymg1 { - yymv1 = yyv1[yymk1] - } else { - yymv1 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - yymv1 = nil - } else { - yyv4 := &yymv1 - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - z.F.DecSliceStringX(yyv4, false, d) - } - } - - if yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } else if yyl1 < 0 { - for yyj1 := 0; !r.CheckBreak(); yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv6 := &yymk1 - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - - if yymg1 { - yymv1 = yyv1[yymk1] - } else { - yymv1 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - yymv1 = nil - } else { - yyv8 := &yymv1 - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - z.F.DecSliceStringX(yyv8, false, d) - } - } - - if yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } // else len==0: TODO: Should we clear map entries? - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) encSlicePtrtoServiceCheck(v []*ServiceCheck, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoServiceCheck(v *[]*ServiceCheck, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*ServiceCheck{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*ServiceCheck, yyrl1) - } - } else { - yyv1 = make([]*ServiceCheck, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = ServiceCheck{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(ServiceCheck) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = ServiceCheck{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(ServiceCheck) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *ServiceCheck - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = ServiceCheck{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(ServiceCheck) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*ServiceCheck{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encSlicePtrtoService(v []*Service, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoService(v *[]*Service, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*Service{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*Service, yyrl1) - } - } else { - yyv1 = make([]*Service, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Service{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Service) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Service{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Service) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *Service - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Service{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Service) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*Service{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encSlicePtrtoTemplate(v []*Template, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoTemplate(v *[]*Template, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*Template{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*Template, yyrl1) - } - } else { - yyv1 = make([]*Template, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Template{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Template) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Template{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Template) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *Template - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = Template{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(Template) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*Template{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encSlicePtrtoTaskArtifact(v []*TaskArtifact, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoTaskArtifact(v *[]*TaskArtifact, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*TaskArtifact{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*TaskArtifact, yyrl1) - } - } else { - yyv1 = make([]*TaskArtifact, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = TaskArtifact{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(TaskArtifact) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = TaskArtifact{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(TaskArtifact) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *TaskArtifact - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = TaskArtifact{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(TaskArtifact) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*TaskArtifact{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encSlicePtrtoTaskEvent(v []*TaskEvent, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoTaskEvent(v *[]*TaskEvent, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*TaskEvent{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*TaskEvent, yyrl1) - } - } else { - yyv1 = make([]*TaskEvent, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = TaskEvent{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(TaskEvent) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = TaskEvent{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(TaskEvent) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *TaskEvent - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = TaskEvent{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(TaskEvent) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*TaskEvent{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encMapstringPtrtoDeploymentState(v map[string]*DeploymentState, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeMapStart(len(v)) - for yyk1, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerMapKey100) - yym2 := z.EncBinary() - _ = yym2 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(yyk1)) - } - z.EncSendContainerState(codecSelfer_containerMapValue100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) decMapstringPtrtoDeploymentState(v *map[string]*DeploymentState, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyl1 := r.ReadMapStart() - yybh1 := z.DecBasicHandle() - if yyv1 == nil { - yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 24) - yyv1 = make(map[string]*DeploymentState, yyrl1) - *v = yyv1 - } - var yymk1 string - var yymv1 *DeploymentState - var yymg1, yyms1, yymok1 bool - if yybh1.MapValueReset { - yymg1 = true - } - if yyl1 > 0 { - for yyj1 := 0; yyj1 < yyl1; yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv2 := &yymk1 - yym3 := z.DecBinary() - _ = yym3 - if false { - } else { - *((*string)(yyv2)) = r.DecodeString() - } - } - - yyms1 = true - if yymg1 { - yymv1, yymok1 = yyv1[yymk1] - if yymok1 { - yyms1 = false - } - } else { - yymv1 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - if yymv1 != nil { - *yymv1 = DeploymentState{} - } - } else { - if yymv1 == nil { - yymv1 = new(DeploymentState) - } - yymv1.CodecDecodeSelf(d) - } - - if yyms1 && yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } else if yyl1 < 0 { - for yyj1 := 0; !r.CheckBreak(); yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv5 := &yymk1 - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*string)(yyv5)) = r.DecodeString() - } - } - - yyms1 = true - if yymg1 { - yymv1, yymok1 = yyv1[yymk1] - if yymok1 { - yyms1 = false - } - } else { - yymv1 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - if yymv1 != nil { - *yymv1 = DeploymentState{} - } - } else { - if yymv1 == nil { - yymv1 = new(DeploymentState) - } - yymv1.CodecDecodeSelf(d) - } - - if yyms1 && yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } // else len==0: TODO: Should we clear map entries? - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) encMapstringPtrtoResources(v map[string]*Resources, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeMapStart(len(v)) - for yyk1, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerMapKey100) - yym2 := z.EncBinary() - _ = yym2 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(yyk1)) - } - z.EncSendContainerState(codecSelfer_containerMapValue100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) decMapstringPtrtoResources(v *map[string]*Resources, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyl1 := r.ReadMapStart() - yybh1 := z.DecBasicHandle() - if yyv1 == nil { - yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 24) - yyv1 = make(map[string]*Resources, yyrl1) - *v = yyv1 - } - var yymk1 string - var yymv1 *Resources - var yymg1, yyms1, yymok1 bool - if yybh1.MapValueReset { - yymg1 = true - } - if yyl1 > 0 { - for yyj1 := 0; yyj1 < yyl1; yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv2 := &yymk1 - yym3 := z.DecBinary() - _ = yym3 - if false { - } else { - *((*string)(yyv2)) = r.DecodeString() - } - } - - yyms1 = true - if yymg1 { - yymv1, yymok1 = yyv1[yymk1] - if yymok1 { - yyms1 = false - } - } else { - yymv1 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - if yymv1 != nil { - *yymv1 = Resources{} - } - } else { - if yymv1 == nil { - yymv1 = new(Resources) - } - yymv1.CodecDecodeSelf(d) - } - - if yyms1 && yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } else if yyl1 < 0 { - for yyj1 := 0; !r.CheckBreak(); yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv5 := &yymk1 - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*string)(yyv5)) = r.DecodeString() - } - } - - yyms1 = true - if yymg1 { - yymv1, yymok1 = yyv1[yymk1] - if yymok1 { - yyms1 = false - } - } else { - yymv1 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - if yymv1 != nil { - *yymv1 = Resources{} - } - } else { - if yymv1 == nil { - yymv1 = new(Resources) - } - yymv1.CodecDecodeSelf(d) - } - - if yyms1 && yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } // else len==0: TODO: Should we clear map entries? - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) encMapstringPtrtoTaskState(v map[string]*TaskState, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeMapStart(len(v)) - for yyk1, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerMapKey100) - yym2 := z.EncBinary() - _ = yym2 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(yyk1)) - } - z.EncSendContainerState(codecSelfer_containerMapValue100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) decMapstringPtrtoTaskState(v *map[string]*TaskState, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyl1 := r.ReadMapStart() - yybh1 := z.DecBasicHandle() - if yyv1 == nil { - yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 24) - yyv1 = make(map[string]*TaskState, yyrl1) - *v = yyv1 - } - var yymk1 string - var yymv1 *TaskState - var yymg1, yyms1, yymok1 bool - if yybh1.MapValueReset { - yymg1 = true - } - if yyl1 > 0 { - for yyj1 := 0; yyj1 < yyl1; yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv2 := &yymk1 - yym3 := z.DecBinary() - _ = yym3 - if false { - } else { - *((*string)(yyv2)) = r.DecodeString() - } - } - - yyms1 = true - if yymg1 { - yymv1, yymok1 = yyv1[yymk1] - if yymok1 { - yyms1 = false - } - } else { - yymv1 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - if yymv1 != nil { - *yymv1 = TaskState{} - } - } else { - if yymv1 == nil { - yymv1 = new(TaskState) - } - yymv1.CodecDecodeSelf(d) - } - - if yyms1 && yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } else if yyl1 < 0 { - for yyj1 := 0; !r.CheckBreak(); yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv5 := &yymk1 - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*string)(yyv5)) = r.DecodeString() - } - } - - yyms1 = true - if yymg1 { - yymv1, yymok1 = yyv1[yymk1] - if yymok1 { - yyms1 = false - } - } else { - yymv1 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - if yymv1 != nil { - *yymv1 = TaskState{} - } - } else { - if yymv1 == nil { - yymv1 = new(TaskState) - } - yymv1.CodecDecodeSelf(d) - } - - if yyms1 && yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } // else len==0: TODO: Should we clear map entries? - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) encMapstringSlicePtrtoAllocation(v map[string][]*Allocation, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeMapStart(len(v)) - for yyk1, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerMapKey100) - yym2 := z.EncBinary() - _ = yym2 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(yyk1)) - } - z.EncSendContainerState(codecSelfer_containerMapValue100) - if yyv1 == nil { - r.EncodeNil() - } else { - yym3 := z.EncBinary() - _ = yym3 - if false { - } else { - h.encSlicePtrtoAllocation(([]*Allocation)(yyv1), e) - } - } - } - z.EncSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) decMapstringSlicePtrtoAllocation(v *map[string][]*Allocation, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyl1 := r.ReadMapStart() - yybh1 := z.DecBasicHandle() - if yyv1 == nil { - yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 40) - yyv1 = make(map[string][]*Allocation, yyrl1) - *v = yyv1 - } - var yymk1 string - var yymv1 []*Allocation - var yymg1 bool - if yybh1.MapValueReset { - yymg1 = true - } - if yyl1 > 0 { - for yyj1 := 0; yyj1 < yyl1; yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv2 := &yymk1 - yym3 := z.DecBinary() - _ = yym3 - if false { - } else { - *((*string)(yyv2)) = r.DecodeString() - } - } - - if yymg1 { - yymv1 = yyv1[yymk1] - } else { - yymv1 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - yymv1 = nil - } else { - yyv4 := &yymv1 - yym5 := z.DecBinary() - _ = yym5 - if false { - } else { - h.decSlicePtrtoAllocation((*[]*Allocation)(yyv4), d) - } - } - - if yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } else if yyl1 < 0 { - for yyj1 := 0; !r.CheckBreak(); yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv6 := &yymk1 - yym7 := z.DecBinary() - _ = yym7 - if false { - } else { - *((*string)(yyv6)) = r.DecodeString() - } - } - - if yymg1 { - yymv1 = yyv1[yymk1] - } else { - yymv1 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - yymv1 = nil - } else { - yyv8 := &yymv1 - yym9 := z.DecBinary() - _ = yym9 - if false { - } else { - h.decSlicePtrtoAllocation((*[]*Allocation)(yyv8), d) - } - } - - if yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } // else len==0: TODO: Should we clear map entries? - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) encMapstringPtrtoDesiredUpdates(v map[string]*DesiredUpdates, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeMapStart(len(v)) - for yyk1, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerMapKey100) - yym2 := z.EncBinary() - _ = yym2 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(yyk1)) - } - z.EncSendContainerState(codecSelfer_containerMapValue100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) decMapstringPtrtoDesiredUpdates(v *map[string]*DesiredUpdates, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyl1 := r.ReadMapStart() - yybh1 := z.DecBasicHandle() - if yyv1 == nil { - yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 24) - yyv1 = make(map[string]*DesiredUpdates, yyrl1) - *v = yyv1 - } - var yymk1 string - var yymv1 *DesiredUpdates - var yymg1, yyms1, yymok1 bool - if yybh1.MapValueReset { - yymg1 = true - } - if yyl1 > 0 { - for yyj1 := 0; yyj1 < yyl1; yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv2 := &yymk1 - yym3 := z.DecBinary() - _ = yym3 - if false { - } else { - *((*string)(yyv2)) = r.DecodeString() - } - } - - yyms1 = true - if yymg1 { - yymv1, yymok1 = yyv1[yymk1] - if yymok1 { - yyms1 = false - } - } else { - yymv1 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - if yymv1 != nil { - *yymv1 = DesiredUpdates{} - } - } else { - if yymv1 == nil { - yymv1 = new(DesiredUpdates) - } - yymv1.CodecDecodeSelf(d) - } - - if yyms1 && yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } else if yyl1 < 0 { - for yyj1 := 0; !r.CheckBreak(); yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv5 := &yymk1 - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*string)(yyv5)) = r.DecodeString() - } - } - - yyms1 = true - if yymg1 { - yymv1, yymok1 = yyv1[yymk1] - if yymok1 { - yyms1 = false - } - } else { - yymv1 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - if yymv1 != nil { - *yymv1 = DesiredUpdates{} - } - } else { - if yymv1 == nil { - yymv1 = new(DesiredUpdates) - } - yymv1.CodecDecodeSelf(d) - } - - if yyms1 && yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } // else len==0: TODO: Should we clear map entries? - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) encSlicePtrtoACLPolicyListStub(v []*ACLPolicyListStub, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoACLPolicyListStub(v *[]*ACLPolicyListStub, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*ACLPolicyListStub{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*ACLPolicyListStub, yyrl1) - } - } else { - yyv1 = make([]*ACLPolicyListStub, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = ACLPolicyListStub{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(ACLPolicyListStub) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = ACLPolicyListStub{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(ACLPolicyListStub) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *ACLPolicyListStub - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = ACLPolicyListStub{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(ACLPolicyListStub) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*ACLPolicyListStub{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encMapstringPtrtoACLPolicy(v map[string]*ACLPolicy, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeMapStart(len(v)) - for yyk1, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerMapKey100) - yym2 := z.EncBinary() - _ = yym2 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(yyk1)) - } - z.EncSendContainerState(codecSelfer_containerMapValue100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) decMapstringPtrtoACLPolicy(v *map[string]*ACLPolicy, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyl1 := r.ReadMapStart() - yybh1 := z.DecBasicHandle() - if yyv1 == nil { - yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 24) - yyv1 = make(map[string]*ACLPolicy, yyrl1) - *v = yyv1 - } - var yymk1 string - var yymv1 *ACLPolicy - var yymg1, yyms1, yymok1 bool - if yybh1.MapValueReset { - yymg1 = true - } - if yyl1 > 0 { - for yyj1 := 0; yyj1 < yyl1; yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv2 := &yymk1 - yym3 := z.DecBinary() - _ = yym3 - if false { - } else { - *((*string)(yyv2)) = r.DecodeString() - } - } - - yyms1 = true - if yymg1 { - yymv1, yymok1 = yyv1[yymk1] - if yymok1 { - yyms1 = false - } - } else { - yymv1 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - if yymv1 != nil { - *yymv1 = ACLPolicy{} - } - } else { - if yymv1 == nil { - yymv1 = new(ACLPolicy) - } - yymv1.CodecDecodeSelf(d) - } - - if yyms1 && yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } else if yyl1 < 0 { - for yyj1 := 0; !r.CheckBreak(); yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv5 := &yymk1 - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*string)(yyv5)) = r.DecodeString() - } - } - - yyms1 = true - if yymg1 { - yymv1, yymok1 = yyv1[yymk1] - if yymok1 { - yyms1 = false - } - } else { - yymv1 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - if yymv1 != nil { - *yymv1 = ACLPolicy{} - } - } else { - if yymv1 == nil { - yymv1 = new(ACLPolicy) - } - yymv1.CodecDecodeSelf(d) - } - - if yyms1 && yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } // else len==0: TODO: Should we clear map entries? - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) encSlicePtrtoACLPolicy(v []*ACLPolicy, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoACLPolicy(v *[]*ACLPolicy, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*ACLPolicy{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*ACLPolicy, yyrl1) - } - } else { - yyv1 = make([]*ACLPolicy, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = ACLPolicy{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(ACLPolicy) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = ACLPolicy{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(ACLPolicy) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *ACLPolicy - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = ACLPolicy{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(ACLPolicy) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*ACLPolicy{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encSlicePtrtoACLTokenListStub(v []*ACLTokenListStub, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoACLTokenListStub(v *[]*ACLTokenListStub, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*ACLTokenListStub{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*ACLTokenListStub, yyrl1) - } - } else { - yyv1 = make([]*ACLTokenListStub, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = ACLTokenListStub{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(ACLTokenListStub) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = ACLTokenListStub{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(ACLTokenListStub) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *ACLTokenListStub - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = ACLTokenListStub{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(ACLTokenListStub) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*ACLTokenListStub{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} - -func (x codecSelfer100) encMapstringPtrtoACLToken(v map[string]*ACLToken, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeMapStart(len(v)) - for yyk1, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerMapKey100) - yym2 := z.EncBinary() - _ = yym2 - if false { - } else { - r.EncodeString(codecSelferC_UTF8100, string(yyk1)) - } - z.EncSendContainerState(codecSelfer_containerMapValue100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) decMapstringPtrtoACLToken(v *map[string]*ACLToken, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyl1 := r.ReadMapStart() - yybh1 := z.DecBasicHandle() - if yyv1 == nil { - yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 24) - yyv1 = make(map[string]*ACLToken, yyrl1) - *v = yyv1 - } - var yymk1 string - var yymv1 *ACLToken - var yymg1, yyms1, yymok1 bool - if yybh1.MapValueReset { - yymg1 = true - } - if yyl1 > 0 { - for yyj1 := 0; yyj1 < yyl1; yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv2 := &yymk1 - yym3 := z.DecBinary() - _ = yym3 - if false { - } else { - *((*string)(yyv2)) = r.DecodeString() - } - } - - yyms1 = true - if yymg1 { - yymv1, yymok1 = yyv1[yymk1] - if yymok1 { - yyms1 = false - } - } else { - yymv1 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - if yymv1 != nil { - *yymv1 = ACLToken{} - } - } else { - if yymv1 == nil { - yymv1 = new(ACLToken) - } - yymv1.CodecDecodeSelf(d) - } - - if yyms1 && yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } else if yyl1 < 0 { - for yyj1 := 0; !r.CheckBreak(); yyj1++ { - z.DecSendContainerState(codecSelfer_containerMapKey100) - if r.TryDecodeAsNil() { - yymk1 = "" - } else { - yyv5 := &yymk1 - yym6 := z.DecBinary() - _ = yym6 - if false { - } else { - *((*string)(yyv5)) = r.DecodeString() - } - } - - yyms1 = true - if yymg1 { - yymv1, yymok1 = yyv1[yymk1] - if yymok1 { - yyms1 = false - } - } else { - yymv1 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue100) - if r.TryDecodeAsNil() { - if yymv1 != nil { - *yymv1 = ACLToken{} - } - } else { - if yymv1 == nil { - yymv1 = new(ACLToken) - } - yymv1.CodecDecodeSelf(d) - } - - if yyms1 && yyv1 != nil { - yyv1[yymk1] = yymv1 - } - } - } // else len==0: TODO: Should we clear map entries? - z.DecSendContainerState(codecSelfer_containerMapEnd100) -} - -func (x codecSelfer100) encSlicePtrtoACLToken(v []*ACLToken, e *codec1978.Encoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem100) - if yyv1 == nil { - r.EncodeNil() - } else { - yyv1.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd100) -} - -func (x codecSelfer100) decSlicePtrtoACLToken(v *[]*ACLToken, d *codec1978.Decoder) { - var h codecSelfer100 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1 := *v - yyh1, yyl1 := z.DecSliceHelperStart() - var yyc1 bool - _ = yyc1 - if yyl1 == 0 { - if yyv1 == nil { - yyv1 = []*ACLToken{} - yyc1 = true - } else if len(yyv1) != 0 { - yyv1 = yyv1[:0] - yyc1 = true - } - } else if yyl1 > 0 { - var yyrr1, yyrl1 int - var yyrt1 bool - _, _ = yyrl1, yyrt1 - yyrr1 = yyl1 // len(yyv1) - if yyl1 > cap(yyv1) { - - yyrg1 := len(yyv1) > 0 - yyv21 := yyv1 - yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1 { - if yyrl1 <= cap(yyv1) { - yyv1 = yyv1[:yyrl1] - } else { - yyv1 = make([]*ACLToken, yyrl1) - } - } else { - yyv1 = make([]*ACLToken, yyrl1) - } - yyc1 = true - yyrr1 = len(yyv1) - if yyrg1 { - copy(yyv1, yyv21) - } - } else if yyl1 != len(yyv1) { - yyv1 = yyv1[:yyl1] - yyc1 = true - } - yyj1 := 0 - for ; yyj1 < yyrr1; yyj1++ { - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = ACLToken{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(ACLToken) - } - yyw2 := yyv1[yyj1] - yyw2.CodecDecodeSelf(d) - } - - } - if yyrt1 { - for ; yyj1 < yyl1; yyj1++ { - yyv1 = append(yyv1, nil) - yyh1.ElemContainerState(yyj1) - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = ACLToken{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(ACLToken) - } - yyw3 := yyv1[yyj1] - yyw3.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1 := 0 - for ; !r.CheckBreak(); yyj1++ { - - if yyj1 >= len(yyv1) { - yyv1 = append(yyv1, nil) // var yyz1 *ACLToken - yyc1 = true - } - yyh1.ElemContainerState(yyj1) - if yyj1 < len(yyv1) { - if r.TryDecodeAsNil() { - if yyv1[yyj1] != nil { - *yyv1[yyj1] = ACLToken{} - } - } else { - if yyv1[yyj1] == nil { - yyv1[yyj1] = new(ACLToken) - } - yyw4 := yyv1[yyj1] - yyw4.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1 < len(yyv1) { - yyv1 = yyv1[:yyj1] - yyc1 = true - } else if yyj1 == 0 && yyv1 == nil { - yyv1 = []*ACLToken{} - yyc1 = true - } - } - yyh1.End() - if yyc1 { - *v = yyv1 - } -} diff --git a/version/version.go b/version/version.go index d41e530a9..6e4afe5c0 100644 --- a/version/version.go +++ b/version/version.go @@ -11,12 +11,12 @@ var ( GitDescribe string // The main version number that is being run at the moment. - Version = "0.7.1" + Version = "0.8.0" // A pre-release marker for the version. If this is "" (empty string) // then it means that it is a final release. Otherwise, this is a pre-release // such as "dev" (in development), "beta", "rc1", etc. - VersionPrerelease = "" + VersionPrerelease = "dev" // VersionMetadata is metadata further describing the build type. VersionMetadata = "" From b612f7a337feb7be134edfc694c8b9be61d134a8 Mon Sep 17 00:00:00 2001 From: Alex Dadgar Date: Tue, 19 Dec 2017 17:12:21 -0800 Subject: [PATCH 022/136] bump website --- website/config.rb | 2 +- website/source/downloads.html.erb | 4 ---- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/website/config.rb b/website/config.rb index fe55d2bc4..46bdc3be8 100644 --- a/website/config.rb +++ b/website/config.rb @@ -2,7 +2,7 @@ set :base_url, "https://www.nomadproject.io/" activate :hashicorp do |h| h.name = "nomad" - h.version = "0.7.0" + h.version = "0.7.1" h.github_slug = "hashicorp/nomad" end diff --git a/website/source/downloads.html.erb b/website/source/downloads.html.erb index d3d994e5b..4156f48ae 100644 --- a/website/source/downloads.html.erb +++ b/website/source/downloads.html.erb @@ -31,10 +31,6 @@ description: |-

      Check out the v<%= latest_version %> CHANGELOG for information on the latest release.

      -

      Nomad 0.7.1 RC1

      -

      - A release candidate of Nomad 0.7.1 is also available! The RC can be downloaded on the Nomad releases page. -

      From 2b1d7f3cc6f3dadd34d04d83d7c2feb90f62d2a8 Mon Sep 17 00:00:00 2001 From: Chelsea Holland Komlo Date: Wed, 20 Dec 2017 15:17:28 -0500 Subject: [PATCH 023/136] search endpoint forwarding --- nomad/search_endpoint.go | 7 ++++++ nomad/search_endpoint_test.go | 44 +++++++++++++++++++++++++++++++++++ 2 files changed, 51 insertions(+) diff --git a/nomad/search_endpoint.go b/nomad/search_endpoint.go index 61931a5e8..512ef3e04 100644 --- a/nomad/search_endpoint.go +++ b/nomad/search_endpoint.go @@ -2,7 +2,9 @@ package nomad import ( "strings" + "time" + metrics "github.com/armon/go-metrics" memdb "github.com/hashicorp/go-memdb" "github.com/hashicorp/nomad/acl" "github.com/hashicorp/nomad/nomad/state" @@ -114,6 +116,11 @@ func roundUUIDDownIfOdd(prefix string, context structs.Context) string { // PrefixSearch is used to list matches for a given prefix, and returns // matching jobs, evaluations, allocations, and/or nodes. func (s *Search) PrefixSearch(args *structs.SearchRequest, reply *structs.SearchResponse) error { + if done, err := s.srv.forward("Search.PrefixSearch", args, args, reply); done { + return err + } + defer metrics.MeasureSince([]string{"nomad", "search", "prefixsearch"}, time.Now()) + aclObj, err := s.srv.ResolveToken(args.AuthToken) if err != nil { return err diff --git a/nomad/search_endpoint_test.go b/nomad/search_endpoint_test.go index 7cd6fe6b2..2631b6958 100644 --- a/nomad/search_endpoint_test.go +++ b/nomad/search_endpoint_test.go @@ -712,3 +712,47 @@ func TestSearch_PrefixSearch_RoundDownToEven(t *testing.T) { assert.Equal(1, len(resp.Matches[structs.Jobs])) assert.Equal(job.ID, resp.Matches[structs.Jobs][0]) } + +func TestSearch_PrefixSearch_MultiRegion(t *testing.T) { + assert := assert.New(t) + + jobName := "exampleexample" + + t.Parallel() + s1 := testServer(t, func(c *Config) { + c.NumSchedulers = 0 + c.Region = "foo" + }) + defer s1.Shutdown() + + s2 := testServer(t, func(c *Config) { + c.NumSchedulers = 0 + c.Region = "bar" + }) + defer s2.Shutdown() + + testJoin(t, s1, s2) + testutil.WaitForLeader(t, s1.RPC) + + job := registerAndVerifyJob(s1, t, jobName, 0) + + req := &structs.SearchRequest{ + Prefix: "", + Context: structs.Jobs, + QueryOptions: structs.QueryOptions{ + Region: "foo", + Namespace: job.Namespace, + }, + } + + codec := rpcClient(t, s2) + + var resp structs.SearchResponse + if err := msgpackrpc.CallWithCodec(codec, "Search.PrefixSearch", req, &resp); err != nil { + t.Fatalf("err: %v", err) + } + + assert.Equal(1, len(resp.Matches[structs.Jobs])) + assert.Equal(job.ID, resp.Matches[structs.Jobs][0]) + assert.Equal(uint64(jobIndex), resp.Index) +} From 47ca3836667d4512779935ca8fcbf85d0335d7d1 Mon Sep 17 00:00:00 2001 From: Chelsea Holland Komlo Date: Wed, 20 Dec 2017 17:52:41 -0500 Subject: [PATCH 024/136] Fixes #3679 code review fixups; add changelog --- CHANGELOG.md | 5 +++++ nomad/search_endpoint.go | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index a828d589e..ca29ae618 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,8 @@ +## 0.8 (Unreleased) + +BUG FIXES: + * core: Fix search endpoint forwarding for multi-region clusters [GH-3679] + ## 0.7.1 (December 19, 2017) __BACKWARDS INCOMPATIBILITIES:__ diff --git a/nomad/search_endpoint.go b/nomad/search_endpoint.go index 512ef3e04..9eb892dd3 100644 --- a/nomad/search_endpoint.go +++ b/nomad/search_endpoint.go @@ -119,7 +119,7 @@ func (s *Search) PrefixSearch(args *structs.SearchRequest, reply *structs.Search if done, err := s.srv.forward("Search.PrefixSearch", args, args, reply); done { return err } - defer metrics.MeasureSince([]string{"nomad", "search", "prefixsearch"}, time.Now()) + defer metrics.MeasureSince([]string{"nomad", "search", "prefix_search"}, time.Now()) aclObj, err := s.srv.ResolveToken(args.AuthToken) if err != nil { From 4668c1f48f8012d651578765d12b2f11e2667576 Mon Sep 17 00:00:00 2001 From: Chelsea Holland Komlo Date: Wed, 20 Dec 2017 19:04:07 -0500 Subject: [PATCH 025/136] update changelog --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ca29ae618..2453ae1a0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,7 +1,7 @@ ## 0.8 (Unreleased) BUG FIXES: - * core: Fix search endpoint forwarding for multi-region clusters [GH-3679] + * core: Fix search endpoint forwarding for multi-region clusters [GH-3680] ## 0.7.1 (December 19, 2017) From edbcea0696f613a2cfd08f396c0d6ce662d39752 Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Wed, 20 Dec 2017 15:41:33 -0800 Subject: [PATCH 026/136] Makes macos/osx builds optional in Travis --- .travis.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.travis.yml b/.travis.yml index 4a40eb16a..022c49a28 100644 --- a/.travis.yml +++ b/.travis.yml @@ -13,9 +13,6 @@ branches: only: - master -matrix: - include: - matrix: include: - os: linux @@ -31,6 +28,9 @@ matrix: env: RUN_STATIC_CHECKS=1 SKIP_NOMAD_TESTS=1 - os: osx osx_image: xcode9.1 + allow_failures: + - os: osx + fast_finish: true cache: directories: From d234641d1c62024eb0076ad8f6e994be0869fec6 Mon Sep 17 00:00:00 2001 From: Filip Ochnik Date: Thu, 21 Dec 2017 10:32:12 +0100 Subject: [PATCH 027/136] Prevent absolute URLs in checks paths --- nomad/structs/structs.go | 8 +++++++ nomad/structs/structs_test.go | 31 ++++++++++++++++++++++++++++ website/source/api/json-jobs.html.md | 3 ++- 3 files changed, 41 insertions(+), 1 deletion(-) diff --git a/nomad/structs/structs.go b/nomad/structs/structs.go index fa994e194..b59a1a2ba 100644 --- a/nomad/structs/structs.go +++ b/nomad/structs/structs.go @@ -12,6 +12,7 @@ import ( "fmt" "io" "net" + "net/url" "os" "path/filepath" "reflect" @@ -2937,6 +2938,13 @@ func (sc *ServiceCheck) validate() error { if sc.Path == "" { return fmt.Errorf("http type must have a valid http path") } + url, err := url.Parse(sc.Path) + if err != nil { + return fmt.Errorf("http type must have a valid http path") + } + if url.IsAbs() { + return fmt.Errorf("http type must have a relative http path") + } case ServiceCheckScript: if sc.Command == "" { diff --git a/nomad/structs/structs_test.go b/nomad/structs/structs_test.go index 4897e0422..c4e52038f 100644 --- a/nomad/structs/structs_test.go +++ b/nomad/structs/structs_test.go @@ -1230,6 +1230,37 @@ func TestTask_Validate_Service_Check(t *testing.T) { if err != nil { t.Fatalf("err: %v", err) } + + check2 := ServiceCheck{ + Name: "check-name-2", + Type: ServiceCheckHTTP, + Interval: 10 * time.Second, + Timeout: 2 * time.Second, + Path: "/foo/bar", + } + + err = check2.validate() + if err != nil { + t.Fatalf("err: %v", err) + } + + check2.Path = "" + err = check2.validate() + if err == nil { + t.Fatal("Expected an error") + } + if !strings.Contains(err.Error(), "valid http path") { + t.Fatalf("err: %v", err) + } + + check2.Path = "http://www.example.com" + err = check2.validate() + if err == nil { + t.Fatal("Expected an error") + } + if !strings.Contains(err.Error(), "relative http path") { + t.Fatalf("err: %v", err) + } } // TestTask_Validate_Service_Check_AddressMode asserts that checks do not diff --git a/website/source/api/json-jobs.html.md b/website/source/api/json-jobs.html.md index 1fe359af9..95fd024b6 100644 --- a/website/source/api/json-jobs.html.md +++ b/website/source/api/json-jobs.html.md @@ -412,7 +412,8 @@ The `Task` object supports the following keys: - `Path`: The path of the HTTP endpoint which Consul will query to query the health of a service if the type of the check is `http`. Nomad will add the IP of the service and the port, users are only required - to add the relative URL of the health check endpoint. + to add the relative URL of the health check endpoint. Absolute paths + are not allowed. - `Protocol`: This indicates the protocol for the HTTP checks. Valid options are `http` and `https`. We default it to `http`. From 76635f285cc4a64960395639e481fd2c7aa44d48 Mon Sep 17 00:00:00 2001 From: Jaemin Sung Date: Wed, 27 Dec 2017 11:54:20 -0500 Subject: [PATCH 028/136] Add missing token option for nomad run command --- website/source/docs/commands/_general_options.html.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/website/source/docs/commands/_general_options.html.md b/website/source/docs/commands/_general_options.html.md index a3d95dfb6..5a1811f9b 100644 --- a/website/source/docs/commands/_general_options.html.md +++ b/website/source/docs/commands/_general_options.html.md @@ -26,3 +26,6 @@ - `-tls-skip-verify`: Do not verify TLS certificate. This is highly not recommended. Verification will also be skipped if `NOMAD_SKIP_VERIFY` is set. + +- `-token`: The SecretID of an ACL token to use to authenticate API requests with. + Overrides the `NOMAD_TOKEN` environment variable if set. From 2f681cd6663ffc0f33343e8f617c303d3215a7da Mon Sep 17 00:00:00 2001 From: rwaweber Date: Wed, 27 Dec 2017 12:43:36 -0500 Subject: [PATCH 029/136] small signal typo and argument consistency --- website/source/guides/securing-nomad.html.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/website/source/guides/securing-nomad.html.md b/website/source/guides/securing-nomad.html.md index 182c04e41..d4898f3dd 100644 --- a/website/source/guides/securing-nomad.html.md +++ b/website/source/guides/securing-nomad.html.md @@ -113,7 +113,7 @@ $ echo '{}' | cfssl gencert -ca=nomad-ca.pem -ca-key=nomad-ca-key.pem -config=cf -hostname="client.global.nomad,localhost,127.0.0.1" - | cfssljson -bare client # Generate a certificate for the CLI -$ echo '{}' | cfssl gencert -ca nomad-ca.pem -ca-key nomad-ca-key.pem -profile=client \ +$ echo '{}' | cfssl gencert -ca=nomad-ca.pem -ca-key=nomad-ca-key.pem -profile=client \ - | cfssljson -bare cli ``` @@ -433,7 +433,7 @@ TTL. ## Changing Nomad certificates on the fly -As of 0.7.1, Nomad supports dynamic certificate reloading via SIHUP. +As of 0.7.1, Nomad supports dynamic certificate reloading via SIGHUP. Given a prior TLS configuration as follows: From 3a6aba08f305c5bd89f1251a539de48578d08503 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Chris=20K=C3=BChl?= Date: Tue, 2 Jan 2018 10:42:29 +0100 Subject: [PATCH 030/136] Change 'CoreOS rkt' to just 'rkt' CoreOS initiated the project but it is now under the CNCF banner and includes many contributors and core maintainers that are not at CoreOS. --- website/source/docs/drivers/rkt.html.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/website/source/docs/drivers/rkt.html.md b/website/source/docs/drivers/rkt.html.md index 33d44f648..b369efb12 100644 --- a/website/source/docs/drivers/rkt.html.md +++ b/website/source/docs/drivers/rkt.html.md @@ -10,7 +10,7 @@ description: |- Name: `rkt` -The `rkt` driver provides an interface for using CoreOS rkt for running +The `rkt` driver provides an interface for using rkt for running application containers. ## Task Configuration From 957712c58774b3d39f5e5a56b5bbdccee003150f Mon Sep 17 00:00:00 2001 From: Fabian Holler Date: Tue, 2 Jan 2018 15:56:02 +0100 Subject: [PATCH 031/136] revert change to increase min. CPU resource value from 20 to 100 In the commit 622d3ddb92ea7e656ef831641c02024cb5a5d6d1 "Fixed test and moved constants into standalone func" the minimum CPU resource value for a job was increased from 100 to 20. This can break the nomad setup for people that used lower CPU values and are at the maximum MHz value of the available CPU on a machine. Change the minimum back to 20 MHz to ensure downwards compatibility. --- api/resources.go | 2 +- nomad/structs/structs.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/api/resources.go b/api/resources.go index 8c547ee7e..1abcf209d 100644 --- a/api/resources.go +++ b/api/resources.go @@ -49,7 +49,7 @@ func DefaultResources() *Resources { // IN nomad/structs/structs.go and should be kept in sync. func MinResources() *Resources { return &Resources{ - CPU: helper.IntToPtr(100), + CPU: helper.IntToPtr(20), MemoryMB: helper.IntToPtr(10), IOPS: helper.IntToPtr(0), } diff --git a/nomad/structs/structs.go b/nomad/structs/structs.go index fa994e194..3a121f12a 100644 --- a/nomad/structs/structs.go +++ b/nomad/structs/structs.go @@ -1253,7 +1253,7 @@ func DefaultResources() *Resources { // api/resources.go and should be kept in sync. func MinResources() *Resources { return &Resources{ - CPU: 100, + CPU: 20, MemoryMB: 10, IOPS: 0, } From 334ebb08239e52fe2762bf5eac21d5b1a838c70b Mon Sep 17 00:00:00 2001 From: Preetha Date: Wed, 3 Jan 2018 11:52:21 -0600 Subject: [PATCH 032/136] Update CHANGELOG.md Mentions min CPU limit change in backward incompatibilities section. --- CHANGELOG.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2453ae1a0..041171f55 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,7 @@ BUG FIXES: * core: Fix search endpoint forwarding for multi-region clusters [GH-3680] + * config: Revert minimum CPU limit back to 20 from 100. ## 0.7.1 (December 19, 2017) @@ -12,6 +13,8 @@ __BACKWARDS INCOMPATIBILITIES:__ * config: Nomad no longer parses Atlas configuration stanzas. Atlas has been deprecated since earlier this year. If you have an Atlas stanza in your config file it will have to be removed. + * config: Default minimum CPU configuration has been changed from 100 to 20. Jobs + using the old minimum value will have to be updated. * telemetry: Hostname is now emitted via a tag rather than within the key name. To maintain old behavior during an upgrade path specify `backwards_compatible_metrics` in the telemetry configuration. From 9d52bd5e0710f36670b6dbe932aa45089e0b1c5f Mon Sep 17 00:00:00 2001 From: Preetha Date: Wed, 3 Jan 2018 11:53:21 -0600 Subject: [PATCH 033/136] Update CHANGELOG.md --- CHANGELOG.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 041171f55..5578ce365 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,8 +13,8 @@ __BACKWARDS INCOMPATIBILITIES:__ * config: Nomad no longer parses Atlas configuration stanzas. Atlas has been deprecated since earlier this year. If you have an Atlas stanza in your config file it will have to be removed. - * config: Default minimum CPU configuration has been changed from 100 to 20. Jobs - using the old minimum value will have to be updated. + * config: Default minimum CPU configuration has been changed to 100 from 20. Jobs + using the old minimum value of 20 will have to be updated. * telemetry: Hostname is now emitted via a tag rather than within the key name. To maintain old behavior during an upgrade path specify `backwards_compatible_metrics` in the telemetry configuration. From ebbbf432e49a6ccce9f7119c39bec69720becf53 Mon Sep 17 00:00:00 2001 From: Preetha Appan Date: Wed, 3 Jan 2018 16:38:41 -0600 Subject: [PATCH 034/136] Add changelog formatting to make dev --- GNUmakefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/GNUmakefile b/GNUmakefile index c2527210b..3c9741a71 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -208,7 +208,7 @@ dev: GOOS=$(shell go env GOOS) dev: GOARCH=$(shell go env GOARCH) dev: GOPATH=$(shell go env GOPATH) dev: DEV_TARGET=pkg/$(GOOS)_$(GOARCH)$(if $(HAS_LXC),-lxc)/nomad -dev: vendorfmt ## Build for the current development platform +dev: vendorfmt changelogfmt ## Build for the current development platform @echo "==> Removing old development build..." @rm -f $(PROJECT_ROOT)/$(DEV_TARGET) @rm -f $(PROJECT_ROOT)/bin/nomad From 12ce2c93e6053323d3c76777141bd74b2e1a3055 Mon Sep 17 00:00:00 2001 From: Preetha Appan Date: Wed, 3 Jan 2018 16:39:12 -0600 Subject: [PATCH 035/136] Linkify CHANGELOG in one missing place. --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ba1fb8449..2837e14ae 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,7 +1,7 @@ ## 0.8 (Unreleased) BUG FIXES: - * core: Fix search endpoint forwarding for multi-region clusters [GH-3680] + * core: Fix search endpoint forwarding for multi-region clusters [[GH-3680](https://github.com/hashicorp/nomad/issues/3680)] * config: Revert minimum CPU limit back to 20 from 100. ## 0.7.1 (December 19, 2017) From b6d850513ab1859127b1cad902b03c07b8c1d97e Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Wed, 3 Jan 2018 16:50:47 -0800 Subject: [PATCH 036/136] Add missing -group=cache to docs Fixes #3699 --- website/source/docs/commands/job/promote.html.md.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/website/source/docs/commands/job/promote.html.md.erb b/website/source/docs/commands/job/promote.html.md.erb index 983499e9d..28b7fba77 100644 --- a/website/source/docs/commands/job/promote.html.md.erb +++ b/website/source/docs/commands/job/promote.html.md.erb @@ -174,7 +174,7 @@ cee52788 6240eed6 web 0 run running 07/25/17 18:37:08 UTC ee8f972e 6240eed6 web 0 run running 07/25/17 18:37:08 UTC # Promote only the cache canaries -$ nomad job promote example +$ nomad job promote -group=cache example ==> Monitoring evaluation "37383564" Evaluation triggered by job "example" Evaluation within deployment: "a6b87a6c" From eee9c034a853b37f18a13ce0b04037e5cb8f7628 Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Thu, 4 Jan 2018 11:01:22 -0800 Subject: [PATCH 037/136] Add #3685 to changelog --- CHANGELOG.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2837e14ae..614642bd8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,10 @@ ## 0.8 (Unreleased) +__BACKWARDS INCOMPATIBILITIES:__ + * discovery: Prevent absolute URLs in check paths. The documentation indicated + that absolute URLs are not allowed, but it was not enforced. Absolute URLs + in HTTP check paths will now fail to validate. [[GH-3685](https://github.com/hashicorp/nomad/issues/3685)] + BUG FIXES: * core: Fix search endpoint forwarding for multi-region clusters [[GH-3680](https://github.com/hashicorp/nomad/issues/3680)] * config: Revert minimum CPU limit back to 20 from 100. From 758b98685be4a2997bd0bc54f55b73ac3d0365cc Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Thu, 4 Jan 2018 11:30:03 -0800 Subject: [PATCH 038/136] Remove mention of check_restart on service This is currently broken and should be removed from docs until a fix is released. See #3713 --- website/source/docs/job-specification/check_restart.html.md | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/website/source/docs/job-specification/check_restart.html.md b/website/source/docs/job-specification/check_restart.html.md index d183bd054..19b720276 100644 --- a/website/source/docs/job-specification/check_restart.html.md +++ b/website/source/docs/job-specification/check_restart.html.md @@ -28,10 +28,7 @@ As of Nomad 0.7 the `check_restart` stanza instructs Nomad when to restart tasks with unhealthy service checks. When a health check in Consul has been unhealthy for the `limit` specified in a `check_restart` stanza, it is restarted according to the task group's [`restart` policy][restart_stanza]. The -`check_restart` settings apply to [`check`s][check_stanza], but may also be -placed on [`service`s][service_stanza] to apply to all checks on a service. -If `check_restart` is set on both the check and service, the stanzas are -merged with the check values taking precedence. +`check_restart` settings apply to [`check`s][check_stanza]. ```hcl job "mysql" { @@ -149,4 +146,3 @@ details. [check_stanza]: /docs/job-specification/service.html#check-parameters "check stanza" [restart_stanza]: /docs/job-specification/restart.html "restart stanza" -[service_stanza]: /docs/job-specification/service.html "service stanza" From 28aa6e1acdc3c0f3e3f56b60a91763d8023e25d7 Mon Sep 17 00:00:00 2001 From: Alex Dadgar Date: Thu, 4 Jan 2018 14:20:32 -0800 Subject: [PATCH 039/136] Fix detection of successful batch allocations This PR restores older behavior of detecting successful batch allocations (04d86ffd1006fde9dfb2ca8c1237fe60b995b0e3). This has the side effect that we correctly filter desired status stop but not successful batch allocations and create their replacements. --- nomad/structs/structs.go | 24 +++++++- scheduler/generic_sched_test.go | 99 +++++++++++++++++++++++++++++++++ 2 files changed, 120 insertions(+), 3 deletions(-) diff --git a/nomad/structs/structs.go b/nomad/structs/structs.go index 375a59d3a..7315f2c10 100644 --- a/nomad/structs/structs.go +++ b/nomad/structs/structs.go @@ -3813,7 +3813,9 @@ func (ts *TaskState) Copy() *TaskState { return copy } -// Successful returns whether a task finished successfully. +// Successful returns whether a task finished successfully. This doesn't really +// have meaning on a non-batch allocation because a service and system +// allocation should not finish. func (ts *TaskState) Successful() bool { l := len(ts.Events) if ts.State != TaskStateDead || l == 0 { @@ -5019,9 +5021,25 @@ func (a *Allocation) Terminated() bool { } // RanSuccessfully returns whether the client has ran the allocation and all -// tasks finished successfully +// tasks finished successfully. Critically this function returns whether the +// allocation has ran to completion and not just that the alloc has converged to +// its desired state. That is to say that a batch allocation must have finished +// with exit code 0 on all task groups. This doesn't really have meaning on a +// non-batch allocation because a service and system allocation should not +// finish. func (a *Allocation) RanSuccessfully() bool { - return a.ClientStatus == AllocClientStatusComplete + // Handle the case the client hasn't started the allocation. + if len(a.TaskStates) == 0 { + return false + } + + // Check to see if all the tasks finised successfully in the allocation + allSuccess := true + for _, state := range a.TaskStates { + allSuccess = allSuccess && state.Successful() + } + + return allSuccess } // ShouldMigrate returns if the allocation needs data migration diff --git a/scheduler/generic_sched_test.go b/scheduler/generic_sched_test.go index 0e88b4255..dbb54d80c 100644 --- a/scheduler/generic_sched_test.go +++ b/scheduler/generic_sched_test.go @@ -13,6 +13,7 @@ import ( "github.com/hashicorp/nomad/nomad/mock" "github.com/hashicorp/nomad/nomad/structs" "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" ) func TestServiceSched_JobRegister(t *testing.T) { @@ -2825,6 +2826,94 @@ func TestBatchSched_Run_FailedAlloc(t *testing.T) { h.AssertEvalStatus(t, structs.EvalStatusComplete) } +func TestBatchSched_Run_LostAlloc(t *testing.T) { + h := NewHarness(t) + + // Create a node + node := mock.Node() + noErr(t, h.State.UpsertNode(h.NextIndex(), node)) + + // Create a job + job := mock.Job() + job.ID = "my-job" + job.Type = structs.JobTypeBatch + job.TaskGroups[0].Count = 3 + noErr(t, h.State.UpsertJob(h.NextIndex(), job)) + + // Desired = 3 + // Mark one as lost and then schedule + // [(0, run, running), (1, run, running), (1, stop, lost)] + + // Create two running allocations + var allocs []*structs.Allocation + for i := 0; i <= 1; i++ { + alloc := mock.Alloc() + alloc.Job = job + alloc.JobID = job.ID + alloc.NodeID = node.ID + alloc.Name = fmt.Sprintf("my-job.web[%d]", i) + alloc.ClientStatus = structs.AllocClientStatusRunning + allocs = append(allocs, alloc) + } + + // Create a failed alloc + alloc := mock.Alloc() + alloc.Job = job + alloc.JobID = job.ID + alloc.NodeID = node.ID + alloc.Name = "my-job.web[1]" + alloc.DesiredStatus = structs.AllocDesiredStatusStop + alloc.ClientStatus = structs.AllocClientStatusComplete + allocs = append(allocs, alloc) + noErr(t, h.State.UpsertAllocs(h.NextIndex(), allocs)) + + // Create a mock evaluation to register the job + eval := &structs.Evaluation{ + Namespace: structs.DefaultNamespace, + ID: uuid.Generate(), + Priority: job.Priority, + TriggeredBy: structs.EvalTriggerJobRegister, + JobID: job.ID, + Status: structs.EvalStatusPending, + } + noErr(t, h.State.UpsertEvals(h.NextIndex(), []*structs.Evaluation{eval})) + + // Process the evaluation + err := h.Process(NewBatchScheduler, eval) + if err != nil { + t.Fatalf("err: %v", err) + } + + // Ensure a plan + if len(h.Plans) != 1 { + t.Fatalf("bad: %#v", h.Plans) + } + + // Lookup the allocations by JobID + ws := memdb.NewWatchSet() + out, err := h.State.AllocsByJob(ws, job.Namespace, job.ID, false) + noErr(t, err) + + // Ensure a replacement alloc was placed. + if len(out) != 4 { + t.Fatalf("bad: %#v", out) + } + + // Assert that we have the correct number of each alloc name + expected := map[string]int{ + "my-job.web[0]": 1, + "my-job.web[1]": 2, + "my-job.web[2]": 1, + } + actual := make(map[string]int, 3) + for _, alloc := range out { + actual[alloc.Name] += 1 + } + require.Equal(t, actual, expected) + + h.AssertEvalStatus(t, structs.EvalStatusComplete) +} + func TestBatchSched_Run_FailedAllocQueuedAllocations(t *testing.T) { h := NewHarness(t) @@ -3177,6 +3266,16 @@ func TestBatchSched_NodeDrain_Complete(t *testing.T) { alloc.NodeID = node.ID alloc.Name = "my-job.web[0]" alloc.ClientStatus = structs.AllocClientStatusComplete + alloc.TaskStates = make(map[string]*structs.TaskState) + alloc.TaskStates["web"] = &structs.TaskState{ + State: structs.TaskStateDead, + Events: []*structs.TaskEvent{ + &structs.TaskEvent{ + Type: structs.TaskTerminated, + ExitCode: 0, + }, + }, + } noErr(t, h.State.UpsertAllocs(h.NextIndex(), []*structs.Allocation{alloc})) // Create a mock evaluation to register the job From 8445a6bedad4a6b525e0ea213993f26b35b8d53f Mon Sep 17 00:00:00 2001 From: Alex Dadgar Date: Thu, 4 Jan 2018 14:27:19 -0800 Subject: [PATCH 040/136] changelog --- CHANGELOG.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2837e14ae..9c34c31a0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,8 @@ BUG FIXES: * core: Fix search endpoint forwarding for multi-region clusters [[GH-3680](https://github.com/hashicorp/nomad/issues/3680)] + * core: Fix an issue in which batch jobs with queued placements and lost + allocations could result in improper placement counts [GH-3717] * config: Revert minimum CPU limit back to 20 from 100. ## 0.7.1 (December 19, 2017) From 4b185af6c91c6b09d1e354e2ef672177bdc9f825 Mon Sep 17 00:00:00 2001 From: Alex Dadgar Date: Thu, 4 Jan 2018 14:39:45 -0800 Subject: [PATCH 041/136] add require --- .../stretchr/testify/require/doc.go | 28 + .../testify/require/forward_requirements.go | 16 + .../stretchr/testify/require/require.go | 911 ++++++++++++++++++ .../stretchr/testify/require/require.go.tmpl | 6 + .../testify/require/require_forward.go | 747 ++++++++++++++ .../testify/require/require_forward.go.tmpl | 4 + .../stretchr/testify/require/requirements.go | 9 + vendor/vendor.json | 1 + 8 files changed, 1722 insertions(+) create mode 100644 vendor/github.com/stretchr/testify/require/doc.go create mode 100644 vendor/github.com/stretchr/testify/require/forward_requirements.go create mode 100644 vendor/github.com/stretchr/testify/require/require.go create mode 100644 vendor/github.com/stretchr/testify/require/require.go.tmpl create mode 100644 vendor/github.com/stretchr/testify/require/require_forward.go create mode 100644 vendor/github.com/stretchr/testify/require/require_forward.go.tmpl create mode 100644 vendor/github.com/stretchr/testify/require/requirements.go diff --git a/vendor/github.com/stretchr/testify/require/doc.go b/vendor/github.com/stretchr/testify/require/doc.go new file mode 100644 index 000000000..169de3922 --- /dev/null +++ b/vendor/github.com/stretchr/testify/require/doc.go @@ -0,0 +1,28 @@ +// Package require implements the same assertions as the `assert` package but +// stops test execution when a test fails. +// +// Example Usage +// +// The following is a complete example using require in a standard test function: +// import ( +// "testing" +// "github.com/stretchr/testify/require" +// ) +// +// func TestSomething(t *testing.T) { +// +// var a string = "Hello" +// var b string = "Hello" +// +// require.Equal(t, a, b, "The two words should be the same.") +// +// } +// +// Assertions +// +// The `require` package have same global functions as in the `assert` package, +// but instead of returning a boolean result they call `t.FailNow()`. +// +// Every assertion function also takes an optional string message as the final argument, +// allowing custom error messages to be appended to the message the assertion method outputs. +package require diff --git a/vendor/github.com/stretchr/testify/require/forward_requirements.go b/vendor/github.com/stretchr/testify/require/forward_requirements.go new file mode 100644 index 000000000..ac71d4058 --- /dev/null +++ b/vendor/github.com/stretchr/testify/require/forward_requirements.go @@ -0,0 +1,16 @@ +package require + +// Assertions provides assertion methods around the +// TestingT interface. +type Assertions struct { + t TestingT +} + +// New makes a new Assertions object for the specified TestingT. +func New(t TestingT) *Assertions { + return &Assertions{ + t: t, + } +} + +//go:generate go run ../_codegen/main.go -output-package=require -template=require_forward.go.tmpl -include-format-funcs diff --git a/vendor/github.com/stretchr/testify/require/require.go b/vendor/github.com/stretchr/testify/require/require.go new file mode 100644 index 000000000..2fe055784 --- /dev/null +++ b/vendor/github.com/stretchr/testify/require/require.go @@ -0,0 +1,911 @@ +/* +* CODE GENERATED AUTOMATICALLY WITH github.com/stretchr/testify/_codegen +* THIS FILE MUST NOT BE EDITED BY HAND + */ + +package require + +import ( + assert "github.com/stretchr/testify/assert" + http "net/http" + url "net/url" + time "time" +) + +// Condition uses a Comparison to assert a complex condition. +func Condition(t TestingT, comp assert.Comparison, msgAndArgs ...interface{}) { + if !assert.Condition(t, comp, msgAndArgs...) { + t.FailNow() + } +} + +// Conditionf uses a Comparison to assert a complex condition. +func Conditionf(t TestingT, comp assert.Comparison, msg string, args ...interface{}) { + if !assert.Conditionf(t, comp, msg, args...) { + t.FailNow() + } +} + +// Contains asserts that the specified string, list(array, slice...) or map contains the +// specified substring or element. +// +// assert.Contains(t, "Hello World", "World") +// assert.Contains(t, ["Hello", "World"], "World") +// assert.Contains(t, {"Hello": "World"}, "Hello") +// +// Returns whether the assertion was successful (true) or not (false). +func Contains(t TestingT, s interface{}, contains interface{}, msgAndArgs ...interface{}) { + if !assert.Contains(t, s, contains, msgAndArgs...) { + t.FailNow() + } +} + +// Containsf asserts that the specified string, list(array, slice...) or map contains the +// specified substring or element. +// +// assert.Containsf(t, "Hello World", "World", "error message %s", "formatted") +// assert.Containsf(t, ["Hello", "World"], "World", "error message %s", "formatted") +// assert.Containsf(t, {"Hello": "World"}, "Hello", "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func Containsf(t TestingT, s interface{}, contains interface{}, msg string, args ...interface{}) { + if !assert.Containsf(t, s, contains, msg, args...) { + t.FailNow() + } +} + +// Empty asserts that the specified object is empty. I.e. nil, "", false, 0 or either +// a slice or a channel with len == 0. +// +// assert.Empty(t, obj) +// +// Returns whether the assertion was successful (true) or not (false). +func Empty(t TestingT, object interface{}, msgAndArgs ...interface{}) { + if !assert.Empty(t, object, msgAndArgs...) { + t.FailNow() + } +} + +// Emptyf asserts that the specified object is empty. I.e. nil, "", false, 0 or either +// a slice or a channel with len == 0. +// +// assert.Emptyf(t, obj, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func Emptyf(t TestingT, object interface{}, msg string, args ...interface{}) { + if !assert.Emptyf(t, object, msg, args...) { + t.FailNow() + } +} + +// Equal asserts that two objects are equal. +// +// assert.Equal(t, 123, 123) +// +// Returns whether the assertion was successful (true) or not (false). +// +// Pointer variable equality is determined based on the equality of the +// referenced values (as opposed to the memory addresses). Function equality +// cannot be determined and will always fail. +func Equal(t TestingT, expected interface{}, actual interface{}, msgAndArgs ...interface{}) { + if !assert.Equal(t, expected, actual, msgAndArgs...) { + t.FailNow() + } +} + +// EqualError asserts that a function returned an error (i.e. not `nil`) +// and that it is equal to the provided error. +// +// actualObj, err := SomeFunction() +// assert.EqualError(t, err, expectedErrorString) +// +// Returns whether the assertion was successful (true) or not (false). +func EqualError(t TestingT, theError error, errString string, msgAndArgs ...interface{}) { + if !assert.EqualError(t, theError, errString, msgAndArgs...) { + t.FailNow() + } +} + +// EqualErrorf asserts that a function returned an error (i.e. not `nil`) +// and that it is equal to the provided error. +// +// actualObj, err := SomeFunction() +// assert.EqualErrorf(t, err, expectedErrorString, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func EqualErrorf(t TestingT, theError error, errString string, msg string, args ...interface{}) { + if !assert.EqualErrorf(t, theError, errString, msg, args...) { + t.FailNow() + } +} + +// EqualValues asserts that two objects are equal or convertable to the same types +// and equal. +// +// assert.EqualValues(t, uint32(123), int32(123)) +// +// Returns whether the assertion was successful (true) or not (false). +func EqualValues(t TestingT, expected interface{}, actual interface{}, msgAndArgs ...interface{}) { + if !assert.EqualValues(t, expected, actual, msgAndArgs...) { + t.FailNow() + } +} + +// EqualValuesf asserts that two objects are equal or convertable to the same types +// and equal. +// +// assert.EqualValuesf(t, uint32(123, "error message %s", "formatted"), int32(123)) +// +// Returns whether the assertion was successful (true) or not (false). +func EqualValuesf(t TestingT, expected interface{}, actual interface{}, msg string, args ...interface{}) { + if !assert.EqualValuesf(t, expected, actual, msg, args...) { + t.FailNow() + } +} + +// Equalf asserts that two objects are equal. +// +// assert.Equalf(t, 123, 123, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +// +// Pointer variable equality is determined based on the equality of the +// referenced values (as opposed to the memory addresses). Function equality +// cannot be determined and will always fail. +func Equalf(t TestingT, expected interface{}, actual interface{}, msg string, args ...interface{}) { + if !assert.Equalf(t, expected, actual, msg, args...) { + t.FailNow() + } +} + +// Error asserts that a function returned an error (i.e. not `nil`). +// +// actualObj, err := SomeFunction() +// if assert.Error(t, err) { +// assert.Equal(t, expectedError, err) +// } +// +// Returns whether the assertion was successful (true) or not (false). +func Error(t TestingT, err error, msgAndArgs ...interface{}) { + if !assert.Error(t, err, msgAndArgs...) { + t.FailNow() + } +} + +// Errorf asserts that a function returned an error (i.e. not `nil`). +// +// actualObj, err := SomeFunction() +// if assert.Errorf(t, err, "error message %s", "formatted") { +// assert.Equal(t, expectedErrorf, err) +// } +// +// Returns whether the assertion was successful (true) or not (false). +func Errorf(t TestingT, err error, msg string, args ...interface{}) { + if !assert.Errorf(t, err, msg, args...) { + t.FailNow() + } +} + +// Exactly asserts that two objects are equal is value and type. +// +// assert.Exactly(t, int32(123), int64(123)) +// +// Returns whether the assertion was successful (true) or not (false). +func Exactly(t TestingT, expected interface{}, actual interface{}, msgAndArgs ...interface{}) { + if !assert.Exactly(t, expected, actual, msgAndArgs...) { + t.FailNow() + } +} + +// Exactlyf asserts that two objects are equal is value and type. +// +// assert.Exactlyf(t, int32(123, "error message %s", "formatted"), int64(123)) +// +// Returns whether the assertion was successful (true) or not (false). +func Exactlyf(t TestingT, expected interface{}, actual interface{}, msg string, args ...interface{}) { + if !assert.Exactlyf(t, expected, actual, msg, args...) { + t.FailNow() + } +} + +// Fail reports a failure through +func Fail(t TestingT, failureMessage string, msgAndArgs ...interface{}) { + if !assert.Fail(t, failureMessage, msgAndArgs...) { + t.FailNow() + } +} + +// FailNow fails test +func FailNow(t TestingT, failureMessage string, msgAndArgs ...interface{}) { + if !assert.FailNow(t, failureMessage, msgAndArgs...) { + t.FailNow() + } +} + +// FailNowf fails test +func FailNowf(t TestingT, failureMessage string, msg string, args ...interface{}) { + if !assert.FailNowf(t, failureMessage, msg, args...) { + t.FailNow() + } +} + +// Failf reports a failure through +func Failf(t TestingT, failureMessage string, msg string, args ...interface{}) { + if !assert.Failf(t, failureMessage, msg, args...) { + t.FailNow() + } +} + +// False asserts that the specified value is false. +// +// assert.False(t, myBool) +// +// Returns whether the assertion was successful (true) or not (false). +func False(t TestingT, value bool, msgAndArgs ...interface{}) { + if !assert.False(t, value, msgAndArgs...) { + t.FailNow() + } +} + +// Falsef asserts that the specified value is false. +// +// assert.Falsef(t, myBool, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func Falsef(t TestingT, value bool, msg string, args ...interface{}) { + if !assert.Falsef(t, value, msg, args...) { + t.FailNow() + } +} + +// HTTPBodyContains asserts that a specified handler returns a +// body that contains a string. +// +// assert.HTTPBodyContains(t, myHandler, "www.google.com", nil, "I'm Feeling Lucky") +// +// Returns whether the assertion was successful (true) or not (false). +func HTTPBodyContains(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values, str interface{}) { + if !assert.HTTPBodyContains(t, handler, method, url, values, str) { + t.FailNow() + } +} + +// HTTPBodyContainsf asserts that a specified handler returns a +// body that contains a string. +// +// assert.HTTPBodyContainsf(t, myHandler, "www.google.com", nil, "I'm Feeling Lucky", "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func HTTPBodyContainsf(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values, str interface{}) { + if !assert.HTTPBodyContainsf(t, handler, method, url, values, str) { + t.FailNow() + } +} + +// HTTPBodyNotContains asserts that a specified handler returns a +// body that does not contain a string. +// +// assert.HTTPBodyNotContains(t, myHandler, "www.google.com", nil, "I'm Feeling Lucky") +// +// Returns whether the assertion was successful (true) or not (false). +func HTTPBodyNotContains(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values, str interface{}) { + if !assert.HTTPBodyNotContains(t, handler, method, url, values, str) { + t.FailNow() + } +} + +// HTTPBodyNotContainsf asserts that a specified handler returns a +// body that does not contain a string. +// +// assert.HTTPBodyNotContainsf(t, myHandler, "www.google.com", nil, "I'm Feeling Lucky", "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func HTTPBodyNotContainsf(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values, str interface{}) { + if !assert.HTTPBodyNotContainsf(t, handler, method, url, values, str) { + t.FailNow() + } +} + +// HTTPError asserts that a specified handler returns an error status code. +// +// assert.HTTPError(t, myHandler, "POST", "/a/b/c", url.Values{"a": []string{"b", "c"}} +// +// Returns whether the assertion was successful (true) or not (false). +func HTTPError(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values) { + if !assert.HTTPError(t, handler, method, url, values) { + t.FailNow() + } +} + +// HTTPErrorf asserts that a specified handler returns an error status code. +// +// assert.HTTPErrorf(t, myHandler, "POST", "/a/b/c", url.Values{"a": []string{"b", "c"}} +// +// Returns whether the assertion was successful (true, "error message %s", "formatted") or not (false). +func HTTPErrorf(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values) { + if !assert.HTTPErrorf(t, handler, method, url, values) { + t.FailNow() + } +} + +// HTTPRedirect asserts that a specified handler returns a redirect status code. +// +// assert.HTTPRedirect(t, myHandler, "GET", "/a/b/c", url.Values{"a": []string{"b", "c"}} +// +// Returns whether the assertion was successful (true) or not (false). +func HTTPRedirect(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values) { + if !assert.HTTPRedirect(t, handler, method, url, values) { + t.FailNow() + } +} + +// HTTPRedirectf asserts that a specified handler returns a redirect status code. +// +// assert.HTTPRedirectf(t, myHandler, "GET", "/a/b/c", url.Values{"a": []string{"b", "c"}} +// +// Returns whether the assertion was successful (true, "error message %s", "formatted") or not (false). +func HTTPRedirectf(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values) { + if !assert.HTTPRedirectf(t, handler, method, url, values) { + t.FailNow() + } +} + +// HTTPSuccess asserts that a specified handler returns a success status code. +// +// assert.HTTPSuccess(t, myHandler, "POST", "http://www.google.com", nil) +// +// Returns whether the assertion was successful (true) or not (false). +func HTTPSuccess(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values) { + if !assert.HTTPSuccess(t, handler, method, url, values) { + t.FailNow() + } +} + +// HTTPSuccessf asserts that a specified handler returns a success status code. +// +// assert.HTTPSuccessf(t, myHandler, "POST", "http://www.google.com", nil, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func HTTPSuccessf(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values) { + if !assert.HTTPSuccessf(t, handler, method, url, values) { + t.FailNow() + } +} + +// Implements asserts that an object is implemented by the specified interface. +// +// assert.Implements(t, (*MyInterface)(nil), new(MyObject)) +func Implements(t TestingT, interfaceObject interface{}, object interface{}, msgAndArgs ...interface{}) { + if !assert.Implements(t, interfaceObject, object, msgAndArgs...) { + t.FailNow() + } +} + +// Implementsf asserts that an object is implemented by the specified interface. +// +// assert.Implementsf(t, (*MyInterface, "error message %s", "formatted")(nil), new(MyObject)) +func Implementsf(t TestingT, interfaceObject interface{}, object interface{}, msg string, args ...interface{}) { + if !assert.Implementsf(t, interfaceObject, object, msg, args...) { + t.FailNow() + } +} + +// InDelta asserts that the two numerals are within delta of each other. +// +// assert.InDelta(t, math.Pi, (22 / 7.0), 0.01) +// +// Returns whether the assertion was successful (true) or not (false). +func InDelta(t TestingT, expected interface{}, actual interface{}, delta float64, msgAndArgs ...interface{}) { + if !assert.InDelta(t, expected, actual, delta, msgAndArgs...) { + t.FailNow() + } +} + +// InDeltaSlice is the same as InDelta, except it compares two slices. +func InDeltaSlice(t TestingT, expected interface{}, actual interface{}, delta float64, msgAndArgs ...interface{}) { + if !assert.InDeltaSlice(t, expected, actual, delta, msgAndArgs...) { + t.FailNow() + } +} + +// InDeltaSlicef is the same as InDelta, except it compares two slices. +func InDeltaSlicef(t TestingT, expected interface{}, actual interface{}, delta float64, msg string, args ...interface{}) { + if !assert.InDeltaSlicef(t, expected, actual, delta, msg, args...) { + t.FailNow() + } +} + +// InDeltaf asserts that the two numerals are within delta of each other. +// +// assert.InDeltaf(t, math.Pi, (22 / 7.0, "error message %s", "formatted"), 0.01) +// +// Returns whether the assertion was successful (true) or not (false). +func InDeltaf(t TestingT, expected interface{}, actual interface{}, delta float64, msg string, args ...interface{}) { + if !assert.InDeltaf(t, expected, actual, delta, msg, args...) { + t.FailNow() + } +} + +// InEpsilon asserts that expected and actual have a relative error less than epsilon +// +// Returns whether the assertion was successful (true) or not (false). +func InEpsilon(t TestingT, expected interface{}, actual interface{}, epsilon float64, msgAndArgs ...interface{}) { + if !assert.InEpsilon(t, expected, actual, epsilon, msgAndArgs...) { + t.FailNow() + } +} + +// InEpsilonSlice is the same as InEpsilon, except it compares each value from two slices. +func InEpsilonSlice(t TestingT, expected interface{}, actual interface{}, epsilon float64, msgAndArgs ...interface{}) { + if !assert.InEpsilonSlice(t, expected, actual, epsilon, msgAndArgs...) { + t.FailNow() + } +} + +// InEpsilonSlicef is the same as InEpsilon, except it compares each value from two slices. +func InEpsilonSlicef(t TestingT, expected interface{}, actual interface{}, epsilon float64, msg string, args ...interface{}) { + if !assert.InEpsilonSlicef(t, expected, actual, epsilon, msg, args...) { + t.FailNow() + } +} + +// InEpsilonf asserts that expected and actual have a relative error less than epsilon +// +// Returns whether the assertion was successful (true) or not (false). +func InEpsilonf(t TestingT, expected interface{}, actual interface{}, epsilon float64, msg string, args ...interface{}) { + if !assert.InEpsilonf(t, expected, actual, epsilon, msg, args...) { + t.FailNow() + } +} + +// IsType asserts that the specified objects are of the same type. +func IsType(t TestingT, expectedType interface{}, object interface{}, msgAndArgs ...interface{}) { + if !assert.IsType(t, expectedType, object, msgAndArgs...) { + t.FailNow() + } +} + +// IsTypef asserts that the specified objects are of the same type. +func IsTypef(t TestingT, expectedType interface{}, object interface{}, msg string, args ...interface{}) { + if !assert.IsTypef(t, expectedType, object, msg, args...) { + t.FailNow() + } +} + +// JSONEq asserts that two JSON strings are equivalent. +// +// assert.JSONEq(t, `{"hello": "world", "foo": "bar"}`, `{"foo": "bar", "hello": "world"}`) +// +// Returns whether the assertion was successful (true) or not (false). +func JSONEq(t TestingT, expected string, actual string, msgAndArgs ...interface{}) { + if !assert.JSONEq(t, expected, actual, msgAndArgs...) { + t.FailNow() + } +} + +// JSONEqf asserts that two JSON strings are equivalent. +// +// assert.JSONEqf(t, `{"hello": "world", "foo": "bar"}`, `{"foo": "bar", "hello": "world"}`, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func JSONEqf(t TestingT, expected string, actual string, msg string, args ...interface{}) { + if !assert.JSONEqf(t, expected, actual, msg, args...) { + t.FailNow() + } +} + +// Len asserts that the specified object has specific length. +// Len also fails if the object has a type that len() not accept. +// +// assert.Len(t, mySlice, 3) +// +// Returns whether the assertion was successful (true) or not (false). +func Len(t TestingT, object interface{}, length int, msgAndArgs ...interface{}) { + if !assert.Len(t, object, length, msgAndArgs...) { + t.FailNow() + } +} + +// Lenf asserts that the specified object has specific length. +// Lenf also fails if the object has a type that len() not accept. +// +// assert.Lenf(t, mySlice, 3, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func Lenf(t TestingT, object interface{}, length int, msg string, args ...interface{}) { + if !assert.Lenf(t, object, length, msg, args...) { + t.FailNow() + } +} + +// Nil asserts that the specified object is nil. +// +// assert.Nil(t, err) +// +// Returns whether the assertion was successful (true) or not (false). +func Nil(t TestingT, object interface{}, msgAndArgs ...interface{}) { + if !assert.Nil(t, object, msgAndArgs...) { + t.FailNow() + } +} + +// Nilf asserts that the specified object is nil. +// +// assert.Nilf(t, err, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func Nilf(t TestingT, object interface{}, msg string, args ...interface{}) { + if !assert.Nilf(t, object, msg, args...) { + t.FailNow() + } +} + +// NoError asserts that a function returned no error (i.e. `nil`). +// +// actualObj, err := SomeFunction() +// if assert.NoError(t, err) { +// assert.Equal(t, expectedObj, actualObj) +// } +// +// Returns whether the assertion was successful (true) or not (false). +func NoError(t TestingT, err error, msgAndArgs ...interface{}) { + if !assert.NoError(t, err, msgAndArgs...) { + t.FailNow() + } +} + +// NoErrorf asserts that a function returned no error (i.e. `nil`). +// +// actualObj, err := SomeFunction() +// if assert.NoErrorf(t, err, "error message %s", "formatted") { +// assert.Equal(t, expectedObj, actualObj) +// } +// +// Returns whether the assertion was successful (true) or not (false). +func NoErrorf(t TestingT, err error, msg string, args ...interface{}) { + if !assert.NoErrorf(t, err, msg, args...) { + t.FailNow() + } +} + +// NotContains asserts that the specified string, list(array, slice...) or map does NOT contain the +// specified substring or element. +// +// assert.NotContains(t, "Hello World", "Earth") +// assert.NotContains(t, ["Hello", "World"], "Earth") +// assert.NotContains(t, {"Hello": "World"}, "Earth") +// +// Returns whether the assertion was successful (true) or not (false). +func NotContains(t TestingT, s interface{}, contains interface{}, msgAndArgs ...interface{}) { + if !assert.NotContains(t, s, contains, msgAndArgs...) { + t.FailNow() + } +} + +// NotContainsf asserts that the specified string, list(array, slice...) or map does NOT contain the +// specified substring or element. +// +// assert.NotContainsf(t, "Hello World", "Earth", "error message %s", "formatted") +// assert.NotContainsf(t, ["Hello", "World"], "Earth", "error message %s", "formatted") +// assert.NotContainsf(t, {"Hello": "World"}, "Earth", "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func NotContainsf(t TestingT, s interface{}, contains interface{}, msg string, args ...interface{}) { + if !assert.NotContainsf(t, s, contains, msg, args...) { + t.FailNow() + } +} + +// NotEmpty asserts that the specified object is NOT empty. I.e. not nil, "", false, 0 or either +// a slice or a channel with len == 0. +// +// if assert.NotEmpty(t, obj) { +// assert.Equal(t, "two", obj[1]) +// } +// +// Returns whether the assertion was successful (true) or not (false). +func NotEmpty(t TestingT, object interface{}, msgAndArgs ...interface{}) { + if !assert.NotEmpty(t, object, msgAndArgs...) { + t.FailNow() + } +} + +// NotEmptyf asserts that the specified object is NOT empty. I.e. not nil, "", false, 0 or either +// a slice or a channel with len == 0. +// +// if assert.NotEmptyf(t, obj, "error message %s", "formatted") { +// assert.Equal(t, "two", obj[1]) +// } +// +// Returns whether the assertion was successful (true) or not (false). +func NotEmptyf(t TestingT, object interface{}, msg string, args ...interface{}) { + if !assert.NotEmptyf(t, object, msg, args...) { + t.FailNow() + } +} + +// NotEqual asserts that the specified values are NOT equal. +// +// assert.NotEqual(t, obj1, obj2) +// +// Returns whether the assertion was successful (true) or not (false). +// +// Pointer variable equality is determined based on the equality of the +// referenced values (as opposed to the memory addresses). +func NotEqual(t TestingT, expected interface{}, actual interface{}, msgAndArgs ...interface{}) { + if !assert.NotEqual(t, expected, actual, msgAndArgs...) { + t.FailNow() + } +} + +// NotEqualf asserts that the specified values are NOT equal. +// +// assert.NotEqualf(t, obj1, obj2, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +// +// Pointer variable equality is determined based on the equality of the +// referenced values (as opposed to the memory addresses). +func NotEqualf(t TestingT, expected interface{}, actual interface{}, msg string, args ...interface{}) { + if !assert.NotEqualf(t, expected, actual, msg, args...) { + t.FailNow() + } +} + +// NotNil asserts that the specified object is not nil. +// +// assert.NotNil(t, err) +// +// Returns whether the assertion was successful (true) or not (false). +func NotNil(t TestingT, object interface{}, msgAndArgs ...interface{}) { + if !assert.NotNil(t, object, msgAndArgs...) { + t.FailNow() + } +} + +// NotNilf asserts that the specified object is not nil. +// +// assert.NotNilf(t, err, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func NotNilf(t TestingT, object interface{}, msg string, args ...interface{}) { + if !assert.NotNilf(t, object, msg, args...) { + t.FailNow() + } +} + +// NotPanics asserts that the code inside the specified PanicTestFunc does NOT panic. +// +// assert.NotPanics(t, func(){ RemainCalm() }) +// +// Returns whether the assertion was successful (true) or not (false). +func NotPanics(t TestingT, f assert.PanicTestFunc, msgAndArgs ...interface{}) { + if !assert.NotPanics(t, f, msgAndArgs...) { + t.FailNow() + } +} + +// NotPanicsf asserts that the code inside the specified PanicTestFunc does NOT panic. +// +// assert.NotPanicsf(t, func(){ RemainCalm() }, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func NotPanicsf(t TestingT, f assert.PanicTestFunc, msg string, args ...interface{}) { + if !assert.NotPanicsf(t, f, msg, args...) { + t.FailNow() + } +} + +// NotRegexp asserts that a specified regexp does not match a string. +// +// assert.NotRegexp(t, regexp.MustCompile("starts"), "it's starting") +// assert.NotRegexp(t, "^start", "it's not starting") +// +// Returns whether the assertion was successful (true) or not (false). +func NotRegexp(t TestingT, rx interface{}, str interface{}, msgAndArgs ...interface{}) { + if !assert.NotRegexp(t, rx, str, msgAndArgs...) { + t.FailNow() + } +} + +// NotRegexpf asserts that a specified regexp does not match a string. +// +// assert.NotRegexpf(t, regexp.MustCompile("starts", "error message %s", "formatted"), "it's starting") +// assert.NotRegexpf(t, "^start", "it's not starting", "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func NotRegexpf(t TestingT, rx interface{}, str interface{}, msg string, args ...interface{}) { + if !assert.NotRegexpf(t, rx, str, msg, args...) { + t.FailNow() + } +} + +// NotSubset asserts that the specified list(array, slice...) contains not all +// elements given in the specified subset(array, slice...). +// +// assert.NotSubset(t, [1, 3, 4], [1, 2], "But [1, 3, 4] does not contain [1, 2]") +// +// Returns whether the assertion was successful (true) or not (false). +func NotSubset(t TestingT, list interface{}, subset interface{}, msgAndArgs ...interface{}) { + if !assert.NotSubset(t, list, subset, msgAndArgs...) { + t.FailNow() + } +} + +// NotSubsetf asserts that the specified list(array, slice...) contains not all +// elements given in the specified subset(array, slice...). +// +// assert.NotSubsetf(t, [1, 3, 4], [1, 2], "But [1, 3, 4] does not contain [1, 2]", "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func NotSubsetf(t TestingT, list interface{}, subset interface{}, msg string, args ...interface{}) { + if !assert.NotSubsetf(t, list, subset, msg, args...) { + t.FailNow() + } +} + +// NotZero asserts that i is not the zero value for its type and returns the truth. +func NotZero(t TestingT, i interface{}, msgAndArgs ...interface{}) { + if !assert.NotZero(t, i, msgAndArgs...) { + t.FailNow() + } +} + +// NotZerof asserts that i is not the zero value for its type and returns the truth. +func NotZerof(t TestingT, i interface{}, msg string, args ...interface{}) { + if !assert.NotZerof(t, i, msg, args...) { + t.FailNow() + } +} + +// Panics asserts that the code inside the specified PanicTestFunc panics. +// +// assert.Panics(t, func(){ GoCrazy() }) +// +// Returns whether the assertion was successful (true) or not (false). +func Panics(t TestingT, f assert.PanicTestFunc, msgAndArgs ...interface{}) { + if !assert.Panics(t, f, msgAndArgs...) { + t.FailNow() + } +} + +// PanicsWithValue asserts that the code inside the specified PanicTestFunc panics, and that +// the recovered panic value equals the expected panic value. +// +// assert.PanicsWithValue(t, "crazy error", func(){ GoCrazy() }) +// +// Returns whether the assertion was successful (true) or not (false). +func PanicsWithValue(t TestingT, expected interface{}, f assert.PanicTestFunc, msgAndArgs ...interface{}) { + if !assert.PanicsWithValue(t, expected, f, msgAndArgs...) { + t.FailNow() + } +} + +// PanicsWithValuef asserts that the code inside the specified PanicTestFunc panics, and that +// the recovered panic value equals the expected panic value. +// +// assert.PanicsWithValuef(t, "crazy error", func(){ GoCrazy() }, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func PanicsWithValuef(t TestingT, expected interface{}, f assert.PanicTestFunc, msg string, args ...interface{}) { + if !assert.PanicsWithValuef(t, expected, f, msg, args...) { + t.FailNow() + } +} + +// Panicsf asserts that the code inside the specified PanicTestFunc panics. +// +// assert.Panicsf(t, func(){ GoCrazy() }, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func Panicsf(t TestingT, f assert.PanicTestFunc, msg string, args ...interface{}) { + if !assert.Panicsf(t, f, msg, args...) { + t.FailNow() + } +} + +// Regexp asserts that a specified regexp matches a string. +// +// assert.Regexp(t, regexp.MustCompile("start"), "it's starting") +// assert.Regexp(t, "start...$", "it's not starting") +// +// Returns whether the assertion was successful (true) or not (false). +func Regexp(t TestingT, rx interface{}, str interface{}, msgAndArgs ...interface{}) { + if !assert.Regexp(t, rx, str, msgAndArgs...) { + t.FailNow() + } +} + +// Regexpf asserts that a specified regexp matches a string. +// +// assert.Regexpf(t, regexp.MustCompile("start", "error message %s", "formatted"), "it's starting") +// assert.Regexpf(t, "start...$", "it's not starting", "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func Regexpf(t TestingT, rx interface{}, str interface{}, msg string, args ...interface{}) { + if !assert.Regexpf(t, rx, str, msg, args...) { + t.FailNow() + } +} + +// Subset asserts that the specified list(array, slice...) contains all +// elements given in the specified subset(array, slice...). +// +// assert.Subset(t, [1, 2, 3], [1, 2], "But [1, 2, 3] does contain [1, 2]") +// +// Returns whether the assertion was successful (true) or not (false). +func Subset(t TestingT, list interface{}, subset interface{}, msgAndArgs ...interface{}) { + if !assert.Subset(t, list, subset, msgAndArgs...) { + t.FailNow() + } +} + +// Subsetf asserts that the specified list(array, slice...) contains all +// elements given in the specified subset(array, slice...). +// +// assert.Subsetf(t, [1, 2, 3], [1, 2], "But [1, 2, 3] does contain [1, 2]", "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func Subsetf(t TestingT, list interface{}, subset interface{}, msg string, args ...interface{}) { + if !assert.Subsetf(t, list, subset, msg, args...) { + t.FailNow() + } +} + +// True asserts that the specified value is true. +// +// assert.True(t, myBool) +// +// Returns whether the assertion was successful (true) or not (false). +func True(t TestingT, value bool, msgAndArgs ...interface{}) { + if !assert.True(t, value, msgAndArgs...) { + t.FailNow() + } +} + +// Truef asserts that the specified value is true. +// +// assert.Truef(t, myBool, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func Truef(t TestingT, value bool, msg string, args ...interface{}) { + if !assert.Truef(t, value, msg, args...) { + t.FailNow() + } +} + +// WithinDuration asserts that the two times are within duration delta of each other. +// +// assert.WithinDuration(t, time.Now(), time.Now(), 10*time.Second) +// +// Returns whether the assertion was successful (true) or not (false). +func WithinDuration(t TestingT, expected time.Time, actual time.Time, delta time.Duration, msgAndArgs ...interface{}) { + if !assert.WithinDuration(t, expected, actual, delta, msgAndArgs...) { + t.FailNow() + } +} + +// WithinDurationf asserts that the two times are within duration delta of each other. +// +// assert.WithinDurationf(t, time.Now(), time.Now(), 10*time.Second, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func WithinDurationf(t TestingT, expected time.Time, actual time.Time, delta time.Duration, msg string, args ...interface{}) { + if !assert.WithinDurationf(t, expected, actual, delta, msg, args...) { + t.FailNow() + } +} + +// Zero asserts that i is the zero value for its type and returns the truth. +func Zero(t TestingT, i interface{}, msgAndArgs ...interface{}) { + if !assert.Zero(t, i, msgAndArgs...) { + t.FailNow() + } +} + +// Zerof asserts that i is the zero value for its type and returns the truth. +func Zerof(t TestingT, i interface{}, msg string, args ...interface{}) { + if !assert.Zerof(t, i, msg, args...) { + t.FailNow() + } +} diff --git a/vendor/github.com/stretchr/testify/require/require.go.tmpl b/vendor/github.com/stretchr/testify/require/require.go.tmpl new file mode 100644 index 000000000..d2c38f6f2 --- /dev/null +++ b/vendor/github.com/stretchr/testify/require/require.go.tmpl @@ -0,0 +1,6 @@ +{{.Comment}} +func {{.DocInfo.Name}}(t TestingT, {{.Params}}) { + if !assert.{{.DocInfo.Name}}(t, {{.ForwardedParams}}) { + t.FailNow() + } +} diff --git a/vendor/github.com/stretchr/testify/require/require_forward.go b/vendor/github.com/stretchr/testify/require/require_forward.go new file mode 100644 index 000000000..c59c3c7b4 --- /dev/null +++ b/vendor/github.com/stretchr/testify/require/require_forward.go @@ -0,0 +1,747 @@ +/* +* CODE GENERATED AUTOMATICALLY WITH github.com/stretchr/testify/_codegen +* THIS FILE MUST NOT BE EDITED BY HAND + */ + +package require + +import ( + assert "github.com/stretchr/testify/assert" + http "net/http" + url "net/url" + time "time" +) + +// Condition uses a Comparison to assert a complex condition. +func (a *Assertions) Condition(comp assert.Comparison, msgAndArgs ...interface{}) { + Condition(a.t, comp, msgAndArgs...) +} + +// Conditionf uses a Comparison to assert a complex condition. +func (a *Assertions) Conditionf(comp assert.Comparison, msg string, args ...interface{}) { + Conditionf(a.t, comp, msg, args...) +} + +// Contains asserts that the specified string, list(array, slice...) or map contains the +// specified substring or element. +// +// a.Contains("Hello World", "World") +// a.Contains(["Hello", "World"], "World") +// a.Contains({"Hello": "World"}, "Hello") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) Contains(s interface{}, contains interface{}, msgAndArgs ...interface{}) { + Contains(a.t, s, contains, msgAndArgs...) +} + +// Containsf asserts that the specified string, list(array, slice...) or map contains the +// specified substring or element. +// +// a.Containsf("Hello World", "World", "error message %s", "formatted") +// a.Containsf(["Hello", "World"], "World", "error message %s", "formatted") +// a.Containsf({"Hello": "World"}, "Hello", "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) Containsf(s interface{}, contains interface{}, msg string, args ...interface{}) { + Containsf(a.t, s, contains, msg, args...) +} + +// Empty asserts that the specified object is empty. I.e. nil, "", false, 0 or either +// a slice or a channel with len == 0. +// +// a.Empty(obj) +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) Empty(object interface{}, msgAndArgs ...interface{}) { + Empty(a.t, object, msgAndArgs...) +} + +// Emptyf asserts that the specified object is empty. I.e. nil, "", false, 0 or either +// a slice or a channel with len == 0. +// +// a.Emptyf(obj, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) Emptyf(object interface{}, msg string, args ...interface{}) { + Emptyf(a.t, object, msg, args...) +} + +// Equal asserts that two objects are equal. +// +// a.Equal(123, 123) +// +// Returns whether the assertion was successful (true) or not (false). +// +// Pointer variable equality is determined based on the equality of the +// referenced values (as opposed to the memory addresses). Function equality +// cannot be determined and will always fail. +func (a *Assertions) Equal(expected interface{}, actual interface{}, msgAndArgs ...interface{}) { + Equal(a.t, expected, actual, msgAndArgs...) +} + +// EqualError asserts that a function returned an error (i.e. not `nil`) +// and that it is equal to the provided error. +// +// actualObj, err := SomeFunction() +// a.EqualError(err, expectedErrorString) +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) EqualError(theError error, errString string, msgAndArgs ...interface{}) { + EqualError(a.t, theError, errString, msgAndArgs...) +} + +// EqualErrorf asserts that a function returned an error (i.e. not `nil`) +// and that it is equal to the provided error. +// +// actualObj, err := SomeFunction() +// a.EqualErrorf(err, expectedErrorString, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) EqualErrorf(theError error, errString string, msg string, args ...interface{}) { + EqualErrorf(a.t, theError, errString, msg, args...) +} + +// EqualValues asserts that two objects are equal or convertable to the same types +// and equal. +// +// a.EqualValues(uint32(123), int32(123)) +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) EqualValues(expected interface{}, actual interface{}, msgAndArgs ...interface{}) { + EqualValues(a.t, expected, actual, msgAndArgs...) +} + +// EqualValuesf asserts that two objects are equal or convertable to the same types +// and equal. +// +// a.EqualValuesf(uint32(123, "error message %s", "formatted"), int32(123)) +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) EqualValuesf(expected interface{}, actual interface{}, msg string, args ...interface{}) { + EqualValuesf(a.t, expected, actual, msg, args...) +} + +// Equalf asserts that two objects are equal. +// +// a.Equalf(123, 123, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +// +// Pointer variable equality is determined based on the equality of the +// referenced values (as opposed to the memory addresses). Function equality +// cannot be determined and will always fail. +func (a *Assertions) Equalf(expected interface{}, actual interface{}, msg string, args ...interface{}) { + Equalf(a.t, expected, actual, msg, args...) +} + +// Error asserts that a function returned an error (i.e. not `nil`). +// +// actualObj, err := SomeFunction() +// if a.Error(err) { +// assert.Equal(t, expectedError, err) +// } +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) Error(err error, msgAndArgs ...interface{}) { + Error(a.t, err, msgAndArgs...) +} + +// Errorf asserts that a function returned an error (i.e. not `nil`). +// +// actualObj, err := SomeFunction() +// if a.Errorf(err, "error message %s", "formatted") { +// assert.Equal(t, expectedErrorf, err) +// } +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) Errorf(err error, msg string, args ...interface{}) { + Errorf(a.t, err, msg, args...) +} + +// Exactly asserts that two objects are equal is value and type. +// +// a.Exactly(int32(123), int64(123)) +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) Exactly(expected interface{}, actual interface{}, msgAndArgs ...interface{}) { + Exactly(a.t, expected, actual, msgAndArgs...) +} + +// Exactlyf asserts that two objects are equal is value and type. +// +// a.Exactlyf(int32(123, "error message %s", "formatted"), int64(123)) +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) Exactlyf(expected interface{}, actual interface{}, msg string, args ...interface{}) { + Exactlyf(a.t, expected, actual, msg, args...) +} + +// Fail reports a failure through +func (a *Assertions) Fail(failureMessage string, msgAndArgs ...interface{}) { + Fail(a.t, failureMessage, msgAndArgs...) +} + +// FailNow fails test +func (a *Assertions) FailNow(failureMessage string, msgAndArgs ...interface{}) { + FailNow(a.t, failureMessage, msgAndArgs...) +} + +// FailNowf fails test +func (a *Assertions) FailNowf(failureMessage string, msg string, args ...interface{}) { + FailNowf(a.t, failureMessage, msg, args...) +} + +// Failf reports a failure through +func (a *Assertions) Failf(failureMessage string, msg string, args ...interface{}) { + Failf(a.t, failureMessage, msg, args...) +} + +// False asserts that the specified value is false. +// +// a.False(myBool) +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) False(value bool, msgAndArgs ...interface{}) { + False(a.t, value, msgAndArgs...) +} + +// Falsef asserts that the specified value is false. +// +// a.Falsef(myBool, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) Falsef(value bool, msg string, args ...interface{}) { + Falsef(a.t, value, msg, args...) +} + +// HTTPBodyContains asserts that a specified handler returns a +// body that contains a string. +// +// a.HTTPBodyContains(myHandler, "www.google.com", nil, "I'm Feeling Lucky") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) HTTPBodyContains(handler http.HandlerFunc, method string, url string, values url.Values, str interface{}) { + HTTPBodyContains(a.t, handler, method, url, values, str) +} + +// HTTPBodyContainsf asserts that a specified handler returns a +// body that contains a string. +// +// a.HTTPBodyContainsf(myHandler, "www.google.com", nil, "I'm Feeling Lucky", "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) HTTPBodyContainsf(handler http.HandlerFunc, method string, url string, values url.Values, str interface{}) { + HTTPBodyContainsf(a.t, handler, method, url, values, str) +} + +// HTTPBodyNotContains asserts that a specified handler returns a +// body that does not contain a string. +// +// a.HTTPBodyNotContains(myHandler, "www.google.com", nil, "I'm Feeling Lucky") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) HTTPBodyNotContains(handler http.HandlerFunc, method string, url string, values url.Values, str interface{}) { + HTTPBodyNotContains(a.t, handler, method, url, values, str) +} + +// HTTPBodyNotContainsf asserts that a specified handler returns a +// body that does not contain a string. +// +// a.HTTPBodyNotContainsf(myHandler, "www.google.com", nil, "I'm Feeling Lucky", "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) HTTPBodyNotContainsf(handler http.HandlerFunc, method string, url string, values url.Values, str interface{}) { + HTTPBodyNotContainsf(a.t, handler, method, url, values, str) +} + +// HTTPError asserts that a specified handler returns an error status code. +// +// a.HTTPError(myHandler, "POST", "/a/b/c", url.Values{"a": []string{"b", "c"}} +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) HTTPError(handler http.HandlerFunc, method string, url string, values url.Values) { + HTTPError(a.t, handler, method, url, values) +} + +// HTTPErrorf asserts that a specified handler returns an error status code. +// +// a.HTTPErrorf(myHandler, "POST", "/a/b/c", url.Values{"a": []string{"b", "c"}} +// +// Returns whether the assertion was successful (true, "error message %s", "formatted") or not (false). +func (a *Assertions) HTTPErrorf(handler http.HandlerFunc, method string, url string, values url.Values) { + HTTPErrorf(a.t, handler, method, url, values) +} + +// HTTPRedirect asserts that a specified handler returns a redirect status code. +// +// a.HTTPRedirect(myHandler, "GET", "/a/b/c", url.Values{"a": []string{"b", "c"}} +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) HTTPRedirect(handler http.HandlerFunc, method string, url string, values url.Values) { + HTTPRedirect(a.t, handler, method, url, values) +} + +// HTTPRedirectf asserts that a specified handler returns a redirect status code. +// +// a.HTTPRedirectf(myHandler, "GET", "/a/b/c", url.Values{"a": []string{"b", "c"}} +// +// Returns whether the assertion was successful (true, "error message %s", "formatted") or not (false). +func (a *Assertions) HTTPRedirectf(handler http.HandlerFunc, method string, url string, values url.Values) { + HTTPRedirectf(a.t, handler, method, url, values) +} + +// HTTPSuccess asserts that a specified handler returns a success status code. +// +// a.HTTPSuccess(myHandler, "POST", "http://www.google.com", nil) +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) HTTPSuccess(handler http.HandlerFunc, method string, url string, values url.Values) { + HTTPSuccess(a.t, handler, method, url, values) +} + +// HTTPSuccessf asserts that a specified handler returns a success status code. +// +// a.HTTPSuccessf(myHandler, "POST", "http://www.google.com", nil, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) HTTPSuccessf(handler http.HandlerFunc, method string, url string, values url.Values) { + HTTPSuccessf(a.t, handler, method, url, values) +} + +// Implements asserts that an object is implemented by the specified interface. +// +// a.Implements((*MyInterface)(nil), new(MyObject)) +func (a *Assertions) Implements(interfaceObject interface{}, object interface{}, msgAndArgs ...interface{}) { + Implements(a.t, interfaceObject, object, msgAndArgs...) +} + +// Implementsf asserts that an object is implemented by the specified interface. +// +// a.Implementsf((*MyInterface, "error message %s", "formatted")(nil), new(MyObject)) +func (a *Assertions) Implementsf(interfaceObject interface{}, object interface{}, msg string, args ...interface{}) { + Implementsf(a.t, interfaceObject, object, msg, args...) +} + +// InDelta asserts that the two numerals are within delta of each other. +// +// a.InDelta(math.Pi, (22 / 7.0), 0.01) +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) InDelta(expected interface{}, actual interface{}, delta float64, msgAndArgs ...interface{}) { + InDelta(a.t, expected, actual, delta, msgAndArgs...) +} + +// InDeltaSlice is the same as InDelta, except it compares two slices. +func (a *Assertions) InDeltaSlice(expected interface{}, actual interface{}, delta float64, msgAndArgs ...interface{}) { + InDeltaSlice(a.t, expected, actual, delta, msgAndArgs...) +} + +// InDeltaSlicef is the same as InDelta, except it compares two slices. +func (a *Assertions) InDeltaSlicef(expected interface{}, actual interface{}, delta float64, msg string, args ...interface{}) { + InDeltaSlicef(a.t, expected, actual, delta, msg, args...) +} + +// InDeltaf asserts that the two numerals are within delta of each other. +// +// a.InDeltaf(math.Pi, (22 / 7.0, "error message %s", "formatted"), 0.01) +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) InDeltaf(expected interface{}, actual interface{}, delta float64, msg string, args ...interface{}) { + InDeltaf(a.t, expected, actual, delta, msg, args...) +} + +// InEpsilon asserts that expected and actual have a relative error less than epsilon +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) InEpsilon(expected interface{}, actual interface{}, epsilon float64, msgAndArgs ...interface{}) { + InEpsilon(a.t, expected, actual, epsilon, msgAndArgs...) +} + +// InEpsilonSlice is the same as InEpsilon, except it compares each value from two slices. +func (a *Assertions) InEpsilonSlice(expected interface{}, actual interface{}, epsilon float64, msgAndArgs ...interface{}) { + InEpsilonSlice(a.t, expected, actual, epsilon, msgAndArgs...) +} + +// InEpsilonSlicef is the same as InEpsilon, except it compares each value from two slices. +func (a *Assertions) InEpsilonSlicef(expected interface{}, actual interface{}, epsilon float64, msg string, args ...interface{}) { + InEpsilonSlicef(a.t, expected, actual, epsilon, msg, args...) +} + +// InEpsilonf asserts that expected and actual have a relative error less than epsilon +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) InEpsilonf(expected interface{}, actual interface{}, epsilon float64, msg string, args ...interface{}) { + InEpsilonf(a.t, expected, actual, epsilon, msg, args...) +} + +// IsType asserts that the specified objects are of the same type. +func (a *Assertions) IsType(expectedType interface{}, object interface{}, msgAndArgs ...interface{}) { + IsType(a.t, expectedType, object, msgAndArgs...) +} + +// IsTypef asserts that the specified objects are of the same type. +func (a *Assertions) IsTypef(expectedType interface{}, object interface{}, msg string, args ...interface{}) { + IsTypef(a.t, expectedType, object, msg, args...) +} + +// JSONEq asserts that two JSON strings are equivalent. +// +// a.JSONEq(`{"hello": "world", "foo": "bar"}`, `{"foo": "bar", "hello": "world"}`) +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) JSONEq(expected string, actual string, msgAndArgs ...interface{}) { + JSONEq(a.t, expected, actual, msgAndArgs...) +} + +// JSONEqf asserts that two JSON strings are equivalent. +// +// a.JSONEqf(`{"hello": "world", "foo": "bar"}`, `{"foo": "bar", "hello": "world"}`, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) JSONEqf(expected string, actual string, msg string, args ...interface{}) { + JSONEqf(a.t, expected, actual, msg, args...) +} + +// Len asserts that the specified object has specific length. +// Len also fails if the object has a type that len() not accept. +// +// a.Len(mySlice, 3) +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) Len(object interface{}, length int, msgAndArgs ...interface{}) { + Len(a.t, object, length, msgAndArgs...) +} + +// Lenf asserts that the specified object has specific length. +// Lenf also fails if the object has a type that len() not accept. +// +// a.Lenf(mySlice, 3, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) Lenf(object interface{}, length int, msg string, args ...interface{}) { + Lenf(a.t, object, length, msg, args...) +} + +// Nil asserts that the specified object is nil. +// +// a.Nil(err) +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) Nil(object interface{}, msgAndArgs ...interface{}) { + Nil(a.t, object, msgAndArgs...) +} + +// Nilf asserts that the specified object is nil. +// +// a.Nilf(err, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) Nilf(object interface{}, msg string, args ...interface{}) { + Nilf(a.t, object, msg, args...) +} + +// NoError asserts that a function returned no error (i.e. `nil`). +// +// actualObj, err := SomeFunction() +// if a.NoError(err) { +// assert.Equal(t, expectedObj, actualObj) +// } +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) NoError(err error, msgAndArgs ...interface{}) { + NoError(a.t, err, msgAndArgs...) +} + +// NoErrorf asserts that a function returned no error (i.e. `nil`). +// +// actualObj, err := SomeFunction() +// if a.NoErrorf(err, "error message %s", "formatted") { +// assert.Equal(t, expectedObj, actualObj) +// } +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) NoErrorf(err error, msg string, args ...interface{}) { + NoErrorf(a.t, err, msg, args...) +} + +// NotContains asserts that the specified string, list(array, slice...) or map does NOT contain the +// specified substring or element. +// +// a.NotContains("Hello World", "Earth") +// a.NotContains(["Hello", "World"], "Earth") +// a.NotContains({"Hello": "World"}, "Earth") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) NotContains(s interface{}, contains interface{}, msgAndArgs ...interface{}) { + NotContains(a.t, s, contains, msgAndArgs...) +} + +// NotContainsf asserts that the specified string, list(array, slice...) or map does NOT contain the +// specified substring or element. +// +// a.NotContainsf("Hello World", "Earth", "error message %s", "formatted") +// a.NotContainsf(["Hello", "World"], "Earth", "error message %s", "formatted") +// a.NotContainsf({"Hello": "World"}, "Earth", "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) NotContainsf(s interface{}, contains interface{}, msg string, args ...interface{}) { + NotContainsf(a.t, s, contains, msg, args...) +} + +// NotEmpty asserts that the specified object is NOT empty. I.e. not nil, "", false, 0 or either +// a slice or a channel with len == 0. +// +// if a.NotEmpty(obj) { +// assert.Equal(t, "two", obj[1]) +// } +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) NotEmpty(object interface{}, msgAndArgs ...interface{}) { + NotEmpty(a.t, object, msgAndArgs...) +} + +// NotEmptyf asserts that the specified object is NOT empty. I.e. not nil, "", false, 0 or either +// a slice or a channel with len == 0. +// +// if a.NotEmptyf(obj, "error message %s", "formatted") { +// assert.Equal(t, "two", obj[1]) +// } +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) NotEmptyf(object interface{}, msg string, args ...interface{}) { + NotEmptyf(a.t, object, msg, args...) +} + +// NotEqual asserts that the specified values are NOT equal. +// +// a.NotEqual(obj1, obj2) +// +// Returns whether the assertion was successful (true) or not (false). +// +// Pointer variable equality is determined based on the equality of the +// referenced values (as opposed to the memory addresses). +func (a *Assertions) NotEqual(expected interface{}, actual interface{}, msgAndArgs ...interface{}) { + NotEqual(a.t, expected, actual, msgAndArgs...) +} + +// NotEqualf asserts that the specified values are NOT equal. +// +// a.NotEqualf(obj1, obj2, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +// +// Pointer variable equality is determined based on the equality of the +// referenced values (as opposed to the memory addresses). +func (a *Assertions) NotEqualf(expected interface{}, actual interface{}, msg string, args ...interface{}) { + NotEqualf(a.t, expected, actual, msg, args...) +} + +// NotNil asserts that the specified object is not nil. +// +// a.NotNil(err) +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) NotNil(object interface{}, msgAndArgs ...interface{}) { + NotNil(a.t, object, msgAndArgs...) +} + +// NotNilf asserts that the specified object is not nil. +// +// a.NotNilf(err, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) NotNilf(object interface{}, msg string, args ...interface{}) { + NotNilf(a.t, object, msg, args...) +} + +// NotPanics asserts that the code inside the specified PanicTestFunc does NOT panic. +// +// a.NotPanics(func(){ RemainCalm() }) +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) NotPanics(f assert.PanicTestFunc, msgAndArgs ...interface{}) { + NotPanics(a.t, f, msgAndArgs...) +} + +// NotPanicsf asserts that the code inside the specified PanicTestFunc does NOT panic. +// +// a.NotPanicsf(func(){ RemainCalm() }, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) NotPanicsf(f assert.PanicTestFunc, msg string, args ...interface{}) { + NotPanicsf(a.t, f, msg, args...) +} + +// NotRegexp asserts that a specified regexp does not match a string. +// +// a.NotRegexp(regexp.MustCompile("starts"), "it's starting") +// a.NotRegexp("^start", "it's not starting") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) NotRegexp(rx interface{}, str interface{}, msgAndArgs ...interface{}) { + NotRegexp(a.t, rx, str, msgAndArgs...) +} + +// NotRegexpf asserts that a specified regexp does not match a string. +// +// a.NotRegexpf(regexp.MustCompile("starts", "error message %s", "formatted"), "it's starting") +// a.NotRegexpf("^start", "it's not starting", "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) NotRegexpf(rx interface{}, str interface{}, msg string, args ...interface{}) { + NotRegexpf(a.t, rx, str, msg, args...) +} + +// NotSubset asserts that the specified list(array, slice...) contains not all +// elements given in the specified subset(array, slice...). +// +// a.NotSubset([1, 3, 4], [1, 2], "But [1, 3, 4] does not contain [1, 2]") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) NotSubset(list interface{}, subset interface{}, msgAndArgs ...interface{}) { + NotSubset(a.t, list, subset, msgAndArgs...) +} + +// NotSubsetf asserts that the specified list(array, slice...) contains not all +// elements given in the specified subset(array, slice...). +// +// a.NotSubsetf([1, 3, 4], [1, 2], "But [1, 3, 4] does not contain [1, 2]", "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) NotSubsetf(list interface{}, subset interface{}, msg string, args ...interface{}) { + NotSubsetf(a.t, list, subset, msg, args...) +} + +// NotZero asserts that i is not the zero value for its type and returns the truth. +func (a *Assertions) NotZero(i interface{}, msgAndArgs ...interface{}) { + NotZero(a.t, i, msgAndArgs...) +} + +// NotZerof asserts that i is not the zero value for its type and returns the truth. +func (a *Assertions) NotZerof(i interface{}, msg string, args ...interface{}) { + NotZerof(a.t, i, msg, args...) +} + +// Panics asserts that the code inside the specified PanicTestFunc panics. +// +// a.Panics(func(){ GoCrazy() }) +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) Panics(f assert.PanicTestFunc, msgAndArgs ...interface{}) { + Panics(a.t, f, msgAndArgs...) +} + +// PanicsWithValue asserts that the code inside the specified PanicTestFunc panics, and that +// the recovered panic value equals the expected panic value. +// +// a.PanicsWithValue("crazy error", func(){ GoCrazy() }) +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) PanicsWithValue(expected interface{}, f assert.PanicTestFunc, msgAndArgs ...interface{}) { + PanicsWithValue(a.t, expected, f, msgAndArgs...) +} + +// PanicsWithValuef asserts that the code inside the specified PanicTestFunc panics, and that +// the recovered panic value equals the expected panic value. +// +// a.PanicsWithValuef("crazy error", func(){ GoCrazy() }, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) PanicsWithValuef(expected interface{}, f assert.PanicTestFunc, msg string, args ...interface{}) { + PanicsWithValuef(a.t, expected, f, msg, args...) +} + +// Panicsf asserts that the code inside the specified PanicTestFunc panics. +// +// a.Panicsf(func(){ GoCrazy() }, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) Panicsf(f assert.PanicTestFunc, msg string, args ...interface{}) { + Panicsf(a.t, f, msg, args...) +} + +// Regexp asserts that a specified regexp matches a string. +// +// a.Regexp(regexp.MustCompile("start"), "it's starting") +// a.Regexp("start...$", "it's not starting") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) Regexp(rx interface{}, str interface{}, msgAndArgs ...interface{}) { + Regexp(a.t, rx, str, msgAndArgs...) +} + +// Regexpf asserts that a specified regexp matches a string. +// +// a.Regexpf(regexp.MustCompile("start", "error message %s", "formatted"), "it's starting") +// a.Regexpf("start...$", "it's not starting", "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) Regexpf(rx interface{}, str interface{}, msg string, args ...interface{}) { + Regexpf(a.t, rx, str, msg, args...) +} + +// Subset asserts that the specified list(array, slice...) contains all +// elements given in the specified subset(array, slice...). +// +// a.Subset([1, 2, 3], [1, 2], "But [1, 2, 3] does contain [1, 2]") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) Subset(list interface{}, subset interface{}, msgAndArgs ...interface{}) { + Subset(a.t, list, subset, msgAndArgs...) +} + +// Subsetf asserts that the specified list(array, slice...) contains all +// elements given in the specified subset(array, slice...). +// +// a.Subsetf([1, 2, 3], [1, 2], "But [1, 2, 3] does contain [1, 2]", "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) Subsetf(list interface{}, subset interface{}, msg string, args ...interface{}) { + Subsetf(a.t, list, subset, msg, args...) +} + +// True asserts that the specified value is true. +// +// a.True(myBool) +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) True(value bool, msgAndArgs ...interface{}) { + True(a.t, value, msgAndArgs...) +} + +// Truef asserts that the specified value is true. +// +// a.Truef(myBool, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) Truef(value bool, msg string, args ...interface{}) { + Truef(a.t, value, msg, args...) +} + +// WithinDuration asserts that the two times are within duration delta of each other. +// +// a.WithinDuration(time.Now(), time.Now(), 10*time.Second) +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) WithinDuration(expected time.Time, actual time.Time, delta time.Duration, msgAndArgs ...interface{}) { + WithinDuration(a.t, expected, actual, delta, msgAndArgs...) +} + +// WithinDurationf asserts that the two times are within duration delta of each other. +// +// a.WithinDurationf(time.Now(), time.Now(), 10*time.Second, "error message %s", "formatted") +// +// Returns whether the assertion was successful (true) or not (false). +func (a *Assertions) WithinDurationf(expected time.Time, actual time.Time, delta time.Duration, msg string, args ...interface{}) { + WithinDurationf(a.t, expected, actual, delta, msg, args...) +} + +// Zero asserts that i is the zero value for its type and returns the truth. +func (a *Assertions) Zero(i interface{}, msgAndArgs ...interface{}) { + Zero(a.t, i, msgAndArgs...) +} + +// Zerof asserts that i is the zero value for its type and returns the truth. +func (a *Assertions) Zerof(i interface{}, msg string, args ...interface{}) { + Zerof(a.t, i, msg, args...) +} diff --git a/vendor/github.com/stretchr/testify/require/require_forward.go.tmpl b/vendor/github.com/stretchr/testify/require/require_forward.go.tmpl new file mode 100644 index 000000000..b93569e0a --- /dev/null +++ b/vendor/github.com/stretchr/testify/require/require_forward.go.tmpl @@ -0,0 +1,4 @@ +{{.CommentWithoutT "a"}} +func (a *Assertions) {{.DocInfo.Name}}({{.Params}}) { + {{.DocInfo.Name}}(a.t, {{.ForwardedParams}}) +} diff --git a/vendor/github.com/stretchr/testify/require/requirements.go b/vendor/github.com/stretchr/testify/require/requirements.go new file mode 100644 index 000000000..e404f016d --- /dev/null +++ b/vendor/github.com/stretchr/testify/require/requirements.go @@ -0,0 +1,9 @@ +package require + +// TestingT is an interface wrapper around *testing.T +type TestingT interface { + Errorf(format string, args ...interface{}) + FailNow() +} + +//go:generate go run ../_codegen/main.go -output-package=require -template=require.go.tmpl -include-format-funcs diff --git a/vendor/vendor.json b/vendor/vendor.json index eec26146c..c1f64dda1 100644 --- a/vendor/vendor.json +++ b/vendor/vendor.json @@ -232,6 +232,7 @@ {"path":"github.com/spf13/pflag","checksumSHA1":"Q52Y7t0lEtk/wcDn5q7tS7B+jqs=","revision":"7aff26db30c1be810f9de5038ec5ef96ac41fd7c","revisionTime":"2017-08-24T17:57:12Z"}, {"path":"github.com/stretchr/objx","checksumSHA1":"K0crHygPTP42i1nLKWphSlvOQJw=","revision":"1a9d0bb9f541897e62256577b352fdbc1fb4fd94","revisionTime":"2015-09-28T12:21:52Z"}, {"path":"github.com/stretchr/testify/mock","checksumSHA1":"o+jsS/rxceTym4M3reSPfrPxaio=","revision":"f6abca593680b2315d2075e0f5e2a9751e3f431a","revisionTime":"2017-06-01T20:57:54Z"}, + {"path":"github.com/stretchr/testify/require","checksumSHA1":"7vs6dSc1PPGBKyzb/SCIyeMJPLQ=","revision":"f6abca593680b2315d2075e0f5e2a9751e3f431a","revisionTime":"2017-06-01T20:57:54Z"}, {"path":"github.com/ugorji/go/codec","checksumSHA1":"8G1zvpE4gTtWQRuP/x2HPVDmflo=","revision":"0053ebfd9d0ee06ccefbfe17072021e1d4acebee","revisionTime":"2017-06-20T06:01:02Z"}, {"path":"github.com/ugorji/go/codec/codecgen","checksumSHA1":"OgParimNuU2CJqr3pcTympeQZUc=","revision":"5efa3251c7f7d05e5d9704a69a984ec9f1386a40","revisionTime":"2017-06-20T10:48:52Z"}, {"path":"github.com/ulikunitz/xz","checksumSHA1":"z2kAtVle4NFV2OExI85fZoTcsI4=","revision":"0c6b41e72360850ca4f98dc341fd999726ea007f","revisionTime":"2017-06-05T21:53:11Z"}, From 73303b4b44a9a76ec52bf4372c89ccf886b82bed Mon Sep 17 00:00:00 2001 From: Alex Dadgar Date: Thu, 4 Jan 2018 14:45:15 -0800 Subject: [PATCH 042/136] gofmt --- CHANGELOG.md | 2 +- scheduler/generic_sched_test.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 9c34c31a0..e23e1d43d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,7 +3,7 @@ BUG FIXES: * core: Fix search endpoint forwarding for multi-region clusters [[GH-3680](https://github.com/hashicorp/nomad/issues/3680)] * core: Fix an issue in which batch jobs with queued placements and lost - allocations could result in improper placement counts [GH-3717] + allocations could result in improper placement counts [[GH-3717](https://github.com/hashicorp/nomad/issues/3717)] * config: Revert minimum CPU limit back to 20 from 100. ## 0.7.1 (December 19, 2017) diff --git a/scheduler/generic_sched_test.go b/scheduler/generic_sched_test.go index dbb54d80c..39eff3773 100644 --- a/scheduler/generic_sched_test.go +++ b/scheduler/generic_sched_test.go @@ -3270,7 +3270,7 @@ func TestBatchSched_NodeDrain_Complete(t *testing.T) { alloc.TaskStates["web"] = &structs.TaskState{ State: structs.TaskStateDead, Events: []*structs.TaskEvent{ - &structs.TaskEvent{ + { Type: structs.TaskTerminated, ExitCode: 0, }, From 8295f81dddf8b53c0b78707be6fddc6e30f95640 Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Thu, 4 Jan 2018 15:05:27 -0800 Subject: [PATCH 043/136] Missed header mention of server.check_restart --- website/source/docs/job-specification/check_restart.html.md | 6 ------ 1 file changed, 6 deletions(-) diff --git a/website/source/docs/job-specification/check_restart.html.md b/website/source/docs/job-specification/check_restart.html.md index 19b720276..f61648f0f 100644 --- a/website/source/docs/job-specification/check_restart.html.md +++ b/website/source/docs/job-specification/check_restart.html.md @@ -10,12 +10,6 @@ description: |- # `check_restart` Stanza - - - -
      Placement - job -> group -> task -> service -> **check_restart** -
      Placement From 357213d8ea4a49b13e18415ffd9de7326e8ad918 Mon Sep 17 00:00:00 2001 From: Alex Dadgar Date: Thu, 4 Jan 2018 15:08:12 -0800 Subject: [PATCH 044/136] Remove consul log line --- nomad/serf.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nomad/serf.go b/nomad/serf.go index 011d7b358..b5df4646a 100644 --- a/nomad/serf.go +++ b/nomad/serf.go @@ -154,7 +154,7 @@ func (s *Server) maybeBootstrap() { if err := s.connPool.RPC(s.config.Region, server.Addr, server.MajorVersion, "Status.Peers", req, &peers); err != nil { nextRetry := (1 << attempt) * peerRetryBase - s.logger.Printf("[ERR] consul: Failed to confirm peer status for %s: %v. Retrying in "+ + s.logger.Printf("[ERR] nomad: Failed to confirm peer status for %s: %v. Retrying in "+ "%v...", server.Name, err, nextRetry.String()) time.Sleep(nextRetry) } else { From 3c57705cd1e00fd76d88099729757a42eca3f98f Mon Sep 17 00:00:00 2001 From: Preetha Appan Date: Fri, 5 Jan 2018 14:22:08 -0600 Subject: [PATCH 045/136] Add a TODO comment around handling peer address for remove peer correctly for raft protocol 3 --- nomad/server.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nomad/server.go b/nomad/server.go index 1bd77e3bb..7648c7436 100644 --- a/nomad/server.go +++ b/nomad/server.go @@ -425,8 +425,8 @@ func (s *Server) Leave() error { return err } - // TODO (alexdadgar) - This will need to be updated once we support node - // IDs. + // TODO (alexdadgar) - This will need to be updated before 0.8 release to + // correctly handle using node IDs instead of address when raftProtocol = 3 addr := s.raftTransport.LocalAddr() // If we are the current leader, and we have any other peers (cluster has multiple From 04383ff15db546ec430e2681fab504fe3cbbb5f8 Mon Sep 17 00:00:00 2001 From: Conchubhar Gannon Date: Mon, 8 Jan 2018 11:30:00 +0000 Subject: [PATCH 046/136] fix(minor typo) --- nomad/structs/structs.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nomad/structs/structs.go b/nomad/structs/structs.go index 7315f2c10..82ef23e4c 100644 --- a/nomad/structs/structs.go +++ b/nomad/structs/structs.go @@ -3643,7 +3643,7 @@ type Template struct { DestPath string // EmbeddedTmpl store the raw template. This is useful for smaller templates - // where they are embedded in the job file rather than sent as an artificat + // where they are embedded in the job file rather than sent as an artifact EmbeddedTmpl string // ChangeMode indicates what should be done if the template is re-rendered From 38996137cf6f134bc7e8a9f8a1d1299ac8529507 Mon Sep 17 00:00:00 2001 From: Filip Ochnik Date: Mon, 8 Jan 2018 20:32:31 +0100 Subject: [PATCH 047/136] Recognize renewing non-renewable Vault lease as fatal --- client/vaultclient/vaultclient.go | 1 + client/vaultclient/vaultclient_test.go | 83 ++++++++++++++++++++++++++ 2 files changed, 84 insertions(+) diff --git a/client/vaultclient/vaultclient.go b/client/vaultclient/vaultclient.go index 7fe7958ed..af78eea64 100644 --- a/client/vaultclient/vaultclient.go +++ b/client/vaultclient/vaultclient.go @@ -428,6 +428,7 @@ func (c *vaultClient) renew(req *vaultClientRenewalRequest) error { fatal := false if renewalErr != nil && (strings.Contains(renewalErr.Error(), "lease not found or lease is not renewable") || + strings.Contains(renewalErr.Error(), "lease is not renewable") || strings.Contains(renewalErr.Error(), "token not found") || strings.Contains(renewalErr.Error(), "permission denied")) { fatal = true diff --git a/client/vaultclient/vaultclient_test.go b/client/vaultclient/vaultclient_test.go index dc0b63aa8..7322d3351 100644 --- a/client/vaultclient/vaultclient_test.go +++ b/client/vaultclient/vaultclient_test.go @@ -3,6 +3,7 @@ package vaultclient import ( "log" "os" + "strings" "testing" "time" @@ -197,3 +198,85 @@ func TestVaultClient_Heap(t *testing.T) { } } + +func TestVaultClient_RenewNonRenewableLease(t *testing.T) { + t.Parallel() + v := testutil.NewTestVault(t) + defer v.Stop() + + logger := log.New(os.Stderr, "TEST: ", log.Lshortfile|log.LstdFlags) + v.Config.ConnectionRetryIntv = 100 * time.Millisecond + v.Config.TaskTokenTTL = "4s" + c, err := NewVaultClient(v.Config, logger, nil) + if err != nil { + t.Fatalf("failed to build vault client: %v", err) + } + + c.Start() + defer c.Stop() + + // Sleep a little while to ensure that the renewal loop is active + time.Sleep(time.Duration(testutil.TestMultiplier()) * time.Second) + + tcr := &vaultapi.TokenCreateRequest{ + Policies: []string{"foo", "bar"}, + TTL: "2s", + DisplayName: "derived-for-task", + Renewable: new(bool), + } + + c.client.SetToken(v.Config.Token) + + if err := c.client.SetAddress(v.Config.Addr); err != nil { + t.Fatal(err) + } + + secret, err := c.client.Auth().Token().Create(tcr) + if err != nil { + t.Fatalf("failed to create vault token: %v", err) + } + + if secret == nil || secret.Auth == nil || secret.Auth.ClientToken == "" { + t.Fatal("failed to derive a wrapped vault token") + } + + _, err = c.RenewToken(secret.Auth.ClientToken, secret.Auth.LeaseDuration) + if err == nil { + t.Fatalf("expected error, got nil") + } else if !strings.Contains(err.Error(), "lease is not renewable") { + t.Fatalf("expected \"%s\" in error message, got \"%v\"", "lease is not renewable", err) + } +} + +func TestVaultClient_RenewNonExistentLease(t *testing.T) { + t.Parallel() + v := testutil.NewTestVault(t) + defer v.Stop() + + logger := log.New(os.Stderr, "TEST: ", log.Lshortfile|log.LstdFlags) + v.Config.ConnectionRetryIntv = 100 * time.Millisecond + v.Config.TaskTokenTTL = "4s" + c, err := NewVaultClient(v.Config, logger, nil) + if err != nil { + t.Fatalf("failed to build vault client: %v", err) + } + + c.Start() + defer c.Stop() + + // Sleep a little while to ensure that the renewal loop is active + time.Sleep(time.Duration(testutil.TestMultiplier()) * time.Second) + + c.client.SetToken(v.Config.Token) + + if err := c.client.SetAddress(v.Config.Addr); err != nil { + t.Fatal(err) + } + + _, err = c.RenewToken(c.client.Token(), 10) + if err == nil { + t.Fatalf("expected error, got nil") + } else if !strings.Contains(err.Error(), "lease not found") { + t.Fatalf("expected \"%s\" in error message, got \"%v\"", "lease not found", err) + } +} From 4c859dc0aa6085d93bc2888ae3b448cb1f76cd09 Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Mon, 8 Jan 2018 12:09:29 -0800 Subject: [PATCH 048/136] Include credentials in fetch requests Fixes #3701 Relevant spec section: https://fetch.spec.whatwg.org/#concept-request-credentials-mode --- CHANGELOG.md | 1 + ui/app/services/token.js | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e23e1d43d..3a4bba81d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,7 @@ BUG FIXES: * core: Fix an issue in which batch jobs with queued placements and lost allocations could result in improper placement counts [[GH-3717](https://github.com/hashicorp/nomad/issues/3717)] * config: Revert minimum CPU limit back to 20 from 100. + * ui: Fix requests using client-side certificates in Firefox. [[GH-3728](https://github.com/hashicorp/nomad/pull/3728)] ## 0.7.1 (December 19, 2017) diff --git a/ui/app/services/token.js b/ui/app/services/token.js index be1da0c90..d51d7510b 100644 --- a/ui/app/services/token.js +++ b/ui/app/services/token.js @@ -19,7 +19,7 @@ export default Service.extend({ }, }), - authorizedRequest(url, options = {}) { + authorizedRequest(url, options = { credentials: 'include' }) { const headers = {}; const token = this.get('secret'); From 4eaa6700face2c2c02779649a148911cd8ffc5c8 Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Mon, 8 Jan 2018 12:53:58 -0800 Subject: [PATCH 049/136] Logger backed by *testing.T For capturing log output in tests and only displaying them on failure. Pulled out of #3241 --- helper/testlog/testlog.go | 40 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 helper/testlog/testlog.go diff --git a/helper/testlog/testlog.go b/helper/testlog/testlog.go new file mode 100644 index 000000000..1b18bc025 --- /dev/null +++ b/helper/testlog/testlog.go @@ -0,0 +1,40 @@ +// Package testlog creates a *log.Logger backed by testing.T to ease logging in +// tests. +package testlog + +import ( + "io" + "log" +) + +// Logger is the methods of testing.T (or testing.B) needed by the test +// logger. +type Logger interface { + Logf(format string, args ...interface{}) +} + +// writer implements io.Writer on top of a Logger. +type writer struct { + t Logger +} + +// Write to an underlying Logger. Never returns an error. +func (w *writer) Write(p []byte) (n int, err error) { + w.t.Logf(string(p)) + return len(p), nil +} + +// NewWriter creates a new io.Writer backed by a Logger. +func NewWriter(t Logger) io.Writer { + return &writer{t} +} + +// NewLog returns a new test logger. See https://golang.org/pkg/log/#New +func NewLog(t Logger, prefix string, flag int) *log.Logger { + return log.New(&writer{t}, prefix, flag) +} + +// New logger with "TEST" prefix and the Lmicroseconds flag. +func New(t Logger) *log.Logger { + return NewLog(t, "TEST ", log.Lmicroseconds) +} From 8d6bd6dca4ab10eec29c9faf4e41bdc66741cba2 Mon Sep 17 00:00:00 2001 From: Charlie Voiselle Date: Mon, 8 Jan 2018 15:56:07 -0500 Subject: [PATCH 050/136] fix typo Priviledge -> privilege --- CHANGELOG.md | 2 +- client/driver/executor/executor_linux_test.go | 2 +- client/driver/structs/structs.go | 2 +- client/driver/utils.go | 2 +- nomad/structs/structs.go | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e23e1d43d..9c840713f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -656,7 +656,7 @@ BUG FIXES: * client: Killing an allocation doesn't cause allocation stats to block [[GH-1454](https://github.com/hashicorp/nomad/issues/1454)] * driver/docker: Disable swap on docker driver [[GH-1480](https://github.com/hashicorp/nomad/issues/1480)] - * driver/docker: Fix improper gating on priviledged mode [[GH-1506](https://github.com/hashicorp/nomad/issues/1506)] + * driver/docker: Fix improper gating on privileged mode [[GH-1506](https://github.com/hashicorp/nomad/issues/1506)] * driver/docker: Default network type is "nat" on Windows [[GH-1521](https://github.com/hashicorp/nomad/issues/1521)] * driver/docker: Cleanup created volume when destroying container [[GH-1519](https://github.com/hashicorp/nomad/issues/1519)] * driver/rkt: Set host environment variables [[GH-1581](https://github.com/hashicorp/nomad/issues/1581)] diff --git a/client/driver/executor/executor_linux_test.go b/client/driver/executor/executor_linux_test.go index 905d88000..ad73f13e3 100644 --- a/client/driver/executor/executor_linux_test.go +++ b/client/driver/executor/executor_linux_test.go @@ -69,7 +69,7 @@ func TestExecutor_IsolationAndConstraints(t *testing.T) { execCmd.FSIsolation = true execCmd.ResourceLimits = true - execCmd.User = dstructs.DefaultUnpriviledgedUser + execCmd.User = dstructs.DefaultUnprivilegedUser executor := NewExecutor(log.New(os.Stdout, "", log.LstdFlags)) diff --git a/client/driver/structs/structs.go b/client/driver/structs/structs.go index aed1e831a..6966205f7 100644 --- a/client/driver/structs/structs.go +++ b/client/driver/structs/structs.go @@ -7,7 +7,7 @@ import ( const ( // The default user that the executor uses to run tasks - DefaultUnpriviledgedUser = "nobody" + DefaultUnprivilegedUser = "nobody" // CheckBufSize is the size of the check output result CheckBufSize = 4 * 1024 diff --git a/client/driver/utils.go b/client/driver/utils.go index 23a64c89c..5fba8071f 100644 --- a/client/driver/utils.go +++ b/client/driver/utils.go @@ -178,7 +178,7 @@ func GetAbsolutePath(bin string) (string, error) { // dstructs.DefaultUnprivilegedUser if none was given. func getExecutorUser(task *structs.Task) string { if task.User == "" { - return dstructs.DefaultUnpriviledgedUser + return dstructs.DefaultUnprivilegedUser } return task.User } diff --git a/nomad/structs/structs.go b/nomad/structs/structs.go index 82ef23e4c..32e624cd2 100644 --- a/nomad/structs/structs.go +++ b/nomad/structs/structs.go @@ -1070,7 +1070,7 @@ type Node struct { // SecretID is an ID that is only known by the Node and the set of Servers. // It is not accessible via the API and is used to authenticate nodes - // conducting priviledged activities. + // conducting privileged activities. SecretID string // Datacenter for this node From 12c6a94590e0b6c3bf176375ef9ef147f7089417 Mon Sep 17 00:00:00 2001 From: Rob Genova Date: Mon, 8 Jan 2018 21:33:26 +0000 Subject: [PATCH 051/136] Merge Community page content into Resources page --- website/source/resources.html.erb | 69 ++++++++++++++++++++----------- 1 file changed, 45 insertions(+), 24 deletions(-) diff --git a/website/source/resources.html.erb b/website/source/resources.html.erb index 06e43b96b..bbcfde46b 100644 --- a/website/source/resources.html.erb +++ b/website/source/resources.html.erb @@ -13,6 +13,25 @@ description: |- integration with third-party tools.

      +

      Community

      + +

      + Gitter: Nomad Gitter Room +

      +

      + IRC: Use the Gitter IRC bridge +

      +

      + Mailing list: + Nomad Google Group +

      +

      + Bug Tracker: + Issue tracker + on GitHub. Please only use this for reporting bugs. Do not ask + for general help here. Use IRC or the mailing list for that. +

      +

      Videos

        @@ -29,45 +48,47 @@ description: |-

        Blog Posts

        Tools for Provisioning and Experimentation

        Integrations

        Other

        Trusted By

        From de3f7b4da8cea4c89f050c2f78d1a1f9ff73b090 Mon Sep 17 00:00:00 2001 From: Rob Genova Date: Mon, 8 Jan 2018 21:33:55 +0000 Subject: [PATCH 052/136] Remove Community links from header and footer --- website/source/layouts/layout.erb | 2 -- 1 file changed, 2 deletions(-) diff --git a/website/source/layouts/layout.erb b/website/source/layouts/layout.erb index 7493446f9..d35945497 100644 --- a/website/source/layouts/layout.erb +++ b/website/source/layouts/layout.erb @@ -84,7 +84,6 @@
      • Guides
      • Docs
      • API
      • -
      • Community
      • Resources
      • Enterprise
      • UI Demo
      • @@ -119,7 +118,6 @@
      • Guides
      • Docs
      • API
      • -
      • Community
      • Resources
      • Enterprise
      • UI Demo
      • From d30d89b89871c59b42344454c0895c3d8bf866b4 Mon Sep 17 00:00:00 2001 From: Rob Genova Date: Mon, 8 Jan 2018 21:34:26 +0000 Subject: [PATCH 053/136] Add redirect from Community page to Resources page --- website/redirects.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/website/redirects.txt b/website/redirects.txt index f1ed702f6..c1a799093 100644 --- a/website/redirects.txt +++ b/website/redirects.txt @@ -36,6 +36,9 @@ # - Items are case-sensitive (please use all lowercase) # +# Website +/community.html /resources.html + # Docs /docs/agent/config.html /docs/agent/configuration/index.html /docs/jobops /docs/operating-a-job/index.html From 98c72e953beefc1a31bcc721bd60f05eeb06b430 Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Mon, 8 Jan 2018 13:36:07 -0800 Subject: [PATCH 054/136] Improve naming and docs --- helper/testlog/testlog.go | 28 +++++++++++++++++----------- 1 file changed, 17 insertions(+), 11 deletions(-) diff --git a/helper/testlog/testlog.go b/helper/testlog/testlog.go index 1b18bc025..7f6c6cb04 100644 --- a/helper/testlog/testlog.go +++ b/helper/testlog/testlog.go @@ -1,5 +1,6 @@ -// Package testlog creates a *log.Logger backed by testing.T to ease logging in -// tests. +// Package testlog creates a *log.Logger backed by *testing.T to ease logging +// in tests. This allows logs from components being tested to only be printed +// if the test fails (or the verbose flag is specified). package testlog import ( @@ -7,15 +8,15 @@ import ( "log" ) -// Logger is the methods of testing.T (or testing.B) needed by the test +// LogPrinter is the methods of testing.T (or testing.B) needed by the test // logger. -type Logger interface { +type LogPrinter interface { Logf(format string, args ...interface{}) } // writer implements io.Writer on top of a Logger. type writer struct { - t Logger + t LogPrinter } // Write to an underlying Logger. Never returns an error. @@ -25,16 +26,21 @@ func (w *writer) Write(p []byte) (n int, err error) { } // NewWriter creates a new io.Writer backed by a Logger. -func NewWriter(t Logger) io.Writer { +func NewWriter(t LogPrinter) io.Writer { return &writer{t} } -// NewLog returns a new test logger. See https://golang.org/pkg/log/#New -func NewLog(t Logger, prefix string, flag int) *log.Logger { +// New returns a new test logger. See https://golang.org/pkg/log/#New +func New(t LogPrinter, prefix string, flag int) *log.Logger { return log.New(&writer{t}, prefix, flag) } -// New logger with "TEST" prefix and the Lmicroseconds flag. -func New(t Logger) *log.Logger { - return NewLog(t, "TEST ", log.Lmicroseconds) +// WithPrefix returns a new test logger with the Lmicroseconds flag set. +func WithPrefix(t LogPrinter, prefix string) *log.Logger { + return New(t, prefix, log.Lmicroseconds) +} + +// NewLog logger with "TEST" prefix and the Lmicroseconds flag. +func Logger(t LogPrinter) *log.Logger { + return WithPrefix(t, "TEST ") } From 2f873299b485a794823991803c041badef8e053e Mon Sep 17 00:00:00 2001 From: Rob Genova Date: Mon, 8 Jan 2018 21:42:47 +0000 Subject: [PATCH 055/136] Add new blog post --- website/source/resources.html.erb | 1 + 1 file changed, 1 insertion(+) diff --git a/website/source/resources.html.erb b/website/source/resources.html.erb index bbcfde46b..2be3c7372 100644 --- a/website/source/resources.html.erb +++ b/website/source/resources.html.erb @@ -49,6 +49,7 @@ description: |-
        • Cluster Schedulers - Cindy Sridharan
        • +
        • Playing with Nomad from HashiCorp - Daniel Parker, Target
        • Migrating from AWS to AWS - Gabriel Teles
        • How CircleCI Processes 4.5 Million Builds Per Month - Rob Zuber
        • Envoy with Nomad and Consul - Tim Perrett
        • From 67e3e19666070194981432d46376ba23a807801a Mon Sep 17 00:00:00 2001 From: Rob Genova Date: Mon, 8 Jan 2018 22:44:02 +0000 Subject: [PATCH 056/136] Use latest versions of Consul, Vault and Nomad --- terraform/shared/scripts/setup.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/terraform/shared/scripts/setup.sh b/terraform/shared/scripts/setup.sh index b60573317..da6ade089 100644 --- a/terraform/shared/scripts/setup.sh +++ b/terraform/shared/scripts/setup.sh @@ -6,17 +6,17 @@ cd /ops CONFIGDIR=/ops/shared/config -CONSULVERSION=1.0.0 +CONSULVERSION=1.0.2 CONSULDOWNLOAD=https://releases.hashicorp.com/consul/${CONSULVERSION}/consul_${CONSULVERSION}_linux_amd64.zip CONSULCONFIGDIR=/etc/consul.d CONSULDIR=/opt/consul -VAULTVERSION=0.8.3 +VAULTVERSION=0.9.1 VAULTDOWNLOAD=https://releases.hashicorp.com/vault/${VAULTVERSION}/vault_${VAULTVERSION}_linux_amd64.zip VAULTCONFIGDIR=/etc/vault.d VAULTDIR=/opt/vault -NOMADVERSION=0.7.0 +NOMADVERSION=0.7.1 NOMADDOWNLOAD=https://releases.hashicorp.com/nomad/${NOMADVERSION}/nomad_${NOMADVERSION}_linux_amd64.zip NOMADCONFIGDIR=/etc/nomad.d NOMADDIR=/opt/nomad From a010d4baa8b5deece14583b4f28af705ded7ec3c Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Fri, 5 Jan 2018 15:45:41 -0800 Subject: [PATCH 057/136] chown dirs when migrating ephemeral_disk data Fixes #3702 Added missing chown call and made it conditional on running as root and not on Windows as we do with files. --- CHANGELOG.md | 1 + client/alloc_watcher.go | 13 ++++++++++--- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e23e1d43d..e6a3711a1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,7 @@ BUG FIXES: * core: Fix search endpoint forwarding for multi-region clusters [[GH-3680](https://github.com/hashicorp/nomad/issues/3680)] * core: Fix an issue in which batch jobs with queued placements and lost allocations could result in improper placement counts [[GH-3717](https://github.com/hashicorp/nomad/issues/3717)] + * client: Migrated ephemeral_disk's maintain directory permissions [[GH-3723](https://github.com/hashicorp/nomad/issues/3723)] * config: Revert minimum CPU limit back to 20 from 100. ## 0.7.1 (December 19, 2017) diff --git a/client/alloc_watcher.go b/client/alloc_watcher.go index e54e7184d..ecac7190f 100644 --- a/client/alloc_watcher.go +++ b/client/alloc_watcher.go @@ -499,7 +499,15 @@ func (p *remotePrevAlloc) streamAllocDir(ctx context.Context, resp io.ReadCloser // If the header is for a directory we create the directory if hdr.Typeflag == tar.TypeDir { - os.MkdirAll(filepath.Join(dest, hdr.Name), os.FileMode(hdr.Mode)) + name := filepath.Join(dest, hdr.Name) + os.MkdirAll(name, os.FileMode(hdr.Mode)) + + // Can't change owner if not root or on Windows. + if euid == 0 { + if err := os.Chown(name, hdr.Uid, hdr.Gid); err != nil { + return fmt.Errorf("error chowning directory %v", err) + } + } continue } // If the header is for a symlink we create the symlink @@ -522,8 +530,7 @@ func (p *remotePrevAlloc) streamAllocDir(ctx context.Context, resp io.ReadCloser return fmt.Errorf("error chmoding file %v", err) } - // Can't change owner if not root. Returns false on - // Windows as Chown always errors there. + // Can't change owner if not root or on Windows. if euid == 0 { if err := f.Chown(hdr.Uid, hdr.Gid); err != nil { f.Close() From 58f76231825c01153cc70c3749744f6ffc5527f2 Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Mon, 8 Jan 2018 16:00:07 -0800 Subject: [PATCH 058/136] Test streamed directory ownership --- client/alloc_watcher_test.go | 29 +++++++++++++++++++++++++---- 1 file changed, 25 insertions(+), 4 deletions(-) diff --git a/client/alloc_watcher_test.go b/client/alloc_watcher_test.go index 0ecb46865..45972e759 100644 --- a/client/alloc_watcher_test.go +++ b/client/alloc_watcher_test.go @@ -10,11 +10,13 @@ import ( "os" "path/filepath" "strings" + "syscall" "testing" "time" "github.com/hashicorp/nomad/client/allocdir" "github.com/hashicorp/nomad/client/config" + "github.com/hashicorp/nomad/client/testutil" "github.com/hashicorp/nomad/nomad/mock" ) @@ -73,6 +75,7 @@ func TestPrevAlloc_LocalPrevAlloc(t *testing.T) { // TestPrevAlloc_StreamAllocDir_Ok asserts that streaming a tar to an alloc dir // works. func TestPrevAlloc_StreamAllocDir_Ok(t *testing.T) { + testutil.RequireRoot(t) t.Parallel() dir, err := ioutil.TempDir("", "") if err != nil { @@ -80,18 +83,29 @@ func TestPrevAlloc_StreamAllocDir_Ok(t *testing.T) { } defer os.RemoveAll(dir) - if err := os.Mkdir(filepath.Join(dir, "foo"), 0777); err != nil { + // Create foo/ + fooDir := filepath.Join(dir, "foo") + if err := os.Mkdir(fooDir, 0777); err != nil { t.Fatalf("err: %v", err) } - dirInfo, err := os.Stat(filepath.Join(dir, "foo")) + + // Change ownership of foo/ to test #3702 (any non-root user is fine) + const uid, gid = 1, 1 + if err := os.Chown(fooDir, uid, gid); err != nil { + t.Fatalf("err : %v", err) + } + + dirInfo, err := os.Stat(fooDir) if err != nil { t.Fatalf("err: %v", err) } - f, err := os.Create(filepath.Join(dir, "foo", "bar")) + + // Create foo/bar + f, err := os.Create(filepath.Join(fooDir, "bar")) if err != nil { t.Fatalf("err: %v", err) } - if _, err := f.WriteString("foo"); err != nil { + if _, err := f.WriteString("123"); err != nil { t.Fatalf("err: %v", err) } if err := f.Chmod(0644); err != nil { @@ -102,6 +116,8 @@ func TestPrevAlloc_StreamAllocDir_Ok(t *testing.T) { t.Fatalf("err: %v", err) } f.Close() + + // Create foo/baz -> bar symlink if err := os.Symlink("bar", filepath.Join(dir, "foo", "baz")); err != nil { t.Fatalf("err: %v", err) } @@ -181,6 +197,11 @@ func TestPrevAlloc_StreamAllocDir_Ok(t *testing.T) { if fi.Mode() != dirInfo.Mode() { t.Fatalf("mode: %v", fi.Mode()) } + stat := fi.Sys().(*syscall.Stat_t) + if stat.Uid != uid || stat.Gid != gid { + t.Fatalf("foo/ has incorrect ownership: expected %d:%d found %d:%d", + uid, gid, stat.Uid, stat.Gid) + } fi1, err := os.Stat(filepath.Join(dir1, "bar")) if err != nil { From 117d3b5239866abc65b0c6e5f1215d27e2165ede Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Mon, 8 Jan 2018 17:27:15 -0800 Subject: [PATCH 059/136] Add demo TLS certificates and configs As well as a brief readme and makefile for generating the certificates. --- demo/tls/GNUmakefile | 56 ++++++++++++++++++++++++++++++++++++++ demo/tls/README.md | 57 +++++++++++++++++++++++++++++++++++++++ demo/tls/ca-csr.json | 19 +++++++++++++ demo/tls/ca-key.pem | 5 ++++ demo/tls/ca.csr | 9 +++++++ demo/tls/ca.pem | 13 +++++++++ demo/tls/cfssl-user.json | 12 +++++++++ demo/tls/cfssl.json | 13 +++++++++ demo/tls/client-key.pem | 5 ++++ demo/tls/client.csr | 9 +++++++ demo/tls/client.pem | 15 +++++++++++ demo/tls/csr.json | 10 +++++++ demo/tls/dev-key.pem | 5 ++++ demo/tls/dev.csr | 10 +++++++ demo/tls/dev.pem | 16 +++++++++++ demo/tls/server-key.pem | 5 ++++ demo/tls/server.csr | 9 +++++++ demo/tls/server.pem | 15 +++++++++++ demo/tls/tls-client.hcl | 11 ++++++++ demo/tls/tls-dev.hcl | 11 ++++++++ demo/tls/tls-server.hcl | 11 ++++++++ demo/tls/user-key.pem | 5 ++++ demo/tls/user.csr | 8 ++++++ demo/tls/user.pem | 14 ++++++++++ demo/tls/user.pfx | Bin 0 -> 1062 bytes 25 files changed, 343 insertions(+) create mode 100644 demo/tls/GNUmakefile create mode 100644 demo/tls/README.md create mode 100644 demo/tls/ca-csr.json create mode 100644 demo/tls/ca-key.pem create mode 100644 demo/tls/ca.csr create mode 100644 demo/tls/ca.pem create mode 100644 demo/tls/cfssl-user.json create mode 100644 demo/tls/cfssl.json create mode 100644 demo/tls/client-key.pem create mode 100644 demo/tls/client.csr create mode 100644 demo/tls/client.pem create mode 100644 demo/tls/csr.json create mode 100644 demo/tls/dev-key.pem create mode 100644 demo/tls/dev.csr create mode 100644 demo/tls/dev.pem create mode 100644 demo/tls/server-key.pem create mode 100644 demo/tls/server.csr create mode 100644 demo/tls/server.pem create mode 100644 demo/tls/tls-client.hcl create mode 100644 demo/tls/tls-dev.hcl create mode 100644 demo/tls/tls-server.hcl create mode 100644 demo/tls/user-key.pem create mode 100644 demo/tls/user.csr create mode 100644 demo/tls/user.pem create mode 100644 demo/tls/user.pfx diff --git a/demo/tls/GNUmakefile b/demo/tls/GNUmakefile new file mode 100644 index 000000000..a33ae4a6e --- /dev/null +++ b/demo/tls/GNUmakefile @@ -0,0 +1,56 @@ +SHELL = bash + +.PHONY: all +all: \ + ca.pem ca-key.pem ca.csr \ + client.pem client-key.pem client.csr \ + dev.pem dev-key.pem dev.csr \ + server.pem server-key.pem server.csr \ + user.pem user-key.pem user.csr user.pfx + +.PHONY: bootstrap +bootstrap: ## Install dependencies + @echo "==> Updating cfssl..." + go get -u github.com/cloudflare/cfssl/cmd/... + +clean: ## Remove generated files + @echo "==> Removing generated files..." + rm -f \ + ca.pem ca-key.pem ca.csr \ + client.pem client-key.pem client.csr \ + dev.pem dev-key.pem dev.csr \ + server.pem server-key.pem server.csr \ + user.pem user-key.pem user.csr user.pfx + +# Generate Nomad certificate authority +ca.pem ca-key.pem ca.csr: + @echo "==> Removing generated files..." + cfssl gencert -initca ca-csr.json | cfssljson -bare ca + +# Generate Nomad server certificate +server.pem server-key.pem server.csr: + @echo "==> Generating Nomad server certificate..." + cfssl gencert -ca=ca.pem -ca-key=ca-key.pem -config=cfssl.json \ + -hostname="server.global.nomad,localhost,127.0.0.1" csr.json \ + | cfssljson -bare server + +# Generate Nomad client node certificate +client.pem client-key.pem client.csr: + @echo "==> Generating Nomad client node certificate..." + cfssl gencert -ca=ca.pem -ca-key=ca-key.pem -config=cfssl.json \ + -hostname="client.global.nomad,localhost,127.0.0.1" csr.json \ + | cfssljson -bare client + +# Generate Nomad combined server and client node certificate +dev.pem dev-key.pem dev.csr: + @echo "==> Generating Nomad server and client node certificate..." + cfssl gencert -ca=ca.pem -ca-key=ca-key.pem -config=cfssl.json \ + -hostname="server.global.nomad,client.global.nomad,localhost,127.0.0.1" csr.json \ + | cfssljson -bare dev + +# Generate certificates for users (CLI and browsers) +user.pem user-key.pem user.csr user.pfx: + @echo "==> Generating Nomad user certificates..." + cfssl gencert -ca=ca.pem -ca-key=ca-key.pem -config=cfssl-user.json \ + csr.json | cfssljson -bare user + openssl pkcs12 -export -inkey user-key.pem -in user.pem -out user.pfx -password pass: diff --git a/demo/tls/README.md b/demo/tls/README.md new file mode 100644 index 000000000..8219fed47 --- /dev/null +++ b/demo/tls/README.md @@ -0,0 +1,57 @@ +Demo TLS Configuration +====================== + +**Do _NOT_ use in production. For testing purposes only.** + +See [Securing Nomad](https://www.nomadproject.io/guides/securing-nomad.html) +for a full guide. + +This directory contains sample TLS certificates and configuration to ease +testing of TLS related features. There is a makefile to generate certificates, +and pre-generated are available for use. + +## Files + +| Generated? | File | Description | +| - | ------------- | ---| +| ◻️ | `GNUmakefile` | Makefile to generate certificates | +| ◻️ | `tls-*.hcl` | Nomad TLS configurations | +| ◻️ | `cfssl*.json` | cfssl configuration files | +| ◻️ | `csr*.json` | cfssl certificate generation configurations | +| ☑️ | `ca*.pem` | Certificate Authority certificate and key | +| ☑️ | `client*.pem` | Nomad client node certificate and key | +| ☑️ | `dev*.pem` | Nomad certificate and key for dev agents | +| ☑️ | `server*.pem` | Nomad server certificate and key | +| ☑️ | `user*.pem` | Nomad user (CLI) certificate and key | +| ☑️ | `user.pfx` | Nomad browser PKCS #12 certificate and key *(blank password)* | + +## Usage + +### Agent + +To run a TLS-enabled Nomad agent include the `tls.hcl` configuration file with +either the `-dev` flag or your own configuration file. If you're not running +the `nomad agent` command from *this* directory you will have to edit the paths +in `tls.hcl`. + +```sh +# Run the dev agent with TLS enabled +nomad agent -dev -config=tls-dev.hcl + +# Run a *server* agent with your configuration and TLS enabled +nomad agent -config=path/to/custom.hcl -config=tls-server.hcl + +# Run a *client* agent with your configuration and TLS enabled +nomad agent -config=path/to/custom.hcl -config=tls-client.hcl +``` + +### Browser + +To access the Nomad Web UI when TLS is enabled you will need to import two +certificate files into your browser: + +- `ca.pem` must be imported as a Certificate Authority +- `user.pfx` must be imported as a Client certificate. The password is blank. + +When you access the UI via https://localhost:4646/ you will be prompted to +select the user certificate you imported. diff --git a/demo/tls/ca-csr.json b/demo/tls/ca-csr.json new file mode 100644 index 000000000..ded502e0a --- /dev/null +++ b/demo/tls/ca-csr.json @@ -0,0 +1,19 @@ +{ + "CN": "example.nomad", + "hosts": [ + "example.nomad" + ], + "key": { + "algo": "ecdsa", + "size": 256 + }, + "names": [ + { + "C": "US", + "ST": "CA", + "L": "San Francisco", + "OU": "Nomad Demo" + } + ] +} + diff --git a/demo/tls/ca-key.pem b/demo/tls/ca-key.pem new file mode 100644 index 000000000..cc95d7c21 --- /dev/null +++ b/demo/tls/ca-key.pem @@ -0,0 +1,5 @@ +-----BEGIN EC PRIVATE KEY----- +MHcCAQEEIKsrq20VeBrZ0VOqMJSvvU6E+w7RAbUR7D5RkZSgNKJQoAoGCCqGSM49 +AwEHoUQDQgAEn/hg7ktoFRazpDTMTkN1mEJoCo/wJOlI7XD98WE1wr6U/4q0Wh9F +YuNyfCb2rK2nSrLKra/1R+z3Q+trXJt2cQ== +-----END EC PRIVATE KEY----- diff --git a/demo/tls/ca.csr b/demo/tls/ca.csr new file mode 100644 index 000000000..01f02b2d8 --- /dev/null +++ b/demo/tls/ca.csr @@ -0,0 +1,9 @@ +-----BEGIN CERTIFICATE REQUEST----- +MIIBRjCB7AIBADBfMQswCQYDVQQGEwJVUzELMAkGA1UECBMCQ0ExFjAUBgNVBAcT +DVNhbiBGcmFuY2lzY28xEzARBgNVBAsTCk5vbWFkIERlbW8xFjAUBgNVBAMTDWV4 +YW1wbGUubm9tYWQwWTATBgcqhkjOPQIBBggqhkjOPQMBBwNCAASf+GDuS2gVFrOk +NMxOQ3WYQmgKj/Ak6UjtcP3xYTXCvpT/irRaH0Vi43J8JvasradKssqtr/VH7PdD +62tcm3ZxoCswKQYJKoZIhvcNAQkOMRwwGjAYBgNVHREEETAPgg1leGFtcGxlLm5v +bWFkMAoGCCqGSM49BAMCA0kAMEYCIQDP+rv/peK1JGFzXOzdLmfjjEg2vOFWGccz +iAy63lDurgIhAIF//KajKrghaC1JXmsrqnVHuP40KZLOcAv54Q4PgH1h +-----END CERTIFICATE REQUEST----- diff --git a/demo/tls/ca.pem b/demo/tls/ca.pem new file mode 100644 index 000000000..945638503 --- /dev/null +++ b/demo/tls/ca.pem @@ -0,0 +1,13 @@ +-----BEGIN CERTIFICATE----- +MIICAzCCAaigAwIBAgIUN0nEio761fu7oRc04wRmlxxY3gowCgYIKoZIzj0EAwIw +XzELMAkGA1UEBhMCVVMxCzAJBgNVBAgTAkNBMRYwFAYDVQQHEw1TYW4gRnJhbmNp +c2NvMRMwEQYDVQQLEwpOb21hZCBEZW1vMRYwFAYDVQQDEw1leGFtcGxlLm5vbWFk +MB4XDTE4MDEwOTE4MDgwMFoXDTIzMDEwODE4MDgwMFowXzELMAkGA1UEBhMCVVMx +CzAJBgNVBAgTAkNBMRYwFAYDVQQHEw1TYW4gRnJhbmNpc2NvMRMwEQYDVQQLEwpO +b21hZCBEZW1vMRYwFAYDVQQDEw1leGFtcGxlLm5vbWFkMFkwEwYHKoZIzj0CAQYI +KoZIzj0DAQcDQgAEn/hg7ktoFRazpDTMTkN1mEJoCo/wJOlI7XD98WE1wr6U/4q0 +Wh9FYuNyfCb2rK2nSrLKra/1R+z3Q+trXJt2caNCMEAwDgYDVR0PAQH/BAQDAgEG +MA8GA1UdEwEB/wQFMAMBAf8wHQYDVR0OBBYEFKaOK4q82ysmZ7dYMhjbZyphHxx3 +MAoGCCqGSM49BAMCA0kAMEYCIQCLoeQKyg1PsyMzETrw3pBA3H3wXU81peHT1t74 +R63a2gIhALIeUT188aOaLtUMgPaWd7wE14BDhSpLp602jVGCNFkH +-----END CERTIFICATE----- diff --git a/demo/tls/cfssl-user.json b/demo/tls/cfssl-user.json new file mode 100644 index 000000000..0fa751cee --- /dev/null +++ b/demo/tls/cfssl-user.json @@ -0,0 +1,12 @@ +{ + "signing": { + "default": { + "expiry": "87600h", + "usages": [ + "signing", + "key encipherment", + "client auth" + ] + } + } +} diff --git a/demo/tls/cfssl.json b/demo/tls/cfssl.json new file mode 100644 index 000000000..6e438c9b9 --- /dev/null +++ b/demo/tls/cfssl.json @@ -0,0 +1,13 @@ +{ + "signing": { + "default": { + "expiry": "87600h", + "usages": [ + "signing", + "key encipherment", + "server auth", + "client auth" + ] + } + } +} diff --git a/demo/tls/client-key.pem b/demo/tls/client-key.pem new file mode 100644 index 000000000..75a665adc --- /dev/null +++ b/demo/tls/client-key.pem @@ -0,0 +1,5 @@ +-----BEGIN EC PRIVATE KEY----- +MHcCAQEEIGCce4MNcD+MHx1hQWOARCLQWCPJVhWzrAiI1QV7ftYKoAoGCCqGSM49 +AwEHoUQDQgAEDotF3nv9Stt9Zp5sBv3BNk4936BFBH6eyGAIULRlqSJQUrbc97cf +hcdwrVU0hDJcM98Bpd0R3OhqU7j86rc0FQ== +-----END EC PRIVATE KEY----- diff --git a/demo/tls/client.csr b/demo/tls/client.csr new file mode 100644 index 000000000..eb2821868 --- /dev/null +++ b/demo/tls/client.csr @@ -0,0 +1,9 @@ +-----BEGIN CERTIFICATE REQUEST----- +MIIBRDCB6wIBADBHMQswCQYDVQQGEwJVUzELMAkGA1UECBMCQ0ExFjAUBgNVBAcT +DVNhbiBGcmFuY2lzY28xEzARBgNVBAsTCk5vbWFkIERlbW8wWTATBgcqhkjOPQIB +BggqhkjOPQMBBwNCAAQOi0Xee/1K231mnmwG/cE2Tj3foEUEfp7IYAhQtGWpIlBS +ttz3tx+Fx3CtVTSEMlwz3wGl3RHc6GpTuPzqtzQVoEIwQAYJKoZIhvcNAQkOMTMw +MTAvBgNVHREEKDAmghNjbGllbnQuZ2xvYmFsLm5vbWFkgglsb2NhbGhvc3SHBH8A +AAEwCgYIKoZIzj0EAwIDSAAwRQIgRr+uu2A1NPkhso3QFWuq9IFf8eCkU6yzkmJI +9R7JZRQCIQDTj2mN3OqJAl1LsMRc2rmD1J7Fp+GvnGmSDT4fcdQ9zA== +-----END CERTIFICATE REQUEST----- diff --git a/demo/tls/client.pem b/demo/tls/client.pem new file mode 100644 index 000000000..67fb7ed54 --- /dev/null +++ b/demo/tls/client.pem @@ -0,0 +1,15 @@ +-----BEGIN CERTIFICATE----- +MIICWjCCAgCgAwIBAgIUDYX/mI1EZQPtc/6kc7Kv2epWDwQwCgYIKoZIzj0EAwIw +XzELMAkGA1UEBhMCVVMxCzAJBgNVBAgTAkNBMRYwFAYDVQQHEw1TYW4gRnJhbmNp +c2NvMRMwEQYDVQQLEwpOb21hZCBEZW1vMRYwFAYDVQQDEw1leGFtcGxlLm5vbWFk +MB4XDTE4MDEwOTE4MDgwMFoXDTI4MDEwNzE4MDgwMFowRzELMAkGA1UEBhMCVVMx +CzAJBgNVBAgTAkNBMRYwFAYDVQQHEw1TYW4gRnJhbmNpc2NvMRMwEQYDVQQLEwpO +b21hZCBEZW1vMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEDotF3nv9Stt9Zp5s +Bv3BNk4936BFBH6eyGAIULRlqSJQUrbc97cfhcdwrVU0hDJcM98Bpd0R3OhqU7j8 +6rc0FaOBsTCBrjAOBgNVHQ8BAf8EBAMCBaAwHQYDVR0lBBYwFAYIKwYBBQUHAwEG +CCsGAQUFBwMCMAwGA1UdEwEB/wQCMAAwHQYDVR0OBBYEFO2ys/83g7JgjwZf5KY4 +nOQojbV1MB8GA1UdIwQYMBaAFKaOK4q82ysmZ7dYMhjbZyphHxx3MC8GA1UdEQQo +MCaCE2NsaWVudC5nbG9iYWwubm9tYWSCCWxvY2FsaG9zdIcEfwAAATAKBggqhkjO +PQQDAgNIADBFAiEAu+R+nZv0QXbo5c+vEA+b8wryMWqK9TSkMZmh/BwMriwCIHIJ +o/vUarVvgFLy+9ZITDYgtQxMWGLjm8brPyDiXNEA +-----END CERTIFICATE----- diff --git a/demo/tls/csr.json b/demo/tls/csr.json new file mode 100644 index 000000000..4f8ae5938 --- /dev/null +++ b/demo/tls/csr.json @@ -0,0 +1,10 @@ +{ + "names": [ + { + "C": "US", + "ST": "CA", + "L": "San Francisco", + "OU": "Nomad Demo" + } + ] +} diff --git a/demo/tls/dev-key.pem b/demo/tls/dev-key.pem new file mode 100644 index 000000000..381f686fd --- /dev/null +++ b/demo/tls/dev-key.pem @@ -0,0 +1,5 @@ +-----BEGIN EC PRIVATE KEY----- +MHcCAQEEIJ/MkDicoe6ohduiDoGOwqGXlk2V13fZBwKRB8Ns+2hkoAoGCCqGSM49 +AwEHoUQDQgAEmjMddkSmrwZ5qamlGgn0NpbV09qvhAFmaBtawpGXa3LlPzvauHfm +lRcSEzHzkS1M6NT5eAKjJG8yojGHR78cXQ== +-----END EC PRIVATE KEY----- diff --git a/demo/tls/dev.csr b/demo/tls/dev.csr new file mode 100644 index 000000000..960bde4b4 --- /dev/null +++ b/demo/tls/dev.csr @@ -0,0 +1,10 @@ +-----BEGIN CERTIFICATE REQUEST----- +MIIBWTCCAQACAQAwRzELMAkGA1UEBhMCVVMxCzAJBgNVBAgTAkNBMRYwFAYDVQQH +Ew1TYW4gRnJhbmNpc2NvMRMwEQYDVQQLEwpOb21hZCBEZW1vMFkwEwYHKoZIzj0C +AQYIKoZIzj0DAQcDQgAEmjMddkSmrwZ5qamlGgn0NpbV09qvhAFmaBtawpGXa3Ll +PzvauHfmlRcSEzHzkS1M6NT5eAKjJG8yojGHR78cXaBXMFUGCSqGSIb3DQEJDjFI +MEYwRAYDVR0RBD0wO4ITc2VydmVyLmdsb2JhbC5ub21hZIITY2xpZW50Lmdsb2Jh +bC5ub21hZIIJbG9jYWxob3N0hwR/AAABMAoGCCqGSM49BAMCA0cAMEQCIEPHMv5p +xoNybtEQVprQrq5ymLX3rm1ZMkjH0EiJjk/AAiAsM2DTQtK8LnL0YKVbbmBNBX5g +1JQeTRt/kW7yKq0OeA== +-----END CERTIFICATE REQUEST----- diff --git a/demo/tls/dev.pem b/demo/tls/dev.pem new file mode 100644 index 000000000..ed6e67266 --- /dev/null +++ b/demo/tls/dev.pem @@ -0,0 +1,16 @@ +-----BEGIN CERTIFICATE----- +MIICbjCCAhWgAwIBAgIUc5S8QB/Kai23mJkU23YD4hoO7zkwCgYIKoZIzj0EAwIw +XzELMAkGA1UEBhMCVVMxCzAJBgNVBAgTAkNBMRYwFAYDVQQHEw1TYW4gRnJhbmNp +c2NvMRMwEQYDVQQLEwpOb21hZCBEZW1vMRYwFAYDVQQDEw1leGFtcGxlLm5vbWFk +MB4XDTE4MDEwOTE4MDgwMFoXDTI4MDEwNzE4MDgwMFowRzELMAkGA1UEBhMCVVMx +CzAJBgNVBAgTAkNBMRYwFAYDVQQHEw1TYW4gRnJhbmNpc2NvMRMwEQYDVQQLEwpO +b21hZCBEZW1vMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEmjMddkSmrwZ5qaml +Ggn0NpbV09qvhAFmaBtawpGXa3LlPzvauHfmlRcSEzHzkS1M6NT5eAKjJG8yojGH +R78cXaOBxjCBwzAOBgNVHQ8BAf8EBAMCBaAwHQYDVR0lBBYwFAYIKwYBBQUHAwEG +CCsGAQUFBwMCMAwGA1UdEwEB/wQCMAAwHQYDVR0OBBYEFBng/OMDB+a/pXc07ZYb +I6OODU5ZMB8GA1UdIwQYMBaAFKaOK4q82ysmZ7dYMhjbZyphHxx3MEQGA1UdEQQ9 +MDuCE3NlcnZlci5nbG9iYWwubm9tYWSCE2NsaWVudC5nbG9iYWwubm9tYWSCCWxv +Y2FsaG9zdIcEfwAAATAKBggqhkjOPQQDAgNHADBEAiAKiyqdAvtQewpuEXLU2VuP +Ifdn+7XK82AoTjOW/BbB0gIgNLusqAft2j7mqDT/LNpUTsl6E7O068METh4I9JlT +nEQ= +-----END CERTIFICATE----- diff --git a/demo/tls/server-key.pem b/demo/tls/server-key.pem new file mode 100644 index 000000000..9ab93fa5a --- /dev/null +++ b/demo/tls/server-key.pem @@ -0,0 +1,5 @@ +-----BEGIN EC PRIVATE KEY----- +MHcCAQEEIP5t9f7rjG4tWmGaDkfIul+OiMEcCOp4aK9oOGQPFcv3oAoGCCqGSM49 +AwEHoUQDQgAErP0oL1Eo7dnxsUbaM0O1zTa2XLQTQrt8sfYQKuSxq5f1w3GxgUYJ +wHEpQRK34cNfvZZ1piAde/wBK8rAKCzhoQ== +-----END EC PRIVATE KEY----- diff --git a/demo/tls/server.csr b/demo/tls/server.csr new file mode 100644 index 000000000..647048909 --- /dev/null +++ b/demo/tls/server.csr @@ -0,0 +1,9 @@ +-----BEGIN CERTIFICATE REQUEST----- +MIIBRTCB6wIBADBHMQswCQYDVQQGEwJVUzELMAkGA1UECBMCQ0ExFjAUBgNVBAcT +DVNhbiBGcmFuY2lzY28xEzARBgNVBAsTCk5vbWFkIERlbW8wWTATBgcqhkjOPQIB +BggqhkjOPQMBBwNCAASs/SgvUSjt2fGxRtozQ7XNNrZctBNCu3yx9hAq5LGrl/XD +cbGBRgnAcSlBErfhw1+9lnWmIB17/AErysAoLOGhoEIwQAYJKoZIhvcNAQkOMTMw +MTAvBgNVHREEKDAmghNzZXJ2ZXIuZ2xvYmFsLm5vbWFkgglsb2NhbGhvc3SHBH8A +AAEwCgYIKoZIzj0EAwIDSQAwRgIhAMpGeIRtFaCxn2Yp8EqRgRT3OnECUv6Mi4+d +Hwn42L2UAiEAzISsF4+Dkemn6KRrOXTv7Anam8fTeoAdqokWV3j4ELQ= +-----END CERTIFICATE REQUEST----- diff --git a/demo/tls/server.pem b/demo/tls/server.pem new file mode 100644 index 000000000..50f6a7706 --- /dev/null +++ b/demo/tls/server.pem @@ -0,0 +1,15 @@ +-----BEGIN CERTIFICATE----- +MIICWjCCAgCgAwIBAgIUJSWExbHzjFPPc/1Eiod55vk+11IwCgYIKoZIzj0EAwIw +XzELMAkGA1UEBhMCVVMxCzAJBgNVBAgTAkNBMRYwFAYDVQQHEw1TYW4gRnJhbmNp +c2NvMRMwEQYDVQQLEwpOb21hZCBEZW1vMRYwFAYDVQQDEw1leGFtcGxlLm5vbWFk +MB4XDTE4MDEwOTE4MDgwMFoXDTI4MDEwNzE4MDgwMFowRzELMAkGA1UEBhMCVVMx +CzAJBgNVBAgTAkNBMRYwFAYDVQQHEw1TYW4gRnJhbmNpc2NvMRMwEQYDVQQLEwpO +b21hZCBEZW1vMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAErP0oL1Eo7dnxsUba +M0O1zTa2XLQTQrt8sfYQKuSxq5f1w3GxgUYJwHEpQRK34cNfvZZ1piAde/wBK8rA +KCzhoaOBsTCBrjAOBgNVHQ8BAf8EBAMCBaAwHQYDVR0lBBYwFAYIKwYBBQUHAwEG +CCsGAQUFBwMCMAwGA1UdEwEB/wQCMAAwHQYDVR0OBBYEFLK3byFY7RGvoyYtJ9sM +DUKbriNRMB8GA1UdIwQYMBaAFKaOK4q82ysmZ7dYMhjbZyphHxx3MC8GA1UdEQQo +MCaCE3NlcnZlci5nbG9iYWwubm9tYWSCCWxvY2FsaG9zdIcEfwAAATAKBggqhkjO +PQQDAgNIADBFAiB7aohsv0AOs7dnL9zrUNoeU6/B90+BntrRtk8+NHTpnQIhAL7W +EpQ9vbAxQ/FouOPC5lLd94yYkMbbUmoke3H2vKkd +-----END CERTIFICATE----- diff --git a/demo/tls/tls-client.hcl b/demo/tls/tls-client.hcl new file mode 100644 index 000000000..ee129e1b1 --- /dev/null +++ b/demo/tls/tls-client.hcl @@ -0,0 +1,11 @@ +tls { + http = true + rpc = true + + ca_file = "ca.pem" + cert_file = "client.pem" + key_file = "client-key.pem" + + verify_server_hostname = true + verify_https_client = true +} diff --git a/demo/tls/tls-dev.hcl b/demo/tls/tls-dev.hcl new file mode 100644 index 000000000..e41ba8f32 --- /dev/null +++ b/demo/tls/tls-dev.hcl @@ -0,0 +1,11 @@ +tls { + http = true + rpc = true + + ca_file = "ca.pem" + cert_file = "dev.pem" + key_file = "dev-key.pem" + + verify_server_hostname = true + verify_https_client = true +} diff --git a/demo/tls/tls-server.hcl b/demo/tls/tls-server.hcl new file mode 100644 index 000000000..9e1a80269 --- /dev/null +++ b/demo/tls/tls-server.hcl @@ -0,0 +1,11 @@ +tls { + http = true + rpc = true + + ca_file = "ca.pem" + cert_file = "server.pem" + key_file = "server-key.pem" + + verify_server_hostname = true + verify_https_client = true +} diff --git a/demo/tls/user-key.pem b/demo/tls/user-key.pem new file mode 100644 index 000000000..6e7fa6b42 --- /dev/null +++ b/demo/tls/user-key.pem @@ -0,0 +1,5 @@ +-----BEGIN EC PRIVATE KEY----- +MHcCAQEEILshv6hNINiqJk7iPOBr1rL519YdPah78vK/uTrJm+eYoAoGCCqGSM49 +AwEHoUQDQgAES0uuEUedpQxKop5YTUgtywlx7vWJ5dN5PTa2MRoccEhKTVTg1IxW +S8OJxffyTIYXxAtTiDA4JVStchBf1rl2LQ== +-----END EC PRIVATE KEY----- diff --git a/demo/tls/user.csr b/demo/tls/user.csr new file mode 100644 index 000000000..d83211583 --- /dev/null +++ b/demo/tls/user.csr @@ -0,0 +1,8 @@ +-----BEGIN CERTIFICATE REQUEST----- +MIIBATCBqQIBADBHMQswCQYDVQQGEwJVUzELMAkGA1UECBMCQ0ExFjAUBgNVBAcT +DVNhbiBGcmFuY2lzY28xEzARBgNVBAsTCk5vbWFkIERlbW8wWTATBgcqhkjOPQIB +BggqhkjOPQMBBwNCAARLS64RR52lDEqinlhNSC3LCXHu9Ynl03k9NrYxGhxwSEpN +VODUjFZLw4nF9/JMhhfEC1OIMDglVK1yEF/WuXYtoAAwCgYIKoZIzj0EAwIDRwAw +RAIgL01k8EVmO9UBLTa5VDTzPmmOBJuB2GAL7KIUc20BVnQCIFNUx7+KblsI6E5Q +qOIZN1QUMPCGedKufHQvZJ9iX5S3 +-----END CERTIFICATE REQUEST----- diff --git a/demo/tls/user.pem b/demo/tls/user.pem new file mode 100644 index 000000000..d92772350 --- /dev/null +++ b/demo/tls/user.pem @@ -0,0 +1,14 @@ +-----BEGIN CERTIFICATE----- +MIICHjCCAcOgAwIBAgIUeB9kcy9/5oLhHCm0PmBiBe6pybwwCgYIKoZIzj0EAwIw +XzELMAkGA1UEBhMCVVMxCzAJBgNVBAgTAkNBMRYwFAYDVQQHEw1TYW4gRnJhbmNp +c2NvMRMwEQYDVQQLEwpOb21hZCBEZW1vMRYwFAYDVQQDEw1leGFtcGxlLm5vbWFk +MB4XDTE4MDEwOTE4MDgwMFoXDTI4MDEwNzE4MDgwMFowRzELMAkGA1UEBhMCVVMx +CzAJBgNVBAgTAkNBMRYwFAYDVQQHEw1TYW4gRnJhbmNpc2NvMRMwEQYDVQQLEwpO +b21hZCBEZW1vMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAES0uuEUedpQxKop5Y +TUgtywlx7vWJ5dN5PTa2MRoccEhKTVTg1IxWS8OJxffyTIYXxAtTiDA4JVStchBf +1rl2LaN1MHMwDgYDVR0PAQH/BAQDAgWgMBMGA1UdJQQMMAoGCCsGAQUFBwMCMAwG +A1UdEwEB/wQCMAAwHQYDVR0OBBYEFIjrKUYag+vlAh5h1eJwhsdekvgGMB8GA1Ud +IwQYMBaAFKaOK4q82ysmZ7dYMhjbZyphHxx3MAoGCCqGSM49BAMCA0kAMEYCIQC6 +AZ/eZTHXKOU1sxLTRsK3FHn88DKBqXhHJG/2rbMWEwIhALCC5fi/lTP1lB/EDm1E +j4gRnSu3V03XWZhK6QcdQhr1 +-----END CERTIFICATE----- diff --git a/demo/tls/user.pfx b/demo/tls/user.pfx new file mode 100644 index 0000000000000000000000000000000000000000..35de38c9d3cfa73585d03c748d84b84347c8ba32 GIT binary patch literal 1062 zcmXqLVo_pZWHxAGe!<46)#lOmotKfFaX}OFO_nC+t3ct422D)I5mIamnwWL~g|;v; zG61Qy2pL8L88$Ac2|SE!27D|W4Y$J|Cm!Et&cwvQ(9p!x@X;!`mS@uukN3xfbg%Pq zFkWQbwEvxU*t0dSK7P?Z(7Mh-)X~gn<+_zK&sDN)xg2$+a>jQLlerO>*PgT3w#E31 z;Ip%qanl7XugTdvf0=VD+Ixd>;koNifAIL7ZB$vHX&*58;3WP9A$@;01#=3;S**~x zs@bsDl*{pVXQ=tv<+{7qC)jmNE;xH^LQB1w9BXnpJG)rIDY1!maa{`yJla?@wis7w z?p%<%Rx;tVTMcK`>y?XS*C<6Xe*D(Le0A3Dm1|#r=v^gjX`VXgRBQVdkFOhJ-6lBw zc_PMHdZ;(4k)P$-U+WD!7qC7xYfLFH>y|Q(`t$wK^QyEU`(H8d_e$njF&48NI~*vg zxbfQ2%!6Df9d6s$I8Xe_Wu9MgyLa7GMfR8pI~w+1niZS>g{!amg4yn0Im_4HYn!;= zf7-0$N@ARHX%FWg|K9!X<(-`qS@MtU^Kf(UP(1o))10pbGK)=DT+Z9Pc%t^*PrE|S zGOc3Vw)SmiLuBf_=*wHR9!x(bpgMh?!)~LhS&tUamNKz>CTc4EH1@NMr{uHnPF=qj z7H=;8b!YT%biETDH1&mO;6A&#CQ;W{skP{4Tu|8GQqkRGw@K}F%Wb>04EKGEb9d#u zs!n_mvo88`qWtqpBQZ9OpukV{mzG{+(+h~+d-}PXy7}3Qha4uWm^;jQqjbHg(ap!o z_w(Tk!9h!uX7&Vqj&1t;kS|eReR4yM#I84YL%tLo+E<=0rJ8T@_sg8wU-R@_E7vXK zR5gEJeE!U}mXECW=PtEu+?xF;&f9m^vD%COF27l;^mN|YC7+X%(h@zCDo$KYiD#EQ zI$vdf-29)+3$%`1)|}z1?vOuS9#a&9wRZ(V&Tu2`RxYX#B#`_|c&8 zok8PkHf~tbaBq&qrC-5xt4d zw^*O4F?4UeRVkb^adr|%#R3;$`IBqy{`xmOe!;u4C63j^^7g{o9q9+1?wR|UZm#H5 zQrDB3vhuCUJV~8P(o^*~>YI-<##DE4F-%_`+I-dVgrTZ|GTeKdqK0BDA`4dkaFR4y zCsJ|Ysb1dB_ Date: Tue, 9 Jan 2018 22:35:58 +0000 Subject: [PATCH 060/136] Update AWS scripts and README to reflect latest, pre-built AMI --- terraform/aws/README.md | 2 +- terraform/aws/env/us-east/terraform.tfvars | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/terraform/aws/README.md b/terraform/aws/README.md index 3cd916c35..6f2f0ac33 100644 --- a/terraform/aws/README.md +++ b/terraform/aws/README.md @@ -43,7 +43,7 @@ a custom AMI: ```bash region = "us-east-1" -ami = "ami-6ce26316" +ami = "ami-d42d74ae" instance_type = "t2.medium" key_name = "KEY_NAME" server_count = "3" diff --git a/terraform/aws/env/us-east/terraform.tfvars b/terraform/aws/env/us-east/terraform.tfvars index 328a9f574..bf4b90236 100644 --- a/terraform/aws/env/us-east/terraform.tfvars +++ b/terraform/aws/env/us-east/terraform.tfvars @@ -1,5 +1,5 @@ region = "us-east-1" -ami = "ami-6ce26316" +ami = "ami-d42d74ae" instance_type = "t2.medium" key_name = "KEY_NAME" server_count = "3" From 304a037e39cb9d15bc6103671a3991d08e989afb Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Thu, 4 Jan 2018 15:04:45 -0800 Subject: [PATCH 061/136] Fix service.check_restart stanza propagation There was a bug in jobspec parsing, a bug in CheckRestart merging, and a bug in CheckRestart canonicalization. All are now tested. --- CHANGELOG.md | 3 +- api/tasks.go | 6 ++-- command/agent/job_endpoint_test.go | 26 ++++++++++++-- jobspec/parse.go | 1 + jobspec/parse_test.go | 36 +++++++++++++++++++ .../test-fixtures/service-check-restart.hcl | 21 +++++++++++ 6 files changed, 87 insertions(+), 6 deletions(-) create mode 100644 jobspec/test-fixtures/service-check-restart.hcl diff --git a/CHANGELOG.md b/CHANGELOG.md index 795157226..964ba1e4a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,7 @@ BUG FIXES: allocations could result in improper placement counts [[GH-3717](https://github.com/hashicorp/nomad/issues/3717)] * client: Migrated ephemeral_disk's maintain directory permissions [[GH-3723](https://github.com/hashicorp/nomad/issues/3723)] * config: Revert minimum CPU limit back to 20 from 100. + * discovery: Fix handling of `service.check_restart` [[GH-3718](https://github.com/hashicorp/nomad/issues/3718)] * ui: Fix requests using client-side certificates in Firefox. [[GH-3728](https://github.com/hashicorp/nomad/pull/3728)] ## 0.7.1 (December 19, 2017) @@ -663,7 +664,7 @@ BUG FIXES: * client: Killing an allocation doesn't cause allocation stats to block [[GH-1454](https://github.com/hashicorp/nomad/issues/1454)] * driver/docker: Disable swap on docker driver [[GH-1480](https://github.com/hashicorp/nomad/issues/1480)] - * driver/docker: Fix improper gating on privileged mode [[GH-1506](https://github.com/hashicorp/nomad/issues/1506)] + * driver/docker: Fix improper gating on priviledged mode [[GH-1506](https://github.com/hashicorp/nomad/issues/1506)] * driver/docker: Default network type is "nat" on Windows [[GH-1521](https://github.com/hashicorp/nomad/issues/1521)] * driver/docker: Cleanup created volume when destroying container [[GH-1519](https://github.com/hashicorp/nomad/issues/1519)] * driver/rkt: Set host environment variables [[GH-1581](https://github.com/hashicorp/nomad/issues/1581)] diff --git a/api/tasks.go b/api/tasks.go index 7dc2950b1..847bb869f 100644 --- a/api/tasks.go +++ b/api/tasks.go @@ -136,7 +136,7 @@ func (c *CheckRestart) Merge(o *CheckRestart) *CheckRestart { nc.Grace = o.Grace } - if nc.IgnoreWarnings { + if !nc.IgnoreWarnings { nc.IgnoreWarnings = o.IgnoreWarnings } @@ -189,9 +189,9 @@ func (s *Service) Canonicalize(t *Task, tg *TaskGroup, job *Job) { // Canonicallize CheckRestart on Checks and merge Service.CheckRestart // into each check. - for _, c := range s.Checks { + for i, c := range s.Checks { + s.Checks[i].CheckRestart = c.CheckRestart.Merge(s.CheckRestart) c.CheckRestart.Canonicalize() - c.CheckRestart = c.CheckRestart.Merge(s.CheckRestart) } } diff --git a/command/agent/job_endpoint_test.go b/command/agent/job_endpoint_test.go index 019a82ae0..b595e28ab 100644 --- a/command/agent/job_endpoint_test.go +++ b/command/agent/job_endpoint_test.go @@ -1212,6 +1212,10 @@ func TestJobs_ApiJobToStructsJob(t *testing.T) { Name: "serviceA", Tags: []string{"1", "2"}, PortLabel: "foo", + CheckRestart: &api.CheckRestart{ + Limit: 4, + Grace: helper.TimeToPtr(11 * time.Second), + }, Checks: []api.ServiceCheck{ { Id: "hello", @@ -1228,10 +1232,17 @@ func TestJobs_ApiJobToStructsJob(t *testing.T) { InitialStatus: "ok", CheckRestart: &api.CheckRestart{ Limit: 3, - Grace: helper.TimeToPtr(10 * time.Second), IgnoreWarnings: true, }, }, + { + Id: "check2id", + Name: "check2", + Type: "tcp", + PortLabel: "foo", + Interval: 4 * time.Second, + Timeout: 2 * time.Second, + }, }, }, }, @@ -1425,10 +1436,21 @@ func TestJobs_ApiJobToStructsJob(t *testing.T) { InitialStatus: "ok", CheckRestart: &structs.CheckRestart{ Limit: 3, - Grace: 10 * time.Second, + Grace: 11 * time.Second, IgnoreWarnings: true, }, }, + { + Name: "check2", + Type: "tcp", + PortLabel: "foo", + Interval: 4 * time.Second, + Timeout: 2 * time.Second, + CheckRestart: &structs.CheckRestart{ + Limit: 4, + Grace: 11 * time.Second, + }, + }, }, }, }, diff --git a/jobspec/parse.go b/jobspec/parse.go index d25f38bd0..babe41b17 100644 --- a/jobspec/parse.go +++ b/jobspec/parse.go @@ -912,6 +912,7 @@ func parseServices(jobName string, taskGroupName string, task *api.Task, service "port", "check", "address_mode", + "check_restart", } if err := helper.CheckHCLKeys(o.Val, valid); err != nil { return multierror.Prefix(err, fmt.Sprintf("service (%d) ->", idx)) diff --git a/jobspec/parse_test.go b/jobspec/parse_test.go index 2dfc890d4..4134e9ee4 100644 --- a/jobspec/parse_test.go +++ b/jobspec/parse_test.go @@ -631,6 +631,42 @@ func TestParse(t *testing.T) { }, false, }, + { + "service-check-restart.hcl", + &api.Job{ + ID: helper.StringToPtr("service_check_restart"), + Name: helper.StringToPtr("service_check_restart"), + Type: helper.StringToPtr("service"), + TaskGroups: []*api.TaskGroup{ + { + Name: helper.StringToPtr("group"), + Tasks: []*api.Task{ + { + Name: "task", + Services: []*api.Service{ + { + Name: "http-service", + CheckRestart: &api.CheckRestart{ + Limit: 3, + Grace: helper.TimeToPtr(10 * time.Second), + IgnoreWarnings: true, + }, + Checks: []api.ServiceCheck{ + { + Name: "random-check", + Type: "tcp", + PortLabel: "9001", + }, + }, + }, + }, + }, + }, + }, + }, + }, + false, + }, } for _, tc := range cases { diff --git a/jobspec/test-fixtures/service-check-restart.hcl b/jobspec/test-fixtures/service-check-restart.hcl new file mode 100644 index 000000000..d34f70003 --- /dev/null +++ b/jobspec/test-fixtures/service-check-restart.hcl @@ -0,0 +1,21 @@ +job "service_check_restart" { + type = "service" + group "group" { + task "task" { + service { + name = "http-service" + check_restart { + limit = 3 + grace = "10s" + ignore_warnings = true + } + check { + name = "random-check" + type = "tcp" + port = "9001" + } + } + } + } +} + From 566abcbe23643c3c823c4359b86cd766852d4567 Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Tue, 9 Jan 2018 14:15:31 -0800 Subject: [PATCH 062/136] Move changelog entry from bug fix to feature It was never really implemented to begin with --- CHANGELOG.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 964ba1e4a..ab026ddd4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,13 +5,16 @@ __BACKWARDS INCOMPATIBILITIES:__ that absolute URLs are not allowed, but it was not enforced. Absolute URLs in HTTP check paths will now fail to validate. [[GH-3685](https://github.com/hashicorp/nomad/issues/3685)] +IMPROVEMENTS: + * discovery: Allow `check_restart` to be specified in the `service` stanza. + [GH-3718] + BUG FIXES: * core: Fix search endpoint forwarding for multi-region clusters [[GH-3680](https://github.com/hashicorp/nomad/issues/3680)] * core: Fix an issue in which batch jobs with queued placements and lost allocations could result in improper placement counts [[GH-3717](https://github.com/hashicorp/nomad/issues/3717)] * client: Migrated ephemeral_disk's maintain directory permissions [[GH-3723](https://github.com/hashicorp/nomad/issues/3723)] * config: Revert minimum CPU limit back to 20 from 100. - * discovery: Fix handling of `service.check_restart` [[GH-3718](https://github.com/hashicorp/nomad/issues/3718)] * ui: Fix requests using client-side certificates in Firefox. [[GH-3728](https://github.com/hashicorp/nomad/pull/3728)] ## 0.7.1 (December 19, 2017) From 9b9a4af182d002e68e2a8db233153df9ae95de89 Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Tue, 9 Jan 2018 14:53:34 -0800 Subject: [PATCH 063/136] Invert and test CheckRestart merge logic --- api/tasks.go | 14 ++++++-------- api/tasks_test.go | 49 +++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 55 insertions(+), 8 deletions(-) diff --git a/api/tasks.go b/api/tasks.go index 847bb869f..a7e3de40a 100644 --- a/api/tasks.go +++ b/api/tasks.go @@ -128,15 +128,15 @@ func (c *CheckRestart) Merge(o *CheckRestart) *CheckRestart { return nc } - if nc.Limit == 0 { + if o.Limit > 0 { nc.Limit = o.Limit } - if nc.Grace == nil { + if o.Grace != nil { nc.Grace = o.Grace } - if !nc.IgnoreWarnings { + if o.IgnoreWarnings { nc.IgnoreWarnings = o.IgnoreWarnings } @@ -185,13 +185,11 @@ func (s *Service) Canonicalize(t *Task, tg *TaskGroup, job *Job) { s.AddressMode = "auto" } - s.CheckRestart.Canonicalize() - // Canonicallize CheckRestart on Checks and merge Service.CheckRestart // into each check. - for i, c := range s.Checks { - s.Checks[i].CheckRestart = c.CheckRestart.Merge(s.CheckRestart) - c.CheckRestart.Canonicalize() + for i, check := range s.Checks { + s.Checks[i].CheckRestart = s.CheckRestart.Merge(check.CheckRestart) + s.Checks[i].CheckRestart.Canonicalize() } } diff --git a/api/tasks_test.go b/api/tasks_test.go index d870eab27..7542c6094 100644 --- a/api/tasks_test.go +++ b/api/tasks_test.go @@ -3,6 +3,7 @@ package api import ( "reflect" "testing" + "time" "github.com/hashicorp/nomad/helper" "github.com/stretchr/testify/assert" @@ -266,3 +267,51 @@ func TestTaskGroup_Canonicalize_Update(t *testing.T) { tg.Canonicalize(job) assert.Nil(t, tg.Update) } + +// TestService_CheckRestart asserts Service.CheckRestart settings are properly +// inherited by Checks. +func TestService_CheckRestart(t *testing.T) { + job := &Job{Name: helper.StringToPtr("job")} + tg := &TaskGroup{Name: helper.StringToPtr("group")} + task := &Task{Name: "task"} + service := &Service{ + CheckRestart: &CheckRestart{ + Limit: 11, + Grace: helper.TimeToPtr(11 * time.Second), + IgnoreWarnings: true, + }, + Checks: []ServiceCheck{ + { + Name: "all-set", + CheckRestart: &CheckRestart{ + Limit: 22, + Grace: helper.TimeToPtr(22 * time.Second), + IgnoreWarnings: true, + }, + }, + { + Name: "some-set", + CheckRestart: &CheckRestart{ + Limit: 33, + Grace: helper.TimeToPtr(33 * time.Second), + }, + }, + { + Name: "unset", + }, + }, + } + + service.Canonicalize(task, tg, job) + assert.Equal(t, service.Checks[0].CheckRestart.Limit, 22) + assert.Equal(t, *service.Checks[0].CheckRestart.Grace, 22*time.Second) + assert.True(t, service.Checks[0].CheckRestart.IgnoreWarnings) + + assert.Equal(t, service.Checks[1].CheckRestart.Limit, 33) + assert.Equal(t, *service.Checks[1].CheckRestart.Grace, 33*time.Second) + assert.True(t, service.Checks[1].CheckRestart.IgnoreWarnings) + + assert.Equal(t, service.Checks[2].CheckRestart.Limit, 11) + assert.Equal(t, *service.Checks[2].CheckRestart.Grace, 11*time.Second) + assert.True(t, service.Checks[2].CheckRestart.IgnoreWarnings) +} From 756305f0299564f1ca46f6c2864c496d013fa8a0 Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Tue, 9 Jan 2018 15:18:22 -0800 Subject: [PATCH 064/136] Revert "Missed header mention of server.check_restart" This reverts commit 8295f81dddf8b53c0b78707be6fddc6e30f95640. --- website/source/docs/job-specification/check_restart.html.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/website/source/docs/job-specification/check_restart.html.md b/website/source/docs/job-specification/check_restart.html.md index f61648f0f..19b720276 100644 --- a/website/source/docs/job-specification/check_restart.html.md +++ b/website/source/docs/job-specification/check_restart.html.md @@ -10,6 +10,12 @@ description: |- # `check_restart` Stanza + + + + {{/t.head}} {{#t.body as |row|}} - - + - - + - - + {{/t.head}} {{#t.body as |row|}} - - - - + + + {{/t.head}} {{#t.body as |row|}} - - - - + + + {{/t.head}} {{#t.body as |row|}} - {{allocation-row allocation=row.model context="node" onClick=(action "gotoAllocation" row.model)}} + {{allocation-row + allocation=row.model + context="node" + onClick=(action "gotoAllocation" row.model) + data-test-allocation=row.model.id}} {{/t.body}} {{/list-table}}
          @@ -73,7 +79,10 @@ Attributes
          - {{attributes-table attributes=model.attributes.attributesStructured class="attributes-table"}} + {{attributes-table + data-test-attributes + attributes=model.attributes.attributesStructured + class="attributes-table"}}
          diff --git a/ui/app/templates/clients/index.hbs b/ui/app/templates/clients/index.hbs index 503341e44..1b43c78c3 100644 --- a/ui/app/templates/clients/index.hbs +++ b/ui/app/templates/clients/index.hbs @@ -32,11 +32,11 @@ {{/t.head}} {{#t.body as |row|}} - {{client-node-row node=row.model onClick=(action "gotoNode" row.model)}} + {{client-node-row data-test-client-node-row node=row.model onClick=(action "gotoNode" row.model)}} {{/t.body}} {{/list-table}}
          -
          {{else}} -
          +
          {{#if (eq nodes.length 0)}} -

          No Clients

          +

          No Clients

          The cluster currently has no client nodes.

          {{else if searchTerm}} -

          No Matches

          +

          No Matches

          No clients match the term {{searchTerm}}

          {{/if}}
          diff --git a/ui/app/templates/components/allocation-row.hbs b/ui/app/templates/components/allocation-row.hbs index 0820dfeb5..7656960e5 100644 --- a/ui/app/templates/components/allocation-row.hbs +++ b/ui/app/templates/components/allocation-row.hbs @@ -1,28 +1,28 @@ -
          - - - + + {{#if (eq context "job")}} - - + + {{else if (eq context "node")}} - + {{/if}} - - - - - - - - + + + + + + {{/t.head}} {{#t.body as |row|}} - {{allocation-row allocation=row.model context="job"}} + {{allocation-row data-test-deployment-allocation allocation=row.model context="job"}} {{/t.body}} {{/list-table}} diff --git a/ui/app/templates/components/job-deployment/deployment-metrics.hbs b/ui/app/templates/components/job-deployment/deployment-metrics.hbs index dae3390ab..a3c3ff585 100644 --- a/ui/app/templates/components/job-deployment/deployment-metrics.hbs +++ b/ui/app/templates/components/job-deployment/deployment-metrics.hbs @@ -3,37 +3,37 @@

          Canaries

          -

          {{deployment.placedCanaries}} / {{deployment.desiredCanaries}}

          +

          {{deployment.placedCanaries}} / {{deployment.desiredCanaries}}

          Placed

          -

          {{deployment.placedAllocs}}

          +

          {{deployment.placedAllocs}}

          Desired

          -

          {{deployment.desiredTotal}}

          +

          {{deployment.desiredTotal}}

          Healthy

          -

          {{deployment.healthyAllocs}}

          +

          {{deployment.healthyAllocs}}

          Unhealthy

          -

          {{deployment.unhealthyAllocs}}

          +

          {{deployment.unhealthyAllocs}}

          -
          +
          {{deployment.statusDescription}}
          diff --git a/ui/app/templates/components/job-deployment/task-groups.hbs b/ui/app/templates/components/job-deployment/task-groups.hbs index 1b0ebcc76..cee10994c 100644 --- a/ui/app/templates/components/job-deployment/task-groups.hbs +++ b/ui/app/templates/components/job-deployment/task-groups.hbs @@ -1,9 +1,10 @@ -
          +
          Task Groups
          {{#list-table + data-test-deployment-task-groups source=deployment.taskGroupSummaries class="task-groups" as |t|}} {{#t.head}} @@ -16,20 +17,20 @@
          {{/t.head}} {{#t.body as |row|}} - - - + + - - - - - + + + + + {{/t.body}} {{/list-table}} diff --git a/ui/app/templates/components/job-deployments-stream.hbs b/ui/app/templates/components/job-deployments-stream.hbs index b92050b13..cf89df615 100644 --- a/ui/app/templates/components/job-deployments-stream.hbs +++ b/ui/app/templates/components/job-deployments-stream.hbs @@ -1,6 +1,6 @@ {{#each annotatedDeployments as |record|}} {{#if record.meta.showDate}} -
        • +
        • {{#if record.deployment.version.submitTime}} {{moment-format record.deployment.version.submitTime "MMMM D, YYYY"}} {{else}} @@ -8,7 +8,7 @@ {{/if}}
        • {{/if}} -
        • +
        • {{job-deployment deployment=record.deployment}}
        • {{/each}} diff --git a/ui/app/templates/components/job-row.hbs b/ui/app/templates/components/job-row.hbs index f18fcd3be..54032c664 100644 --- a/ui/app/templates/components/job-row.hbs +++ b/ui/app/templates/components/job-row.hbs @@ -1,16 +1,16 @@ - - + - - - + + - diff --git a/ui/app/templates/components/job-version.hbs b/ui/app/templates/components/job-version.hbs index 6fc55a308..a60b40b70 100644 --- a/ui/app/templates/components/job-version.hbs +++ b/ui/app/templates/components/job-version.hbs @@ -1,12 +1,12 @@
          Version #{{version.number}} - + Stable - {{version.stable}} + {{version.stable}} - + Submitted - {{moment-format version.submitTime "MM/DD/YY HH:mm:ss"}} + {{moment-format version.submitTime "MM/DD/YY HH:mm:ss"}} {{#if version.diff}} diff --git a/ui/app/templates/components/job-versions-stream.hbs b/ui/app/templates/components/job-versions-stream.hbs index a9fc61720..30f3dabdc 100644 --- a/ui/app/templates/components/job-versions-stream.hbs +++ b/ui/app/templates/components/job-versions-stream.hbs @@ -1,10 +1,10 @@ {{#each annotatedVersions as |record|}} {{#if record.meta.showDate}} -
        • +
        • {{moment-format record.version.submitTime "MMMM D, YYYY"}}
        • {{/if}} -
        • +
        • {{job-version version=record.version verbose=verbose}}
        • {{/each}} diff --git a/ui/app/templates/components/server-agent-row.hbs b/ui/app/templates/components/server-agent-row.hbs index 6a5779b3d..e7e926dd6 100644 --- a/ui/app/templates/components/server-agent-row.hbs +++ b/ui/app/templates/components/server-agent-row.hbs @@ -1,6 +1,6 @@ -
          - - - - - + + + + + + diff --git a/ui/app/templates/components/task-group-row.hbs b/ui/app/templates/components/task-group-row.hbs index f37f720b2..4abd42d99 100644 --- a/ui/app/templates/components/task-group-row.hbs +++ b/ui/app/templates/components/task-group-row.hbs @@ -1,12 +1,12 @@ - - - + - - - + + + diff --git a/ui/app/templates/jobs/index.hbs b/ui/app/templates/jobs/index.hbs index 76d63662e..9c8c93888 100644 --- a/ui/app/templates/jobs/index.hbs +++ b/ui/app/templates/jobs/index.hbs @@ -10,7 +10,7 @@ {{else}} {{#if filteredJobs.length}}
          -
          {{search-box searchTerm=(mut searchTerm) placeholder="Search jobs..."}}
          +
          {{search-box data-test-jobs-search searchTerm=(mut searchTerm) placeholder="Search jobs..."}}
          {{/if}} {{#list-pagination @@ -31,7 +31,7 @@ {{/t.head}} {{#t.body key="model.id" as |row|}} - {{job-row job=row.model onClick=(action "gotoJob" row.model)}} + {{job-row data-test-job-row job=row.model onClick=(action "gotoJob" row.model)}} {{/t.body}} {{/list-table}}
          @@ -45,14 +45,14 @@
          {{else}} -
          +
          {{#if (eq filteredJobs.length 0)}} -

          No Jobs

          +

          No Jobs

          The cluster is currently empty.

          {{else if searchTerm}} -

          No Matches

          +

          No Matches

          No jobs match the term {{searchTerm}}

          {{/if}}
          diff --git a/ui/app/templates/jobs/job/definition.hbs b/ui/app/templates/jobs/job/definition.hbs index 51cf8345f..d2722fa6a 100644 --- a/ui/app/templates/jobs/job/definition.hbs +++ b/ui/app/templates/jobs/job/definition.hbs @@ -10,7 +10,7 @@
          - {{json-viewer json=model.definition}} + {{json-viewer data-test-definition-view json=model.definition}}
          diff --git a/ui/app/templates/jobs/job/index.hbs b/ui/app/templates/jobs/job/index.hbs index 3366d4ab8..8a0ac1c0d 100644 --- a/ui/app/templates/jobs/job/index.hbs +++ b/ui/app/templates/jobs/job/index.hbs @@ -1,7 +1,7 @@ {{#global-header class="page-header"}} {{#each breadcrumbs as |breadcrumb index|}} {{/each}} {{/global-header}} @@ -10,7 +10,7 @@

          {{model.name}} - {{model.status}} + {{model.status}} {{#if model.periodic}} periodic {{else if model.parameterized}} @@ -20,10 +20,10 @@
          - Type: {{model.type}} | - Priority: {{model.priority}} + Type: {{model.type}} | + Priority: {{model.priority}} {{#if (and model.namespace system.shouldShowNamespaces)}} - | Namespace: {{model.namespace.name}} + | Namespace: {{model.namespace.name}} {{/if}}
          @@ -34,11 +34,11 @@

          {{#allocation-status-bar allocationContainer=model class="split-view" as |chart|}} -
            +
              {{#each chart.data as |datum index|}}
            1. - {{datum.value}} + {{datum.value}} {{datum.label}} @@ -50,7 +50,7 @@
          {{#if model.hasPlacementFailures}} -
          +
          Placement Failures
          @@ -58,7 +58,7 @@ {{#each model.taskGroups as |taskGroup|}} {{#if taskGroup.placementFailures}} {{#with taskGroup.placementFailures as |failures|}} -

          +

          {{taskGroup.name}} {{inc failures.coalescedFailures}} unplaced

          @@ -101,13 +101,13 @@ {{/if}} {{#if model.runningDeployment}} -
          +
          Active Deployment - {{model.runningDeployment.shortId}} + {{model.runningDeployment.shortId}} {{#if model.runningDeployment.version.submitTime}} - {{moment-from-now model.runningDeployment.version.submitTime}} + {{moment-from-now model.runningDeployment.version.submitTime}} {{/if}}
          @@ -127,7 +127,7 @@ {{/job-deployment-details}}
          @@ -156,7 +156,7 @@ {{#t.sort-by prop="reservedEphemeralDisk"}}Reserved Disk{{/t.sort-by}} {{/t.head}} {{#t.body as |row|}} - {{task-group-row taskGroup=row.model onClick=(action "gotoTaskGroup" row.model)}} + {{task-group-row data-test-task-group taskGroup=row.model onClick=(action "gotoTaskGroup" row.model)}} {{/t.body}} {{/list-table}} {{/list-pagination}} @@ -177,12 +177,12 @@
          {{/t.head}} {{#t.body as |row|}} - - - - - - + + + + + {{/t.head}} {{#t.body as |row|}} - {{allocation-row allocation=row.model context="job" onClick=(action "gotoAllocation" row.model)}} + {{allocation-row data-test-allocation allocation=row.model context="job" onClick=(action "gotoAllocation" row.model)}} {{/t.body}} {{/list-table}}
          @@ -100,8 +101,8 @@
          {{else}}
          -
          -

          No Matches

          +
          +

          No Matches

          No allocations match the term {{searchTerm}}

          diff --git a/ui/app/templates/partials/forbidden-message.hbs b/ui/app/templates/partials/forbidden-message.hbs index a421e08e9..9fad4e384 100644 --- a/ui/app/templates/partials/forbidden-message.hbs +++ b/ui/app/templates/partials/forbidden-message.hbs @@ -1,6 +1,6 @@ -
          -

          Not Authorized

          -

          +

          +

          Not Authorized

          +

          {{#if token.secret}} Your {{#link-to "settings.tokens"}}ACL token{{/link-to}} does not provide the required permissions. Contact your administrator if this is an error. {{else}} diff --git a/ui/app/templates/servers.hbs b/ui/app/templates/servers.hbs index 5b97959ed..6a639191d 100644 --- a/ui/app/templates/servers.hbs +++ b/ui/app/templates/servers.hbs @@ -27,7 +27,7 @@ {{#t.sort-by prop="datacenter"}}Datacenter{{/t.sort-by}} {{/t.head}} {{#t.body as |row|}} - {{server-agent-row agent=row.model}} + {{server-agent-row data-test-server-agent-row agent=row.model}} {{/t.body}} {{/list-table}}

          diff --git a/ui/app/templates/servers/server.hbs b/ui/app/templates/servers/server.hbs index 231d704e1..c9ef7a925 100644 --- a/ui/app/templates/servers/server.hbs +++ b/ui/app/templates/servers/server.hbs @@ -13,7 +13,7 @@
          {{#each sortedTags as |tag|}} - + diff --git a/ui/app/templates/settings/tokens.hbs b/ui/app/templates/settings/tokens.hbs index 7f3e75673..e17b84393 100644 --- a/ui/app/templates/settings/tokens.hbs +++ b/ui/app/templates/settings/tokens.hbs @@ -20,16 +20,22 @@
          - +

          Sent with every request to determine authorization

          -

          +

          {{/if}} {{#if tokenIsValid}} -
          +

          Token Authenticated!

          @@ -40,7 +46,7 @@ {{/if}} {{#if tokenIsInvalid}} -
          +

          Token Failed to Authenticate

          @@ -58,26 +64,26 @@

          Policies

          {{#if (eq tokenRecord.type "management")}} -
          +
          The management token has all permissions
          {{else}} {{#each tokenRecord.policies as |policy|}} -
          -
          +
          +
          {{policy.name}}
          -

          +

          {{#if policy.description}} {{policy.description}} {{else}} No description {{/if}}

          -
          {{policy.rules}}
          +
          {{policy.rules}}
          {{/each}} diff --git a/ui/tests/acceptance/allocation-detail-test.js b/ui/tests/acceptance/allocation-detail-test.js index f8a7eff95..de651ca10 100644 --- a/ui/tests/acceptance/allocation-detail-test.js +++ b/ui/tests/acceptance/allocation-detail-test.js @@ -25,20 +25,23 @@ moduleForAcceptance('Acceptance | allocation detail', { test('/allocation/:id should name the allocation and link to the corresponding job and node', function( assert ) { - assert.ok(find('h1').textContent.includes(allocation.name), 'Allocation name is in the heading'); + assert.ok( + find('[data-test-title]').textContent.includes(allocation.name), + 'Allocation name is in the heading' + ); assert.equal( - find('.inline-definitions .job-link a').textContent.trim(), + find('[data-test-allocation-details] [data-test-job-link]').textContent.trim(), job.name, 'Job name is in the subheading' ); assert.equal( - find('.inline-definitions .node-link a').textContent.trim(), + find('[data-test-allocation-details] [data-test-client-link]').textContent.trim(), node.id.split('-')[0], 'Node short id is in the subheading' ); andThen(() => { - click('.inline-definitions .job-link a'); + click('[data-test-allocation-details] [data-test-job-link]'); }); andThen(() => { @@ -48,7 +51,7 @@ test('/allocation/:id should name the allocation and link to the corresponding j visit(`/allocations/${allocation.id}`); andThen(() => { - click('.inline-definitions .node-link a'); + click('[data-test-allocation-details] [data-test-client-link]'); }); andThen(() => { @@ -58,7 +61,7 @@ test('/allocation/:id should name the allocation and link to the corresponding j test('/allocation/:id should list all tasks for the allocation', function(assert) { assert.equal( - findAll('.tasks tbody tr').length, + findAll('[data-test-task-row]').length, server.db.taskStates.where({ allocationId: allocation.id }).length, 'Table lists all tasks' ); @@ -71,13 +74,13 @@ test('each task row should list high-level information for the task', function(a .sortBy('name')[0]; const reservedPorts = taskResources.resources.Networks[0].ReservedPorts; const dynamicPorts = taskResources.resources.Networks[0].DynamicPorts; - const taskRow = $(findAll('.tasks tbody tr')[0]); + const taskRow = $(findAll('[data-test-task-row]')[0]); const events = server.db.taskEvents.where({ taskStateId: task.id }); const event = events[events.length - 1]; assert.equal( taskRow - .find('td:eq(0)') + .find('[data-test-name]') .text() .trim(), task.name, @@ -85,7 +88,7 @@ test('each task row should list high-level information for the task', function(a ); assert.equal( taskRow - .find('td:eq(1)') + .find('[data-test-state]') .text() .trim(), task.state, @@ -93,7 +96,7 @@ test('each task row should list high-level information for the task', function(a ); assert.equal( taskRow - .find('td:eq(2)') + .find('[data-test-message]') .text() .trim(), event.message, @@ -101,7 +104,7 @@ test('each task row should list high-level information for the task', function(a ); assert.equal( taskRow - .find('td:eq(3)') + .find('[data-test-time]') .text() .trim(), moment(event.time / 1000000).format('MM/DD/YY HH:mm:ss'), @@ -111,7 +114,7 @@ test('each task row should list high-level information for the task', function(a assert.ok(reservedPorts.length, 'The task has reserved ports'); assert.ok(dynamicPorts.length, 'The task has dynamic ports'); - const addressesText = taskRow.find('td:eq(4)').text(); + const addressesText = taskRow.find('[data-test-ports]').text(); reservedPorts.forEach(port => { assert.ok(addressesText.includes(port.Label), `Found label ${port.Label}`); assert.ok(addressesText.includes(port.Value), `Found value ${port.Value}`); @@ -134,9 +137,9 @@ test('when the allocation is not found, an error message is shown, but the URL p 'A request to the non-existent allocation is made' ); assert.equal(currentURL(), '/allocations/not-a-real-allocation', 'The URL persists'); - assert.ok(find('.error-message'), 'Error message is shown'); + assert.ok(find('[data-test-error]'), 'Error message is shown'); assert.equal( - find('.error-message .title').textContent, + find('[data-test-error-title]').textContent, 'Not Found', 'Error message is for 404' ); diff --git a/ui/tests/acceptance/application-errors-test.js b/ui/tests/acceptance/application-errors-test.js index b5e2e636e..121e572c6 100644 --- a/ui/tests/acceptance/application-errors-test.js +++ b/ui/tests/acceptance/application-errors-test.js @@ -16,13 +16,13 @@ test('transitioning away from an error page resets the global error', function(a visit('/clients'); andThen(() => { - assert.ok(find('.error-message'), 'Application has errored'); + assert.ok(find('[data-test-error]'), 'Application has errored'); }); visit('/jobs'); andThen(() => { - assert.notOk(find('.error-message'), 'Application is no longer in an error state'); + assert.notOk(find('[data-test-error]'), 'Application is no longer in an error state'); }); }); @@ -34,16 +34,16 @@ test('the 403 error page links to the ACL tokens page', function(assert) { visit(`/jobs/${job.id}`); andThen(() => { - assert.ok(find('.error-message'), 'Error message is shown'); + assert.ok(find('[data-test-error]'), 'Error message is shown'); assert.equal( - find('.error-message .title').textContent, + find('[data-test-error] .title').textContent, 'Not Authorized', 'Error message is for 403' ); }); andThen(() => { - click('.error-message a'); + click('[data-test-error-acl-link]'); }); andThen(() => { diff --git a/ui/tests/acceptance/client-detail-test.js b/ui/tests/acceptance/client-detail-test.js index 03e28ed6a..1b0788b00 100644 --- a/ui/tests/acceptance/client-detail-test.js +++ b/ui/tests/acceptance/client-detail-test.js @@ -24,19 +24,19 @@ test('/clients/:id should have a breadrcumb trail linking back to clients', func andThen(() => { assert.equal( - findAll('.breadcrumb a')[0].textContent, + find('[data-test-breadcrumb="clients"]').textContent, 'Clients', 'First breadcrumb says clients' ); assert.equal( - findAll('.breadcrumb a')[1].textContent, + find('[data-test-breadcrumb="client"]').textContent, node.id.split('-')[0], 'Second breadcrumb says the node short id' ); }); andThen(() => { - click(findAll('.breadcrumb a')[0]); + click(find('[data-test-breadcrumb="clients"]')); }); andThen(() => { @@ -48,12 +48,9 @@ test('/clients/:id should list immediate details for the node in the title', fun visit(`/clients/${node.id}`); andThen(() => { - assert.ok(find('.title').textContent.includes(node.name), 'Title includes name'); - assert.ok(find('.title').textContent.includes(node.id), 'Title includes id'); - assert.ok( - findAll(`.title .node-status-light.${node.status}`).length, - 'Title includes status light' - ); + assert.ok(find('[data-test-title]').textContent.includes(node.name), 'Title includes name'); + assert.ok(find('[data-test-title]').textContent.includes(node.id), 'Title includes id'); + assert.ok(find(`[data-test-node-status="${node.status}"]`), 'Title includes status light'); }); }); @@ -67,16 +64,16 @@ test('/clients/:id should list additional detail for the node below the title', 'Status is in additional details' ); assert.ok( - $('.inline-definitions .pair:eq(0) .status-text').hasClass(`node-${node.status}`), + $('[data-test-status-definition] .status-text').hasClass(`node-${node.status}`), 'Status is decorated with a status class' ); assert.equal( - findAll('.inline-definitions .pair')[1].textContent, + find('[data-test-address-definition]').textContent, `Address ${node.httpAddr}`, 'Address is in additional detals' ); assert.equal( - findAll('.inline-definitions .pair')[2].textContent, + find('[data-test-datacenter-definition]').textContent, `Datacenter ${node.datacenter}`, 'Datacenter is in additional details' ); @@ -90,7 +87,7 @@ test('/clients/:id should list all allocations on the node', function(assert) { andThen(() => { assert.equal( - findAll('.allocations tbody tr').length, + findAll('[data-test-allocation]').length, allocationsCount, `Allocations table lists all ${allocationsCount} associated allocations` ); @@ -116,10 +113,10 @@ test('each allocation should have high-level details for the allocation', functi visit(`/clients/${node.id}`); andThen(() => { - const allocationRow = $(findAll('.allocations tbody tr')[0]); + const allocationRow = $(find('[data-test-allocation]')); assert.equal( allocationRow - .find('td:eq(0)') + .find('[data-test-short-id]') .text() .trim(), allocation.id.split('-')[0], @@ -127,7 +124,7 @@ test('each allocation should have high-level details for the allocation', functi ); assert.equal( allocationRow - .find('td:eq(1)') + .find('[data-test-modify-time]') .text() .trim(), moment(allocation.modifyTime / 1000000).format('MM/DD HH:mm:ss'), @@ -135,7 +132,7 @@ test('each allocation should have high-level details for the allocation', functi ); assert.equal( allocationRow - .find('td:eq(2)') + .find('[data-test-name]') .text() .trim(), allocation.name, @@ -143,56 +140,57 @@ test('each allocation should have high-level details for the allocation', functi ); assert.equal( allocationRow - .find('td:eq(3)') + .find('[data-test-client-status]') .text() .trim(), allocation.clientStatus, 'Client status' ); - assert.ok( + assert.equal( allocationRow - .find('td:eq(4)') + .find('[data-test-job]') .text() - .includes(server.db.jobs.find(allocation.jobId).name), + .trim(), + server.db.jobs.find(allocation.jobId).name, 'Job name' ); assert.ok( allocationRow - .find('td:eq(4) .is-faded') + .find('[data-test-task-group]') .text() .includes(allocation.taskGroup), 'Task group name' ); assert.ok( allocationRow - .find('td:eq(5)') + .find('[data-test-job-version]') .text() .includes(allocation.jobVersion), 'Job Version' ); assert.equal( allocationRow - .find('td:eq(6)') + .find('[data-test-cpu]') .text() .trim(), Math.floor(allocStats.resourceUsage.CpuStats.TotalTicks) / cpuUsed, 'CPU %' ); assert.equal( - allocationRow.find('td:eq(6) .tooltip').attr('aria-label'), + allocationRow.find('[data-test-cpu] .tooltip').attr('aria-label'), `${Math.floor(allocStats.resourceUsage.CpuStats.TotalTicks)} / ${cpuUsed} MHz`, 'Detailed CPU information is in a tooltip' ); assert.equal( allocationRow - .find('td:eq(7)') + .find('[data-test-mem]') .text() .trim(), allocStats.resourceUsage.MemoryStats.RSS / 1024 / 1024 / memoryUsed, 'Memory used' ); assert.equal( - allocationRow.find('td:eq(7) .tooltip').attr('aria-label'), + allocationRow.find('[data-test-mem] .tooltip').attr('aria-label'), `${formatBytes([allocStats.resourceUsage.MemoryStats.RSS])} / ${memoryUsed} MiB`, 'Detailed memory information is in a tooltip' ); @@ -219,7 +217,7 @@ test('each allocation should show job information even if the job is incomplete visit(`/clients/${node.id}`); andThen(() => { - const allocationRow = $(findAll('.allocations tbody tr')[0]); + const allocationRow = $(find('[data-test-allocation]')); const allocation = server.db.allocations .where({ nodeId: node.id }) .sortBy('modifyIndex') @@ -227,14 +225,14 @@ test('each allocation should show job information even if the job is incomplete assert.ok( allocationRow - .find('td:eq(4)') + .find('[data-test-job]') .text() .includes(server.db.jobs.find(allocation.jobId).name), 'Job name' ); assert.ok( allocationRow - .find('td:eq(4) .is-faded') + .find('[data-test-task-group]') .text() .includes(allocation.taskGroup), 'Task group name' @@ -251,7 +249,7 @@ test('each allocation should link to the allocation detail page', function(asser visit(`/clients/${node.id}`); andThen(() => { - click($('.allocations tbody tr:eq(0) td:eq(0) a').get(0)); + click('[data-test-short-id] a'); }); andThen(() => { @@ -270,7 +268,7 @@ test('each allocation should link to the job the allocation belongs to', functio const job = server.db.jobs.find(allocation.jobId); andThen(() => { - click($('.allocations tbody tr:eq(0) td:eq(4) a').get(0)); + click('[data-test-job]'); }); andThen(() => { @@ -286,7 +284,7 @@ test('/clients/:id should list all attributes for the node', function(assert) { visit(`/clients/${node.id}`); andThen(() => { - assert.ok(find('.attributes-table'), 'Attributes table is on the page'); + assert.ok(find('[data-test-attributes]'), 'Attributes table is on the page'); }); }); @@ -302,9 +300,9 @@ test('when the node is not found, an error message is shown, but the URL persist 'A request to the non-existent node is made' ); assert.equal(currentURL(), '/clients/not-a-real-node', 'The URL persists'); - assert.ok(find('.error-message'), 'Error message is shown'); + assert.ok(find('[data-test-error]'), 'Error message is shown'); assert.equal( - find('.error-message .title').textContent, + find('[data-test-error-title]').textContent, 'Not Found', 'Error message is for 404' ); diff --git a/ui/tests/acceptance/job-definition-test.js b/ui/tests/acceptance/job-definition-test.js index 0317ec93b..5a5478fb8 100644 --- a/ui/tests/acceptance/job-definition-test.js +++ b/ui/tests/acceptance/job-definition-test.js @@ -18,7 +18,7 @@ test('visiting /jobs/:job_id/definition', function(assert) { }); test('the job definition page contains a json viewer component', function(assert) { - assert.ok(findAll('.json-viewer').length, 'JSON viewer found'); + assert.ok(findAll('[data-test-definition-view]').length, 'JSON viewer found'); }); test('the job definition page requests the job to display in an unmutated form', function(assert) { diff --git a/ui/tests/acceptance/job-deployments-test.js b/ui/tests/acceptance/job-deployments-test.js index 45a6ae426..b2bcfffe4 100644 --- a/ui/tests/acceptance/job-deployments-test.js +++ b/ui/tests/acceptance/job-deployments-test.js @@ -33,7 +33,7 @@ test('/jobs/:id/deployments should list all job deployments', function(assert) { visit(`/jobs/${job.id}/deployments`); andThen(() => { assert.ok( - findAll('.timeline-object').length, + findAll('[data-test-deployment]').length, deployments.length, 'Each deployment gets a row in the timeline' ); @@ -51,17 +51,32 @@ test('each deployment mentions the deployment shortId, status, version, and time jobId: deployment.jobId, version: deployment.versionNumber, }); - const deploymentRow = $(findAll('.timeline-object')[0]); + const deploymentRow = $(find('[data-test-deployment]')); assert.ok(deploymentRow.text().includes(deployment.id.split('-')[0]), 'Short ID'); - assert.equal(deploymentRow.find('.tag').text(), deployment.status, 'Status'); + assert.equal( + deploymentRow.find('[data-test-deployment-status]').text(), + deployment.status, + 'Status' + ); assert.ok( - deploymentRow.find('.tag').hasClass(classForStatus(deployment.status)), + deploymentRow + .find('[data-test-deployment-status]') + .hasClass(classForStatus(deployment.status)), 'Status Class' ); - assert.ok(deploymentRow.text().includes(deployment.versionNumber), 'Version #'); assert.ok( - deploymentRow.text().includes(moment(version.submitTime / 1000000).fromNow()), + deploymentRow + .find('[data-test-deployment-version]') + .text() + .includes(deployment.versionNumber), + 'Version #' + ); + assert.ok( + deploymentRow + .find('[data-test-deployment-submit-time]') + .text() + .includes(moment(version.submitTime / 1000000).fromNow()), 'Submit time ago' ); }); @@ -90,9 +105,9 @@ test('when the deployment is running and needs promotion, the deployment item sa visit(`/jobs/${job.id}/deployments`); andThen(() => { - const deploymentRow = $(findAll('.timeline-object')[0]); + const deploymentRow = find('[data-test-deployment]'); assert.ok( - deploymentRow.find('.badge:contains("Requires Promotion")').length, + deploymentRow.querySelector('[data-test-promotion-required]'), 'Requires Promotion badge found' ); }); @@ -104,14 +119,20 @@ test('each deployment item can be opened to show details', function(assert) { visit(`/jobs/${job.id}/deployments`); andThen(() => { - deploymentRow = $(findAll('.timeline-object')[0]); + deploymentRow = find('[data-test-deployment]'); - assert.ok(deploymentRow.find('.boxed-section-body').length === 0, 'No deployment body'); + assert.notOk( + deploymentRow.querySelector('[data-test-deployment-details]'), + 'No deployment body' + ); - click(deploymentRow.find('button').get(0)); + click(deploymentRow.querySelector('[data-test-deployment-toggle-details]')); andThen(() => { - assert.ok(deploymentRow.find('.boxed-section-body').length, 'Deployment body found'); + assert.ok( + deploymentRow.querySelector('[data-test-deployment-details]'), + 'Deployment body found' + ); }); }); }); @@ -121,18 +142,16 @@ test('when open, a deployment shows the deployment metrics', function(assert) { andThen(() => { const deployment = sortedDeployments.models[0]; - const deploymentRow = $(findAll('.timeline-object')[0]); + const deploymentRow = find('[data-test-deployment]'); const taskGroupSummaries = deployment.deploymentTaskGroupSummaryIds.map(id => server.db.deploymentTaskGroupSummaries.find(id) ); - click(deploymentRow.find('button').get(0)); + click(deploymentRow.querySelector('[data-test-deployment-toggle-details]')); andThen(() => { assert.equal( - $('.deployment-metrics .label:contains("Canaries") + .value') - .get(0) - .textContent.trim(), + find('[data-test-deployment-metric="canaries"]').textContent.trim(), `${sum(taskGroupSummaries, 'placedCanaries')} / ${sum( taskGroupSummaries, 'desiredCanaries' @@ -141,39 +160,31 @@ test('when open, a deployment shows the deployment metrics', function(assert) { ); assert.equal( - $('.deployment-metrics .label:contains("Placed") + .value') - .get(0) - .textContent.trim(), + find('[data-test-deployment-metric="placed"]').textContent.trim(), sum(taskGroupSummaries, 'placedAllocs'), 'Placed allocs aggregates across task groups' ); assert.equal( - $('.deployment-metrics .label:contains("Desired") + .value') - .get(0) - .textContent.trim(), + find('[data-test-deployment-metric="desired"]').textContent.trim(), sum(taskGroupSummaries, 'desiredTotal'), 'Desired allocs aggregates across task groups' ); assert.equal( - $('.deployment-metrics .label:contains("Healthy") + .value') - .get(0) - .textContent.trim(), + find('[data-test-deployment-metric="healthy"]').textContent.trim(), sum(taskGroupSummaries, 'healthyAllocs'), 'Healthy allocs aggregates across task groups' ); assert.equal( - $('.deployment-metrics .label:contains("Unhealthy") + .value') - .get(0) - .textContent.trim(), + find('[data-test-deployment-metric="unhealthy"]').textContent.trim(), sum(taskGroupSummaries, 'unhealthyAllocs'), 'Unhealthy allocs aggregates across task groups' ); assert.equal( - find('.deployment-metrics .notification').textContent.trim(), + find('[data-test-deployment-notification]').textContent.trim(), deployment.statusDescription, 'Status description is in the metrics block' ); @@ -188,85 +199,65 @@ test('when open, a deployment shows a list of all task groups and their respecti andThen(() => { const deployment = sortedDeployments.models[0]; - const deploymentRow = $(findAll('.timeline-object')[0]); + const deploymentRow = find('[data-test-deployment]'); const taskGroupSummaries = deployment.deploymentTaskGroupSummaryIds.map(id => server.db.deploymentTaskGroupSummaries.find(id) ); - click(deploymentRow.find('button').get(0)); + click(deploymentRow.querySelector('[data-test-deployment-toggle-details]')); andThen(() => { - assert.ok( - deploymentRow.find('.boxed-section-head:contains("Task Groups")').length, - 'Task groups found' - ); + const taskGroupTable = deploymentRow.querySelector('[data-test-deployment-task-groups]'); - const taskGroupTable = deploymentRow.find( - '.boxed-section-head:contains("Task Groups") + .boxed-section-body tbody' - ); + assert.ok(taskGroupTable, 'Task groups found'); assert.equal( - taskGroupTable.find('tr').length, + taskGroupTable.querySelectorAll('[data-test-deployment-task-group]').length, taskGroupSummaries.length, 'One row per task group' ); const taskGroup = taskGroupSummaries[0]; - const taskGroupRow = taskGroupTable.find('tr:eq(0)'); + const taskGroupRow = taskGroupTable.querySelector('[data-test-deployment-task-group]'); assert.equal( - taskGroupRow - .find('td:eq(0)') - .text() - .trim(), + taskGroupRow.querySelector('[data-test-deployment-task-group-name]').textContent.trim(), taskGroup.name, 'Name' ); assert.equal( taskGroupRow - .find('td:eq(1)') - .text() - .trim(), + .querySelector('[data-test-deployment-task-group-promotion]') + .textContent.trim(), promotionTestForTaskGroup(taskGroup), 'Needs Promotion' ); assert.equal( taskGroupRow - .find('td:eq(2)') - .text() - .trim(), + .querySelector('[data-test-deployment-task-group-auto-revert]') + .textContent.trim(), taskGroup.autoRevert ? 'Yes' : 'No', 'Auto Revert' ); assert.equal( - taskGroupRow - .find('td:eq(3)') - .text() - .trim(), + taskGroupRow.querySelector('[data-test-deployment-task-group-canaries]').textContent.trim(), `${taskGroup.placedCanaries} / ${taskGroup.desiredCanaries}`, 'Canaries' ); assert.equal( - taskGroupRow - .find('td:eq(4)') - .text() - .trim(), + taskGroupRow.querySelector('[data-test-deployment-task-group-allocs]').textContent.trim(), `${taskGroup.placedAllocs} / ${taskGroup.desiredTotal}`, 'Allocs' ); assert.equal( - taskGroupRow - .find('td:eq(5)') - .text() - .trim(), + taskGroupRow.querySelector('[data-test-deployment-task-group-healthy]').textContent.trim(), taskGroup.healthyAllocs, 'Healthy Allocs' ); assert.equal( taskGroupRow - .find('td:eq(6)') - .text() - .trim(), + .querySelector('[data-test-deployment-task-group-unhealthy]') + .textContent.trim(), taskGroup.unhealthyAllocs, 'Unhealthy Allocs' ); @@ -281,38 +272,31 @@ test('when open, a deployment shows a list of all allocations for the deployment andThen(() => { const deployment = sortedDeployments.models[0]; - const deploymentRow = $(findAll('.timeline-object')[0]); + const deploymentRow = find('[data-test-deployment]'); // TODO: Make this less brittle. This logic is copied from the mirage config, // since there is no reference to allocations on the deployment model. const allocations = server.db.allocations.where({ jobId: deployment.jobId }).slice(0, 3); - click(deploymentRow.find('button').get(0)); + click(deploymentRow.querySelector('[data-test-deployment-toggle-details]')); andThen(() => { assert.ok( - deploymentRow.find('.boxed-section-head:contains("Allocations")').length, + deploymentRow.querySelector('[data-test-deployment-allocations]'), 'Allocations found' ); - const allocationsTable = deploymentRow.find( - '.boxed-section-head:contains("Allocations") + .boxed-section-body tbody' - ); - assert.equal( - allocationsTable.find('tr').length, + deploymentRow.querySelectorAll('[data-test-deployment-allocation]').length, allocations.length, 'One row per allocation' ); const allocation = allocations[0]; - const allocationRow = allocationsTable.find('tr:eq(0)'); + const allocationRow = deploymentRow.querySelector('[data-test-deployment-allocation]'); assert.equal( - allocationRow - .find('td:eq(0)') - .text() - .trim(), + allocationRow.querySelector('[data-test-short-id]').textContent.trim(), allocation.id.split('-')[0], 'Allocation is as expected' ); diff --git a/ui/tests/acceptance/job-detail-test.js b/ui/tests/acceptance/job-detail-test.js index 758e40c91..a1df252ec 100644 --- a/ui/tests/acceptance/job-detail-test.js +++ b/ui/tests/acceptance/job-detail-test.js @@ -1,5 +1,4 @@ import { get } from '@ember/object'; -import $ from 'jquery'; import { click, findAll, currentURL, find, visit } from 'ember-native-dom-helpers'; import moment from 'moment'; import { test } from 'qunit'; @@ -22,14 +21,18 @@ test('visiting /jobs/:job_id', function(assert) { }); test('breadcrumbs includes job name and link back to the jobs list', function(assert) { - assert.equal(findAll('.breadcrumb a')[0].textContent, 'Jobs', 'First breadcrumb says jobs'); assert.equal( - findAll('.breadcrumb a')[1].textContent, + find('[data-test-breadcrumb="Jobs"]').textContent, + 'Jobs', + 'First breadcrumb says jobs' + ); + assert.equal( + find(`[data-test-breadcrumb="${job.name}"]`).textContent, job.name, 'Second breadcrumb says the job name' ); - click(findAll('.breadcrumb a')[0]); + click(find('[data-test-breadcrumb="Jobs"]')); andThen(() => { assert.equal(currentURL(), '/jobs', 'First breadcrumb links back to jobs'); }); @@ -38,7 +41,7 @@ test('breadcrumbs includes job name and link back to the jobs list', function(as test('the subnav includes links to definition, versions, and deployments when type = service', function( assert ) { - const subnavLabels = findAll('.tabs.is-subnav a').map(anchor => anchor.textContent); + const subnavLabels = findAll('[data-test-tab]').map(anchor => anchor.textContent); assert.ok(subnavLabels.some(label => label === 'Definition'), 'Definition link'); assert.ok(subnavLabels.some(label => label === 'Versions'), 'Versions link'); assert.ok(subnavLabels.some(label => label === 'Deployments'), 'Deployments link'); @@ -49,7 +52,7 @@ test('the subnav includes links to definition and versions when type != service' visit(`/jobs/${job.id}`); andThen(() => { - const subnavLabels = findAll('.tabs.is-subnav a').map(anchor => anchor.textContent); + const subnavLabels = findAll('[data-test-tab]').map(anchor => anchor.textContent); assert.ok(subnavLabels.some(label => label === 'Definition'), 'Definition link'); assert.ok(subnavLabels.some(label => label === 'Versions'), 'Versions link'); assert.notOk(subnavLabels.some(label => label === 'Deployments'), 'Deployments link'); @@ -57,15 +60,15 @@ test('the subnav includes links to definition and versions when type != service' }); test('the job detail page should contain basic information about the job', function(assert) { - assert.ok(findAll('.title .tag')[0].textContent.includes(job.status), 'Status'); - assert.ok(findAll('.job-stats span')[0].textContent.includes(job.type), 'Type'); - assert.ok(findAll('.job-stats span')[1].textContent.includes(job.priority), 'Priority'); - assert.notOk(findAll('.job-stats span')[2], 'Namespace is not included'); + assert.ok(find('[data-test-job-status]').textContent.includes(job.status), 'Status'); + assert.ok(find('[data-test-job-stat="type"]').textContent.includes(job.type), 'Type'); + assert.ok(find('[data-test-job-stat="priority"]').textContent.includes(job.priority), 'Priority'); + assert.notOk(find('[data-test-job-stat="namespace"]'), 'Namespace is not included'); }); test('the job detail page should list all task groups', function(assert) { assert.equal( - findAll('.task-group-row').length, + findAll('[data-test-task-group]').length, server.db.taskGroups.where({ jobId: job.id }).length ); }); @@ -74,45 +77,38 @@ test('each row in the task group table should show basic information about the t assert ) { const taskGroup = job.taskGroupIds.map(id => server.db.taskGroups.find(id)).sortBy('name')[0]; - const taskGroupRow = $(findAll('.task-group-row')[0]); + const taskGroupRow = find('[data-test-task-group]'); const tasks = server.db.tasks.where({ taskGroupId: taskGroup.id }); const sum = (list, key) => list.reduce((sum, item) => sum + get(item, key), 0); assert.equal( - taskGroupRow - .find('td:eq(0)') - .text() - .trim(), + taskGroupRow.querySelector('[data-test-task-group-name]').textContent.trim(), taskGroup.name, 'Name' ); assert.equal( - taskGroupRow - .find('td:eq(1)') - .text() - .trim(), + taskGroupRow.querySelector('[data-test-task-group-count]').textContent.trim(), taskGroup.count, 'Count' ); assert.equal( - taskGroupRow.find('td:eq(3)').text(), + taskGroupRow.querySelector('[data-test-task-group-cpu]').textContent.trim(), `${sum(tasks, 'Resources.CPU')} MHz`, 'Reserved CPU' ); assert.equal( - taskGroupRow.find('td:eq(4)').text(), + taskGroupRow.querySelector('[data-test-task-group-mem]').textContent.trim(), `${sum(tasks, 'Resources.MemoryMB')} MiB`, 'Reserved Memory' ); assert.equal( - taskGroupRow.find('td:eq(5)').text(), + taskGroupRow.querySelector('[data-test-task-group-disk]').textContent.trim(), `${taskGroup.ephemeralDisk.SizeMB} MiB`, 'Reserved Disk' ); }); test('the allocations diagram lists all allocation status figures', function(assert) { - const legend = find('.distribution-bar .legend'); const jobSummary = server.db.jobSummaries.findBy({ jobId: job.id }); const statusCounts = Object.keys(jobSummary.Summary).reduce( (counts, key) => { @@ -129,37 +125,37 @@ test('the allocations diagram lists all allocation status figures', function(ass ); assert.equal( - legend.querySelector('li.queued .value').textContent, + find('[data-test-legend-value="queued"]').textContent, statusCounts.queued, `${statusCounts.queued} are queued` ); assert.equal( - legend.querySelector('li.starting .value').textContent, + find('[data-test-legend-value="starting"]').textContent, statusCounts.starting, `${statusCounts.starting} are starting` ); assert.equal( - legend.querySelector('li.running .value').textContent, + find('[data-test-legend-value="running"]').textContent, statusCounts.running, `${statusCounts.running} are running` ); assert.equal( - legend.querySelector('li.complete .value').textContent, + find('[data-test-legend-value="complete"]').textContent, statusCounts.complete, `${statusCounts.complete} are complete` ); assert.equal( - legend.querySelector('li.failed .value').textContent, + find('[data-test-legend-value="failed"]').textContent, statusCounts.failed, `${statusCounts.failed} are failed` ); assert.equal( - legend.querySelector('li.lost .value').textContent, + find('[data-test-legend-value="lost"]').textContent, statusCounts.lost, `${statusCounts.lost} are lost` ); @@ -174,7 +170,7 @@ test('there is no active deployment section when the job has no active deploymen visit(`/jobs/${job.id}`); andThen(() => { - assert.ok(findAll('.active-deployment').length === 0, 'No active deployment'); + assert.notOk(find('[data-test-active-deployment]'), 'No active deployment'); }); }); @@ -193,27 +189,21 @@ test('the active deployment section shows up for the currently running deploymen visit(`/jobs/${job.id}`); andThen(() => { - assert.ok(findAll('.active-deployment').length === 1, 'Active deployment'); + assert.ok(find('[data-test-active-deployment]'), 'Active deployment'); assert.equal( - $('.active-deployment > .boxed-section-head .badge') - .get(0) - .textContent.trim(), + find('[data-test-active-deployment-stat="id"]').textContent.trim(), deployment.id.split('-')[0], 'The active deployment is the most recent running deployment' ); assert.equal( - $('.active-deployment > .boxed-section-head .submit-time') - .get(0) - .textContent.trim(), + find('[data-test-active-deployment-stat="submit-time"]').textContent.trim(), moment(version.submitTime / 1000000).fromNow(), 'Time since the job was submitted is in the active deployment header' ); assert.equal( - $('.deployment-metrics .label:contains("Canaries") + .value') - .get(0) - .textContent.trim(), + find('[data-test-deployment-metric="canaries"]').textContent.trim(), `${sum(taskGroupSummaries, 'placedCanaries')} / ${sum( taskGroupSummaries, 'desiredCanaries' @@ -222,41 +212,31 @@ test('the active deployment section shows up for the currently running deploymen ); assert.equal( - $('.deployment-metrics .label:contains("Placed") + .value') - .get(0) - .textContent.trim(), + find('[data-test-deployment-metric="placed"]').textContent.trim(), sum(taskGroupSummaries, 'placedAllocs'), 'Placed allocs aggregates across task groups' ); assert.equal( - $('.deployment-metrics .label:contains("Desired") + .value') - .get(0) - .textContent.trim(), + find('[data-test-deployment-metric="desired"]').textContent.trim(), sum(taskGroupSummaries, 'desiredTotal'), 'Desired allocs aggregates across task groups' ); assert.equal( - $('.deployment-metrics .label:contains("Healthy") + .value') - .get(0) - .textContent.trim(), + find('[data-test-deployment-metric="healthy"]').textContent.trim(), sum(taskGroupSummaries, 'healthyAllocs'), 'Healthy allocs aggregates across task groups' ); assert.equal( - $('.deployment-metrics .label:contains("Unhealthy") + .value') - .get(0) - .textContent.trim(), + find('[data-test-deployment-metric="unhealthy"]').textContent.trim(), sum(taskGroupSummaries, 'unhealthyAllocs'), 'Unhealthy allocs aggregates across task groups' ); assert.equal( - $('.deployment-metrics .notification') - .get(0) - .textContent.trim(), + find('[data-test-deployment-notification]').textContent.trim(), deployment.statusDescription, 'Status description is in the metrics block' ); @@ -270,29 +250,17 @@ test('the active deployment section can be expanded to show task groups and allo visit(`/jobs/${job.id}`); andThen(() => { - assert.ok( - $('.active-deployment .boxed-section-head:contains("Task Groups")').length === 0, - 'Task groups not found' - ); - assert.ok( - $('.active-deployment .boxed-section-head:contains("Allocations")').length === 0, - 'Allocations not found' - ); + assert.notOk(find('[data-test-deployment-task-groups]'), 'Task groups not found'); + assert.notOk(find('[data-test-deployment-allocations]'), 'Allocations not found'); }); andThen(() => { - click('.active-deployment-details-toggle'); + click('[data-test-deployment-toggle-details]'); }); andThen(() => { - assert.ok( - $('.active-deployment .boxed-section-head:contains("Task Groups")').length === 1, - 'Task groups found' - ); - assert.ok( - $('.active-deployment .boxed-section-head:contains("Allocations")').length === 1, - 'Allocations found' - ); + assert.ok(find('[data-test-deployment-task-groups]'), 'Task groups found'); + assert.ok(find('[data-test-deployment-allocations]'), 'Allocations found'); }); }); @@ -307,25 +275,37 @@ test('the evaluations table lists evaluations sorted by modify index', function( andThen(() => { assert.equal( - findAll('.evaluations tbody tr').length, + findAll('[data-test-evaluation]').length, evaluations.length, 'A row for each evaluation' ); evaluations.forEach((evaluation, index) => { - const row = $(findAll('.evaluations tbody tr')[index]); + const row = findAll('[data-test-evaluation]')[index]; assert.equal( - row.find('td:eq(0)').text(), + row.querySelector('[data-test-id]').textContent, evaluation.id.split('-')[0], `Short ID, row ${index}` ); }); const firstEvaluation = evaluations[0]; - const row = $(findAll('.evaluations tbody tr')[0]); - assert.equal(row.find('td:eq(1)').text(), '' + firstEvaluation.priority, 'Priority'); - assert.equal(row.find('td:eq(2)').text(), firstEvaluation.triggeredBy, 'Triggered By'); - assert.equal(row.find('td:eq(3)').text(), firstEvaluation.status, 'Status'); + const row = find('[data-test-evaluation]'); + assert.equal( + row.querySelector('[data-test-priority]').textContent, + '' + firstEvaluation.priority, + 'Priority' + ); + assert.equal( + row.querySelector('[data-test-triggered-by]').textContent, + firstEvaluation.triggeredBy, + 'Triggered By' + ); + assert.equal( + row.querySelector('[data-test-status]').textContent, + firstEvaluation.status, + 'Status' + ); }); }); @@ -342,9 +322,9 @@ test('when the job has placement failures, they are called out', function(assert visit(`/jobs/${job.id}`); andThen(() => { - assert.ok(find('.placement-failures'), 'Placement failures section found'); + assert.ok(find('[data-test-placement-failures]'), 'Placement failures section found'); - const taskGroupLabels = findAll('.placement-failures h3.title').map(title => + const taskGroupLabels = findAll('[data-test-placement-failure-task-group]').map(title => title.textContent.trim() ); failedTaskGroupNames.forEach(name => { @@ -369,7 +349,7 @@ test('when the job has no placement failures, the placement failures section is visit(`/jobs/${job.id}`); andThen(() => { - assert.notOk(find('.placement-failures'), 'Placement failures section not found'); + assert.notOk(find('[data-test-placement-failures]'), 'Placement failures section not found'); }); }); @@ -385,9 +365,9 @@ test('when the job is not found, an error message is shown, but the URL persists 'A request to the non-existent job is made' ); assert.equal(currentURL(), '/jobs/not-a-real-job', 'The URL persists'); - assert.ok(find('.error-message'), 'Error message is shown'); + assert.ok(find('[data-test-error]'), 'Error message is shown'); assert.equal( - find('.error-message .title').textContent, + find('[data-test-error-title]').textContent, 'Not Found', 'Error message is for 404' ); @@ -411,7 +391,7 @@ test('when there are namespaces, the job detail page states the namespace for th andThen(() => { assert.ok( - findAll('.job-stats span')[2].textContent.includes(namespace.name), + find('[data-test-job-stat="namespace"]').textContent.includes(namespace.name), 'Namespace included in stats' ); }); @@ -427,7 +407,7 @@ test('when switching namespaces, the app redirects to /jobs with the new namespa visit(`/jobs/${job.id}?namespace=${namespace.name}`); andThen(() => { - selectChoose('.namespace-switcher', label); + selectChoose('[data-test-namespace-switcher]', label); }); andThen(() => { @@ -436,13 +416,15 @@ test('when switching namespaces, the app redirects to /jobs with the new namespa .where({ namespace: otherNamespace }) .sortBy('modifyIndex') .reverse(); - assert.equal(findAll('.job-row').length, jobs.length, 'Shows the right number of jobs'); + assert.equal( + findAll('[data-test-job-row]').length, + jobs.length, + 'Shows the right number of jobs' + ); jobs.forEach((job, index) => { + const jobRow = findAll('[data-test-job-row]')[index]; assert.equal( - $(findAll('.job-row')[index]) - .find('td:eq(0)') - .text() - .trim(), + jobRow.querySelector('[data-test-job-name]').textContent.trim(), job.name, `Job ${index} is right` ); diff --git a/ui/tests/acceptance/job-versions-test.js b/ui/tests/acceptance/job-versions-test.js index 4d8b161ce..8a20f366b 100644 --- a/ui/tests/acceptance/job-versions-test.js +++ b/ui/tests/acceptance/job-versions-test.js @@ -1,5 +1,4 @@ -import $ from 'jquery'; -import { findAll, visit } from 'ember-native-dom-helpers'; +import { find, findAll, visit } from 'ember-native-dom-helpers'; import { test } from 'qunit'; import moduleForAcceptance from 'nomad-ui/tests/helpers/module-for-acceptance'; import moment from 'moment'; @@ -18,7 +17,7 @@ moduleForAcceptance('Acceptance | job versions', { test('/jobs/:id/versions should list all job versions', function(assert) { assert.ok( - findAll('.timeline-object').length, + findAll('[data-test-version]').length, versions.length, 'Each version gets a row in the timeline' ); @@ -28,16 +27,16 @@ test('each version mentions the version number, the stability, and the submitted assert ) { const version = versions.sortBy('submitTime').reverse()[0]; - const versionRow = $(findAll('.timeline-object')[0]); + const versionRow = find('[data-test-version]'); - assert.ok(versionRow.text().includes(`Version #${version.version}`), 'Version #'); + assert.ok(versionRow.textContent.includes(`Version #${version.version}`), 'Version #'); assert.equal( - versionRow.find('.version-stability .badge').text(), + versionRow.querySelector('[data-test-version-stability]').textContent, version.stable.toString(), 'Stability' ); assert.equal( - versionRow.find('.version-submit-date .submit-date').text(), + versionRow.querySelector('[data-test-version-submit-date]').textContent, moment(version.submitTime / 1000000).format('MM/DD/YY HH:mm:ss'), 'Submit time' ); diff --git a/ui/tests/acceptance/jobs-list-test.js b/ui/tests/acceptance/jobs-list-test.js index 4de2869ea..d7f870214 100644 --- a/ui/tests/acceptance/jobs-list-test.js +++ b/ui/tests/acceptance/jobs-list-test.js @@ -1,4 +1,3 @@ -import $ from 'jquery'; import { click, find, findAll, currentURL, visit, fillIn } from 'ember-native-dom-helpers'; import { test } from 'qunit'; import moduleForAcceptance from 'nomad-ui/tests/helpers/module-for-acceptance'; @@ -27,10 +26,11 @@ test('/jobs should list the first page of jobs sorted by modify index', function andThen(() => { const sortedJobs = server.db.jobs.sortBy('modifyIndex').reverse(); - assert.equal(findAll('.job-row').length, pageSize); + assert.equal(findAll('[data-test-job-row]').length, pageSize); for (var jobNumber = 0; jobNumber < pageSize; jobNumber++) { + const jobRow = findAll('[data-test-job-row]')[jobNumber]; assert.equal( - $(`.job-row:eq(${jobNumber}) td:eq(0)`).text(), + jobRow.querySelector('[data-test-job-name]').textContent, sortedJobs[jobNumber].name, 'Jobs are ordered' ); @@ -46,26 +46,28 @@ test('each job row should contain information about the job', function(assert) { visit('/jobs'); andThen(() => { - const jobRow = $(findAll('.job-row')[0]); + const jobRow = find('[data-test-job-row]'); - assert.equal(jobRow.find('td:eq(0)').text(), job.name, 'Name'); - assert.equal(jobRow.find('td:eq(0) a').attr('href'), `/ui/jobs/${job.id}`, 'Detail Link'); + assert.equal(jobRow.querySelector('[data-test-job-name]').textContent, job.name, 'Name'); assert.equal( - jobRow - .find('td:eq(1)') - .text() - .trim(), + jobRow.querySelector('[data-test-job-name] a').getAttribute('href'), + `/ui/jobs/${job.id}`, + 'Detail Link' + ); + assert.equal( + jobRow.querySelector('[data-test-job-status]').textContent.trim(), job.status, 'Status' ); - assert.equal(jobRow.find('td:eq(2)').text(), job.type, 'Type'); - assert.equal(jobRow.find('td:eq(3)').text(), job.priority, 'Priority'); + assert.equal(jobRow.querySelector('[data-test-job-type]').textContent, job.type, 'Type'); + assert.equal( + jobRow.querySelector('[data-test-job-priority]').textContent, + job.priority, + 'Priority' + ); andThen(() => { assert.equal( - jobRow - .find('td:eq(4)') - .text() - .trim(), + jobRow.querySelector('[data-test-job-task-groups]').textContent.trim(), taskGroups.length, '# Groups' ); @@ -80,7 +82,7 @@ test('each job row should link to the corresponding job', function(assert) { visit('/jobs'); andThen(() => { - click($('.job-row:eq(0) td:eq(0) a').get(0)); + click('[data-test-job-name] a'); }); andThen(() => { @@ -92,8 +94,8 @@ test('when there are no jobs, there is an empty message', function(assert) { visit('/jobs'); andThen(() => { - assert.ok(find('.empty-message')); - assert.equal(find('.empty-message-headline').textContent, 'No Jobs'); + assert.ok(find('[data-test-empty-jobs-list]')); + assert.equal(find('[data-test-empty-jobs-list-headline]').textContent, 'No Jobs'); }); }); @@ -106,12 +108,12 @@ test('when there are jobs, but no matches for a search result, there is an empty visit('/jobs'); andThen(() => { - fillIn('.search-box input', 'dog'); + fillIn('[data-test-jobs-search] input', 'dog'); }); andThen(() => { - assert.ok(find('.empty-message')); - assert.equal(find('.empty-message-headline').textContent, 'No Matches'); + assert.ok(find('[data-test-empty-jobs-list]')); + assert.equal(find('[data-test-empty-jobs-list-headline]').textContent, 'No Matches'); }); }); @@ -125,16 +127,20 @@ test('when the namespace query param is set, only matching jobs are shown and th visit('/jobs'); andThen(() => { - assert.equal(findAll('.job-row').length, 1, 'One job in the default namespace'); - assert.equal(find('.job-row td').textContent, job1.name, 'The correct job is shown'); + assert.equal(findAll('[data-test-job-row]').length, 1, 'One job in the default namespace'); + assert.equal(find('[data-test-job-name]').textContent, job1.name, 'The correct job is shown'); }); const secondNamespace = server.db.namespaces[1]; visit(`/jobs?namespace=${secondNamespace.id}`); andThen(() => { - assert.equal(findAll('.job-row').length, 1, `One job in the ${secondNamespace.name} namespace`); - assert.equal(find('.job-row td').textContent, job2.name, 'The correct job is shown'); + assert.equal( + findAll('[data-test-job-row]').length, + 1, + `One job in the ${secondNamespace.name} namespace` + ); + assert.equal(find('[data-test-job-name]').textContent, job2.name, 'The correct job is shown'); }); }); @@ -146,11 +152,11 @@ test('when accessing jobs is forbidden, show a message with a link to the tokens visit('/jobs'); andThen(() => { - assert.equal(find('.empty-message-headline').textContent, 'Not Authorized'); + assert.equal(find('[data-test-error-title]').textContent, 'Not Authorized'); }); andThen(() => { - click('.empty-message-body a'); + click('[data-test-error-message] a'); }); andThen(() => { diff --git a/ui/tests/acceptance/namespaces-test.js b/ui/tests/acceptance/namespaces-test.js index 12b0df203..9237fed75 100644 --- a/ui/tests/acceptance/namespaces-test.js +++ b/ui/tests/acceptance/namespaces-test.js @@ -42,11 +42,11 @@ test('the namespace switcher lists all namespaces', function(assert) { visit('/jobs'); andThen(() => { - assert.ok(find('.gutter .menu .namespace-switcher'), 'Namespace switcher found'); + assert.ok(find('[data-test-namespace-switcher]'), 'Namespace switcher found'); }); andThen(() => { - click('.gutter .menu .namespace-switcher .ember-power-select-trigger'); + click('[data-test-namespace-switcher] .ember-power-select-trigger'); }); andThen(() => { @@ -81,7 +81,7 @@ test('changing the namespace sets the namespace in localStorage', function(asser visit('/jobs'); - selectChoose('.namespace-switcher', namespace.name); + selectChoose('[data-test-namespace-switcher]', namespace.name); andThen(() => { assert.equal( window.localStorage.nomadActiveNamespace, @@ -106,7 +106,7 @@ test('changing the namespace refreshes the jobs list when on the jobs page', fun ); }); - selectChoose('.namespace-switcher', namespace.name); + selectChoose('[data-test-namespace-switcher]', namespace.name); andThen(() => { const requests = server.pretender.handledRequests.filter(req => req.url.startsWith('/v1/jobs')); diff --git a/ui/tests/acceptance/nodes-list-test.js b/ui/tests/acceptance/nodes-list-test.js index cc0ab00bc..dde20b744 100644 --- a/ui/tests/acceptance/nodes-list-test.js +++ b/ui/tests/acceptance/nodes-list-test.js @@ -1,4 +1,3 @@ -import $ from 'jquery'; import { click, find, findAll, currentURL, visit } from 'ember-native-dom-helpers'; import { test } from 'qunit'; import moduleForAcceptance from 'nomad-ui/tests/helpers/module-for-acceptance'; @@ -23,14 +22,15 @@ test('/clients should list one page of clients', function(assert) { visit('/clients'); andThen(() => { - assert.equal(findAll('.client-node-row').length, pageSize); - assert.ok(findAll('.pagination').length, 'Pagination found on the page'); + assert.equal(findAll('[data-test-client-node-row]').length, pageSize); + assert.ok(find('[data-test-pagination]'), 'Pagination found on the page'); const sortedNodes = server.db.nodes.sortBy('modifyIndex').reverse(); for (var nodeNumber = 0; nodeNumber < pageSize; nodeNumber++) { + const nodeRow = findAll('[data-test-client-node-row]')[nodeNumber]; assert.equal( - $(`.client-node-row:eq(${nodeNumber}) td:eq(0)`).text(), + nodeRow.querySelector('[data-test-client-id]').textContent.trim(), sortedNodes[nodeNumber].id.split('-')[0], 'Clients are ordered' ); @@ -45,17 +45,41 @@ test('each client record should show high-level info of the client', function(as visit('/clients'); andThen(() => { - const nodeRow = $(findAll('.client-node-row')[0]); + const nodeRow = find('[data-test-client-node-row]'); const allocations = server.db.allocations.where({ nodeId: node.id }); const { address, port } = ipParts(node.httpAddr); - assert.equal(nodeRow.find('td:eq(0)').text(), node.id.split('-')[0], 'ID'); - assert.equal(nodeRow.find('td:eq(1)').text(), node.name, 'Name'); - assert.equal(nodeRow.find('td:eq(2)').text(), node.status, 'Status'); - assert.equal(nodeRow.find('td:eq(3)').text(), address, 'Address'); - assert.equal(nodeRow.find('td:eq(4)').text(), port, 'Port'); - assert.equal(nodeRow.find('td:eq(5)').text(), node.datacenter, 'Datacenter'); - assert.equal(nodeRow.find('td:eq(6)').text(), allocations.length, '# Allocations'); + assert.equal( + nodeRow.querySelector('[data-test-client-id]').textContent.trim(), + node.id.split('-')[0], + 'ID' + ); + assert.equal( + nodeRow.querySelector('[data-test-client-name]').textContent.trim(), + node.name, + 'Name' + ); + assert.equal( + nodeRow.querySelector('[data-test-client-status]').textContent.trim(), + node.status, + 'Status' + ); + assert.equal( + nodeRow.querySelector('[data-test-client-address]').textContent.trim(), + address, + 'Address' + ); + assert.equal(nodeRow.querySelector('[data-test-client-port]').textContent.trim(), port, 'Port'); + assert.equal( + nodeRow.querySelector('[data-test-client-datacenter]').textContent.trim(), + node.datacenter, + 'Datacenter' + ); + assert.equal( + nodeRow.querySelector('[data-test-client-allocations]').textContent.trim(), + allocations.length, + '# Allocations' + ); }); }); @@ -65,7 +89,7 @@ test('each client should link to the client detail page', function(assert) { visit('/clients'); andThen(() => { - click(findAll('.client-node-row')[0]); + click('[data-test-client-node-row]'); }); andThen(() => { @@ -79,8 +103,8 @@ test('when there are no clients, there is an empty message', function(assert) { visit('/clients'); andThen(() => { - assert.ok(find('.empty-message')); - assert.equal(find('.empty-message-headline').textContent, 'No Clients'); + assert.ok(find('[data-test-empty-clients-list]')); + assert.equal(find('[data-test-empty-clients-list-headline]').textContent, 'No Clients'); }); }); @@ -97,8 +121,8 @@ test('when there are clients, but no matches for a search term, there is an empt }); andThen(() => { - assert.ok(find('.empty-message')); - assert.equal(find('.empty-message-headline').textContent, 'No Matches'); + assert.ok(find('[data-test-empty-clients-list]')); + assert.equal(find('[data-test-empty-clients-list-headline]').textContent, 'No Matches'); }); }); @@ -112,11 +136,11 @@ test('when accessing clients is forbidden, show a message with a link to the tok visit('/clients'); andThen(() => { - assert.equal(find('.empty-message-headline').textContent, 'Not Authorized'); + assert.equal(find('[data-test-error-title]').textContent, 'Not Authorized'); }); andThen(() => { - click('.empty-message-body a'); + click('[data-test-error-message] a'); }); andThen(() => { @@ -136,7 +160,7 @@ test('/servers should list all servers', function(assert) { visit('/servers'); andThen(() => { - assert.equal(findAll('.server-agent-row').length, pageSize); + assert.equal(findAll('[data-test-server-agent-row]').length, pageSize); const sortedAgents = server.db.agents .sort((a, b) => { @@ -150,10 +174,11 @@ test('/servers should list all servers', function(assert) { .reverse(); for (var agentNumber = 0; agentNumber < 8; agentNumber++) { + const serverRow = findAll('[data-test-server-agent-row]')[agentNumber]; assert.equal( - $(`.server-agent-row:eq(${agentNumber}) td:eq(0)`).text(), + serverRow.querySelector('[data-test-server-name]').textContent.trim(), sortedAgents[agentNumber].name, - 'Clients are ordered' + 'Servers are ordered' ); } }); @@ -166,14 +191,34 @@ test('each server should show high-level info of the server', function(assert) { visit('/servers'); andThen(() => { - const agentRow = $(findAll('.server-agent-row')[0]); + const agentRow = find('[data-test-server-agent-row]'); - assert.equal(agentRow.find('td:eq(0)').text(), agent.name, 'Name'); - assert.equal(agentRow.find('td:eq(1)').text(), agent.status, 'Status'); - assert.equal(agentRow.find('td:eq(2)').text(), 'True', 'Leader?'); - assert.equal(agentRow.find('td:eq(3)').text(), agent.address, 'Address'); - assert.equal(agentRow.find('td:eq(4)').text(), agent.serf_port, 'Serf Port'); - assert.equal(agentRow.find('td:eq(5)').text(), agent.tags.dc, 'Datacenter'); + assert.equal(agentRow.querySelector('[data-test-server-name]').textContent, agent.name, 'Name'); + assert.equal( + agentRow.querySelector('[data-test-server-status]').textContent, + agent.status, + 'Status' + ); + assert.equal( + agentRow.querySelector('[data-test-server-is-leader]').textContent, + 'True', + 'Leader?' + ); + assert.equal( + agentRow.querySelector('[data-test-server-address]').textContent, + agent.address, + 'Address' + ); + assert.equal( + agentRow.querySelector('[data-test-server-port]').textContent, + agent.serf_port, + 'Serf Port' + ); + assert.equal( + agentRow.querySelector('[data-test-server-datacenter]').textContent, + agent.tags.dc, + 'Datacenter' + ); }); }); @@ -183,7 +228,7 @@ test('each server should link to the server detail page', function(assert) { visit('/servers'); andThen(() => { - click(findAll('.server-agent-row')[0]); + click('[data-test-server-agent-row]'); }); andThen(() => { @@ -200,11 +245,11 @@ test('when accessing servers is forbidden, show a message with a link to the tok visit('/servers'); andThen(() => { - assert.equal(find('.empty-message-headline').textContent, 'Not Authorized'); + assert.equal(find('[data-test-error-title]').textContent, 'Not Authorized'); }); andThen(() => { - click('.empty-message-body a'); + click('[data-test-error-message] a'); }); andThen(() => { diff --git a/ui/tests/acceptance/server-detail-test.js b/ui/tests/acceptance/server-detail-test.js index 07c14324c..1ef079e4a 100644 --- a/ui/tests/acceptance/server-detail-test.js +++ b/ui/tests/acceptance/server-detail-test.js @@ -20,7 +20,7 @@ test('visiting /servers/:server_name', function(assert) { test('the server detail page should list all tags for the server', function(assert) { const tags = agent.tags; - assert.equal(findAll('.server-tags tbody tr').length, Object.keys(tags).length, '# of tags'); + assert.equal(findAll('[data-test-server-tag]').length, Object.keys(tags).length, '# of tags'); Object.keys(tags) .map(name => ({ name, value: tags[name] })) .sortBy('name') @@ -32,13 +32,21 @@ test('the server detail page should list all tags for the server', function(asse }); test('the list of servers from /servers should still be present', function(assert) { - assert.equal(findAll('.server-agent-row').length, server.db.agents.length, '# of servers'); + assert.equal( + findAll('[data-test-server-agent-row]').length, + server.db.agents.length, + '# of servers' + ); }); test('the active server should be denoted in the table', function(assert) { - assert.equal(findAll('.server-agent-row.is-active').length, 1, 'Only one active server'); assert.equal( - findAll('.server-agent-row.is-active td')[0].textContent, + findAll('[data-test-server-agent-row].is-active').length, + 1, + 'Only one active server' + ); + assert.equal( + find('[data-test-server-agent-row].is-active [data-test-server-name]').textContent.trim(), agent.name, 'Active server matches current route' ); @@ -51,9 +59,9 @@ test('when the server is not found, an error message is shown, but the URL persi andThen(() => { assert.equal(currentURL(), '/servers/not-a-real-server', 'The URL persists'); - assert.ok(find('.error-message'), 'Error message is shown'); + assert.ok(find('[data-test-error]'), 'Error message is shown'); assert.equal( - find('.error-message .title').textContent, + find('[data-test-error-title]').textContent, 'Not Found', 'Error message is for 404' ); diff --git a/ui/tests/acceptance/task-detail-test.js b/ui/tests/acceptance/task-detail-test.js index 84dd97708..b0cbc65da 100644 --- a/ui/tests/acceptance/task-detail-test.js +++ b/ui/tests/acceptance/task-detail-test.js @@ -1,4 +1,3 @@ -import $ from 'jquery'; import { click, findAll, currentURL, find, visit } from 'ember-native-dom-helpers'; import { test } from 'qunit'; import moduleForAcceptance from 'nomad-ui/tests/helpers/module-for-acceptance'; @@ -25,36 +24,40 @@ moduleForAcceptance('Acceptance | task detail', { test('/allocation/:id/:task_name should name the task and list high-level task information', function( assert ) { - assert.ok(find('.title').textContent.includes(task.name), 'Task name'); - assert.ok(find('.title').textContent.includes(task.state), 'Task state'); + assert.ok(find('[data-test-title]').textContent.includes(task.name), 'Task name'); + assert.ok(find('[data-test-state]').textContent.includes(task.state), 'Task state'); - const inlineDefinitions = findAll('.inline-definitions .pair'); assert.ok( - inlineDefinitions[0].textContent.includes(moment(task.startedAt).format('MM/DD/YY HH:mm:ss')), + find('[data-test-started-at]').textContent.includes( + moment(task.startedAt).format('MM/DD/YY HH:mm:ss') + ), 'Task started at' ); }); test('breadcrumbs includes allocations and link to the allocation detail page', function(assert) { - const breadcrumbs = findAll('.breadcrumb a'); assert.equal( - breadcrumbs[0].textContent.trim(), + find('[data-test-breadcrumb="allocations"]').textContent.trim(), 'Allocations', 'Allocations is the first breadcrumb' ); assert.equal( - breadcrumbs[0].getAttribute('href'), + find('[data-test-breadcrumb="allocations"]').getAttribute('href'), '#', "Allocations breadcrumb doesn't link anywhere" ); assert.equal( - breadcrumbs[1].textContent.trim(), + find('[data-test-breadcrumb="allocation"]').textContent.trim(), allocation.id.split('-')[0], 'Allocation short id is the second breadcrumb' ); - assert.equal(breadcrumbs[2].textContent.trim(), task.name, 'Task name is the third breadcrumb'); + assert.equal( + find('[data-test-breadcrumb="task"]').textContent.trim(), + task.name, + 'Task name is the third breadcrumb' + ); - click(breadcrumbs[1]); + click('[data-test-breadcrumb="allocation"]'); andThen(() => { assert.equal( currentURL(), @@ -73,7 +76,7 @@ test('the addresses table lists all reserved and dynamic ports', function(assert const addresses = reservedPorts.concat(dynamicPorts); assert.equal( - findAll('.addresses-list tbody tr').length, + findAll('[data-test-task-address]').length, addresses.length, 'All addresses are listed' ); @@ -88,28 +91,19 @@ test('each address row shows the label and value of the address', function(asser const dynamicPorts = taskResources.resources.Networks[0].DynamicPorts; const address = reservedPorts.concat(dynamicPorts).sortBy('Label')[0]; - const addressRow = $(find('.addresses-list tbody tr')); + const addressRow = find('[data-test-task-address]'); assert.equal( - addressRow - .find('td:eq(0)') - .text() - .trim(), + addressRow.querySelector('[data-test-task-address-is-dynamic]').textContent.trim(), reservedPorts.includes(address) ? 'No' : 'Yes', 'Dynamic port is denoted as such' ); assert.equal( - addressRow - .find('td:eq(1)') - .text() - .trim(), + addressRow.querySelector('[data-test-task-address-name]').textContent.trim(), address.Label, 'Label' ); assert.equal( - addressRow - .find('td:eq(2)') - .text() - .trim(), + addressRow.querySelector('[data-test-task-address-address]').textContent.trim(), `${ipParts(node.httpAddr).address}:${address.Value}`, 'Value' ); @@ -119,7 +113,7 @@ test('the events table lists all recent events', function(assert) { const events = server.db.taskEvents.where({ taskStateId: task.id }); assert.equal( - findAll('.task-events tbody tr').length, + findAll('[data-test-task-event]').length, events.length, `Lists ${events.length} events` ); @@ -129,29 +123,20 @@ test('each recent event should list the time, type, and description of the event assert ) { const event = server.db.taskEvents.where({ taskStateId: task.id })[0]; - const recentEvent = $('.task-events tbody tr:last'); + const recentEvent = findAll('[data-test-task-event]').get('lastObject'); assert.equal( - recentEvent - .find('td:eq(0)') - .text() - .trim(), + recentEvent.querySelector('[data-test-task-event-time]').textContent.trim(), moment(event.time / 1000000).format('MM/DD/YY HH:mm:ss'), 'Event timestamp' ); assert.equal( - recentEvent - .find('td:eq(1)') - .text() - .trim(), + recentEvent.querySelector('[data-test-task-event-type]').textContent.trim(), event.type, 'Event type' ); assert.equal( - recentEvent - .find('td:eq(2)') - .text() - .trim(), + recentEvent.querySelector('[data-test-task-event-message]').textContent.trim(), event.message, 'Event message' ); @@ -171,9 +156,9 @@ test('when the allocation is not found, the application errors', function(assert `/allocations/not-a-real-allocation/${task.name}`, 'The URL persists' ); - assert.ok(find('.error-message'), 'Error message is shown'); + assert.ok(find('[data-test-error]'), 'Error message is shown'); assert.equal( - find('.error-message .title').textContent, + find('[data-test-error-title]').textContent, 'Not Found', 'Error message is for 404' ); @@ -194,9 +179,9 @@ test('when the allocation is found but the task is not, the application errors', `/allocations/${allocation.id}/not-a-real-task-name`, 'The URL persists' ); - assert.ok(find('.error-message'), 'Error message is shown'); + assert.ok(find('[data-test-error]'), 'Error message is shown'); assert.equal( - find('.error-message .title').textContent, + find('[data-test-error-title]').textContent, 'Not Found', 'Error message is for 404' ); @@ -216,5 +201,5 @@ moduleForAcceptance('Acceptance | task detail (no addresses)', { }); test('when the task has no addresses, the addresses table is not shown', function(assert) { - assert.notOk(find('.addresses-list'), 'No addresses table'); + assert.notOk(find('[data-test-task-addresses]'), 'No addresses table'); }); diff --git a/ui/tests/acceptance/task-group-detail-test.js b/ui/tests/acceptance/task-group-detail-test.js index 1757f42a9..c9665b966 100644 --- a/ui/tests/acceptance/task-group-detail-test.js +++ b/ui/tests/acceptance/task-group-detail-test.js @@ -1,4 +1,3 @@ -import $ from 'jquery'; import { click, find, findAll, fillIn, currentURL, visit } from 'ember-native-dom-helpers'; import { test } from 'qunit'; import moduleForAcceptance from 'nomad-ui/tests/helpers/module-for-acceptance'; @@ -56,22 +55,22 @@ test('/jobs/:id/:task-group should list high-level metrics for the allocation', const totalDisk = taskGroup.ephemeralDisk.SizeMB; assert.equal( - findAll('.inline-definitions .pair')[0].textContent, + find('[data-test-task-group-tasks]').textContent, `# Tasks ${tasks.length}`, '# Tasks' ); assert.equal( - findAll('.inline-definitions .pair')[1].textContent, + find('[data-test-task-group-cpu]').textContent, `Reserved CPU ${totalCPU} MHz`, 'Aggregated CPU reservation for all tasks' ); assert.equal( - findAll('.inline-definitions .pair')[2].textContent, + find('[data-test-task-group-mem]').textContent, `Reserved Memory ${totalMemory} MiB`, 'Aggregated Memory reservation for all tasks' ); assert.equal( - findAll('.inline-definitions .pair')[3].textContent, + find('[data-test-task-group-disk]').textContent, `Reserved Disk ${totalDisk} MiB`, 'Aggregated Disk reservation for all tasks' ); @@ -79,24 +78,24 @@ test('/jobs/:id/:task-group should list high-level metrics for the allocation', test('/jobs/:id/:task-group should have breadcrumbs for job and jobs', function(assert) { assert.equal( - findAll('.breadcrumb a')[0].textContent.trim(), + find('[data-test-breadcrumb="Jobs"]').textContent.trim(), 'Jobs', 'First breadcrumb says jobs' ); assert.equal( - findAll('.breadcrumb a')[1].textContent.trim(), + find(`[data-test-breadcrumb="${job.name}"]`).textContent.trim(), job.name, 'Second breadcrumb says the job name' ); assert.equal( - findAll('.breadcrumb a')[2].textContent.trim(), + find(`[data-test-breadcrumb="${taskGroup.name}"]`).textContent.trim(), taskGroup.name, 'Third breadcrumb says the job name' ); }); test('/jobs/:id/:task-group first breadcrumb should link to jobs', function(assert) { - click(findAll('.breadcrumb a')[0]); + click('[data-test-breadcrumb="Jobs"]'); andThen(() => { assert.equal(currentURL(), '/jobs', 'First breadcrumb links back to jobs'); }); @@ -105,7 +104,7 @@ test('/jobs/:id/:task-group first breadcrumb should link to jobs', function(asse test('/jobs/:id/:task-group second breadcrumb should link to the job for the task group', function( assert ) { - click(findAll('.breadcrumb a')[1]); + click(`[data-test-breadcrumb="${job.name}"]`); andThen(() => { assert.equal( currentURL(), @@ -135,7 +134,7 @@ test('/jobs/:id/:task-group should list one page of allocations for the task gro ); assert.equal( - findAll('.allocations tbody tr').length, + findAll('[data-test-allocation]').length, pageSize, 'All allocations for the task group' ); @@ -144,60 +143,42 @@ test('/jobs/:id/:task-group should list one page of allocations for the task gro test('each allocation should show basic information about the allocation', function(assert) { const allocation = allocations.sortBy('modifyIndex').reverse()[0]; - const allocationRow = $(findAll('.allocations tbody tr')[0]); + const allocationRow = find('[data-test-allocation]'); andThen(() => { assert.equal( - allocationRow - .find('td:eq(0)') - .text() - .trim(), + allocationRow.querySelector('[data-test-short-id]').textContent.trim(), allocation.id.split('-')[0], 'Allocation short id' ); assert.equal( - allocationRow - .find('td:eq(1)') - .text() - .trim(), + allocationRow.querySelector('[data-test-modify-time]').textContent.trim(), moment(allocation.modifyTime / 1000000).format('MM/DD HH:mm:ss'), 'Allocation modify time' ); assert.equal( - allocationRow - .find('td:eq(2)') - .text() - .trim(), + allocationRow.querySelector('[data-test-name]').textContent.trim(), allocation.name, 'Allocation name' ); assert.equal( - allocationRow - .find('td:eq(3)') - .text() - .trim(), + allocationRow.querySelector('[data-test-client-status]').textContent.trim(), allocation.clientStatus, 'Client status' ); assert.equal( - allocationRow - .find('td:eq(4)') - .text() - .trim(), + allocationRow.querySelector('[data-test-job-version]').textContent.trim(), allocation.jobVersion, 'Job Version' ); assert.equal( - allocationRow - .find('td:eq(5)') - .text() - .trim(), + allocationRow.querySelector('[data-test-client]').textContent.trim(), server.db.nodes.find(allocation.nodeId).id.split('-')[0], 'Node ID' ); }); - click(allocationRow.find('td:eq(5) a').get(0)); + click(allocationRow.querySelector('[data-test-client] a')); andThen(() => { assert.equal(currentURL(), `/clients/${allocation.nodeId}`, 'Node links to node page'); @@ -208,7 +189,7 @@ test('each allocation should show stats about the allocation, retrieved directly assert ) { const allocation = allocations.sortBy('name')[0]; - const allocationRow = $(findAll('.allocations tbody tr')[0]); + const allocationRow = find('[data-test-allocation]'); const allocStats = server.db.clientAllocationStats.find(allocation.id); const tasks = taskGroup.taskIds.map(id => server.db.tasks.find(id)); @@ -216,31 +197,25 @@ test('each allocation should show stats about the allocation, retrieved directly const memoryUsed = tasks.reduce((sum, task) => sum + task.Resources.MemoryMB, 0); assert.equal( - allocationRow - .find('td:eq(6)') - .text() - .trim(), + allocationRow.querySelector('[data-test-cpu]').textContent.trim(), Math.floor(allocStats.resourceUsage.CpuStats.TotalTicks) / cpuUsed, 'CPU %' ); assert.equal( - allocationRow.find('td:eq(6) .tooltip').attr('aria-label'), + allocationRow.querySelector('[data-test-cpu] .tooltip').getAttribute('aria-label'), `${Math.floor(allocStats.resourceUsage.CpuStats.TotalTicks)} / ${cpuUsed} MHz`, 'Detailed CPU information is in a tooltip' ); assert.equal( - allocationRow - .find('td:eq(7)') - .text() - .trim(), + allocationRow.querySelector('[data-test-mem]').textContent.trim(), allocStats.resourceUsage.MemoryStats.RSS / 1024 / 1024 / memoryUsed, 'Memory used' ); assert.equal( - allocationRow.find('td:eq(7) .tooltip').attr('aria-label'), + allocationRow.querySelector('[data-test-mem] .tooltip').getAttribute('aria-label'), `${formatBytes([allocStats.resourceUsage.MemoryStats.RSS])} / ${memoryUsed} MiB`, 'Detailed memory information is in a tooltip' ); @@ -258,7 +233,7 @@ test('when the allocation search has no matches, there is an empty message', fun fillIn('.search-box input', 'zzzzzz'); andThen(() => { - assert.ok(find('.allocations .empty-message')); - assert.equal(find('.allocations .empty-message-headline').textContent, 'No Matches'); + assert.ok(find('[data-test-empty-allocations-list]')); + assert.equal(find('[data-test-empty-allocations-list-headline]').textContent, 'No Matches'); }); }); diff --git a/ui/tests/acceptance/task-logs-test.js b/ui/tests/acceptance/task-logs-test.js index 9d75fa391..e59fb6af2 100644 --- a/ui/tests/acceptance/task-logs-test.js +++ b/ui/tests/acceptance/task-logs-test.js @@ -22,7 +22,7 @@ moduleForAcceptance('Acceptance | task logs', { test('/allocation/:id/:task_name/logs should have a log component', function(assert) { assert.equal(currentURL(), `/allocations/${allocation.id}/${task.name}/logs`, 'No redirect'); - assert.ok(find('.task-log'), 'Task log component found'); + assert.ok(find('[data-test-task-log]'), 'Task log component found'); }); test('the stdout log immediately starts streaming', function(assert) { diff --git a/ui/tests/acceptance/token-test.js b/ui/tests/acceptance/token-test.js index 028f0d708..110d72010 100644 --- a/ui/tests/acceptance/token-test.js +++ b/ui/tests/acceptance/token-test.js @@ -1,4 +1,3 @@ -import $ from 'jquery'; import { find, findAll, fillIn, click, visit } from 'ember-native-dom-helpers'; import { test, skip } from 'ember-qunit'; import moduleForAcceptance from 'nomad-ui/tests/helpers/module-for-acceptance'; @@ -26,8 +25,8 @@ test('the token form sets the token in session storage', function(assert) { andThen(() => { assert.ok(window.sessionStorage.nomadTokenSecret == null, 'No token secret set'); - fillIn('.token-secret', secretId); - click('.token-submit'); + fillIn('[data-test-token-secret]', secretId); + click('[data-test-token-submit]'); andThen(() => { assert.equal(window.sessionStorage.nomadTokenSecret, secretId, 'Token secret was set'); @@ -55,8 +54,8 @@ skip('the X-Nomad-Token header gets sent with requests once it is set', function visit('/settings/tokens'); andThen(() => { - fillIn('.token-secret', secretId); - click('.token-submit'); + fillIn('[data-test-token-secret]', secretId); + click('[data-test-token-submit]'); }); visit(`/jobs/${job.id}`); @@ -85,17 +84,17 @@ test('an error message is shown when authenticating a token fails', function(ass visit('/settings/tokens'); andThen(() => { - fillIn('.token-secret', bogusSecret); - click('.token-submit'); + fillIn('[data-test-token-secret]', bogusSecret); + click('[data-test-token-submit]'); andThen(() => { assert.ok( window.sessionStorage.nomadTokenSecret == null, 'Token secret is discarded on failure' ); - assert.ok(find('.token-error'), 'Token error message is shown'); - assert.notOk(find('.token-success'), 'Token success message is not shown'); - assert.notOk(find('.token-policy'), 'No token policies are shown'); + assert.ok(find('[data-test-token-error]'), 'Token error message is shown'); + assert.notOk(find('[data-test-token-success]'), 'Token success message is not shown'); + assert.notOk(find('[data-test-token-policy]'), 'No token policies are shown'); }); }); }); @@ -108,14 +107,14 @@ test('a success message and a special management token message are shown when au visit('/settings/tokens'); andThen(() => { - fillIn('.token-secret', secretId); - click('.token-submit'); + fillIn('[data-test-token-secret]', secretId); + click('[data-test-token-submit]'); andThen(() => { - assert.ok(find('.token-success'), 'Token success message is shown'); - assert.notOk(find('.token-error'), 'Token error message is not shown'); - assert.ok(find('.token-management-message'), 'Token management message is shown'); - assert.notOk(find('.token-policy'), 'No token policies are shown'); + assert.ok(find('[data-test-token-success]'), 'Token success message is shown'); + assert.notOk(find('[data-test-token-error]'), 'Token error message is not shown'); + assert.ok(find('[data-test-token-management-message]'), 'Token management message is shown'); + assert.notOk(find('[data-test-token-policy]'), 'No token policies are shown'); }); }); }); @@ -130,39 +129,36 @@ test('a success message and associated policies are shown when authenticating su visit('/settings/tokens'); andThen(() => { - fillIn('.token-secret', secretId); - click('.token-submit'); + fillIn('[data-test-token-secret]', secretId); + click('[data-test-token-submit]'); andThen(() => { - assert.ok(find('.token-success'), 'Token success message is shown'); - assert.notOk(find('.token-error'), 'Token error message is not shown'); - assert.notOk(find('.token-management-message'), 'Token management message is not shown'); + assert.ok(find('[data-test-token-success]'), 'Token success message is shown'); + assert.notOk(find('[data-test-token-error]'), 'Token error message is not shown'); + assert.notOk( + find('[data-test-token-management-message]'), + 'Token management message is not shown' + ); assert.equal( - findAll('.token-policy').length, + findAll('[data-test-token-policy]').length, clientToken.policies.length, 'Each policy associated with the token is listed' ); - const policyElement = $(find('.token-policy')); + const policyElement = find('[data-test-token-policy]'); assert.equal( - policyElement - .find('.boxed-section-head') - .text() - .trim(), + policyElement.querySelector('[data-test-policy-name]').textContent.trim(), policy.name, 'Policy Name' ); assert.equal( - policyElement - .find('.boxed-section-body p.content') - .text() - .trim(), + policyElement.querySelector('[data-test-policy-description]').textContent.trim(), policy.description, 'Policy Description' ); assert.equal( - policyElement.find('.boxed-section-body pre code').text(), + policyElement.querySelector('[data-test-policy-rules]').textContent, policy.rules, 'Policy Rules' ); @@ -182,8 +178,8 @@ test('setting a token clears the store', function(assert) { visit('/settings/tokens'); andThen(() => { - fillIn('.token-secret', secretId); - click('.token-submit'); + fillIn('[data-test-token-secret]', secretId); + click('[data-test-token-submit]'); }); // Don't return jobs from the API the second time around @@ -196,7 +192,7 @@ test('setting a token clears the store', function(assert) { visit('/jobs'); // If jobs are lingering in the store, they would show up - assert.notOk(find('.job-row'), 'No jobs found'); + assert.notOk(find('[data-test-job-row]'), 'No jobs found'); }); function getHeader({ requestHeaders }, name) { From efbe0c1faf31c1fc0a2facabe58094154b4e6e3a Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Fri, 5 Jan 2018 15:58:58 -0800 Subject: [PATCH 107/136] Switch from phantomjs to headless chrome --- ui/testem.js | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/ui/testem.js b/ui/testem.js index 9a0e1deb1..630bfd548 100644 --- a/ui/testem.js +++ b/ui/testem.js @@ -2,6 +2,21 @@ module.exports = { test_page: 'tests/index.html?hidepassed', disable_watching: true, - launch_in_ci: ['PhantomJS'], + launch_in_ci: ['Chrome'], launch_in_dev: ['Chrome'], + browser_args: { + // New format in testem/master, but not in a release yet + // Chrome: { + // ci: ['--headless', '--disable-gpu', '--remote-debugging-port=9222', '--window-size=1440,900'], + // }, + Chrome: { + mode: 'ci', + args: [ + '--headless', + '--disable-gpu', + '--remote-debugging-port=9222', + '--window-size=1440,900', + ], + }, + }, }; From 14adc01f68ec4469a7b25616169b397707e872aa Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Fri, 5 Jan 2018 17:24:57 -0800 Subject: [PATCH 108/136] Upgrade testing related dependencies --- ui/package.json | 14 +--- ui/yarn.lock | 208 +++++++++++++++++++++++++++++++++++++----------- 2 files changed, 164 insertions(+), 58 deletions(-) diff --git a/ui/package.json b/ui/package.json index 5ae3fa696..db06268b6 100644 --- a/ui/package.json +++ b/ui/package.json @@ -20,10 +20,7 @@ "prettier --single-quote --trailing-comma es5 --print-width 100 --write", "git add" ], - "ui/app/styles/**/*.*": [ - "prettier --write", - "git add" - ] + "ui/app/styles/**/*.*": ["prettier --write", "git add"] } }, "devDependencies": { @@ -44,7 +41,7 @@ "ember-cli-inject-live-reload": "^1.4.1", "ember-cli-mirage": "^0.4.1", "ember-cli-moment-shim": "^3.5.0", - "ember-cli-qunit": "^4.0.0", + "ember-cli-qunit": "^4.2.1", "ember-cli-sass": "^7.1.2", "ember-cli-shims": "^1.2.0", "ember-cli-sri": "^2.1.0", @@ -63,7 +60,7 @@ "ember-native-dom-helpers": "^0.5.4", "ember-power-select": "^1.10.4", "ember-resolver": "^4.5.0", - "ember-sinon": "^0.7.0", + "ember-sinon": "^1.0.1", "ember-source": "~2.17.0", "ember-test-selectors": "^0.3.8", "ember-truth-helpers": "^2.0.0", @@ -82,9 +79,6 @@ }, "private": true, "ember-addon": { - "paths": [ - "lib/bulma", - "lib/calendar" - ] + "paths": ["lib/bulma", "lib/calendar"] } } diff --git a/ui/yarn.lock b/ui/yarn.lock index 016fbf6bf..cbbce95f5 100644 --- a/ui/yarn.lock +++ b/ui/yarn.lock @@ -2,6 +2,14 @@ # yarn lockfile v1 +"@ember/test-helpers@^0.7.9": + version "0.7.13" + resolved "https://registry.yarnpkg.com/@ember/test-helpers/-/test-helpers-0.7.13.tgz#89523a101b5bd731e9dcaf7d0c57155b6386a4e3" + dependencies: + broccoli-funnel "^2.0.1" + ember-cli-babel "^6.10.0" + ember-cli-htmlbars-inline-precompile "^1.0.0" + "@glimmer/di@^0.2.0": version "0.2.0" resolved "https://registry.yarnpkg.com/@glimmer/di/-/di-0.2.0.tgz#73bfd4a6ee4148a80bf092e8a5d29bcac9d4ce7e" @@ -345,6 +353,10 @@ async@~0.2.9: version "0.2.10" resolved "https://registry.yarnpkg.com/async/-/async-0.2.10.tgz#b6bbe0b0674b9d719708ca38de8c237cb526c3d1" +async@~1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/async/-/async-1.0.0.tgz#f8fc04ca3a13784ade9e1641af98578cfbd647a9" + asynckit@^0.4.0: version "0.4.0" resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" @@ -1327,7 +1339,7 @@ broccoli-funnel@^1.0.0, broccoli-funnel@^1.0.1, broccoli-funnel@^1.0.2, broccoli symlink-or-copy "^1.0.0" walk-sync "^0.3.1" -broccoli-funnel@^2.0.0: +broccoli-funnel@^2.0.0, broccoli-funnel@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/broccoli-funnel/-/broccoli-funnel-2.0.1.tgz#6823c73b675ef78fffa7ab800f083e768b51d449" dependencies: @@ -1371,7 +1383,7 @@ broccoli-lint-eslint@^4.2.1: lodash.defaultsdeep "^4.6.0" md5-hex "^2.0.0" -broccoli-merge-trees@^1.0.0, broccoli-merge-trees@^1.1.0, broccoli-merge-trees@^1.1.1, broccoli-merge-trees@^1.1.2, broccoli-merge-trees@^1.2.1: +broccoli-merge-trees@^1.0.0, broccoli-merge-trees@^1.1.0, broccoli-merge-trees@^1.1.1, broccoli-merge-trees@^1.1.2: version "1.2.4" resolved "https://registry.yarnpkg.com/broccoli-merge-trees/-/broccoli-merge-trees-1.2.4.tgz#a001519bb5067f06589d91afa2942445a2d0fdb5" dependencies: @@ -1709,6 +1721,21 @@ buffer@^4.1.0: ieee754 "^1.1.4" isarray "^1.0.0" +build@^0.1.4: + version "0.1.4" + resolved "https://registry.yarnpkg.com/build/-/build-0.1.4.tgz#707fe026ffceddcacbfdcdf356eafda64f151046" + dependencies: + cssmin "0.3.x" + jsmin "1.x" + jxLoader "*" + moo-server "*" + promised-io "*" + timespan "2.x" + uglify-js "1.x" + walker "1.x" + winston "*" + wrench "1.3.x" + builtin-modules@^1.0.0: version "1.1.1" resolved "https://registry.yarnpkg.com/builtin-modules/-/builtin-modules-1.1.1.tgz#270f076c5a72c02f5b65a47df94c5fe3a278892f" @@ -2009,7 +2036,7 @@ color-name@^1.1.1: version "1.1.3" resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.3.tgz#a7d0558bd89c42f795dd42328f740831ca53bc25" -colors@1.0.3: +colors@1.0.3, colors@1.0.x: version "1.0.3" resolved "https://registry.yarnpkg.com/colors/-/colors-1.0.3.tgz#0433f44d809680fdeb60ed260f1b0c262e82a40b" @@ -2048,6 +2075,12 @@ commander@~2.12.1: version "2.12.2" resolved "https://registry.yarnpkg.com/commander/-/commander-2.12.2.tgz#0f5946c427ed9ec0d91a46bb9def53e54650e555" +common-tags@^1.4.0: + version "1.6.0" + resolved "https://registry.yarnpkg.com/common-tags/-/common-tags-1.6.0.tgz#788e4bcc582f16993e5b2c92f76b1ccb80731537" + dependencies: + babel-runtime "^6.26.0" + commoner@~0.10.3: version "0.10.8" resolved "https://registry.yarnpkg.com/commoner/-/commoner-0.10.8.tgz#34fc3672cd24393e8bb47e70caa0293811f4f2c5" @@ -2295,6 +2328,10 @@ crypto-random-string@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/crypto-random-string/-/crypto-random-string-1.0.0.tgz#a230f64f568310e1498009940790ec99545bca7e" +cssmin@0.3.x: + version "0.3.2" + resolved "https://registry.yarnpkg.com/cssmin/-/cssmin-0.3.2.tgz#ddce4c547b510ae0d594a8f1fbf8aaf8e2c5c00d" + csso@~2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/csso/-/csso-2.0.0.tgz#178b43a44621221c27756086f531e02f42900ee8" @@ -2308,6 +2345,10 @@ currently-unhandled@^0.4.1: dependencies: array-find-index "^1.0.1" +cycle@1.0.x: + version "1.0.3" + resolved "https://registry.yarnpkg.com/cycle/-/cycle-1.0.3.tgz#21e80b2be8580f98b468f379430662b046c34ad2" + d3-color@1: version "1.0.3" resolved "https://registry.yarnpkg.com/d3-color/-/d3-color-1.0.3.tgz#bc7643fca8e53a8347e2fbdaffa236796b58509b" @@ -2743,7 +2784,7 @@ ember-cli-get-dependency-depth@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/ember-cli-get-dependency-depth/-/ember-cli-get-dependency-depth-1.0.0.tgz#e0afecf82a2d52f00f28ab468295281aec368d11" -ember-cli-htmlbars-inline-precompile@^1.0.2: +ember-cli-htmlbars-inline-precompile@^1.0.0, ember-cli-htmlbars-inline-precompile@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/ember-cli-htmlbars-inline-precompile/-/ember-cli-htmlbars-inline-precompile-1.0.2.tgz#5b544f664d5d9911f08cd979c5f70d8cb0ca2add" dependencies: @@ -2883,20 +2924,12 @@ ember-cli-preprocess-registry@^3.1.0: process-relative-require "^1.0.0" silent-error "^1.0.0" -ember-cli-qunit@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/ember-cli-qunit/-/ember-cli-qunit-4.0.0.tgz#1f0022469a5bd64f627b8102880a25e94e533a3b" +ember-cli-qunit@^4.2.1: + version "4.2.1" + resolved "https://registry.yarnpkg.com/ember-cli-qunit/-/ember-cli-qunit-4.2.1.tgz#89580e6eb157ee98b9eefbd48fba9bb75ea64544" dependencies: - broccoli-funnel "^1.0.1" - broccoli-merge-trees "^2.0.0" - ember-cli-babel "^6.0.0-beta.7" - ember-cli-test-loader "^2.0.0" - ember-cli-version-checker "^1.1.4" - ember-qunit "^2.1.3" - qunit-notifications "^0.1.1" - qunitjs "^2.0.1" - resolve "^1.1.6" - silent-error "^1.0.0" + ember-cli-babel "^6.8.1" + ember-qunit "^3.2.2" ember-cli-sass@^6.1.3: version "6.2.0" @@ -2965,7 +2998,7 @@ ember-cli-test-info@^1.0.0: dependencies: ember-cli-string-utils "^1.0.0" -ember-cli-test-loader@^2.0.0: +ember-cli-test-loader@^2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/ember-cli-test-loader/-/ember-cli-test-loader-2.2.0.tgz#3fb8d5d1357e4460d3f0a092f5375e71b6f7c243" dependencies: @@ -3301,11 +3334,17 @@ ember-power-select@^1.10.4: ember-text-measurer "^0.4.0" ember-truth-helpers "^2.0.0" -ember-qunit@^2.1.3: - version "2.2.0" - resolved "https://registry.yarnpkg.com/ember-qunit/-/ember-qunit-2.2.0.tgz#3cdf400031c93a38de781a7304819738753b7f99" +ember-qunit@^3.2.2: + version "3.2.2" + resolved "https://registry.yarnpkg.com/ember-qunit/-/ember-qunit-3.2.2.tgz#96c8818ecfa3894580a3dc805f7e7f1e82e07c4a" dependencies: - ember-test-helpers "^0.6.3" + "@ember/test-helpers" "^0.7.9" + broccoli-funnel "^2.0.1" + broccoli-merge-trees "^2.0.0" + common-tags "^1.4.0" + ember-cli-babel "^6.3.0" + ember-cli-test-loader "^2.2.0" + qunit "^2.4.1" ember-resolver@^4.5.0: version "4.5.0" @@ -3340,14 +3379,14 @@ ember-runtime-enumerable-includes-polyfill@^2.0.0: ember-cli-babel "^6.0.0" ember-cli-version-checker "^1.1.6" -ember-sinon@^0.7.0: - version "0.7.0" - resolved "https://registry.yarnpkg.com/ember-sinon/-/ember-sinon-0.7.0.tgz#41b83b5b1c71626db26e8ffb4a52cdab9c039a29" +ember-sinon@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/ember-sinon/-/ember-sinon-1.0.1.tgz#056390eacc9367b4c3955ce1cb5a04246f8197f5" dependencies: - broccoli-funnel "^1.1.0" - broccoli-merge-trees "^1.2.1" - ember-cli-babel "^5.1.7" - sinon "^2.1.0" + broccoli-funnel "^2.0.0" + broccoli-merge-trees "^2.0.0" + ember-cli-babel "^6.3.0" + sinon "^3.2.1" ember-source@~2.17.0: version "2.17.0" @@ -3369,10 +3408,6 @@ ember-source@~2.17.0: jquery "^3.2.1" resolve "^1.3.3" -ember-test-helpers@^0.6.3: - version "0.6.3" - resolved "https://registry.yarnpkg.com/ember-test-helpers/-/ember-test-helpers-0.6.3.tgz#f864cdf6f4e75f3f8768d6537785b5ab6e82d907" - ember-test-selectors@^0.3.8: version "0.3.8" resolved "https://registry.yarnpkg.com/ember-test-selectors/-/ember-test-selectors-0.3.8.tgz#1e8ae3e78c64bacc4bbfe87f9973c85805699db2" @@ -3892,6 +3927,10 @@ extsprintf@1.3.0, extsprintf@^1.2.0: version "1.3.0" resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.3.0.tgz#96918440e3041a7a414f8c52e3c574eb3c3e1e05" +eyes@0.1.x: + version "0.1.8" + resolved "https://registry.yarnpkg.com/eyes/-/eyes-0.1.8.tgz#62cf120234c683785d902348a800ef3e0cc20bc0" + fake-xml-http-request@^1.4.0, fake-xml-http-request@^1.6.0: version "1.6.0" resolved "https://registry.yarnpkg.com/fake-xml-http-request/-/fake-xml-http-request-1.6.0.tgz#bd0ac79ae3e2660098282048a12c730a6f64d550" @@ -4067,7 +4106,7 @@ form-data@~2.1.1: combined-stream "^1.0.5" mime-types "^2.1.12" -formatio@1.2.0: +formatio@1.2.0, formatio@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/formatio/-/formatio-1.2.0.tgz#f3b2167d9068c4698a8d51f4f760a39a54d818eb" dependencies: @@ -4874,7 +4913,7 @@ isobject@^2.0.0: dependencies: isarray "1.0.0" -isstream@~0.1.2: +isstream@0.1.x, isstream@~0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/isstream/-/isstream-0.1.2.tgz#47e63f7af55afa6f92e1500e690eb8b8529c099a" @@ -4906,6 +4945,10 @@ js-tokens@^3.0.0, js-tokens@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.2.tgz#9866df395102130e38f7f996bceb65443209c25b" +js-yaml@0.3.x: + version "0.3.7" + resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-0.3.7.tgz#d739d8ee86461e54b354d6a7d7d1f2ad9a167f62" + js-yaml@^3.2.5, js-yaml@^3.2.7, js-yaml@^3.4.3, js-yaml@^3.6.1, js-yaml@^3.9.1: version "3.9.1" resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.9.1.tgz#08775cebdfdd359209f0d2acd383c8f86a6904a0" @@ -4944,6 +4987,10 @@ jsesc@~0.5.0: version "0.5.0" resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-0.5.0.tgz#e7dee66e35d6fc16f710fe91d5cf69f70f08911d" +jsmin@1.x: + version "1.0.1" + resolved "https://registry.yarnpkg.com/jsmin/-/jsmin-1.0.1.tgz#e7bd0dcd6496c3bf4863235bf461a3d98aa3b98c" + json-formatter-js@^2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/json-formatter-js/-/json-formatter-js-2.2.0.tgz#1ed987223ef2f1d945304597faae78b580a8212b" @@ -5017,6 +5064,19 @@ jsprim@^1.2.2: json-schema "0.2.3" verror "1.10.0" +just-extend@^1.1.26: + version "1.1.27" + resolved "https://registry.yarnpkg.com/just-extend/-/just-extend-1.1.27.tgz#ec6e79410ff914e472652abfa0e603c03d60e905" + +jxLoader@*: + version "0.1.1" + resolved "https://registry.yarnpkg.com/jxLoader/-/jxLoader-0.1.1.tgz#0134ea5144e533b594fc1ff25ff194e235c53ecd" + dependencies: + js-yaml "0.3.x" + moo-server "1.3.x" + promised-io "*" + walker "1.x" + kind-of@^3.0.2: version "3.2.2" resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-3.2.2.tgz#31ea21a734bab9bbb0f32466d893aea51e4a3c64" @@ -5422,6 +5482,10 @@ lodash.forown@~2.3.0: lodash._objecttypes "~2.3.0" lodash.keys "~2.3.0" +lodash.get@^4.4.2: + version "4.4.2" + resolved "https://registry.yarnpkg.com/lodash.get/-/lodash.get-4.4.2.tgz#2d177f652fa31e939b4438d5341499dfa3825e99" + lodash.identity@~2.3.0: version "2.3.0" resolved "https://registry.yarnpkg.com/lodash.identity/-/lodash.identity-2.3.0.tgz#6b01a210c9485355c2a913b48b6711219a173ded" @@ -5582,6 +5646,10 @@ lolex@^1.6.0: version "1.6.0" resolved "https://registry.yarnpkg.com/lolex/-/lolex-1.6.0.tgz#3a9a0283452a47d7439e72731b9e07d7386e49f6" +lolex@^2.1.2: + version "2.3.1" + resolved "https://registry.yarnpkg.com/lolex/-/lolex-2.3.1.tgz#3d2319894471ea0950ef64692ead2a5318cff362" + longest@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/longest/-/longest-1.0.1.tgz#30a0b2da38f73770e8294a0d22e6625ed77d0097" @@ -5858,6 +5926,10 @@ moment-timezone@^0.5.13: version "2.18.1" resolved "https://registry.yarnpkg.com/moment/-/moment-2.18.1.tgz#c36193dd3ce1c2eed2adb7c802dbbc77a81b1c0f" +moo-server@*, moo-server@1.3.x: + version "1.3.0" + resolved "https://registry.yarnpkg.com/moo-server/-/moo-server-1.3.0.tgz#5dc79569565a10d6efed5439491e69d2392e58f1" + morgan@^1.8.1: version "1.8.2" resolved "https://registry.yarnpkg.com/morgan/-/morgan-1.8.2.tgz#784ac7734e4a453a9c6e6e8680a9329275c8b687" @@ -5912,6 +5984,16 @@ negotiator@0.6.1: version "0.6.1" resolved "https://registry.yarnpkg.com/negotiator/-/negotiator-0.6.1.tgz#2b327184e8992101177b28563fb5e7102acd0ca9" +nise@^1.0.1: + version "1.2.0" + resolved "https://registry.yarnpkg.com/nise/-/nise-1.2.0.tgz#079d6cadbbcb12ba30e38f1c999f36ad4d6baa53" + dependencies: + formatio "^1.2.0" + just-extend "^1.1.26" + lolex "^1.6.0" + path-to-regexp "^1.7.0" + text-encoding "^0.6.4" + node-fetch@^1.3.3: version "1.7.2" resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-1.7.2.tgz#c54e9aac57e432875233525f3c891c4159ffefd7" @@ -6449,6 +6531,10 @@ promise-map-series@^0.2.0, promise-map-series@^0.2.1: dependencies: rsvp "^3.0.14" +promised-io@*: + version "0.3.5" + resolved "https://registry.yarnpkg.com/promised-io/-/promised-io-0.3.5.tgz#4ad217bb3658bcaae9946b17a8668ecd851e1356" + proxy-addr@~1.1.5: version "1.1.5" resolved "https://registry.yarnpkg.com/proxy-addr/-/proxy-addr-1.1.5.tgz#71c0ee3b102de3f202f3b64f608d173fcba1a918" @@ -6514,13 +6600,9 @@ quick-temp@^0.1.0, quick-temp@^0.1.2, quick-temp@^0.1.3, quick-temp@^0.1.5, quic rimraf "^2.5.4" underscore.string "~3.3.4" -qunit-notifications@^0.1.1: - version "0.1.1" - resolved "https://registry.yarnpkg.com/qunit-notifications/-/qunit-notifications-0.1.1.tgz#3001afc6a6a77dfbd962ccbcddde12dec5286c09" - -qunitjs@^2.0.1: - version "2.4.0" - resolved "https://registry.yarnpkg.com/qunitjs/-/qunitjs-2.4.0.tgz#58f3a81e846687f2e7f637c5bedc9c267f887261" +qunit@^2.4.1: + version "2.4.1" + resolved "https://registry.yarnpkg.com/qunit/-/qunit-2.4.1.tgz#373c826b3b91795f3e5479cc94f0f6fa14dedc47" dependencies: chokidar "1.6.1" commander "2.9.0" @@ -7100,14 +7182,17 @@ simple-is@~0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/simple-is/-/simple-is-0.2.0.tgz#2abb75aade39deb5cc815ce10e6191164850baf0" -sinon@^2.1.0: - version "2.4.1" - resolved "https://registry.yarnpkg.com/sinon/-/sinon-2.4.1.tgz#021fd64b54cb77d9d2fb0d43cdedfae7629c3a36" +sinon@^3.2.1: + version "3.3.0" + resolved "https://registry.yarnpkg.com/sinon/-/sinon-3.3.0.tgz#9132111b4bbe13c749c2848210864250165069b1" dependencies: + build "^0.1.4" diff "^3.1.0" formatio "1.2.0" - lolex "^1.6.0" + lodash.get "^4.4.2" + lolex "^2.1.2" native-promise-only "^0.8.1" + nise "^1.0.1" path-to-regexp "^1.7.0" samsam "^1.1.3" text-encoding "0.6.4" @@ -7285,6 +7370,10 @@ stable@~0.1.3: version "0.1.6" resolved "https://registry.yarnpkg.com/stable/-/stable-0.1.6.tgz#910f5d2aed7b520c6e777499c1f32e139fdecb10" +stack-trace@0.0.x: + version "0.0.10" + resolved "https://registry.yarnpkg.com/stack-trace/-/stack-trace-0.0.10.tgz#547c70b347e8d32b4e108ea1a2a159e5fdde19c0" + staged-git-files@0.0.4: version "0.0.4" resolved "https://registry.yarnpkg.com/staged-git-files/-/staged-git-files-0.0.4.tgz#d797e1b551ca7a639dec0237dc6eb4bb9be17d35" @@ -7560,7 +7649,7 @@ testem@^1.18.0: tap-parser "^5.1.0" xmldom "^0.1.19" -text-encoding@0.6.4: +text-encoding@0.6.4, text-encoding@^0.6.4: version "0.6.4" resolved "https://registry.yarnpkg.com/text-encoding/-/text-encoding-0.6.4.tgz#e399a982257a276dae428bb92845cb71bdc26d19" @@ -7589,6 +7678,10 @@ timers-browserify@^1.0.1: dependencies: process "~0.11.0" +timespan@2.x: + version "2.3.0" + resolved "https://registry.yarnpkg.com/timespan/-/timespan-2.3.0.tgz#4902ce040bd13d845c8f59b27e9d59bad6f39929" + tiny-lr@^1.0.3: version "1.0.5" resolved "https://registry.yarnpkg.com/tiny-lr/-/tiny-lr-1.0.5.tgz#21f40bf84ebd1f853056680375eef1670c334112" @@ -7716,6 +7809,10 @@ uglify-es@^3.1.3: commander "~2.12.1" source-map "~0.6.1" +uglify-js@1.x: + version "1.3.5" + resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-1.3.5.tgz#4b5bfff9186effbaa888e4c9e94bd9fc4c94929d" + uglify-js@^2.6: version "2.8.29" resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-2.8.29.tgz#29c5733148057bb4e1f75df35b7a9cb72e6a59dd" @@ -7861,7 +7958,7 @@ walk-sync@^0.3.0, walk-sync@^0.3.1, walk-sync@^0.3.2: ensure-posix-path "^1.0.0" matcher-collection "^1.0.0" -walker@~1.0.5: +walker@1.x, walker@~1.0.5: version "1.0.7" resolved "https://registry.yarnpkg.com/walker/-/walker-1.0.7.tgz#2f7f9b8fd10d677262b18a884e28d19618e028fb" dependencies: @@ -7917,6 +8014,17 @@ window-size@^0.1.2: version "0.1.4" resolved "https://registry.yarnpkg.com/window-size/-/window-size-0.1.4.tgz#f8e1aa1ee5a53ec5bf151ffa09742a6ad7697876" +winston@*: + version "2.4.0" + resolved "https://registry.yarnpkg.com/winston/-/winston-2.4.0.tgz#808050b93d52661ed9fb6c26b3f0c826708b0aee" + dependencies: + async "~1.0.0" + colors "1.0.x" + cycle "1.0.x" + eyes "0.1.x" + isstream "0.1.x" + stack-trace "0.0.x" + wordwrap@0.0.2: version "0.0.2" resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-0.0.2.tgz#b79669bb42ecb409f83d583cad52ca17eaa1643f" @@ -7946,6 +8054,10 @@ wrappy@1: version "1.0.2" resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" +wrench@1.3.x: + version "1.3.9" + resolved "https://registry.yarnpkg.com/wrench/-/wrench-1.3.9.tgz#6f13ec35145317eb292ca5f6531391b244111411" + write-file-atomic@^2.0.0: version "2.3.0" resolved "https://registry.yarnpkg.com/write-file-atomic/-/write-file-atomic-2.3.0.tgz#1ff61575c2e2a4e8e510d6fa4e243cce183999ab" From 7526295e885077e14ea39a5447f34dadaa7bc1f2 Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Mon, 8 Jan 2018 13:08:14 -0800 Subject: [PATCH 109/136] Use ember-test-selectors for integration tests --- .../components/attributes-section.hbs | 14 +++---- .../job-diff-fields-and-objects.hbs | 24 +++++++----- ui/app/templates/components/job-diff.hbs | 36 ++++++++++-------- ui/app/templates/components/task-log.hbs | 14 +++---- ui/tests/integration/attributes-table-test.js | 37 +++++------------- ui/tests/integration/job-diff-test.js | 32 ++++++++++------ ui/tests/integration/task-log-test.js | 38 ++++++++++--------- 7 files changed, 100 insertions(+), 95 deletions(-) diff --git a/ui/app/templates/components/attributes-section.hbs b/ui/app/templates/components/attributes-section.hbs index dd55bb591..8abeeb135 100644 --- a/ui/app/templates/components/attributes-section.hbs +++ b/ui/app/templates/components/attributes-section.hbs @@ -1,18 +1,18 @@ {{#each-in attributes as |key value|}} {{#if (is-object value)}} -
          - + {{attributes-section prefix=(if prefix (concat prefix '.' key) key) attributes=value}} {{else}} - - + - + {{/if}} {{/each-in}} diff --git a/ui/app/templates/components/job-diff-fields-and-objects.hbs b/ui/app/templates/components/job-diff-fields-and-objects.hbs index 7da3703c8..dfb51e6e4 100644 --- a/ui/app/templates/components/job-diff-fields-and-objects.hbs +++ b/ui/app/templates/components/job-diff-fields-and-objects.hbs @@ -1,9 +1,12 @@
          {{#each fields as |field|}} -
          +
          {{#if (eq (lowercase field.Type) "added")}} @@ -30,10 +33,13 @@
          {{#each objects as |object|}} -
          +
          {{#if (eq (lowercase object.Type) "added")}} + @@ -44,7 +50,7 @@ {{/if}} {{object.Name}} { -
          Placement + job -> group -> task -> service -> **check_restart** +
          Placement From b658ac35aec07e18ca6e939e85b32706fbcc097b Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Tue, 9 Jan 2018 15:18:34 -0800 Subject: [PATCH 065/136] Revert "Remove mention of check_restart on service" This reverts commit 758b98685be4a2997bd0bc54f55b73ac3d0365cc. --- website/source/docs/job-specification/check_restart.html.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/website/source/docs/job-specification/check_restart.html.md b/website/source/docs/job-specification/check_restart.html.md index 19b720276..d183bd054 100644 --- a/website/source/docs/job-specification/check_restart.html.md +++ b/website/source/docs/job-specification/check_restart.html.md @@ -28,7 +28,10 @@ As of Nomad 0.7 the `check_restart` stanza instructs Nomad when to restart tasks with unhealthy service checks. When a health check in Consul has been unhealthy for the `limit` specified in a `check_restart` stanza, it is restarted according to the task group's [`restart` policy][restart_stanza]. The -`check_restart` settings apply to [`check`s][check_stanza]. +`check_restart` settings apply to [`check`s][check_stanza], but may also be +placed on [`service`s][service_stanza] to apply to all checks on a service. +If `check_restart` is set on both the check and service, the stanzas are +merged with the check values taking precedence. ```hcl job "mysql" { @@ -146,3 +149,4 @@ details. [check_stanza]: /docs/job-specification/service.html#check-parameters "check stanza" [restart_stanza]: /docs/job-specification/restart.html "restart stanza" +[service_stanza]: /docs/job-specification/service.html "service stanza" From 09de90514e92f28e3e7fb7d8ec5778eae8fa5e23 Mon Sep 17 00:00:00 2001 From: Ron Alexssen Date: Tue, 9 Jan 2018 15:21:30 -0800 Subject: [PATCH 066/136] remove duplicate typo --- website/source/guides/acl.html.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/website/source/guides/acl.html.markdown b/website/source/guides/acl.html.markdown index 8e16b2131..c009a9017 100644 --- a/website/source/guides/acl.html.markdown +++ b/website/source/guides/acl.html.markdown @@ -56,7 +56,7 @@ Constructing rules from these policies is covered in detail in the Rule Specific Nomad supports multi-datacenter and multi-region configurations. A single region is able to service multiple datacenters, and all servers in a region replicate their state between each other. In a multi-region configuration, there is a set of servers per region. Each region operates independently and is loosely coupled to allow jobs to be scheduled in any region and requests to flow transparently to the correct region. -When ACLs are enabled, Nomad depends on an "authoritative region" to act as a single source of truth for ACL policies and global ACL tokens. The authoritative region is configured in the [`server` stanza](/docs/agent/configuration/server.html) of agents, and all regions must share a single a single authoritative source. Any ACL policies or global ACL tokens are created in the authoritative region first. All other regions replicate ACL policies and global ACL tokens to act as local mirrors. This allows policies to be administered centrally, and for enforcement to be local to each region for low latency. +When ACLs are enabled, Nomad depends on an "authoritative region" to act as a single source of truth for ACL policies and global ACL tokens. The authoritative region is configured in the [`server` stanza](/docs/agent/configuration/server.html) of agents, and all regions must share a single authoritative source. Any ACL policies or global ACL tokens are created in the authoritative region first. All other regions replicate ACL policies and global ACL tokens to act as local mirrors. This allows policies to be administered centrally, and for enforcement to be local to each region for low latency. Global ACL tokens are used to allow cross region requests. Standard ACL tokens are created in a single target region and not replicated. This means if a request takes place between regions, global tokens must be used so that both regions will have the token registered. From ae61f7308d858794cef5bd29896553bc76f25bbe Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Fri, 5 Jan 2018 14:12:52 -0800 Subject: [PATCH 067/136] Fix HTTP code for permission denied errors Fixes #3697 The existing code and test case only covered the leader behavior. When querying against non-leaders the error has an "rpc error: " prefix. To provide consistency in HTTP error response I also strip the "rpc error: " prefix for 403 responses as they offer no beneficial additional information (and in theory disclose a tiny bit of data to unauthorized users, but it would be a pretty weird bit of data to use in a malicious way). --- CHANGELOG.md | 3 ++- command/agent/http.go | 12 +++++++++--- command/agent/http_test.go | 27 ++++++++++++++++++++------- 3 files changed, 31 insertions(+), 11 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 795157226..fde6c90fa 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,7 @@ BUG FIXES: allocations could result in improper placement counts [[GH-3717](https://github.com/hashicorp/nomad/issues/3717)] * client: Migrated ephemeral_disk's maintain directory permissions [[GH-3723](https://github.com/hashicorp/nomad/issues/3723)] * config: Revert minimum CPU limit back to 20 from 100. + * ui: Fix ui on non-leaders when ACLs are enabled [[GH-3722](https://github.com/hashicorp/nomad/issues/3722)] * ui: Fix requests using client-side certificates in Firefox. [[GH-3728](https://github.com/hashicorp/nomad/pull/3728)] ## 0.7.1 (December 19, 2017) @@ -663,7 +664,7 @@ BUG FIXES: * client: Killing an allocation doesn't cause allocation stats to block [[GH-1454](https://github.com/hashicorp/nomad/issues/1454)] * driver/docker: Disable swap on docker driver [[GH-1480](https://github.com/hashicorp/nomad/issues/1480)] - * driver/docker: Fix improper gating on privileged mode [[GH-1506](https://github.com/hashicorp/nomad/issues/1506)] + * driver/docker: Fix improper gating on priviledged mode [[GH-1506](https://github.com/hashicorp/nomad/issues/1506)] * driver/docker: Default network type is "nat" on Windows [[GH-1521](https://github.com/hashicorp/nomad/issues/1521)] * driver/docker: Cleanup created volume when destroying container [[GH-1519](https://github.com/hashicorp/nomad/issues/1519)] * driver/rkt: Set host environment variables [[GH-1581](https://github.com/hashicorp/nomad/issues/1581)] diff --git a/command/agent/http.go b/command/agent/http.go index 4146cffd4..8aa1b2f09 100644 --- a/command/agent/http.go +++ b/command/agent/http.go @@ -11,6 +11,7 @@ import ( "net/http/pprof" "os" "strconv" + "strings" "time" "github.com/NYTimes/gziphandler" @@ -281,17 +282,22 @@ func (s *HTTPServer) wrap(handler func(resp http.ResponseWriter, req *http.Reque if err != nil { s.logger.Printf("[ERR] http: Request %v, error: %v", reqURL, err) code := 500 + errMsg := err.Error() if http, ok := err.(HTTPCodedError); ok { code = http.Code() } else { - switch err.Error() { - case structs.ErrPermissionDenied.Error(), structs.ErrTokenNotFound.Error(): + // RPC errors get wrapped, so manually unwrap by only looking at their suffix + if strings.HasSuffix(errMsg, structs.ErrPermissionDenied.Error()) { + errMsg = structs.ErrPermissionDenied.Error() + code = 403 + } else if strings.HasSuffix(errMsg, structs.ErrTokenNotFound.Error()) { + errMsg = structs.ErrTokenNotFound.Error() code = 403 } } resp.WriteHeader(code) - resp.Write([]byte(err.Error())) + resp.Write([]byte(errMsg)) return } diff --git a/command/agent/http_test.go b/command/agent/http_test.go index 5d4004c18..6c4e637eb 100644 --- a/command/agent/http_test.go +++ b/command/agent/http_test.go @@ -225,15 +225,28 @@ func TestPermissionDenied(t *testing.T) { }) defer s.Shutdown() - resp := httptest.NewRecorder() - handler := func(resp http.ResponseWriter, req *http.Request) (interface{}, error) { - return nil, structs.ErrPermissionDenied + { + resp := httptest.NewRecorder() + handler := func(resp http.ResponseWriter, req *http.Request) (interface{}, error) { + return nil, structs.ErrPermissionDenied + } + + req, _ := http.NewRequest("GET", "/v1/job/foo", nil) + s.Server.wrap(handler)(resp, req) + assert.Equal(t, resp.Code, 403) } - urlStr := "/v1/job/foo" - req, _ := http.NewRequest("GET", urlStr, nil) - s.Server.wrap(handler)(resp, req) - assert.Equal(t, resp.Code, 403) + // When remote RPC is used the errors have "rpc error: " prependend + { + resp := httptest.NewRecorder() + handler := func(resp http.ResponseWriter, req *http.Request) (interface{}, error) { + return nil, fmt.Errorf("rpc error: %v", structs.ErrPermissionDenied) + } + + req, _ := http.NewRequest("GET", "/v1/job/foo", nil) + s.Server.wrap(handler)(resp, req) + assert.Equal(t, resp.Code, 403) + } } func TestTokenNotFound(t *testing.T) { From 7466e12a65849b5786cad9f3e8b7bc7c2ed0236b Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Mon, 8 Jan 2018 11:02:36 -0800 Subject: [PATCH 068/136] Update Consul/rkt/Vault in Vagrant Needed to update Vault for #3334 --- scripts/vagrant-linux-priv-consul.sh | 2 +- scripts/vagrant-linux-priv-rkt.sh | 2 +- scripts/vagrant-linux-priv-vault.sh | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/vagrant-linux-priv-consul.sh b/scripts/vagrant-linux-priv-consul.sh index 94027cac1..c9a0ba5b8 100755 --- a/scripts/vagrant-linux-priv-consul.sh +++ b/scripts/vagrant-linux-priv-consul.sh @@ -2,7 +2,7 @@ set -o errexit -VERSION=1.0.0 +VERSION=1.0.2 DOWNLOAD=https://releases.hashicorp.com/consul/${VERSION}/consul_${VERSION}_linux_amd64.zip function install_consul() { diff --git a/scripts/vagrant-linux-priv-rkt.sh b/scripts/vagrant-linux-priv-rkt.sh index 07375133f..ad7c26af3 100755 --- a/scripts/vagrant-linux-priv-rkt.sh +++ b/scripts/vagrant-linux-priv-rkt.sh @@ -3,7 +3,7 @@ set -o errexit VERSION=1.27.0 -DOWNLOAD=https://github.com/coreos/rkt/releases/download/v${VERSION}/rkt-v${VERSION}.tar.gz +DOWNLOAD=https://github.com/rkt/rkt/releases/download/v${VERSION}/rkt-v${VERSION}.tar.gz function install_rkt() { if [[ -e /usr/local/bin/rkt ]] ; then diff --git a/scripts/vagrant-linux-priv-vault.sh b/scripts/vagrant-linux-priv-vault.sh index 6882c865e..11a2b47ea 100755 --- a/scripts/vagrant-linux-priv-vault.sh +++ b/scripts/vagrant-linux-priv-vault.sh @@ -2,7 +2,7 @@ set -o errexit -VERSION=0.7.0 +VERSION=0.9.1 DOWNLOAD=https://releases.hashicorp.com/vault/${VERSION}/vault_${VERSION}_linux_amd64.zip function install_vault() { From ffb4c57a8f3abba6d88cee0530aea4c078603e4f Mon Sep 17 00:00:00 2001 From: Alex Dadgar Date: Wed, 10 Jan 2018 11:48:11 -0800 Subject: [PATCH 069/136] changelog --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index fde6c90fa..bf72f4efe 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,7 @@ BUG FIXES: * core: Fix an issue in which batch jobs with queued placements and lost allocations could result in improper placement counts [[GH-3717](https://github.com/hashicorp/nomad/issues/3717)] * client: Migrated ephemeral_disk's maintain directory permissions [[GH-3723](https://github.com/hashicorp/nomad/issues/3723)] + * client/vault: Recognize renewing non-renewable Vault lease as fatal [[GH-3727](https://github.com/hashicorp/nomad/issues/3727)] * config: Revert minimum CPU limit back to 20 from 100. * ui: Fix ui on non-leaders when ACLs are enabled [[GH-3722](https://github.com/hashicorp/nomad/issues/3722)] * ui: Fix requests using client-side certificates in Firefox. [[GH-3728](https://github.com/hashicorp/nomad/pull/3728)] From 2c58fb0f32c642ed79f766623712b1dc7e16d71c Mon Sep 17 00:00:00 2001 From: Alex Dadgar Date: Thu, 11 Jan 2018 13:39:04 -0800 Subject: [PATCH 070/136] Build all branches on travis --- .travis.yml | 4 ---- 1 file changed, 4 deletions(-) diff --git a/.travis.yml b/.travis.yml index 022c49a28..258b59a16 100644 --- a/.travis.yml +++ b/.travis.yml @@ -9,10 +9,6 @@ go: git: depth: 300 -branches: - only: - - master - matrix: include: - os: linux From cd5df24fcab9814f7148002ee9d89eb440344f66 Mon Sep 17 00:00:00 2001 From: Filip Ochnik Date: Fri, 12 Jan 2018 14:29:31 +0100 Subject: [PATCH 071/136] Remove duplicate docs entry for docker privileged option --- website/source/docs/drivers/docker.html.md | 5 ----- 1 file changed, 5 deletions(-) diff --git a/website/source/docs/drivers/docker.html.md b/website/source/docs/drivers/docker.html.md index 4ea260386..5000f2a7a 100644 --- a/website/source/docs/drivers/docker.html.md +++ b/website/source/docs/drivers/docker.html.md @@ -210,11 +210,6 @@ The `docker` driver supports the following configuration in the job spec. Only * `port_map` - (Optional) A key-value map of port labels (see below). -* `privileged` - (Optional) `true` or `false` (default). Privileged mode gives - the container access to devices on the host. Note that this also requires the - nomad agent and docker daemon to be configured to allow privileged - containers. - * `security_opt` - (Optional) A list of string flags to pass directly to [`--security-opt`](https://docs.docker.com/engine/reference/run/#security-configuration). For example: From 45c3d8d5a1552349a9e6179d2ddf12339ed68f83 Mon Sep 17 00:00:00 2001 From: Charlie Voiselle Date: Fri, 12 Jan 2018 09:44:53 -0500 Subject: [PATCH 072/136] Found more priviledge. priviledge -> privilege --- CHANGELOG.md | 2 +- client/driver/java.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index bf72f4efe..e33f99349 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -665,7 +665,7 @@ BUG FIXES: * client: Killing an allocation doesn't cause allocation stats to block [[GH-1454](https://github.com/hashicorp/nomad/issues/1454)] * driver/docker: Disable swap on docker driver [[GH-1480](https://github.com/hashicorp/nomad/issues/1480)] - * driver/docker: Fix improper gating on priviledged mode [[GH-1506](https://github.com/hashicorp/nomad/issues/1506)] + * driver/docker: Fix improper gating on privileged mode [[GH-1506](https://github.com/hashicorp/nomad/issues/1506)] * driver/docker: Default network type is "nat" on Windows [[GH-1521](https://github.com/hashicorp/nomad/issues/1521)] * driver/docker: Cleanup created volume when destroying container [[GH-1519](https://github.com/hashicorp/nomad/issues/1519)] * driver/rkt: Set host environment variables [[GH-1581](https://github.com/hashicorp/nomad/issues/1581)] diff --git a/client/driver/java.go b/client/driver/java.go index 0c660547c..8c162e0cd 100644 --- a/client/driver/java.go +++ b/client/driver/java.go @@ -116,7 +116,7 @@ func (d *JavaDriver) Fingerprint(cfg *config.Config, node *structs.Node) (bool, // Only enable if we are root and cgroups are mounted when running on linux systems. if runtime.GOOS == "linux" && (syscall.Geteuid() != 0 || !cgroupsMounted(node)) { if d.fingerprintSuccess == nil || *d.fingerprintSuccess { - d.logger.Printf("[DEBUG] driver.java: root priviledges and mounted cgroups required on linux, disabling") + d.logger.Printf("[DEBUG] driver.java: root privileges and mounted cgroups required on linux, disabling") } delete(node.Attributes, "driver.java") d.fingerprintSuccess = helper.BoolToPtr(false) From 6f038c8d1d61e65d9833e52ee60a7266bbd50634 Mon Sep 17 00:00:00 2001 From: Shantanu Gadgil Date: Fri, 12 Jan 2018 23:35:49 +0530 Subject: [PATCH 073/136] 'drain' node is a POST rather than a GET 'drain' node is a POST rather than a GET --- website/source/api/nodes.html.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/website/source/api/nodes.html.md b/website/source/api/nodes.html.md index 0d7ff6c78..68d982e2f 100644 --- a/website/source/api/nodes.html.md +++ b/website/source/api/nodes.html.md @@ -598,7 +598,7 @@ The table below shows this endpoint's support for ```text $ curl \ - https://nomad.rocks/v1/node/fb2170a8-257d-3c64-b14d-bc06cc94e34c/drain?enable=true + -XPOST https://nomad.rocks/v1/node/fb2170a8-257d-3c64-b14d-bc06cc94e34c/drain?enable=true ``` ### Sample Response From 47f90683fb88a5581b2c0e9c82f840b7f248c099 Mon Sep 17 00:00:00 2001 From: Alex Dadgar Date: Fri, 12 Jan 2018 14:33:42 -0800 Subject: [PATCH 074/136] Remove networking from basic resources --- client/driver/driver_test.go | 7 ------- 1 file changed, 7 deletions(-) diff --git a/client/driver/driver_test.go b/client/driver/driver_test.go index c2d59541c..7e9a43534 100644 --- a/client/driver/driver_test.go +++ b/client/driver/driver_test.go @@ -24,13 +24,6 @@ var basicResources = &structs.Resources{ CPU: 250, MemoryMB: 256, DiskMB: 20, - Networks: []*structs.NetworkResource{ - { - IP: "0.0.0.0", - ReservedPorts: []structs.Port{{Label: "main", Value: 12345}}, - DynamicPorts: []structs.Port{{Label: "HTTP", Value: 43330}}, - }, - }, } func init() { From 4c56501aa38bb90b285e87c0bac4e06f822370f1 Mon Sep 17 00:00:00 2001 From: Alex Dadgar Date: Fri, 12 Jan 2018 15:10:26 -0800 Subject: [PATCH 075/136] Test listener uses freeport instead of static ports --- command/agent/config_test.go | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/command/agent/config_test.go b/command/agent/config_test.go index 67d75d480..0bd286868 100644 --- a/command/agent/config_test.go +++ b/command/agent/config_test.go @@ -1,6 +1,7 @@ package agent import ( + "fmt" "io/ioutil" "net" "os" @@ -9,6 +10,7 @@ import ( "testing" "time" + "github.com/hashicorp/consul/lib/freeport" "github.com/hashicorp/nomad/nomad/structs" "github.com/hashicorp/nomad/nomad/structs/config" ) @@ -520,7 +522,8 @@ func TestConfig_Listener(t *testing.T) { } // Works with valid inputs - ln, err := config.Listener("tcp", "127.0.0.1", 24000) + ports := freeport.GetT(t, 2) + ln, err := config.Listener("tcp", "127.0.0.1", ports[0]) if err != nil { t.Fatalf("err: %s", err) } @@ -529,20 +532,22 @@ func TestConfig_Listener(t *testing.T) { if net := ln.Addr().Network(); net != "tcp" { t.Fatalf("expected tcp, got: %q", net) } - if addr := ln.Addr().String(); addr != "127.0.0.1:24000" { - t.Fatalf("expected 127.0.0.1:4646, got: %q", addr) + want := fmt.Sprintf("127.0.0.1:%d", ports[0]) + if addr := ln.Addr().String(); addr != want { + t.Fatalf("expected %q, got: %q", want, addr) } // Falls back to default bind address if non provided config.BindAddr = "0.0.0.0" - ln, err = config.Listener("tcp4", "", 24000) + ln, err = config.Listener("tcp4", "", ports[1]) if err != nil { t.Fatalf("err: %s", err) } ln.Close() - if addr := ln.Addr().String(); addr != "0.0.0.0:24000" { - t.Fatalf("expected 0.0.0.0:24000, got: %q", addr) + want = fmt.Sprintf("0.0.0.0:%d", ports[1]) + if addr := ln.Addr().String(); addr != want { + t.Fatalf("expected %q, got: %q", want, addr) } } From 59d360c7f4db83c5f0fa38500000838f22fbc1a4 Mon Sep 17 00:00:00 2001 From: Jeff Silberman Date: Fri, 12 Jan 2018 16:09:50 -0800 Subject: [PATCH 076/136] Update volume-driver, reflecting a supported driver --- website/source/docs/drivers/docker.html.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/website/source/docs/drivers/docker.html.md b/website/source/docs/drivers/docker.html.md index 5000f2a7a..d99592246 100644 --- a/website/source/docs/drivers/docker.html.md +++ b/website/source/docs/drivers/docker.html.md @@ -270,7 +270,7 @@ The `docker` driver supports the following configuration in the job spec. Only "name-of-the-volume:/path/in/container" ] # Name of the Docker Volume Driver used by the container - volume_driver = "flocker" + volume_driver = "pxd" } ``` @@ -293,7 +293,7 @@ The `docker` driver supports the following configuration in the job spec. Only foo = "bar" } driver_config { - name = "flocker" + name = "pxd" options = { foo = "bar" } From 8d81a0f408c175eb4ab738e5f6bf3d0a271b606d Mon Sep 17 00:00:00 2001 From: Alex Dadgar Date: Tue, 16 Jan 2018 11:37:59 -0800 Subject: [PATCH 077/136] actually show defaults --- website/source/docs/agent/configuration/consul.html.md | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/website/source/docs/agent/configuration/consul.html.md b/website/source/docs/agent/configuration/consul.html.md index 85a7e176e..f0cfa4b01 100644 --- a/website/source/docs/agent/configuration/consul.html.md +++ b/website/source/docs/agent/configuration/consul.html.md @@ -109,12 +109,14 @@ Nomad cluster will [automatically bootstrap][bootstrap] provided This example shows the default Consul integration: ```hcl + address = "127.0.0.1:8500" + server_service_name = "nomad" + client_service_name = "nomad-client" + auto_advertise = true + server_auto_join = true + client_auto_join = true ``` -That is not a mistake - it is intentionally empty. If a local Consul agent is -running at the default address, Nomad will automatically connect and use the -default values listed above. - ### Custom Address and Port This example shows pointing the Nomad agent at a different Consul address. Note From b83869efc407d71768ecb0b58a7f29c0e0025f2b Mon Sep 17 00:00:00 2001 From: Alex Dadgar Date: Tue, 16 Jan 2018 15:56:02 -0800 Subject: [PATCH 078/136] Update consul.html.md --- .../source/docs/agent/configuration/consul.html.md | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/website/source/docs/agent/configuration/consul.html.md b/website/source/docs/agent/configuration/consul.html.md index f0cfa4b01..f056ddd22 100644 --- a/website/source/docs/agent/configuration/consul.html.md +++ b/website/source/docs/agent/configuration/consul.html.md @@ -109,12 +109,14 @@ Nomad cluster will [automatically bootstrap][bootstrap] provided This example shows the default Consul integration: ```hcl - address = "127.0.0.1:8500" - server_service_name = "nomad" - client_service_name = "nomad-client" - auto_advertise = true - server_auto_join = true - client_auto_join = true +consul { + address = "127.0.0.1:8500" + server_service_name = "nomad" + client_service_name = "nomad-client" + auto_advertise = true + server_auto_join = true + client_auto_join = true +} ``` ### Custom Address and Port From e482a9927f05a9beaa2a90202ed486e1a9e18803 Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Mon, 11 Dec 2017 14:42:17 -0800 Subject: [PATCH 079/136] Never fetch a job with null as the namespace --- ui/app/routes/jobs/job.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/app/routes/jobs/job.js b/ui/app/routes/jobs/job.js index 4317a1e35..fa40f07bd 100644 --- a/ui/app/routes/jobs/job.js +++ b/ui/app/routes/jobs/job.js @@ -13,7 +13,7 @@ export default Route.extend({ model(params, transition) { const namespace = transition.queryParams.namespace || this.get('system.activeNamespace.id'); const name = params.job_name; - const fullId = JSON.stringify([name, namespace]); + const fullId = JSON.stringify([name, namespace || 'default']); return this.get('store') .findRecord('job', fullId, { reload: true }) .then(job => { From 534376ac62f7a99aace73c63577f55f3f8ba032a Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Mon, 11 Dec 2017 16:19:49 -0800 Subject: [PATCH 080/136] Don't dot twice after an @each --- ui/app/components/job-deployments-stream.js | 4 ++-- ui/app/models/deployment.js | 3 +++ 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/ui/app/components/job-deployments-stream.js b/ui/app/components/job-deployments-stream.js index 95bd4f198..65b700491 100644 --- a/ui/app/components/job-deployments-stream.js +++ b/ui/app/components/job-deployments-stream.js @@ -9,9 +9,9 @@ export default Component.extend({ deployments: computed(() => []), - sortedDeployments: computed('deployments.@each.version.submitTime', function() { + sortedDeployments: computed('deployments.@each.versionSubmitTime', function() { return this.get('deployments') - .sortBy('version.submitTime') + .sortBy('versionSubmitTime') .reverse(); }), diff --git a/ui/app/models/deployment.js b/ui/app/models/deployment.js index 2a952afb7..8f4440ba2 100644 --- a/ui/app/models/deployment.js +++ b/ui/app/models/deployment.js @@ -34,6 +34,9 @@ export default Model.extend({ return (this.get('job.versions') || []).findBy('number', this.get('versionNumber')); }), + // Dependent keys can only go one level past an @each so an alias is needed + versionSubmitTime: computed.alias('version.submitTime'), + placedCanaries: sumAggregation('taskGroupSummaries', 'placedCanaries'), desiredCanaries: sumAggregation('taskGroupSummaries', 'desiredCanaries'), desiredTotal: sumAggregation('taskGroupSummaries', 'desiredTotal'), From fbdf3ed3cb80a2dd37aee56d87a7d52c5cf29edb Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Mon, 11 Dec 2017 16:20:13 -0800 Subject: [PATCH 081/136] Don't warn intentional errors in tests It's too noisy --- ui/app/controllers/application.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/app/controllers/application.js b/ui/app/controllers/application.js index ee8bee9ee..faa744e96 100644 --- a/ui/app/controllers/application.js +++ b/ui/app/controllers/application.js @@ -33,7 +33,7 @@ export default Controller.extend({ run.next(() => { throw this.get('error'); }); - } else { + } else if (!Ember.testing) { run.next(() => { // eslint-disable-next-line console.warn('UNRECOVERABLE ERROR:', this.get('error')); From d53849d2a5d5152cd75302b299fcc8daa98681d8 Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Mon, 11 Dec 2017 16:20:38 -0800 Subject: [PATCH 082/136] Disambiguate what to do with the child task for the task logger linked tasks are killed when the parent task is killed. --- ui/app/utils/classes/poll-logger.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ui/app/utils/classes/poll-logger.js b/ui/app/utils/classes/poll-logger.js index 3077e80a0..5310f3e45 100644 --- a/ui/app/utils/classes/poll-logger.js +++ b/ui/app/utils/classes/poll-logger.js @@ -8,7 +8,9 @@ export default EmberObject.extend(AbstractLogger, { interval: 1000, start() { - return this.get('poll').perform(); + return this.get('poll') + .linked() + .perform(); }, stop() { From cbf883a9a664eceb9d6d13bec842decdeb9ef13b Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Mon, 11 Dec 2017 17:48:02 -0800 Subject: [PATCH 083/136] Upgrade to ember-cli 2.17 and ember 2.17 --- ui/package.json | 4 +- ui/yarn.lock | 450 ++++++++++++++++++++---------------------------- 2 files changed, 190 insertions(+), 264 deletions(-) diff --git a/ui/package.json b/ui/package.json index d56b7749b..dd49aa5f1 100644 --- a/ui/package.json +++ b/ui/package.json @@ -34,7 +34,7 @@ "d3-transition": "^1.1.0", "ember-ajax": "^3.0.0", "ember-browserify": "^1.1.13", - "ember-cli": "2.13.2", + "ember-cli": "2.17.1", "ember-cli-babel": "^6.0.0", "ember-cli-bourbon": "2.0.0-beta.1", "ember-cli-dependency-checker": "^1.3.0", @@ -65,7 +65,7 @@ "ember-power-select": "^1.9.9", "ember-resolver": "^4.0.0", "ember-sinon": "^0.7.0", - "ember-source": "~2.14.0", + "ember-source": "~2.17.0", "ember-truth-helpers": "^1.3.0", "ember-welcome-page": "^3.0.0", "eslint": "^4.0.0", diff --git a/ui/yarn.lock b/ui/yarn.lock index 62c3cdee1..de9eb1405 100644 --- a/ui/yarn.lock +++ b/ui/yarn.lock @@ -2,86 +2,16 @@ # yarn lockfile v1 -"@glimmer/compiler@^0.22.3": - version "0.22.3" - resolved "https://registry.yarnpkg.com/@glimmer/compiler/-/compiler-0.22.3.tgz#3aef9448460af1d320a82423323498a6ff38a0c6" - dependencies: - "@glimmer/syntax" "^0.22.3" - "@glimmer/util" "^0.22.3" - "@glimmer/wire-format" "^0.22.3" - simple-html-tokenizer "^0.3.0" - "@glimmer/di@^0.2.0": version "0.2.0" resolved "https://registry.yarnpkg.com/@glimmer/di/-/di-0.2.0.tgz#73bfd4a6ee4148a80bf092e8a5d29bcac9d4ce7e" -"@glimmer/interfaces@^0.22.3": - version "0.22.3" - resolved "https://registry.yarnpkg.com/@glimmer/interfaces/-/interfaces-0.22.3.tgz#1c2e3289ae41a750f0c8ddcc64529b9e90dda604" - dependencies: - "@glimmer/wire-format" "^0.22.3" - -"@glimmer/node@^0.22.3": - version "0.22.3" - resolved "https://registry.yarnpkg.com/@glimmer/node/-/node-0.22.3.tgz#ff33eea6e65147a20c1bd1f05fdc4a6c3595c54c" - dependencies: - "@glimmer/runtime" "^0.22.3" - simple-dom "^0.3.0" - -"@glimmer/object-reference@^0.22.3": - version "0.22.3" - resolved "https://registry.yarnpkg.com/@glimmer/object-reference/-/object-reference-0.22.3.tgz#31db68c8912324c63509b1ef83213f7ad4ef312b" - dependencies: - "@glimmer/reference" "^0.22.3" - "@glimmer/util" "^0.22.3" - -"@glimmer/object@^0.22.3": - version "0.22.3" - resolved "https://registry.yarnpkg.com/@glimmer/object/-/object-0.22.3.tgz#1fc9fd7465c7d12e5b92464ad40038b595de8ed0" - dependencies: - "@glimmer/object-reference" "^0.22.3" - "@glimmer/util" "^0.22.3" - -"@glimmer/reference@^0.22.3": - version "0.22.3" - resolved "https://registry.yarnpkg.com/@glimmer/reference/-/reference-0.22.3.tgz#6f2ef8cd97fe756d89fef75f8c3c79003502a2a9" - dependencies: - "@glimmer/util" "^0.22.3" - "@glimmer/resolver@^0.4.1": version "0.4.1" resolved "https://registry.yarnpkg.com/@glimmer/resolver/-/resolver-0.4.1.tgz#cd9644572c556e7e799de1cf8eff2b999cf5b878" dependencies: "@glimmer/di" "^0.2.0" -"@glimmer/runtime@^0.22.3": - version "0.22.3" - resolved "https://registry.yarnpkg.com/@glimmer/runtime/-/runtime-0.22.3.tgz#b8cb28efc9cc86c406ee996f5c2cf6730620d404" - dependencies: - "@glimmer/interfaces" "^0.22.3" - "@glimmer/object" "^0.22.3" - "@glimmer/object-reference" "^0.22.3" - "@glimmer/reference" "^0.22.3" - "@glimmer/util" "^0.22.3" - "@glimmer/wire-format" "^0.22.3" - -"@glimmer/syntax@^0.22.3": - version "0.22.3" - resolved "https://registry.yarnpkg.com/@glimmer/syntax/-/syntax-0.22.3.tgz#8528d19324bf7f920f5cfd31925e452e51781b44" - dependencies: - handlebars "^4.0.6" - simple-html-tokenizer "^0.3.0" - -"@glimmer/util@^0.22.3": - version "0.22.3" - resolved "https://registry.yarnpkg.com/@glimmer/util/-/util-0.22.3.tgz#8272f50905d1bb904ee371e8ade83fd779b51508" - -"@glimmer/wire-format@^0.22.3": - version "0.22.3" - resolved "https://registry.yarnpkg.com/@glimmer/wire-format/-/wire-format-0.22.3.tgz#19b226d9b93ba6ee54472d9ffb1d48e7c0d80a0d" - dependencies: - "@glimmer/util" "^0.22.3" - JSONStream@^1.0.3: version "1.3.1" resolved "https://registry.yarnpkg.com/JSONStream/-/JSONStream-1.3.1.tgz#707f761e01dae9e16f1bcf93703b78c70966579a" @@ -163,18 +93,18 @@ alter@~0.2.0: dependencies: stable "~0.1.3" -amd-name-resolver@0.0.6: - version "0.0.6" - resolved "https://registry.yarnpkg.com/amd-name-resolver/-/amd-name-resolver-0.0.6.tgz#d3e4ba2dfcaab1d820c1be9de947c67828cfe595" - dependencies: - ensure-posix-path "^1.0.1" - amd-name-resolver@0.0.7: version "0.0.7" resolved "https://registry.yarnpkg.com/amd-name-resolver/-/amd-name-resolver-0.0.7.tgz#814301adfe8a2f109f6e84d5e935196efb669615" dependencies: ensure-posix-path "^1.0.1" +amd-name-resolver@1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/amd-name-resolver/-/amd-name-resolver-1.0.0.tgz#0e593b28d6fa3326ab1798107edaea961046e8d8" + dependencies: + ensure-posix-path "^1.0.1" + amdefine@>=0.0.4: version "1.0.1" resolved "https://registry.yarnpkg.com/amdefine/-/amdefine-1.0.1.tgz#4a5282ac164729e93619bcfd3ad151f817ce91f5" @@ -203,11 +133,11 @@ ansi-styles@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-1.1.0.tgz#eaecbf66cd706882760b2f4691582b8f55d7a7de" -ansi-styles@^2.1.0, ansi-styles@^2.2.1: +ansi-styles@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-2.2.1.tgz#b432dd3358b634cf75e1e4664368240533c1ddbe" -ansi-styles@^3.1.0: +ansi-styles@^3.0.0, ansi-styles@^3.1.0: version "3.2.0" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.0.tgz#c159b8d5be0f9e5a6f346dab94f16ce022161b88" dependencies: @@ -245,7 +175,7 @@ are-we-there-yet@~1.1.2: delegates "^1.0.0" readable-stream "^2.0.6" -argparse@^1.0.7, argparse@~1.0.2: +argparse@^1.0.7: version "1.0.9" resolved "https://registry.yarnpkg.com/argparse/-/argparse-1.0.9.tgz#73d83bc263f86e97f8cc4f6bae1b0e90a7d22c86" dependencies: @@ -1217,9 +1147,9 @@ broccoli-brocfile-loader@^0.18.0: dependencies: findup-sync "^0.4.2" -broccoli-builder@^0.18.3: - version "0.18.8" - resolved "https://registry.yarnpkg.com/broccoli-builder/-/broccoli-builder-0.18.8.tgz#fe54694d544c3cdfdb01028e802eeca65749a879" +broccoli-builder@^0.18.8: + version "0.18.10" + resolved "https://registry.yarnpkg.com/broccoli-builder/-/broccoli-builder-0.18.10.tgz#9767e0061ff5b5e6eb1619d1a972ef2c7fd07631" dependencies: heimdalljs "^0.2.0" promise-map-series "^0.2.1" @@ -1303,6 +1233,17 @@ broccoli-debug@^0.6.1, broccoli-debug@^0.6.2: symlink-or-copy "^1.1.8" tree-sync "^1.2.2" +broccoli-debug@^0.6.3: + version "0.6.4" + resolved "https://registry.yarnpkg.com/broccoli-debug/-/broccoli-debug-0.6.4.tgz#986eb3d2005e00e3bb91f9d0a10ab137210cd150" + dependencies: + broccoli-plugin "^1.2.1" + fs-tree-diff "^0.5.2" + heimdalljs "^0.2.1" + heimdalljs-logger "^0.1.7" + symlink-or-copy "^1.1.8" + tree-sync "^1.2.2" + broccoli-file-creator@^1.0.0, broccoli-file-creator@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/broccoli-file-creator/-/broccoli-file-creator-1.1.1.tgz#1b35b67d215abdfadd8d49eeb69493c39e6c3450" @@ -1354,7 +1295,7 @@ broccoli-funnel-reducer@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/broccoli-funnel-reducer/-/broccoli-funnel-reducer-1.0.0.tgz#11365b2a785aec9b17972a36df87eef24c5cc0ea" -broccoli-funnel@^1.0.0, broccoli-funnel@^1.0.1, broccoli-funnel@^1.0.2, broccoli-funnel@^1.0.6, broccoli-funnel@^1.1.0, broccoli-funnel@^1.2.0: +broccoli-funnel@^1.0.0, broccoli-funnel@^1.0.1, broccoli-funnel@^1.0.2, broccoli-funnel@^1.1.0, broccoli-funnel@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/broccoli-funnel/-/broccoli-funnel-1.2.0.tgz#cddc3afc5ff1685a8023488fff74ce6fb5a51296" dependencies: @@ -1373,6 +1314,24 @@ broccoli-funnel@^1.0.0, broccoli-funnel@^1.0.1, broccoli-funnel@^1.0.2, broccoli symlink-or-copy "^1.0.0" walk-sync "^0.3.1" +broccoli-funnel@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/broccoli-funnel/-/broccoli-funnel-2.0.1.tgz#6823c73b675ef78fffa7ab800f083e768b51d449" + dependencies: + array-equal "^1.0.0" + blank-object "^1.0.1" + broccoli-plugin "^1.3.0" + debug "^2.2.0" + fast-ordered-set "^1.0.0" + fs-tree-diff "^0.5.3" + heimdalljs "^0.2.0" + minimatch "^3.0.0" + mkdirp "^0.5.0" + path-posix "^1.0.0" + rimraf "^2.4.3" + symlink-or-copy "^1.0.0" + walk-sync "^0.3.1" + broccoli-kitchen-sink-helpers@^0.2.5, broccoli-kitchen-sink-helpers@^0.2.6, broccoli-kitchen-sink-helpers@~0.2.0, broccoli-kitchen-sink-helpers@~0.2.4: version "0.2.9" resolved "https://registry.yarnpkg.com/broccoli-kitchen-sink-helpers/-/broccoli-kitchen-sink-helpers-0.2.9.tgz#a5e0986ed8d76fb5984b68c3f0450d3a96e36ecc" @@ -1419,7 +1378,7 @@ broccoli-merge-trees@^2.0.0: broccoli-plugin "^1.3.0" merge-trees "^1.0.1" -broccoli-middleware@^1.0.0-beta.8: +broccoli-middleware@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/broccoli-middleware/-/broccoli-middleware-1.0.0.tgz#92f4e1fb9a791ea986245a7077f35cc648dab097" dependencies: @@ -1805,12 +1764,12 @@ capture-exit@^1.1.0: dependencies: rsvp "^3.3.3" -cardinal@^0.5.0: - version "0.5.0" - resolved "https://registry.yarnpkg.com/cardinal/-/cardinal-0.5.0.tgz#00d5f661dbd4aabfdf7d41ce48a5a59bca35a291" +cardinal@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/cardinal/-/cardinal-1.0.0.tgz#50e21c1b0aa37729f9377def196b5a9cec932ee9" dependencies: ansicolors "~0.2.1" - redeyed "~0.5.0" + redeyed "~1.0.0" caseless@~0.12.0: version "0.12.0" @@ -1851,6 +1810,14 @@ chalk@^2.0.0, chalk@^2.1.0: escape-string-regexp "^1.0.5" supports-color "^4.0.0" +chalk@^2.0.1: + version "2.3.0" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.3.0.tgz#b5ea48efc9c1793dccc9b4767c93914d3f2d52ba" + dependencies: + ansi-styles "^3.1.0" + escape-string-regexp "^1.0.5" + supports-color "^4.0.0" + charm@^1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/charm/-/charm-1.0.2.tgz#8add367153a6d9a581331052c4090991da995e35" @@ -1928,6 +1895,10 @@ cli-spinners@^0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/cli-spinners/-/cli-spinners-0.1.2.tgz#bb764d88e185fb9e1e6a2a1f19772318f605e31c" +cli-spinners@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/cli-spinners/-/cli-spinners-1.1.0.tgz#f1847b168844d917a671eb9d147e3df497c90d06" + cli-table2@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/cli-table2/-/cli-table2-0.2.0.tgz#2d1ef7f218a0e786e214540562d4bd177fe32d97" @@ -2126,13 +2097,13 @@ console-control-strings@^1.0.0, console-control-strings@~1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/console-control-strings/-/console-control-strings-1.1.0.tgz#3d7cf4464db6446ea644bf4b39507f9851008e8e" -console-ui@^1.0.2: - version "1.0.3" - resolved "https://registry.yarnpkg.com/console-ui/-/console-ui-1.0.3.tgz#31c524461b63422769f9e89c173495d91393721c" +console-ui@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/console-ui/-/console-ui-2.0.1.tgz#56d0721ebcc44e6c9c3de02f355f898aba41ea79" dependencies: - chalk "^1.1.3" - inquirer "^1.2.3" - ora "^0.2.0" + chalk "^2.1.0" + inquirer "^2" + ora "^1.3.0" through "^2.3.8" consolidate@^0.14.0: @@ -2189,7 +2160,7 @@ core-object@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/core-object/-/core-object-1.1.0.tgz#86d63918733cf9da1a5aae729e62c0a88e66ad0a" -core-object@^3.0.0: +core-object@^3.1.3: version "3.1.5" resolved "https://registry.yarnpkg.com/core-object/-/core-object-3.1.5.tgz#fa627b87502adc98045e44678e9a8ec3b9c0d2a9" dependencies: @@ -2335,6 +2306,10 @@ d@1: dependencies: es5-ext "^0.10.9" +dag-map@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/dag-map/-/dag-map-2.0.2.tgz#9714b472de82a1843de2fba9b6876938cab44c68" + dashdash@^1.12.0: version "1.14.1" resolved "https://registry.yarnpkg.com/dashdash/-/dashdash-1.14.1.tgz#853cfa0f7cbe2fed5de20326b8dd581035f6e2f0" @@ -2743,10 +2718,14 @@ ember-cli-legacy-blueprints@^0.1.2: rsvp "^3.0.17" silent-error "^1.0.0" -ember-cli-lodash-subset@^1.0.11, ember-cli-lodash-subset@^1.0.7: +ember-cli-lodash-subset@^1.0.7: version "1.0.12" resolved "https://registry.yarnpkg.com/ember-cli-lodash-subset/-/ember-cli-lodash-subset-1.0.12.tgz#af2e77eba5dcb0d77f3308d3a6fd7d3450f6e537" +ember-cli-lodash-subset@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/ember-cli-lodash-subset/-/ember-cli-lodash-subset-2.0.1.tgz#20cb68a790fe0fde2488ddfd8efbb7df6fe766f2" + ember-cli-mirage@^0.3.3: version "0.3.4" resolved "https://registry.yarnpkg.com/ember-cli-mirage/-/ember-cli-mirage-0.3.4.tgz#eeb9d6e02c0c49c81915762178bab9a42d86ada8" @@ -2924,53 +2903,53 @@ ember-cli-version-checker@^2.1.0: resolve "^1.3.3" semver "^5.3.0" -ember-cli@2.13.2: - version "2.13.2" - resolved "https://registry.yarnpkg.com/ember-cli/-/ember-cli-2.13.2.tgz#a561f08e69b184fa3175f706cced299c0d1684e5" +ember-cli@2.17.1: + version "2.17.1" + resolved "https://registry.yarnpkg.com/ember-cli/-/ember-cli-2.17.1.tgz#915a140732cd28d6c3d5b2e890731864ea55ad5b" dependencies: - amd-name-resolver "0.0.6" + amd-name-resolver "1.0.0" babel-plugin-transform-es2015-modules-amd "^6.24.0" bower-config "^1.3.0" bower-endpoint-parser "0.2.2" broccoli-babel-transpiler "^6.0.0" broccoli-brocfile-loader "^0.18.0" - broccoli-builder "^0.18.3" + broccoli-builder "^0.18.8" broccoli-concat "^3.2.2" broccoli-config-loader "^1.0.0" broccoli-config-replace "^1.1.2" - broccoli-funnel "^1.0.6" + broccoli-debug "^0.6.3" + broccoli-funnel "^2.0.0" broccoli-funnel-reducer "^1.0.0" broccoli-merge-trees "^2.0.0" - broccoli-middleware "^1.0.0-beta.8" + broccoli-middleware "^1.0.0" broccoli-source "^1.1.0" broccoli-stew "^1.2.0" calculate-cache-key-for-tree "^1.0.0" capture-exit "^1.1.0" - chalk "^1.1.3" + chalk "^2.0.1" clean-base-url "^1.0.0" compression "^1.4.4" configstore "^3.0.0" - console-ui "^1.0.2" - core-object "^3.0.0" + console-ui "^2.0.0" + core-object "^3.1.3" + dag-map "^2.0.2" diff "^3.2.0" ember-cli-broccoli-sane-watcher "^2.0.4" - ember-cli-get-component-path-option "^1.0.0" ember-cli-is-package-missing "^1.0.0" ember-cli-legacy-blueprints "^0.1.2" - ember-cli-lodash-subset "^1.0.11" + ember-cli-lodash-subset "^2.0.1" ember-cli-normalize-entity-name "^1.0.0" ember-cli-preprocess-registry "^3.1.0" ember-cli-string-utils "^1.0.0" - ember-try "^0.2.14" + ember-try "^0.2.15" ensure-posix-path "^1.0.2" - escape-string-regexp "^1.0.3" - execa "^0.6.0" + execa "^0.8.0" exists-sync "0.0.4" exit "^0.1.2" express "^4.12.3" filesize "^3.1.3" find-up "^2.1.0" - fs-extra "2.0.0" + fs-extra "^4.0.0" fs-tree-diff "^0.5.2" get-caller-file "^1.0.0" git-repo-info "^1.4.1" @@ -2981,14 +2960,14 @@ ember-cli@2.13.2: heimdalljs-logger "^0.1.7" http-proxy "^1.9.0" inflection "^1.7.0" - is-git-url "^0.2.0" + is-git-url "^1.0.0" isbinaryfile "^3.0.0" js-yaml "^3.6.1" json-stable-stringify "^1.0.1" leek "0.0.24" lodash.template "^4.2.5" markdown-it "^8.3.0" - markdown-it-terminal "0.0.4" + markdown-it-terminal "0.1.0" minimatch "^3.0.0" morgan "^1.8.1" node-modules-path "^1.0.0" @@ -2998,14 +2977,14 @@ ember-cli@2.13.2: promise-map-series "^0.2.1" quick-temp "^0.1.8" resolve "^1.3.0" - rsvp "^3.3.3" + rsvp "^4.7.0" sane "^1.6.0" semver "^5.1.1" silent-error "^1.0.0" sort-package-json "^1.4.0" symlink-or-copy "^1.1.8" temp "0.8.3" - testem "^1.15.0" + testem "^1.18.0" tiny-lr "^1.0.3" tree-sync "^1.2.1" uuid "^3.0.0" @@ -3261,7 +3240,7 @@ ember-rfc176-data@^0.3.0: version "0.3.1" resolved "https://registry.yarnpkg.com/ember-rfc176-data/-/ember-rfc176-data-0.3.1.tgz#6a5a4b8b82ec3af34f3010965fa96b936ca94519" -ember-router-generator@^1.0.0: +ember-router-generator@^1.0.0, ember-router-generator@^1.2.3: version "1.2.3" resolved "https://registry.yarnpkg.com/ember-router-generator/-/ember-router-generator-1.2.3.tgz#8ed2ca86ff323363120fc14278191e9e8f1315ee" dependencies: @@ -3283,30 +3262,25 @@ ember-sinon@^0.7.0: ember-cli-babel "^5.1.7" sinon "^2.1.0" -ember-source@~2.14.0: - version "2.14.1" - resolved "https://registry.yarnpkg.com/ember-source/-/ember-source-2.14.1.tgz#4abf0b4c916f2da8bf317349df4750905df7e628" +ember-source@~2.17.0: + version "2.17.0" + resolved "https://registry.yarnpkg.com/ember-source/-/ember-source-2.17.0.tgz#b78871dd49bd8d642b80176df4faf7fd7d059dac" dependencies: - "@glimmer/compiler" "^0.22.3" - "@glimmer/node" "^0.22.3" - "@glimmer/reference" "^0.22.3" - "@glimmer/runtime" "^0.22.3" - "@glimmer/util" "^0.22.3" broccoli-funnel "^1.2.0" broccoli-merge-trees "^2.0.0" ember-cli-get-component-path-option "^1.0.0" + ember-cli-is-package-missing "^1.0.0" ember-cli-normalize-entity-name "^1.0.0" ember-cli-path-utils "^1.0.0" ember-cli-string-utils "^1.1.0" ember-cli-test-info "^1.0.0" ember-cli-valid-component-name "^1.0.0" - ember-cli-version-checker "^1.3.1" - handlebars "^4.0.6" + ember-cli-version-checker "^2.1.0" + ember-router-generator "^1.2.3" + fs-extra "^4.0.1" + inflection "^1.12.0" jquery "^3.2.1" resolve "^1.3.3" - rsvp "^3.5.0" - simple-dom "^0.3.0" - simple-html-tokenizer "^0.4.1" ember-test-helpers@^0.6.3: version "0.6.3" @@ -3324,25 +3298,24 @@ ember-truth-helpers@^1.3.0: dependencies: ember-cli-babel "^5.1.6" -ember-try-config@^2.0.1: - version "2.1.0" - resolved "https://registry.yarnpkg.com/ember-try-config/-/ember-try-config-2.1.0.tgz#e0e156229a542346a58ee6f6ad605104c98edfe0" +ember-try-config@^2.2.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/ember-try-config/-/ember-try-config-2.2.0.tgz#6be0af6c71949813e02ac793564fddbf8336b807" dependencies: lodash "^4.6.1" node-fetch "^1.3.3" rsvp "^3.2.1" semver "^5.1.0" -ember-try@^0.2.14: - version "0.2.16" - resolved "https://registry.yarnpkg.com/ember-try/-/ember-try-0.2.16.tgz#cf7092d8a8fea9701d7faa73cbdbff37a8ada330" +ember-try@^0.2.15: + version "0.2.22" + resolved "https://registry.yarnpkg.com/ember-try/-/ember-try-0.2.22.tgz#3989e9c013c1d5c209ec97f5dfcf4234e594d5e2" dependencies: chalk "^1.0.0" cli-table2 "^0.2.0" core-object "^1.1.0" debug "^2.2.0" - ember-cli-version-checker "^1.1.6" - ember-try-config "^2.0.1" + ember-try-config "^2.2.0" extend "^3.0.0" fs-extra "^0.26.0" promise-map-series "^0.2.1" @@ -3502,7 +3475,7 @@ escape-html@~1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/escape-html/-/escape-html-1.0.3.tgz#0258eae4d3d0c0974de1c169188ef0051d1d1988" -escape-string-regexp@^1.0.0, escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.3, escape-string-regexp@^1.0.5: +escape-string-regexp@^1.0.0, escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" @@ -3611,10 +3584,6 @@ espree@^3.4.0, espree@^3.5.0: acorn "^5.1.1" acorn-jsx "^3.0.0" -esprima-fb@~12001.1.0-dev-harmony-fb: - version "12001.1.0-dev-harmony-fb" - resolved "https://registry.yarnpkg.com/esprima-fb/-/esprima-fb-12001.1.0-dev-harmony-fb.tgz#d84400384ba95ce2678c617ad24a7f40808da915" - esprima-fb@~15001.1001.0-dev-harmony-fb: version "15001.1001.0-dev-harmony-fb" resolved "https://registry.yarnpkg.com/esprima-fb/-/esprima-fb-15001.1001.0-dev-harmony-fb.tgz#43beb57ec26e8cf237d3dd8b33e42533577f2659" @@ -3627,6 +3596,10 @@ esprima@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.0.tgz#4499eddcd1110e0b218bacf2fa7f7f59f55ca804" +esprima@~3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/esprima/-/esprima-3.0.0.tgz#53cf247acda77313e551c3aa2e73342d3fb4f7d9" + esprima@~3.1.0: version "3.1.3" resolved "https://registry.yarnpkg.com/esprima/-/esprima-3.1.3.tgz#fdca51cee6133895e3c88d535ce49dbff62a4633" @@ -3688,9 +3661,9 @@ exec-sh@^0.2.0: dependencies: merge "^1.1.3" -execa@^0.6.0: - version "0.6.3" - resolved "https://registry.yarnpkg.com/execa/-/execa-0.6.3.tgz#57b69a594f081759c69e5370f0d17b9cb11658fe" +execa@^0.7.0: + version "0.7.0" + resolved "https://registry.yarnpkg.com/execa/-/execa-0.7.0.tgz#944becd34cc41ee32a63a9faf27ad5a65fc59777" dependencies: cross-spawn "^5.0.1" get-stream "^3.0.0" @@ -3700,9 +3673,9 @@ execa@^0.6.0: signal-exit "^3.0.0" strip-eof "^1.0.0" -execa@^0.7.0: - version "0.7.0" - resolved "https://registry.yarnpkg.com/execa/-/execa-0.7.0.tgz#944becd34cc41ee32a63a9faf27ad5a65fc59777" +execa@^0.8.0: + version "0.8.0" + resolved "https://registry.yarnpkg.com/execa/-/execa-0.8.0.tgz#d8d76bbc1b55217ed190fd6dd49d3c774ecfc8da" dependencies: cross-spawn "^5.0.1" get-stream "^3.0.0" @@ -4006,13 +3979,6 @@ fs-exists-sync@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/fs-exists-sync/-/fs-exists-sync-0.1.0.tgz#982d6893af918e72d08dec9e8673ff2b5a8d6add" -fs-extra@2.0.0, fs-extra@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-2.0.0.tgz#337352bded4a0b714f3eb84de8cea765e9d37600" - dependencies: - graceful-fs "^4.1.2" - jsonfile "^2.1.0" - fs-extra@^0.24.0: version "0.24.0" resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-0.24.0.tgz#d4e4342a96675cb7846633a6099249332b539952" @@ -4050,6 +4016,21 @@ fs-extra@^1.0.0: jsonfile "^2.1.0" klaw "^1.0.0" +fs-extra@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-2.0.0.tgz#337352bded4a0b714f3eb84de8cea765e9d37600" + dependencies: + graceful-fs "^4.1.2" + jsonfile "^2.1.0" + +fs-extra@^4.0.0, fs-extra@^4.0.1: + version "4.0.3" + resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-4.0.3.tgz#0d852122e5bc5beb453fb028e9c0c9bf36340c94" + dependencies: + graceful-fs "^4.1.2" + jsonfile "^4.0.0" + universalify "^0.1.0" + fs-readdir-recursive@^0.1.0: version "0.1.2" resolved "https://registry.yarnpkg.com/fs-readdir-recursive/-/fs-readdir-recursive-0.1.2.tgz#315b4fb8c1ca5b8c47defef319d073dad3568059" @@ -4257,7 +4238,7 @@ growly@^1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/growly/-/growly-1.3.0.tgz#f10748cbe76af964b7c96c93c6bcc28af120c081" -handlebars@^4.0.4, handlebars@^4.0.6: +handlebars@^4.0.4: version "4.0.10" resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-4.0.10.tgz#3d30c718b09a3d96f23ea4cc1f403c4d3ba9ff4f" dependencies: @@ -4507,7 +4488,7 @@ indexof@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/indexof/-/indexof-0.0.1.tgz#82dc336d232b9062179d05ab3293a66059fd435d" -inflection@^1.7.0, inflection@^1.7.1, inflection@^1.8.0: +inflection@^1.12.0, inflection@^1.7.0, inflection@^1.7.1, inflection@^1.8.0: version "1.12.0" resolved "https://registry.yarnpkg.com/inflection/-/inflection-1.12.0.tgz#a200935656d6f5f6bc4dc7502e1aecb703228416" @@ -4564,22 +4545,22 @@ inquirer@^0.12.0: strip-ansi "^3.0.0" through "^2.3.6" -inquirer@^1.2.3: - version "1.2.3" - resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-1.2.3.tgz#4dec6f32f37ef7bb0b2ed3f1d1a5c3f545074918" +inquirer@^2: + version "2.0.0" + resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-2.0.0.tgz#e1351687b90d150ca403ceaa3cefb1e3065bef4b" dependencies: ansi-escapes "^1.1.0" chalk "^1.0.0" cli-cursor "^1.0.1" cli-width "^2.0.0" external-editor "^1.1.0" - figures "^1.3.5" + figures "^2.0.0" lodash "^4.3.0" mute-stream "0.0.6" pinkie-promise "^2.0.0" run-async "^2.2.0" rx "^4.1.0" - string-width "^1.0.1" + string-width "^2.0.0" strip-ansi "^3.0.0" through "^2.3.6" @@ -4697,6 +4678,10 @@ is-git-url@^0.2.0: version "0.2.3" resolved "https://registry.yarnpkg.com/is-git-url/-/is-git-url-0.2.3.tgz#445200d6fbd6da028fb5e01440d9afc93f3ccb64" +is-git-url@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/is-git-url/-/is-git-url-1.0.0.tgz#53f684cd143285b52c3244b4e6f28253527af66b" + is-glob@^2.0.0, is-glob@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-2.0.1.tgz#d096f926a3ded5600f3fdfd91198cb0888c2d863" @@ -4932,6 +4917,12 @@ jsonfile@^2.1.0: optionalDependencies: graceful-fs "^4.1.6" +jsonfile@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/jsonfile/-/jsonfile-4.0.0.tgz#8771aae0799b64076b76640fca058f9c10e33ecb" + optionalDependencies: + graceful-fs "^4.1.6" + jsonify@~0.0.0: version "0.0.0" resolved "https://registry.yarnpkg.com/jsonify/-/jsonify-0.0.0.tgz#2c74b6ee41d93ca51b7b5aaee8f503631d252a73" @@ -5020,12 +5011,6 @@ linkify-it@^2.0.0: dependencies: uc.micro "^1.0.1" -linkify-it@~1.2.0: - version "1.2.4" - resolved "https://registry.yarnpkg.com/linkify-it/-/linkify-it-1.2.4.tgz#0773526c317c8fd13bd534ee1d180ff88abf881a" - dependencies: - uc.micro "^1.0.1" - lint-staged@^3.6.1: version "3.6.1" resolved "https://registry.yarnpkg.com/lint-staged/-/lint-staged-3.6.1.tgz#24423c8b7bd99d96e15acd1ac8cb392a78e58582" @@ -5125,14 +5110,6 @@ lodash-es@^4.17.4: version "4.17.4" resolved "https://registry.yarnpkg.com/lodash-es/-/lodash-es-4.17.4.tgz#dcc1d7552e150a0640073ba9cb31d70f032950e7" -lodash._arraycopy@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/lodash._arraycopy/-/lodash._arraycopy-3.0.0.tgz#76e7b7c1f1fb92547374878a562ed06a3e50f6e1" - -lodash._arrayeach@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/lodash._arrayeach/-/lodash._arrayeach-3.0.0.tgz#bab156b2a90d3f1bbd5c653403349e5e5933ef9e" - lodash._baseassign@^3.0.0: version "3.2.0" resolved "https://registry.yarnpkg.com/lodash._baseassign/-/lodash._baseassign-3.2.0.tgz#8c38a099500f215ad09e59f1722fd0c52bfe0a4e" @@ -5185,10 +5162,6 @@ lodash._baseflatten@^3.0.0: lodash.isarguments "^3.0.0" lodash.isarray "^3.0.0" -lodash._basefor@^3.0.0: - version "3.0.3" - resolved "https://registry.yarnpkg.com/lodash._basefor/-/lodash._basefor-3.0.3.tgz#7550b4e9218ef09fad24343b612021c79b4c20c2" - lodash._basetostring@^3.0.0: version "3.0.1" resolved "https://registry.yarnpkg.com/lodash._basetostring/-/lodash._basetostring-3.0.1.tgz#d1861d877f824a52f669832dcaf3ee15566a07d5" @@ -5398,18 +5371,6 @@ lodash.isobject@~2.3.0: dependencies: lodash._objecttypes "~2.3.0" -lodash.isplainobject@^3.0.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/lodash.isplainobject/-/lodash.isplainobject-3.2.0.tgz#9a8238ae16b200432960cd7346512d0123fbf4c5" - dependencies: - lodash._basefor "^3.0.0" - lodash.isarguments "^3.0.0" - lodash.keysin "^3.0.0" - -lodash.istypedarray@^3.0.0: - version "3.0.6" - resolved "https://registry.yarnpkg.com/lodash.istypedarray/-/lodash.istypedarray-3.0.6.tgz#c9a477498607501d8e8494d283b87c39281cef62" - lodash.keys@^3.0.0: version "3.1.2" resolved "https://registry.yarnpkg.com/lodash.keys/-/lodash.keys-3.1.2.tgz#4dbc0472b156be50a0b286855d1bd0b0c656098a" @@ -5426,34 +5387,11 @@ lodash.keys@~2.3.0: lodash._shimkeys "~2.3.0" lodash.isobject "~2.3.0" -lodash.keysin@^3.0.0: - version "3.0.8" - resolved "https://registry.yarnpkg.com/lodash.keysin/-/lodash.keysin-3.0.8.tgz#22c4493ebbedb1427962a54b445b2c8a767fb47f" - dependencies: - lodash.isarguments "^3.0.0" - lodash.isarray "^3.0.0" - lodash.memoize@~3.0.3: version "3.0.4" resolved "https://registry.yarnpkg.com/lodash.memoize/-/lodash.memoize-3.0.4.tgz#2dcbd2c287cbc0a55cc42328bd0c736150d53e3f" -lodash.merge@^3.3.2: - version "3.3.2" - resolved "https://registry.yarnpkg.com/lodash.merge/-/lodash.merge-3.3.2.tgz#0d90d93ed637b1878437bb3e21601260d7afe994" - dependencies: - lodash._arraycopy "^3.0.0" - lodash._arrayeach "^3.0.0" - lodash._createassigner "^3.0.0" - lodash._getnative "^3.0.0" - lodash.isarguments "^3.0.0" - lodash.isarray "^3.0.0" - lodash.isplainobject "^3.0.0" - lodash.istypedarray "^3.0.0" - lodash.keys "^3.0.0" - lodash.keysin "^3.0.0" - lodash.toplainobject "^3.0.0" - -lodash.merge@^4.3.0, lodash.merge@^4.4.0, lodash.merge@^4.5.1: +lodash.merge@^4.3.0, lodash.merge@^4.4.0, lodash.merge@^4.5.1, lodash.merge@^4.6.0: version "4.6.0" resolved "https://registry.yarnpkg.com/lodash.merge/-/lodash.merge-4.6.0.tgz#69884ba144ac33fe699737a6086deffadd0f89c5" @@ -5532,13 +5470,6 @@ lodash.templatesettings@~2.3.0: lodash._reinterpolate "~2.3.0" lodash.escape "~2.3.0" -lodash.toplainobject@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/lodash.toplainobject/-/lodash.toplainobject-3.0.0.tgz#28790ad942d293d78aa663a07ecf7f52ca04198d" - dependencies: - lodash._basecopy "^3.0.0" - lodash.keysin "^3.0.0" - lodash.uniq@^4.2.0: version "4.5.0" resolved "https://registry.yarnpkg.com/lodash.uniq/-/lodash.uniq-4.5.0.tgz#d0225373aeb652adc1bc82e4945339a842754773" @@ -5618,27 +5549,17 @@ map-obj@^1.0.0, map-obj@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/map-obj/-/map-obj-1.0.1.tgz#d933ceb9205d82bdcf4886f6742bdc2b4dea146d" -markdown-it-terminal@0.0.4: - version "0.0.4" - resolved "https://registry.yarnpkg.com/markdown-it-terminal/-/markdown-it-terminal-0.0.4.tgz#3f2ce624ba2ca964a78b8b388d605ee330de9ced" +markdown-it-terminal@0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/markdown-it-terminal/-/markdown-it-terminal-0.1.0.tgz#545abd8dd01c3d62353bfcea71db580b51d22bd9" dependencies: - ansi-styles "^2.1.0" - cardinal "^0.5.0" + ansi-styles "^3.0.0" + cardinal "^1.0.0" cli-table "^0.3.1" - lodash.merge "^3.3.2" - markdown-it "^4.4.0" + lodash.merge "^4.6.0" + markdown-it "^8.3.1" -markdown-it@^4.4.0: - version "4.4.0" - resolved "https://registry.yarnpkg.com/markdown-it/-/markdown-it-4.4.0.tgz#3df373dbea587a9a7fef3e56311b68908f75c414" - dependencies: - argparse "~1.0.2" - entities "~1.1.1" - linkify-it "~1.2.0" - mdurl "~1.0.0" - uc.micro "^1.0.0" - -markdown-it@^8.3.0: +markdown-it@^8.3.0, markdown-it@^8.3.1: version "8.4.0" resolved "https://registry.yarnpkg.com/markdown-it/-/markdown-it-8.4.0.tgz#e2400881bf171f7018ed1bd9da441dac8af6306d" dependencies: @@ -5677,7 +5598,7 @@ md5.js@^1.3.4: hash-base "^3.0.0" inherits "^2.0.1" -mdurl@^1.0.1, mdurl@~1.0.0: +mdurl@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/mdurl/-/mdurl-1.0.1.tgz#fe85b2ec75a59037f2adfec100fd6c601761152e" @@ -6150,7 +6071,7 @@ options@>=0.0.5: version "0.0.6" resolved "https://registry.yarnpkg.com/options/-/options-0.0.6.tgz#ec22d312806bb53e731773e7cdaefcf1c643128f" -ora@^0.2.0, ora@^0.2.3: +ora@^0.2.3: version "0.2.3" resolved "https://registry.yarnpkg.com/ora/-/ora-0.2.3.tgz#37527d220adcd53c39b73571d754156d5db657a4" dependencies: @@ -6159,6 +6080,15 @@ ora@^0.2.0, ora@^0.2.3: cli-spinners "^0.1.2" object-assign "^4.0.1" +ora@^1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/ora/-/ora-1.3.0.tgz#80078dd2b92a934af66a3ad72a5b910694ede51a" + dependencies: + chalk "^1.1.1" + cli-cursor "^2.1.0" + cli-spinners "^1.0.0" + log-symbols "^1.0.2" + os-browserify@~0.1.1: version "0.1.2" resolved "https://registry.yarnpkg.com/os-browserify/-/os-browserify-0.1.2.tgz#49ca0293e0b19590a5f5de10c7f265a617d8fe54" @@ -6678,11 +6608,11 @@ redent@^1.0.0: indent-string "^2.1.0" strip-indent "^1.0.1" -redeyed@~0.5.0: - version "0.5.0" - resolved "https://registry.yarnpkg.com/redeyed/-/redeyed-0.5.0.tgz#7ab000e60ee3875ac115d29edb32c1403c6c25d1" +redeyed@~1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/redeyed/-/redeyed-1.0.1.tgz#e96c193b40c0816b00aec842698e61185e55498a" dependencies: - esprima-fb "~12001.1.0-dev-harmony-fb" + esprima "~3.0.0" regenerate@^1.2.1: version "1.3.2" @@ -6910,6 +6840,10 @@ rsvp@^3.0.14, rsvp@^3.0.16, rsvp@^3.0.17, rsvp@^3.0.18, rsvp@^3.0.21, rsvp@^3.0. version "3.6.2" resolved "https://registry.yarnpkg.com/rsvp/-/rsvp-3.6.2.tgz#2e96491599a96cde1b515d5674a8f7a91452926a" +rsvp@^4.7.0: + version "4.7.0" + resolved "https://registry.yarnpkg.com/rsvp/-/rsvp-4.7.0.tgz#dc1b0b1a536f7dec9d2be45e0a12ad4197c9fd96" + rsvp@~3.0.6: version "3.0.21" resolved "https://registry.yarnpkg.com/rsvp/-/rsvp-3.0.21.tgz#49c588fe18ef293bcd0ab9f4e6756e6ac433359f" @@ -7109,22 +7043,10 @@ silent-error@^1.0.0, silent-error@^1.0.1, silent-error@^1.1.0: dependencies: debug "^2.2.0" -simple-dom@^0.3.0: - version "0.3.2" - resolved "https://registry.yarnpkg.com/simple-dom/-/simple-dom-0.3.2.tgz#0663d10f1556f1500551d518f56e3aba0871371d" - simple-fmt@~0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/simple-fmt/-/simple-fmt-0.1.0.tgz#191bf566a59e6530482cb25ab53b4a8dc85c3a6b" -simple-html-tokenizer@^0.3.0: - version "0.3.0" - resolved "https://registry.yarnpkg.com/simple-html-tokenizer/-/simple-html-tokenizer-0.3.0.tgz#9b8b5559d80e331a544dd13dd59382e5d0d94411" - -simple-html-tokenizer@^0.4.1: - version "0.4.1" - resolved "https://registry.yarnpkg.com/simple-html-tokenizer/-/simple-html-tokenizer-0.4.1.tgz#028988bb7fe8b2e6645676d82052587d440b02d3" - simple-is@~0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/simple-is/-/simple-is-0.2.0.tgz#2abb75aade39deb5cc815ce10e6191164850baf0" @@ -7587,7 +7509,7 @@ testem@1.15.0: tap-parser "^5.1.0" xmldom "^0.1.19" -testem@^1.15.0: +testem@^1.18.0: version "1.18.4" resolved "https://registry.yarnpkg.com/testem/-/testem-1.18.4.tgz#e45fed922bec2f54a616c43f11922598ac97eb41" dependencies: @@ -7763,7 +7685,7 @@ typedarray@^0.0.6, typedarray@~0.0.5: version "0.0.6" resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777" -uc.micro@^1.0.0, uc.micro@^1.0.1, uc.micro@^1.0.3: +uc.micro@^1.0.1, uc.micro@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/uc.micro/-/uc.micro-1.0.3.tgz#7ed50d5e0f9a9fb0a573379259f2a77458d50192" @@ -7809,6 +7731,10 @@ unique-string@^1.0.0: dependencies: crypto-random-string "^1.0.0" +universalify@^0.1.0: + version "0.1.1" + resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.1.1.tgz#fa71badd4437af4c148841e3b3b165f9e9e590b7" + unpipe@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/unpipe/-/unpipe-1.0.0.tgz#b2bf4ee8514aae6165b4817829d21b2ef49904ec" From 5a94a50074f28bb6f98d5137609c435367493a99 Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Mon, 11 Dec 2017 17:59:26 -0800 Subject: [PATCH 084/136] Upgrade to Ember Data 2.17 --- ui/package.json | 2 +- ui/yarn.lock | 49 ++++++++++--------------------------------------- 2 files changed, 11 insertions(+), 40 deletions(-) diff --git a/ui/package.json b/ui/package.json index dd49aa5f1..3c7c3b842 100644 --- a/ui/package.json +++ b/ui/package.json @@ -52,7 +52,7 @@ "ember-cli-uglify": "^1.2.0", "ember-composable-helpers": "^2.0.3", "ember-concurrency": "^0.8.12", - "ember-data": "^2.14.0", + "ember-data": "~2.17.0", "ember-data-model-fragments": "^2.14.0", "ember-export-application-global": "^2.0.0", "ember-fetch": "^3.2.7", diff --git a/ui/yarn.lock b/ui/yarn.lock index de9eb1405..0f0c39d00 100644 --- a/ui/yarn.lock +++ b/ui/yarn.lock @@ -567,7 +567,7 @@ babel-plugin-debug-macros@^0.1.10, babel-plugin-debug-macros@^0.1.11: dependencies: semver "^5.3.0" -babel-plugin-ember-modules-api-polyfill@^1.5.1: +babel-plugin-ember-modules-api-polyfill@^1.4.2, babel-plugin-ember-modules-api-polyfill@^1.5.1: version "1.6.0" resolved "https://registry.yarnpkg.com/babel-plugin-ember-modules-api-polyfill/-/babel-plugin-ember-modules-api-polyfill-1.6.0.tgz#abd1afa4237b3121cb51222f9bf3283cad8990aa" dependencies: @@ -1705,7 +1705,7 @@ cached-path-relative@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/cached-path-relative/-/cached-path-relative-1.0.1.tgz#d09c4b52800aa4c078e2dd81a869aac90d2e54e7" -calculate-cache-key-for-tree@^1.0.0: +calculate-cache-key-for-tree@^1.0.0, calculate-cache-key-for-tree@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/calculate-cache-key-for-tree/-/calculate-cache-key-for-tree-1.1.0.tgz#0c3e42c9c134f3c9de5358c0f16793627ea976d6" dependencies: @@ -2217,7 +2217,7 @@ cross-spawn@^3.0.0: lru-cache "^4.0.1" which "^1.2.9" -cross-spawn@^5.0.0, cross-spawn@^5.0.1, cross-spawn@^5.1.0: +cross-spawn@^5.0.1, cross-spawn@^5.1.0: version "5.1.0" resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-5.1.0.tgz#e8bd0efee58fcff6f8f94510a0a554bbfa235449" dependencies: @@ -3028,11 +3028,12 @@ ember-data-model-fragments@^2.14.0: git-repo-info "^1.4.1" npm-git-info "^1.0.3" -ember-data@^2.14.0: - version "2.14.10" - resolved "https://registry.yarnpkg.com/ember-data/-/ember-data-2.14.10.tgz#acf66ffffb062a7fc999f9d989d0e0d2e3858cd3" +ember-data@~2.17.0: + version "2.17.0" + resolved "https://registry.yarnpkg.com/ember-data/-/ember-data-2.17.0.tgz#d952cf98d7461abf41ed6d248cf2a5836c623276" dependencies: amd-name-resolver "0.0.7" + babel-plugin-ember-modules-api-polyfill "^1.4.2" babel-plugin-feature-flags "^0.3.1" babel-plugin-filter-imports "^0.3.1" babel-plugin-transform-es2015-block-scoping "^6.24.1" @@ -3042,10 +3043,11 @@ ember-data@^2.14.0: broccoli-debug "^0.6.2" broccoli-file-creator "^1.0.0" broccoli-funnel "^1.2.0" - broccoli-merge-trees "^1.0.0" + broccoli-merge-trees "^2.0.0" broccoli-rollup "^1.2.0" + calculate-cache-key-for-tree "^1.1.0" chalk "^1.1.1" - ember-cli-babel "^6.4.1" + ember-cli-babel "^6.8.2" ember-cli-path-utils "^1.0.0" ember-cli-string-utils "^1.0.0" ember-cli-test-info "^1.0.0" @@ -3059,7 +3061,6 @@ ember-data@^2.14.0: npm-git-info "^1.0.0" semver "^5.1.0" silent-error "^1.0.0" - testem "1.15.0" ember-export-application-global@^2.0.0: version "2.0.0" @@ -7479,36 +7480,6 @@ temp@0.8.3: os-tmpdir "^1.0.0" rimraf "~2.2.6" -testem@1.15.0: - version "1.15.0" - resolved "https://registry.yarnpkg.com/testem/-/testem-1.15.0.tgz#2e3a9e7ac29f16a20f718eb0c4b12e7a44900675" - dependencies: - backbone "^1.1.2" - bluebird "^3.4.6" - charm "^1.0.0" - commander "^2.6.0" - consolidate "^0.14.0" - cross-spawn "^5.0.0" - express "^4.10.7" - fireworm "^0.7.0" - glob "^7.0.4" - http-proxy "^1.13.1" - js-yaml "^3.2.5" - lodash.assignin "^4.1.0" - lodash.clonedeep "^4.4.1" - lodash.find "^4.5.1" - mkdirp "^0.5.1" - mustache "^2.2.1" - node-notifier "^5.0.1" - npmlog "^4.0.0" - printf "^0.2.3" - rimraf "^2.4.4" - socket.io "1.6.0" - spawn-args "^0.2.0" - styled_string "0.0.1" - tap-parser "^5.1.0" - xmldom "^0.1.19" - testem@^1.18.0: version "1.18.4" resolved "https://registry.yarnpkg.com/testem/-/testem-1.18.4.tgz#e45fed922bec2f54a616c43f11922598ac97eb41" From cb3e4a3905e93c3ac3235018322f82b4f17d5def Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Mon, 11 Dec 2017 18:27:53 -0800 Subject: [PATCH 085/136] Never use native fetch when mirage is enabled Unfortunately, Mirage/Pretender don't support fetch --- ui/app/utils/fetch.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ui/app/utils/fetch.js b/ui/app/utils/fetch.js index 98b81a889..bad071006 100644 --- a/ui/app/utils/fetch.js +++ b/ui/app/utils/fetch.js @@ -1,8 +1,10 @@ import Ember from 'ember'; import fetch from 'fetch'; +import config from '../config/environment'; // The ember-fetch polyfill does not provide streaming // Additionally, Mirage/Pretender does not support fetch -const fetchToUse = Ember.testing ? fetch : window.fetch || fetch; +const mirageEnabled = config['ember-cli-mirage'] && config['ember-cli-mirage'].enabled !== false; +const fetchToUse = Ember.testing || mirageEnabled ? fetch : window.fetch || fetch; export default fetchToUse; From e892d48608e4c86b8a411247ba5205f9b2eba85a Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Tue, 12 Dec 2017 13:28:40 -0800 Subject: [PATCH 086/136] Upgrade Ember CLI Mirage to 0.4.1 --- ui/mirage/config.js | 1 + ui/package.json | 2 +- ui/yarn.lock | 46 +++++++++++++++++++++++++++++++-------------- 3 files changed, 34 insertions(+), 15 deletions(-) diff --git a/ui/mirage/config.js b/ui/mirage/config.js index dd23a35e7..b32c70b7c 100644 --- a/ui/mirage/config.js +++ b/ui/mirage/config.js @@ -14,6 +14,7 @@ export default function() { this.timing = 0; // delay for each request, automatically set to 0 during testing this.namespace = 'v1'; + this.trackRequests = Ember.testing; this.get('/jobs', function({ jobs }, { queryParams }) { const json = this.serialize(jobs.all()); diff --git a/ui/package.json b/ui/package.json index 3c7c3b842..490c8bff8 100644 --- a/ui/package.json +++ b/ui/package.json @@ -42,7 +42,7 @@ "ember-cli-htmlbars": "^1.1.1", "ember-cli-htmlbars-inline-precompile": "^0.4.0", "ember-cli-inject-live-reload": "^1.4.1", - "ember-cli-mirage": "^0.3.3", + "ember-cli-mirage": "^0.4.1", "ember-cli-moment-shim": "^3.3.3", "ember-cli-qunit": "^4.0.0", "ember-cli-sass": "^6.2.0", diff --git a/ui/yarn.lock b/ui/yarn.lock index 0f0c39d00..2b7e95bb9 100644 --- a/ui/yarn.lock +++ b/ui/yarn.lock @@ -2596,6 +2596,24 @@ ember-cli-babel@^6.0.0, ember-cli-babel@^6.0.0-beta.4, ember-cli-babel@^6.0.0-be clone "^2.0.0" ember-cli-version-checker "^2.0.0" +ember-cli-babel@^6.3.0: + version "6.10.0" + resolved "https://registry.yarnpkg.com/ember-cli-babel/-/ember-cli-babel-6.10.0.tgz#81424acd1d97fb13658168121eeb2007d6edee84" + dependencies: + amd-name-resolver "0.0.7" + babel-plugin-debug-macros "^0.1.11" + babel-plugin-ember-modules-api-polyfill "^2.0.1" + babel-plugin-transform-es2015-modules-amd "^6.24.0" + babel-polyfill "^6.16.0" + babel-preset-env "^1.5.1" + broccoli-babel-transpiler "^6.1.2" + broccoli-debug "^0.6.2" + broccoli-funnel "^1.0.0" + broccoli-source "^1.1.0" + clone "^2.0.0" + ember-cli-version-checker "^2.1.0" + semver "^5.4.1" + ember-cli-babel@^6.8.2: version "6.9.0" resolved "https://registry.yarnpkg.com/ember-cli-babel/-/ember-cli-babel-6.9.0.tgz#5147391389bdbb7091d15f81ae1dff1eb49d71aa" @@ -2726,23 +2744,23 @@ ember-cli-lodash-subset@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/ember-cli-lodash-subset/-/ember-cli-lodash-subset-2.0.1.tgz#20cb68a790fe0fde2488ddfd8efbb7df6fe766f2" -ember-cli-mirage@^0.3.3: - version "0.3.4" - resolved "https://registry.yarnpkg.com/ember-cli-mirage/-/ember-cli-mirage-0.3.4.tgz#eeb9d6e02c0c49c81915762178bab9a42d86ada8" +ember-cli-mirage@^0.4.1: + version "0.4.1" + resolved "https://registry.yarnpkg.com/ember-cli-mirage/-/ember-cli-mirage-0.4.1.tgz#bfdfe61e5e74dc3881ed31f12112dae1a29f0d4c" dependencies: broccoli-funnel "^1.0.2" broccoli-merge-trees "^1.1.0" broccoli-stew "^1.5.0" chalk "^1.1.1" - ember-cli-babel "^5.1.7" + ember-cli-babel "^6.8.2" ember-cli-node-assets "^0.1.4" - ember-get-config "0.2.1" + ember-get-config "^0.2.2" ember-inflector "^2.0.0" ember-lodash "^4.17.3" exists-sync "0.0.3" fake-xml-http-request "^1.4.0" faker "^3.0.0" - pretender "^1.4.2" + pretender "^1.6.1" route-recognizer "^0.2.3" ember-cli-moment-shim@^3.3.3: @@ -3104,12 +3122,12 @@ ember-freestyle@^0.4.1: glob "^7.1.1" highlight.js "^9.3.0" -ember-get-config@0.2.1: - version "0.2.1" - resolved "https://registry.yarnpkg.com/ember-get-config/-/ember-get-config-0.2.1.tgz#a1325cceefcb4534c78fc6ccb2be87a3feda6817" +ember-get-config@^0.2.2: + version "0.2.4" + resolved "https://registry.yarnpkg.com/ember-get-config/-/ember-get-config-0.2.4.tgz#118492a2a03d73e46004ed777928942021fe1ecd" dependencies: broccoli-file-creator "^1.1.1" - ember-cli-babel "^5.1.6" + ember-cli-babel "^6.3.0" ember-getowner-polyfill@^1.2.2: version "1.2.5" @@ -6332,9 +6350,9 @@ preserve@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/preserve/-/preserve-0.2.0.tgz#815ed1f6ebc65926f865b310c0713bcb3315ce4b" -pretender@^1.4.2: - version "1.5.1" - resolved "https://registry.yarnpkg.com/pretender/-/pretender-1.5.1.tgz#bd9098c03d39c3bc7dcb84a28ee27e096e2e32b8" +pretender@^1.6.1: + version "1.6.1" + resolved "https://registry.yarnpkg.com/pretender/-/pretender-1.6.1.tgz#77d1e42ac8c6b298f5cd43534a87645df035db8c" dependencies: fake-xml-http-request "^1.6.0" route-recognizer "^0.3.3" @@ -6933,7 +6951,7 @@ scss-tokenizer@^0.2.3: js-base64 "^2.1.8" source-map "^0.4.2" -"semver@2 || 3 || 4 || 5", semver@^5.1.0, semver@^5.1.1, semver@^5.3.0: +"semver@2 || 3 || 4 || 5", semver@^5.1.0, semver@^5.1.1, semver@^5.3.0, semver@^5.4.1: version "5.4.1" resolved "https://registry.yarnpkg.com/semver/-/semver-5.4.1.tgz#e059c09d8571f0540823733433505d3a2f00b18e" From 53e60500f30df2bdb2d0d7774520add11591b3d9 Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Tue, 12 Dec 2017 16:44:41 -0800 Subject: [PATCH 087/136] Upgrade ember-browserify to 1.2 --- ui/package.json | 2 +- ui/yarn.lock | 90 +++++++++++++++++++++++++++++++++++-------------- 2 files changed, 66 insertions(+), 26 deletions(-) diff --git a/ui/package.json b/ui/package.json index 490c8bff8..1f758b8b6 100644 --- a/ui/package.json +++ b/ui/package.json @@ -33,7 +33,7 @@ "d3-selection": "^1.1.0", "d3-transition": "^1.1.0", "ember-ajax": "^3.0.0", - "ember-browserify": "^1.1.13", + "ember-browserify": "^1.2.0", "ember-cli": "2.17.1", "ember-cli-babel": "^6.0.0", "ember-cli-bourbon": "2.0.0-beta.1", diff --git a/ui/yarn.lock b/ui/yarn.lock index 2b7e95bb9..d3b90f0dd 100644 --- a/ui/yarn.lock +++ b/ui/yarn.lock @@ -51,7 +51,11 @@ acorn@^4.0.3: version "4.0.13" resolved "https://registry.yarnpkg.com/acorn/-/acorn-4.0.13.tgz#105495ae5361d697bd195c825192e1ad7f253787" -acorn@^5.0.3, acorn@^5.1.1: +acorn@^5.0.3, acorn@^5.2.1: + version "5.2.1" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.2.1.tgz#317ac7821826c22c702d66189ab8359675f135d7" + +acorn@^5.1.1: version "5.1.1" resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.1.1.tgz#53fe161111f912ab999ee887a90a0bc52822fd75" @@ -248,8 +252,8 @@ arrify@^1.0.0: resolved "https://registry.yarnpkg.com/arrify/-/arrify-1.0.1.tgz#898508da2226f380df904728456849c1501a4b0d" asn1.js@^4.0.0: - version "4.9.1" - resolved "https://registry.yarnpkg.com/asn1.js/-/asn1.js-4.9.1.tgz#48ba240b45a9280e94748990ba597d216617fd40" + version "4.9.2" + resolved "https://registry.yarnpkg.com/asn1.js/-/asn1.js-4.9.2.tgz#8117ef4f7ed87cd8f89044b5bff97ac243a16c9a" dependencies: bn.js "^4.0.0" inherits "^2.0.1" @@ -1550,14 +1554,15 @@ browser-resolve@^1.11.0, browser-resolve@^1.7.0: resolve "1.1.7" browserify-aes@^1.0.0, browserify-aes@^1.0.4: - version "1.0.6" - resolved "https://registry.yarnpkg.com/browserify-aes/-/browserify-aes-1.0.6.tgz#5e7725dbdef1fd5930d4ebab48567ce451c48a0a" + version "1.1.1" + resolved "https://registry.yarnpkg.com/browserify-aes/-/browserify-aes-1.1.1.tgz#38b7ab55edb806ff2dcda1a7f1620773a477c49f" dependencies: - buffer-xor "^1.0.2" + buffer-xor "^1.0.3" cipher-base "^1.0.0" create-hash "^1.1.0" - evp_bytestokey "^1.0.0" + evp_bytestokey "^1.0.3" inherits "^2.0.1" + safe-buffer "^5.0.1" browserify-cipher@^1.0.0: version "1.0.0" @@ -1665,7 +1670,7 @@ bser@^2.0.0: dependencies: node-int64 "^0.4.0" -buffer-xor@^1.0.2: +buffer-xor@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/buffer-xor/-/buffer-xor-1.0.3.tgz#26e61ed1422fb70dd42e6e36729ed51d855fe8d9" @@ -2232,8 +2237,8 @@ cryptiles@2.x.x: boom "2.x.x" crypto-browserify@^3.0.0: - version "3.11.1" - resolved "https://registry.yarnpkg.com/crypto-browserify/-/crypto-browserify-3.11.1.tgz#948945efc6757a400d6e5e5af47194d10064279f" + version "3.12.0" + resolved "https://registry.yarnpkg.com/crypto-browserify/-/crypto-browserify-3.12.0.tgz#396cf9f3137f03e4b8e532c58f698254e00f80ec" dependencies: browserify-cipher "^1.0.0" browserify-sign "^4.0.0" @@ -2245,6 +2250,7 @@ crypto-browserify@^3.0.0: pbkdf2 "^3.0.3" public-encrypt "^4.0.0" randombytes "^2.0.0" + randomfill "^1.0.3" crypto-random-string@^1.0.0: version "1.0.0" @@ -2451,7 +2457,14 @@ detect-indent@^4.0.0: dependencies: repeating "^2.0.0" -detective@^4.0.0, detective@^4.3.1: +detective@^4.0.0: + version "4.7.0" + resolved "https://registry.yarnpkg.com/detective/-/detective-4.7.0.tgz#6276e150f9e50829ad1f90ace4d9a2304188afcf" + dependencies: + acorn "^5.2.1" + defined "^1.0.0" + +detective@^4.3.1: version "4.5.0" resolved "https://registry.yarnpkg.com/detective/-/detective-4.5.0.tgz#6e5a8c6b26e6c7a254b1c6b6d7490d98ec91edd1" dependencies: @@ -2542,7 +2555,7 @@ ember-basic-dropdown@^0.33.1: ember-native-dom-helpers "^0.5.4" ember-wormhole "^0.5.2" -ember-browserify@^1.1.13: +ember-browserify@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/ember-browserify/-/ember-browserify-1.2.0.tgz#c774896dc44ab2c5c608226f31628994348a3fd5" dependencies: @@ -3667,9 +3680,9 @@ events@~1.1.0: version "1.1.1" resolved "https://registry.yarnpkg.com/events/-/events-1.1.1.tgz#9ebdb7635ad099c70dcc4c2a1f5004288e8bd924" -evp_bytestokey@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/evp_bytestokey/-/evp_bytestokey-1.0.2.tgz#f66bb88ecd57f71a766821e20283ea38c68bf80a" +evp_bytestokey@^1.0.0, evp_bytestokey@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/evp_bytestokey/-/evp_bytestokey-1.0.3.tgz#7fcbdb198dc71959432efe13842684e0525acb02" dependencies: md5.js "^1.3.4" safe-buffer "^5.1.1" @@ -4054,7 +4067,16 @@ fs-readdir-recursive@^0.1.0: version "0.1.2" resolved "https://registry.yarnpkg.com/fs-readdir-recursive/-/fs-readdir-recursive-0.1.2.tgz#315b4fb8c1ca5b8c47defef319d073dad3568059" -fs-tree-diff@^0.5.0, fs-tree-diff@^0.5.2, fs-tree-diff@^0.5.3, fs-tree-diff@^0.5.4, fs-tree-diff@^0.5.6: +fs-tree-diff@^0.5.0: + version "0.5.7" + resolved "https://registry.yarnpkg.com/fs-tree-diff/-/fs-tree-diff-0.5.7.tgz#315e2b098d5fe7f622880ac965b1b051868ac871" + dependencies: + heimdalljs-logger "^0.1.7" + object-assign "^4.1.0" + path-posix "^1.0.0" + symlink-or-copy "^1.1.8" + +fs-tree-diff@^0.5.2, fs-tree-diff@^0.5.3, fs-tree-diff@^0.5.4, fs-tree-diff@^0.5.6: version "0.5.6" resolved "https://registry.yarnpkg.com/fs-tree-diff/-/fs-tree-diff-0.5.6.tgz#342665749e8dca406800b672268c8f5073f3e623" dependencies: @@ -4643,7 +4665,11 @@ is-binary-path@^1.0.0: dependencies: binary-extensions "^1.0.0" -is-buffer@^1.1.0, is-buffer@^1.1.5, is-buffer@~1.1.2: +is-buffer@^1.1.0: + version "1.1.6" + resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-1.1.6.tgz#efaa2ea9daa0d7ab2ea13a97b2b8ad51fefbe8be" + +is-buffer@^1.1.5, is-buffer@~1.1.2: version "1.1.5" resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-1.1.5.tgz#1f3b26ef613b214b88cbca23cc6c01d87961eecc" @@ -5694,8 +5720,8 @@ micromatch@^2.1.5, micromatch@^2.3.7: regex-cache "^0.4.2" miller-rabin@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/miller-rabin/-/miller-rabin-4.0.0.tgz#4a62fb1d42933c05583982f4c716f6fb9e6c6d3d" + version "4.0.1" + resolved "https://registry.yarnpkg.com/miller-rabin/-/miller-rabin-4.0.1.tgz#f080351c865b0dc562a8462966daa53543c78a4d" dependencies: bn.js "^4.0.0" brorand "^1.0.1" @@ -6299,8 +6325,8 @@ path-type@^2.0.0: pify "^2.0.0" pbkdf2@^3.0.3: - version "3.0.13" - resolved "https://registry.yarnpkg.com/pbkdf2/-/pbkdf2-3.0.13.tgz#c37d295531e786b1da3e3eadc840426accb0ae25" + version "3.0.14" + resolved "https://registry.yarnpkg.com/pbkdf2/-/pbkdf2-3.0.14.tgz#a35e13c64799b06ce15320f459c230e68e73bade" dependencies: create-hash "^1.1.2" create-hmac "^1.1.4" @@ -6485,12 +6511,19 @@ randomatic@^1.1.3: is-number "^3.0.0" kind-of "^4.0.0" -randombytes@^2.0.0, randombytes@^2.0.1: +randombytes@^2.0.0, randombytes@^2.0.1, randombytes@^2.0.5: version "2.0.5" resolved "https://registry.yarnpkg.com/randombytes/-/randombytes-2.0.5.tgz#dc009a246b8d09a177b4b7a0ae77bc570f4b1b79" dependencies: safe-buffer "^5.1.0" +randomfill@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/randomfill/-/randomfill-1.0.3.tgz#b96b7df587f01dd91726c418f30553b1418e3d62" + dependencies: + randombytes "^2.0.5" + safe-buffer "^5.1.0" + range-parser@~1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/range-parser/-/range-parser-1.2.0.tgz#f49be6b487894ddc40dcc94a322f611092e00d5e" @@ -6798,12 +6831,18 @@ resolve@1.3.2: dependencies: path-parse "^1.0.5" -resolve@^1.1.2, resolve@^1.1.3, resolve@^1.1.4, resolve@^1.1.6, resolve@^1.1.7, resolve@^1.3.0, resolve@^1.3.3, resolve@^1.4.0: +resolve@^1.1.2, resolve@^1.1.6, resolve@^1.1.7, resolve@^1.3.0, resolve@^1.3.3, resolve@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.4.0.tgz#a75be01c53da25d934a98ebd0e4c4a7312f92a86" dependencies: path-parse "^1.0.5" +resolve@^1.1.3, resolve@^1.1.4: + version "1.5.0" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.5.0.tgz#1f09acce796c9a762579f31b2c1cc4c3cddf9f36" + dependencies: + path-parse "^1.0.5" + restore-cursor@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-1.0.1.tgz#34661f46886327fed2991479152252df92daa541" @@ -7003,10 +7042,11 @@ setprototypeof@1.0.3: resolved "https://registry.yarnpkg.com/setprototypeof/-/setprototypeof-1.0.3.tgz#66567e37043eeb4f04d91bd658c0cbefb55b8e04" sha.js@^2.4.0, sha.js@^2.4.8, sha.js@~2.4.4: - version "2.4.8" - resolved "https://registry.yarnpkg.com/sha.js/-/sha.js-2.4.8.tgz#37068c2c476b6baf402d14a49c67f597921f634f" + version "2.4.9" + resolved "https://registry.yarnpkg.com/sha.js/-/sha.js-2.4.9.tgz#98f64880474b74f4a38b8da9d3c0f2d104633e7d" dependencies: inherits "^2.0.1" + safe-buffer "^5.0.1" shasum@^1.0.0: version "1.0.2" From c5c2c2bd147234aa13c5c769d7e0ab76c045b1b4 Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Tue, 12 Dec 2017 19:14:19 -0800 Subject: [PATCH 088/136] Upgrade various minor dependencies --- ui/package.json | 33 ++- ui/yarn.lock | 623 +++++++++++++++++++++++------------------------- 2 files changed, 309 insertions(+), 347 deletions(-) diff --git a/ui/package.json b/ui/package.json index 1f758b8b6..90e888938 100644 --- a/ui/package.json +++ b/ui/package.json @@ -37,40 +37,39 @@ "ember-cli": "2.17.1", "ember-cli-babel": "^6.0.0", "ember-cli-bourbon": "2.0.0-beta.1", - "ember-cli-dependency-checker": "^1.3.0", - "ember-cli-eslint": "^3.0.0", - "ember-cli-htmlbars": "^1.1.1", - "ember-cli-htmlbars-inline-precompile": "^0.4.0", + "ember-cli-dependency-checker": "^2.1.0", + "ember-cli-eslint": "^4.2.3", + "ember-cli-htmlbars": "^2.0.3", + "ember-cli-htmlbars-inline-precompile": "^1.0.2", "ember-cli-inject-live-reload": "^1.4.1", "ember-cli-mirage": "^0.4.1", - "ember-cli-moment-shim": "^3.3.3", + "ember-cli-moment-shim": "^3.5.0", "ember-cli-qunit": "^4.0.0", "ember-cli-sass": "^6.2.0", - "ember-cli-shims": "^1.1.0", + "ember-cli-shims": "^1.2.0", "ember-cli-sri": "^2.1.0", - "ember-cli-string-helpers": "^1.4.0", - "ember-cli-uglify": "^1.2.0", + "ember-cli-string-helpers": "^1.5.0", + "ember-cli-uglify": "^2.0.0", "ember-composable-helpers": "^2.0.3", "ember-concurrency": "^0.8.12", "ember-data": "~2.17.0", "ember-data-model-fragments": "^2.14.0", "ember-export-application-global": "^2.0.0", - "ember-fetch": "^3.2.7", + "ember-fetch": "^3.4.3", "ember-freestyle": "^0.4.1", - "ember-href-to": "^1.13.0", "ember-inline-svg": "^0.1.11", "ember-load-initializers": "^1.0.0", - "ember-moment": "^7.3.1", + "ember-moment": "^7.5.0", "ember-native-dom-helpers": "^0.5.4", - "ember-power-select": "^1.9.9", - "ember-resolver": "^4.0.0", + "ember-power-select": "^1.10.4", + "ember-resolver": "^4.5.0", "ember-sinon": "^0.7.0", "ember-source": "~2.17.0", - "ember-truth-helpers": "^1.3.0", + "ember-truth-helpers": "^2.0.0", "ember-welcome-page": "^3.0.0", - "eslint": "^4.0.0", - "flat": "^2.0.1", - "husky": "^0.13.4", + "eslint": "^4.13.1", + "flat": "^4.0.0", + "husky": "^0.14.3", "json-formatter-js": "^2.2.0", "lint-staged": "^3.6.1", "loader.js": "^4.2.3", diff --git a/ui/yarn.lock b/ui/yarn.lock index d3b90f0dd..37cf1a911 100644 --- a/ui/yarn.lock +++ b/ui/yarn.lock @@ -83,6 +83,15 @@ ajv@^5.2.0: json-schema-traverse "^0.3.0" json-stable-stringify "^1.0.1" +ajv@^5.3.0: + version "5.5.1" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-5.5.1.tgz#b38bb8876d9e86bee994956a04e721e88b248eb2" + dependencies: + co "^4.6.0" + fast-deep-equal "^1.0.0" + fast-json-stable-stringify "^2.0.0" + json-schema-traverse "^0.3.0" + align-text@^0.1.1, align-text@^0.1.3: version "0.1.4" resolved "https://registry.yarnpkg.com/align-text/-/align-text-0.1.4.tgz#0cd90a561093f35d0a99256c22b7069433fad117" @@ -348,7 +357,7 @@ aws4@^1.2.1: version "1.6.0" resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.6.0.tgz#83ef5ca860b2b32e4a0deedee8c771b9db57471e" -babel-code-frame@^6.16.0, babel-code-frame@^6.22.0, babel-code-frame@^6.26.0: +babel-code-frame@^6.22.0, babel-code-frame@^6.26.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-code-frame/-/babel-code-frame-6.26.0.tgz#63fd43f7dc1e3bb7ce35947db8fe369a3f58c74b" dependencies: @@ -1350,14 +1359,14 @@ broccoli-kitchen-sink-helpers@^0.3.1: glob "^5.0.10" mkdirp "^0.5.1" -broccoli-lint-eslint@^3.3.0: - version "3.3.1" - resolved "https://registry.yarnpkg.com/broccoli-lint-eslint/-/broccoli-lint-eslint-3.3.1.tgz#35c675546a5a7ad8f3319edd732e3aad8ca241de" +broccoli-lint-eslint@^4.2.1: + version "4.2.1" + resolved "https://registry.yarnpkg.com/broccoli-lint-eslint/-/broccoli-lint-eslint-4.2.1.tgz#f780dc083a7357a9746a9cfa8f76feb092777477" dependencies: aot-test-generators "^0.1.0" broccoli-concat "^3.2.2" - broccoli-persistent-filter "^1.2.0" - eslint "^3.0.0" + broccoli-persistent-filter "^1.4.3" + eslint "^4.0.0" json-stable-stringify "^1.0.1" lodash.defaultsdeep "^4.6.0" md5-hex "^2.0.0" @@ -1389,7 +1398,7 @@ broccoli-middleware@^1.0.0: handlebars "^4.0.4" mime "^1.2.11" -broccoli-persistent-filter@^1.0.3, broccoli-persistent-filter@^1.1.5, broccoli-persistent-filter@^1.1.6, broccoli-persistent-filter@^1.2.0, broccoli-persistent-filter@^1.4.0, broccoli-persistent-filter@^1.4.2: +broccoli-persistent-filter@^1.0.3, broccoli-persistent-filter@^1.1.5, broccoli-persistent-filter@^1.1.6, broccoli-persistent-filter@^1.4.0, broccoli-persistent-filter@^1.4.2, broccoli-persistent-filter@^1.4.3: version "1.4.3" resolved "https://registry.yarnpkg.com/broccoli-persistent-filter/-/broccoli-persistent-filter-1.4.3.tgz#3511bc52fc53740cda51621f58a28152d9911bc1" dependencies: @@ -1472,7 +1481,7 @@ broccoli-sri-hash@^2.1.0: sri-toolbox "^0.2.0" symlink-or-copy "^1.0.1" -broccoli-stew@^1.2.0, broccoli-stew@^1.3.3, broccoli-stew@^1.4.0, broccoli-stew@^1.4.2, broccoli-stew@^1.5.0: +broccoli-stew@^1.2.0, broccoli-stew@^1.3.3, broccoli-stew@^1.4.2, broccoli-stew@^1.5.0: version "1.5.0" resolved "https://registry.yarnpkg.com/broccoli-stew/-/broccoli-stew-1.5.0.tgz#d7af8c18511dce510e49d308a62e5977f461883c" dependencies: @@ -1506,19 +1515,19 @@ broccoli-templater@^1.0.0: broccoli-stew "^1.2.0" lodash.template "^3.3.2" -broccoli-uglify-sourcemap@^1.0.0: - version "1.5.2" - resolved "https://registry.yarnpkg.com/broccoli-uglify-sourcemap/-/broccoli-uglify-sourcemap-1.5.2.tgz#04f84ab0db539031fa868ccfa563c9932d50cedb" +broccoli-uglify-sourcemap@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/broccoli-uglify-sourcemap/-/broccoli-uglify-sourcemap-2.0.1.tgz#e8f2f6c49e04b6e921f1ecd30e12f06fb75e585f" dependencies: broccoli-plugin "^1.2.1" - debug "^2.2.0" - lodash.merge "^4.5.1" - matcher-collection "^1.0.0" + debug "^3.1.0" + lodash.defaultsdeep "^4.6.0" + matcher-collection "^1.0.5" mkdirp "^0.5.0" - source-map-url "^0.3.0" + source-map-url "^0.4.0" symlink-or-copy "^1.0.1" - uglify-js "^2.7.0" - walk-sync "^0.1.3" + uglify-es "^3.1.3" + walk-sync "^0.3.2" broccoli-unwatched-tree@^0.1.1: version "0.1.3" @@ -1664,6 +1673,13 @@ browserslist@^2.1.2: caniuse-lite "^1.0.30000718" electron-to-chromium "^1.3.18" +browserslist@^2.2.2: + version "2.10.0" + resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-2.10.0.tgz#bac5ee1cc69ca9d96403ffb8a3abdc5b6aed6346" + dependencies: + caniuse-lite "^1.0.30000780" + electron-to-chromium "^1.3.28" + bser@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/bser/-/bser-2.0.0.tgz#9ac78d3ed5d915804fd87acb158bc797147a1719" @@ -1763,6 +1779,10 @@ caniuse-lite@^1.0.30000718: version "1.0.30000718" resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000718.tgz#0dd24290beb11310b2d80f6b70a823c2a65a6fad" +caniuse-lite@^1.0.30000780: + version "1.0.30000782" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000782.tgz#5b82b8c385f25348745c471ca51320afb1b7f254" + capture-exit@^1.1.0: version "1.2.0" resolved "https://registry.yarnpkg.com/capture-exit/-/capture-exit-1.2.0.tgz#1c5fcc489fd0ab00d4f1ac7ae1072e3173fbab6f" @@ -2013,6 +2033,10 @@ commander@2.9.0, commander@^2.5.0, commander@^2.6.0, commander@^2.9.0: dependencies: graceful-readlink ">= 1.0.0" +commander@~2.12.1: + version "2.12.2" + resolved "https://registry.yarnpkg.com/commander/-/commander-2.12.2.tgz#0f5946c427ed9ec0d91a46bb9def53e54650e555" + commoner@~0.10.3: version "0.10.8" resolved "https://registry.yarnpkg.com/commoner/-/commoner-0.10.8.tgz#34fc3672cd24393e8bb47e70caa0293811f4f2c5" @@ -2065,7 +2089,7 @@ concat-map@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" -concat-stream@^1.4.6, concat-stream@^1.4.7, concat-stream@^1.5.2, concat-stream@^1.6.0: +concat-stream@^1.4.6, concat-stream@^1.4.7, concat-stream@^1.6.0: version "1.6.0" resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.6.0.tgz#0aac662fd52be78964d5532f694784e70110acf7" dependencies: @@ -2157,10 +2181,14 @@ core-js@^1.0.0: version "1.2.7" resolved "https://registry.yarnpkg.com/core-js/-/core-js-1.2.7.tgz#652294c14651db28fa93bd2d5ff2983a4f08c636" -core-js@^2.4.0, core-js@^2.4.1, core-js@^2.5.0: +core-js@^2.4.0, core-js@^2.5.0: version "2.5.0" resolved "https://registry.yarnpkg.com/core-js/-/core-js-2.5.0.tgz#569c050918be6486b3837552028ae0466b717086" +core-js@^2.4.1: + version "2.5.3" + resolved "https://registry.yarnpkg.com/core-js/-/core-js-2.5.3.tgz#8acc38345824f16d8365b7c9b4259168e8ed603e" + core-object@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/core-object/-/core-object-1.1.0.tgz#86d63918733cf9da1a5aae729e62c0a88e66ad0a" @@ -2288,16 +2316,16 @@ d3-interpolate@1: d3-color "1" d3-selection@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/d3-selection/-/d3-selection-1.1.0.tgz#1998684896488f839ca0372123da34f1d318809c" + version "1.2.0" + resolved "https://registry.yarnpkg.com/d3-selection/-/d3-selection-1.2.0.tgz#1b8ec1c7cedadfb691f2ba20a4a3cfbeb71bbc88" d3-timer@1: version "1.0.6" resolved "https://registry.yarnpkg.com/d3-timer/-/d3-timer-1.0.6.tgz#4044bf15d7025c06ce7d1149f73cd07b54dbd784" d3-transition@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/d3-transition/-/d3-transition-1.1.0.tgz#cfc85c74e5239324290546623572990560c3966f" + version "1.1.1" + resolved "https://registry.yarnpkg.com/d3-transition/-/d3-transition-1.1.1.tgz#d8ef89c3b848735b060e54a39b32aaebaa421039" dependencies: d3-color "1" d3-dispatch "1" @@ -2348,6 +2376,12 @@ debug@2.6.8, debug@^2.1.0, debug@^2.1.1, debug@^2.1.3, debug@^2.2.0, debug@^2.4. dependencies: ms "2.0.0" +debug@^3.0.1, debug@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/debug/-/debug-3.1.0.tgz#5bb5a0672628b64149566ba16819e61518c67261" + dependencies: + ms "2.0.0" + decamelize@^1.0.0, decamelize@^1.1.1, decamelize@^1.1.2: version "1.2.0" resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-1.2.0.tgz#f6534d15148269b20352e7bee26f501f9a191290" @@ -2490,6 +2524,12 @@ doctrine@^2.0.0: esutils "^2.0.2" isarray "^1.0.0" +doctrine@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-2.0.2.tgz#68f96ce8efc56cc42651f1faadb4f175273b0075" + dependencies: + esutils "^2.0.2" + domain-browser@~1.1.0: version "1.1.7" resolved "https://registry.yarnpkg.com/domain-browser/-/domain-browser-1.1.7.tgz#867aa4b093faa05f1de08c06f4d7b21fdf8698bc" @@ -2524,6 +2564,10 @@ electron-to-chromium@^1.3.18: version "1.3.18" resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.18.tgz#3dcc99da3e6b665f6abbc71c28ad51a2cd731a9c" +electron-to-chromium@^1.3.28: + version "1.3.28" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.28.tgz#8dd4e6458086644e9f9f0a1cf32e2a1f9dffd9ee" + elegant-spinner@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/elegant-spinner/-/elegant-spinner-1.0.1.tgz#db043521c95d7e303fd8f345bedc3349cfb0729e" @@ -2546,11 +2590,11 @@ ember-ajax@^3.0.0: dependencies: ember-cli-babel "^6.0.0" -ember-basic-dropdown@^0.33.1: - version "0.33.6" - resolved "https://registry.yarnpkg.com/ember-basic-dropdown/-/ember-basic-dropdown-0.33.6.tgz#120d462c33ee5ea5ccb25a169e2b5af20d762d8a" +ember-basic-dropdown@^0.34.0: + version "0.34.0" + resolved "https://registry.yarnpkg.com/ember-basic-dropdown/-/ember-basic-dropdown-0.34.0.tgz#a0371b7c06756cdd3170e7d4a9ed4f4890bc2d59" dependencies: - ember-cli-babel "^6.8.1" + ember-cli-babel "^6.8.2" ember-cli-htmlbars "^2.0.3" ember-native-dom-helpers "^0.5.4" ember-wormhole "^0.5.2" @@ -2592,24 +2636,7 @@ ember-cli-babel@^5.1.6, ember-cli-babel@^5.1.7: ember-cli-version-checker "^1.0.2" resolve "^1.1.2" -ember-cli-babel@^6.0.0, ember-cli-babel@^6.0.0-beta.4, ember-cli-babel@^6.0.0-beta.7, ember-cli-babel@^6.0.0-beta.9, ember-cli-babel@^6.1.0, ember-cli-babel@^6.4.1, ember-cli-babel@^6.6.0, ember-cli-babel@^6.8.1: - version "6.8.1" - resolved "https://registry.yarnpkg.com/ember-cli-babel/-/ember-cli-babel-6.8.1.tgz#695f94c57a9375c2a0e219306a41105d6b937991" - dependencies: - amd-name-resolver "0.0.7" - babel-plugin-debug-macros "^0.1.11" - babel-plugin-ember-modules-api-polyfill "^1.5.1" - babel-plugin-transform-es2015-modules-amd "^6.24.0" - babel-polyfill "^6.16.0" - babel-preset-env "^1.5.1" - broccoli-babel-transpiler "^6.1.2" - broccoli-debug "^0.6.2" - broccoli-funnel "^1.0.0" - broccoli-source "^1.1.0" - clone "^2.0.0" - ember-cli-version-checker "^2.0.0" - -ember-cli-babel@^6.3.0: +ember-cli-babel@^6.0.0, ember-cli-babel@^6.10.0, ember-cli-babel@^6.3.0, ember-cli-babel@^6.7.2: version "6.10.0" resolved "https://registry.yarnpkg.com/ember-cli-babel/-/ember-cli-babel-6.10.0.tgz#81424acd1d97fb13658168121eeb2007d6edee84" dependencies: @@ -2627,6 +2654,23 @@ ember-cli-babel@^6.3.0: ember-cli-version-checker "^2.1.0" semver "^5.4.1" +ember-cli-babel@^6.0.0-beta.4, ember-cli-babel@^6.0.0-beta.7, ember-cli-babel@^6.0.0-beta.9, ember-cli-babel@^6.1.0, ember-cli-babel@^6.4.1, ember-cli-babel@^6.6.0, ember-cli-babel@^6.8.1: + version "6.8.1" + resolved "https://registry.yarnpkg.com/ember-cli-babel/-/ember-cli-babel-6.8.1.tgz#695f94c57a9375c2a0e219306a41105d6b937991" + dependencies: + amd-name-resolver "0.0.7" + babel-plugin-debug-macros "^0.1.11" + babel-plugin-ember-modules-api-polyfill "^1.5.1" + babel-plugin-transform-es2015-modules-amd "^6.24.0" + babel-polyfill "^6.16.0" + babel-preset-env "^1.5.1" + broccoli-babel-transpiler "^6.1.2" + broccoli-debug "^0.6.2" + broccoli-funnel "^1.0.0" + broccoli-source "^1.1.0" + clone "^2.0.0" + ember-cli-version-checker "^2.0.0" + ember-cli-babel@^6.8.2: version "6.9.0" resolved "https://registry.yarnpkg.com/ember-cli-babel/-/ember-cli-babel-6.9.0.tgz#5147391389bdbb7091d15f81ae1dff1eb49d71aa" @@ -2662,21 +2706,22 @@ ember-cli-broccoli-sane-watcher@^2.0.4: rsvp "^3.0.18" sane "^1.1.1" -ember-cli-dependency-checker@^1.3.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/ember-cli-dependency-checker/-/ember-cli-dependency-checker-1.4.0.tgz#2b13f977e1eea843fc1a21a001be6ca5d4ef1942" +ember-cli-dependency-checker@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/ember-cli-dependency-checker/-/ember-cli-dependency-checker-2.1.0.tgz#9d66286a7c778e94733eaf21320d129c4fd0dd64" dependencies: - chalk "^0.5.1" - is-git-url "^0.2.0" - semver "^4.1.0" + chalk "^1.1.3" + is-git-url "^1.0.0" + resolve "^1.5.0" + semver "^5.3.0" -ember-cli-eslint@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/ember-cli-eslint/-/ember-cli-eslint-3.1.0.tgz#8d9e2a867654835ac1b24858d9117e143fa54bd4" +ember-cli-eslint@^4.2.3: + version "4.2.3" + resolved "https://registry.yarnpkg.com/ember-cli-eslint/-/ember-cli-eslint-4.2.3.tgz#2844d3f5e8184f19b2d7132ba99eb0b370b55598" dependencies: - broccoli-lint-eslint "^3.3.0" - ember-cli-version-checker "^1.3.1" - rsvp "^3.2.1" + broccoli-lint-eslint "^4.2.1" + ember-cli-version-checker "^2.1.0" + rsvp "^4.6.1" walk-sync "^0.3.0" ember-cli-get-component-path-option@^1.0.0: @@ -2687,13 +2732,14 @@ ember-cli-get-dependency-depth@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/ember-cli-get-dependency-depth/-/ember-cli-get-dependency-depth-1.0.0.tgz#e0afecf82a2d52f00f28ab468295281aec368d11" -ember-cli-htmlbars-inline-precompile@^0.4.0: - version "0.4.4" - resolved "https://registry.yarnpkg.com/ember-cli-htmlbars-inline-precompile/-/ember-cli-htmlbars-inline-precompile-0.4.4.tgz#24a7617152630d64a047e553b72e00963a4f8d73" +ember-cli-htmlbars-inline-precompile@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/ember-cli-htmlbars-inline-precompile/-/ember-cli-htmlbars-inline-precompile-1.0.2.tgz#5b544f664d5d9911f08cd979c5f70d8cb0ca2add" dependencies: babel-plugin-htmlbars-inline-precompile "^0.2.3" ember-cli-version-checker "^2.0.0" hash-for-dep "^1.0.2" + heimdalljs-logger "^0.1.7" silent-error "^1.1.0" ember-cli-htmlbars@^1.0.3, ember-cli-htmlbars@^1.1.1, ember-cli-htmlbars@^1.3.0: @@ -2776,21 +2822,21 @@ ember-cli-mirage@^0.4.1: pretender "^1.6.1" route-recognizer "^0.2.3" -ember-cli-moment-shim@^3.3.3: - version "3.4.0" - resolved "https://registry.yarnpkg.com/ember-cli-moment-shim/-/ember-cli-moment-shim-3.4.0.tgz#2fbe13d8654097da86abb64016cddf12ff19a3de" +ember-cli-moment-shim@^3.5.0: + version "3.5.0" + resolved "https://registry.yarnpkg.com/ember-cli-moment-shim/-/ember-cli-moment-shim-3.5.0.tgz#7ea8d42b0a04c767258287b30447681e52fba0c4" dependencies: - broccoli-funnel "^1.1.0" + broccoli-funnel "^2.0.0" broccoli-merge-trees "^2.0.0" broccoli-source "^1.1.0" - broccoli-stew "^1.4.0" + broccoli-stew "^1.5.0" chalk "^1.1.3" - ember-cli-babel "^6.6.0" + ember-cli-babel "^6.8.2" ember-cli-import-polyfill "^0.2.0" exists-sync "^0.0.4" lodash.defaults "^4.2.0" moment "^2.18.1" - moment-timezone "~0.5.11" + moment-timezone "^0.5.13" ember-cli-node-assets@^0.1.4: version "0.1.6" @@ -2851,12 +2897,14 @@ ember-cli-sass@^6.1.3, ember-cli-sass@^6.2.0: ember-cli-version-checker "^1.0.2" merge "^1.2.0" -ember-cli-shims@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/ember-cli-shims/-/ember-cli-shims-1.1.0.tgz#0e3b8a048be865b4f81cc81d397ff1eeb13f75b6" +ember-cli-shims@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/ember-cli-shims/-/ember-cli-shims-1.2.0.tgz#0f53aff0aab80b5f29da3a9731bac56169dd941f" dependencies: - ember-cli-babel "^6.0.0-beta.7" - ember-cli-version-checker "^1.2.0" + broccoli-file-creator "^1.1.1" + broccoli-merge-trees "^2.0.0" + ember-cli-version-checker "^2.0.0" + ember-rfc176-data "^0.3.1" silent-error "^1.0.1" ember-cli-showdown@^3.2.1: @@ -2879,12 +2927,12 @@ ember-cli-sri@^2.1.0: dependencies: broccoli-sri-hash "^2.1.0" -ember-cli-string-helpers@^1.4.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/ember-cli-string-helpers/-/ember-cli-string-helpers-1.4.0.tgz#f7142a9499a149f69a9f2662b94f5f21eae0ec48" +ember-cli-string-helpers@^1.5.0: + version "1.5.0" + resolved "https://registry.yarnpkg.com/ember-cli-string-helpers/-/ember-cli-string-helpers-1.5.0.tgz#b7c1b27ffd4bb4bf4846b3167f730f0125a96f44" dependencies: broccoli-funnel "^1.0.1" - ember-cli-babel "^5.1.7" + ember-cli-babel "^6.3.0" ember-cli-string-utils@^1.0.0, ember-cli-string-utils@^1.1.0: version "1.1.0" @@ -2902,11 +2950,12 @@ ember-cli-test-loader@^2.0.0: dependencies: ember-cli-babel "^6.8.1" -ember-cli-uglify@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/ember-cli-uglify/-/ember-cli-uglify-1.2.0.tgz#3208c32b54bc2783056e8bb0d5cfe9bbaf17ffb2" +ember-cli-uglify@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/ember-cli-uglify/-/ember-cli-uglify-2.0.0.tgz#b096727d7d1718acc9bfe5d1bc81ce26cafdf6ca" dependencies: - broccoli-uglify-sourcemap "^1.0.0" + broccoli-uglify-sourcemap "^2.0.0" + lodash.defaultsdeep "^4.6.0" ember-cli-valid-component-name@^1.0.0: version "1.0.0" @@ -2914,7 +2963,7 @@ ember-cli-valid-component-name@^1.0.0: dependencies: silent-error "^1.0.0" -ember-cli-version-checker@^1.0.2, ember-cli-version-checker@^1.1.4, ember-cli-version-checker@^1.1.6, ember-cli-version-checker@^1.1.7, ember-cli-version-checker@^1.2.0, ember-cli-version-checker@^1.3.1: +ember-cli-version-checker@^1.0.2, ember-cli-version-checker@^1.1.4, ember-cli-version-checker@^1.1.6, ember-cli-version-checker@^1.1.7, ember-cli-version-checker@^1.2.0: version "1.3.1" resolved "https://registry.yarnpkg.com/ember-cli-version-checker/-/ember-cli-version-checker-1.3.1.tgz#0bc2d134c830142da64bf9627a0eded10b61ae72" dependencies: @@ -3030,15 +3079,6 @@ ember-composable-helpers@^2.0.3: broccoli-funnel "^1.0.1" ember-cli-babel "^6.1.0" -ember-concurrency@^0.8.1: - version "0.8.10" - resolved "https://registry.yarnpkg.com/ember-concurrency/-/ember-concurrency-0.8.10.tgz#5788d1a43ed1e73562495719b29efe903c789675" - dependencies: - babel-core "^6.24.1" - ember-cli-babel "^6.6.0" - ember-getowner-polyfill "^2.0.0" - ember-maybe-import-regenerator "^0.1.5" - ember-concurrency@^0.8.12: version "0.8.12" resolved "https://registry.yarnpkg.com/ember-concurrency/-/ember-concurrency-0.8.12.tgz#fb91180e5efeb1024cfa2cfb99d2fe6721930c91" @@ -3105,15 +3145,15 @@ ember-factory-for-polyfill@^1.1.0: dependencies: ember-cli-version-checker "^1.2.0" -ember-fetch@^3.2.7: - version "3.3.1" - resolved "https://registry.yarnpkg.com/ember-fetch/-/ember-fetch-3.3.1.tgz#47f7c0d282bfe61d4899f3a9d5af9f71e5558910" +ember-fetch@^3.4.3: + version "3.4.3" + resolved "https://registry.yarnpkg.com/ember-fetch/-/ember-fetch-3.4.3.tgz#fb8ba73148bb2399a82b037e4fdf9a953cd496ba" dependencies: broccoli-funnel "^1.2.0" broccoli-stew "^1.4.2" broccoli-templater "^1.0.0" ember-cli-babel "^6.8.1" - node-fetch "^2.0.0-alpha.3" + node-fetch "^2.0.0-alpha.9" whatwg-fetch "^2.0.3" ember-freestyle@^0.4.1: @@ -3157,12 +3197,6 @@ ember-getowner-polyfill@^2.0.0, ember-getowner-polyfill@^2.0.1: ember-cli-version-checker "^1.2.0" ember-factory-for-polyfill "^1.1.0" -ember-href-to@^1.13.0: - version "1.13.0" - resolved "https://registry.yarnpkg.com/ember-href-to/-/ember-href-to-1.13.0.tgz#308ab4803d9d08e30a92af888cc67412a800468d" - dependencies: - ember-cli-babel "^5.1.6" - ember-inflector@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/ember-inflector/-/ember-inflector-2.0.1.tgz#e9ac469ffa17992a43276bb1c9b8d87992b10d37" @@ -3202,14 +3236,14 @@ ember-lodash@^4.17.3: ember-cli-babel "^6.4.1" lodash-es "^4.17.4" -ember-macro-helpers@^0.15.1: - version "0.15.1" - resolved "https://registry.yarnpkg.com/ember-macro-helpers/-/ember-macro-helpers-0.15.1.tgz#a402651fafb3a25b3612a8c09843bc4061553a13" +ember-macro-helpers@^0.17.0: + version "0.17.0" + resolved "https://registry.yarnpkg.com/ember-macro-helpers/-/ember-macro-helpers-0.17.0.tgz#5e64a49f476e38c1916aff75f949455533cd1abe" dependencies: - ember-cli-babel "^6.0.0" + ember-cli-babel "^6.6.0" ember-cli-string-utils "^1.1.0" ember-cli-test-info "^1.0.0" - ember-weakmap "^2.0.0" + ember-weakmap "^3.0.0" ember-maybe-import-regenerator@^0.1.5: version "0.1.6" @@ -3220,31 +3254,31 @@ ember-maybe-import-regenerator@^0.1.5: ember-cli-babel "^6.0.0-beta.4" regenerator-runtime "^0.9.5" -ember-moment@^7.3.1: - version "7.4.1" - resolved "https://registry.yarnpkg.com/ember-moment/-/ember-moment-7.4.1.tgz#88018c4d981643bb4521ad39539f60ba3ec6bf42" +ember-moment@^7.5.0: + version "7.5.0" + resolved "https://registry.yarnpkg.com/ember-moment/-/ember-moment-7.5.0.tgz#9ed25b32ae941b2f1d9116c44f518a52bdb01722" dependencies: - ember-cli-babel "^6.6.0" + ember-cli-babel "^6.7.2" ember-getowner-polyfill "^2.0.1" - ember-macro-helpers "^0.15.1" + ember-macro-helpers "^0.17.0" ember-native-dom-helpers@^0.5.4: - version "0.5.4" - resolved "https://registry.yarnpkg.com/ember-native-dom-helpers/-/ember-native-dom-helpers-0.5.4.tgz#0bc1506a643fb7adc0abf1d09c44a7914459296b" + version "0.5.10" + resolved "https://registry.yarnpkg.com/ember-native-dom-helpers/-/ember-native-dom-helpers-0.5.10.tgz#9c7172e4ddfa5dd86830c46a936e2f8eca3e5896" dependencies: broccoli-funnel "^1.1.0" ember-cli-babel "^6.6.0" -ember-power-select@^1.9.9: - version "1.9.9" - resolved "https://registry.yarnpkg.com/ember-power-select/-/ember-power-select-1.9.9.tgz#24b733f5be603a434dffdb57dffe702759448ca5" +ember-power-select@^1.10.4: + version "1.10.4" + resolved "https://registry.yarnpkg.com/ember-power-select/-/ember-power-select-1.10.4.tgz#7f0bb8c55279375391f2d97591ed65f727061579" dependencies: - ember-basic-dropdown "^0.33.1" - ember-cli-babel "^6.6.0" + ember-basic-dropdown "^0.34.0" + ember-cli-babel "^6.10.0" ember-cli-htmlbars "^2.0.1" - ember-concurrency "^0.8.1" - ember-text-measurer "^0.3.3" - ember-truth-helpers "^1.3.0" + ember-concurrency "^0.8.12" + ember-text-measurer "^0.4.0" + ember-truth-helpers "^2.0.0" ember-qunit@^2.1.3: version "2.2.0" @@ -3252,9 +3286,9 @@ ember-qunit@^2.1.3: dependencies: ember-test-helpers "^0.6.3" -ember-resolver@^4.0.0: - version "4.4.0" - resolved "https://registry.yarnpkg.com/ember-resolver/-/ember-resolver-4.4.0.tgz#211ad00dea0ff2f3344aea156e556de42fc7ec74" +ember-resolver@^4.5.0: + version "4.5.0" + resolved "https://registry.yarnpkg.com/ember-resolver/-/ember-resolver-4.5.0.tgz#9248bf534dfc197fafe3118fff538d436078bf99" dependencies: "@glimmer/resolver" "^0.4.1" babel-plugin-debug-macros "^0.1.10" @@ -3268,7 +3302,7 @@ ember-rfc176-data@^0.2.0: version "0.2.7" resolved "https://registry.yarnpkg.com/ember-rfc176-data/-/ember-rfc176-data-0.2.7.tgz#bd355bc9b473e08096b518784170a23388bc973b" -ember-rfc176-data@^0.3.0: +ember-rfc176-data@^0.3.0, ember-rfc176-data@^0.3.1: version "0.3.1" resolved "https://registry.yarnpkg.com/ember-rfc176-data/-/ember-rfc176-data-0.3.1.tgz#6a5a4b8b82ec3af34f3010965fa96b936ca94519" @@ -3318,17 +3352,17 @@ ember-test-helpers@^0.6.3: version "0.6.3" resolved "https://registry.yarnpkg.com/ember-test-helpers/-/ember-test-helpers-0.6.3.tgz#f864cdf6f4e75f3f8768d6537785b5ab6e82d907" -ember-text-measurer@^0.3.3: - version "0.3.3" - resolved "https://registry.yarnpkg.com/ember-text-measurer/-/ember-text-measurer-0.3.3.tgz#0762809a71c2e1f2e60ab00c53c6eb1b63c9f963" +ember-text-measurer@^0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/ember-text-measurer/-/ember-text-measurer-0.4.0.tgz#a676195378d4eb4c1617678c2d198a2344b4d12b" dependencies: - ember-cli-babel "^5.1.6" + ember-cli-babel "^6.8.2" -ember-truth-helpers@^1.3.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/ember-truth-helpers/-/ember-truth-helpers-1.3.0.tgz#6ed9f83ce9a49f52bb416d55e227426339a64c60" +ember-truth-helpers@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/ember-truth-helpers/-/ember-truth-helpers-2.0.0.tgz#f3e2eef667859197f1328bb4f83b0b35b661c1ac" dependencies: - ember-cli-babel "^5.1.6" + ember-cli-babel "^6.8.2" ember-try-config@^2.2.0: version "2.2.0" @@ -3356,11 +3390,13 @@ ember-try@^0.2.15: rsvp "^3.0.17" semver "^5.1.0" -ember-weakmap@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/ember-weakmap/-/ember-weakmap-2.0.0.tgz#71c6819a8bfd0b077ae17ca1d9053fc5db06e4ac" +ember-weakmap@^3.0.0: + version "3.1.1" + resolved "https://registry.yarnpkg.com/ember-weakmap/-/ember-weakmap-3.1.1.tgz#2ae6e0080b5b80cf0d108f7752dc69ea9603dbd7" dependencies: - ember-cli-babel "^5.1.6" + browserslist "^2.2.2" + debug "^3.1.0" + ember-cli-babel "^6.3.0" ember-welcome-page@^3.0.0: version "3.1.1" @@ -3527,46 +3563,6 @@ eslint-scope@^3.7.1: esrecurse "^4.1.0" estraverse "^4.1.1" -eslint@^3.0.0: - version "3.19.0" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-3.19.0.tgz#c8fc6201c7f40dd08941b87c085767386a679acc" - dependencies: - babel-code-frame "^6.16.0" - chalk "^1.1.3" - concat-stream "^1.5.2" - debug "^2.1.1" - doctrine "^2.0.0" - escope "^3.6.0" - espree "^3.4.0" - esquery "^1.0.0" - estraverse "^4.2.0" - esutils "^2.0.2" - file-entry-cache "^2.0.0" - glob "^7.0.3" - globals "^9.14.0" - ignore "^3.2.0" - imurmurhash "^0.1.4" - inquirer "^0.12.0" - is-my-json-valid "^2.10.0" - is-resolvable "^1.0.0" - js-yaml "^3.5.1" - json-stable-stringify "^1.0.0" - levn "^0.3.0" - lodash "^4.0.0" - mkdirp "^0.5.0" - natural-compare "^1.4.0" - optionator "^0.8.2" - path-is-inside "^1.0.1" - pluralize "^1.2.1" - progress "^1.1.8" - require-uncached "^1.0.2" - shelljs "^0.7.5" - strip-bom "^3.0.0" - strip-json-comments "~2.0.1" - table "^3.7.8" - text-table "~0.2.0" - user-home "^2.0.0" - eslint@^4.0.0: version "4.5.0" resolved "https://registry.yarnpkg.com/eslint/-/eslint-4.5.0.tgz#bb75d3b8bde97fb5e13efcd539744677feb019c3" @@ -3609,13 +3605,62 @@ eslint@^4.0.0: table "^4.0.1" text-table "~0.2.0" -espree@^3.4.0, espree@^3.5.0: +eslint@^4.13.1: + version "4.13.1" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-4.13.1.tgz#0055e0014464c7eb7878caf549ef2941992b444f" + dependencies: + ajv "^5.3.0" + babel-code-frame "^6.22.0" + chalk "^2.1.0" + concat-stream "^1.6.0" + cross-spawn "^5.1.0" + debug "^3.0.1" + doctrine "^2.0.2" + eslint-scope "^3.7.1" + espree "^3.5.2" + esquery "^1.0.0" + estraverse "^4.2.0" + esutils "^2.0.2" + file-entry-cache "^2.0.0" + functional-red-black-tree "^1.0.1" + glob "^7.1.2" + globals "^11.0.1" + ignore "^3.3.3" + imurmurhash "^0.1.4" + inquirer "^3.0.6" + is-resolvable "^1.0.0" + js-yaml "^3.9.1" + json-stable-stringify-without-jsonify "^1.0.1" + levn "^0.3.0" + lodash "^4.17.4" + minimatch "^3.0.2" + mkdirp "^0.5.1" + natural-compare "^1.4.0" + optionator "^0.8.2" + path-is-inside "^1.0.2" + pluralize "^7.0.0" + progress "^2.0.0" + require-uncached "^1.0.3" + semver "^5.3.0" + strip-ansi "^4.0.0" + strip-json-comments "~2.0.1" + table "^4.0.1" + text-table "~0.2.0" + +espree@^3.5.0: version "3.5.0" resolved "https://registry.yarnpkg.com/espree/-/espree-3.5.0.tgz#98358625bdd055861ea27e2867ea729faf463d8d" dependencies: acorn "^5.1.1" acorn-jsx "^3.0.0" +espree@^3.5.2: + version "3.5.2" + resolved "https://registry.yarnpkg.com/espree/-/espree-3.5.2.tgz#756ada8b979e9dcfcdb30aad8d1a9304a905e1ca" + dependencies: + acorn "^5.2.1" + acorn-jsx "^3.0.0" + esprima-fb@~15001.1001.0-dev-harmony-fb: version "15001.1001.0-dev-harmony-fb" resolved "https://registry.yarnpkg.com/esprima-fb/-/esprima-fb-15001.1001.0-dev-harmony-fb.tgz#43beb57ec26e8cf237d3dd8b33e42533577f2659" @@ -3830,6 +3875,10 @@ fast-deep-equal@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-1.0.0.tgz#96256a3bc975595eb36d82e9929d060d893439ff" +fast-json-stable-stringify@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz#d5142c0caee6b1189f87d3a76111064f86c8bbf2" + fast-levenshtein@~2.0.4: version "2.0.6" resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" @@ -3866,7 +3915,7 @@ fb-watchman@^2.0.0: dependencies: bser "^2.0.0" -figures@^1.3.5, figures@^1.7.0: +figures@^1.7.0: version "1.7.0" resolved "https://registry.yarnpkg.com/figures/-/figures-1.7.0.tgz#cbe1e3affcf1cd44b80cadfed28dc793a9701d2e" dependencies: @@ -3920,10 +3969,6 @@ find-index@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/find-index/-/find-index-1.1.0.tgz#53007c79cd30040d6816d79458e8837d5c5705ef" -find-parent-dir@^0.3.0: - version "0.3.0" - resolved "https://registry.yarnpkg.com/find-parent-dir/-/find-parent-dir-0.3.0.tgz#33c44b429ab2b2f0646299c5f9f718f376ff8d54" - find-up@^1.0.0: version "1.1.2" resolved "https://registry.yarnpkg.com/find-up/-/find-up-1.1.2.tgz#6b2e9822b1a2ce0a60ab64d610eccad53cb24d0f" @@ -3965,11 +4010,11 @@ flat-cache@^1.2.1: graceful-fs "^4.1.2" write "^0.2.1" -flat@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/flat/-/flat-2.0.1.tgz#70e29188a74be0c3c89409eed1fa9577907ae32f" +flat@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/flat/-/flat-4.0.0.tgz#3abc7f3b588e64ce77dc42fd59aa35806622fea8" dependencies: - is-buffer "~1.1.2" + is-buffer "~1.1.5" for-in@^1.0.1: version "1.0.2" @@ -4147,16 +4192,6 @@ gaze@^1.0.0: dependencies: globule "^1.0.0" -generate-function@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/generate-function/-/generate-function-2.0.0.tgz#6858fe7c0969b7d4e9093337647ac79f60dfbe74" - -generate-object-property@^1.1.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/generate-object-property/-/generate-object-property-1.2.0.tgz#9c0e1c40308ce804f4783618b937fa88f99d50d0" - dependencies: - is-property "^1.0.0" - get-caller-file@^1.0.0, get-caller-file@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-1.0.2.tgz#f702e63127e7e231c160a80c1554acb70d5047e5" @@ -4240,11 +4275,15 @@ global-prefix@^0.1.4: is-windows "^0.2.0" which "^1.2.12" +globals@^11.0.1: + version "11.1.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-11.1.0.tgz#632644457f5f0e3ae711807183700ebf2e4633e4" + globals@^6.4.0: version "6.4.1" resolved "https://registry.yarnpkg.com/globals/-/globals-6.4.1.tgz#8498032b3b6d1cc81eebc5f79690d8fe29fabf4f" -globals@^9.14.0, globals@^9.17.0, globals@^9.18.0: +globals@^9.17.0, globals@^9.18.0: version "9.18.0" resolved "https://registry.yarnpkg.com/globals/-/globals-9.18.0.tgz#aa3896b3e69b487f17e31ed2143d69a8e30c2d8a" @@ -4482,14 +4521,13 @@ https-browserify@~0.0.0: version "0.0.1" resolved "https://registry.yarnpkg.com/https-browserify/-/https-browserify-0.0.1.tgz#3f91365cabe60b77ed0ebba24b454e3e09d95a82" -husky@^0.13.4: - version "0.13.4" - resolved "https://registry.yarnpkg.com/husky/-/husky-0.13.4.tgz#48785c5028de3452a51c48c12c4f94b2124a1407" +husky@^0.14.3: + version "0.14.3" + resolved "https://registry.yarnpkg.com/husky/-/husky-0.14.3.tgz#c69ed74e2d2779769a17ba8399b54ce0b63c12c3" dependencies: - chalk "^1.1.3" - find-parent-dir "^0.3.0" - is-ci "^1.0.9" + is-ci "^1.0.10" normalize-path "^1.0.0" + strip-indent "^2.0.0" iconv-lite@^0.4.17, iconv-lite@^0.4.5, iconv-lite@~0.4.13: version "0.4.18" @@ -4499,7 +4537,7 @@ ieee754@^1.1.4: version "1.1.8" resolved "https://registry.yarnpkg.com/ieee754/-/ieee754-1.1.8.tgz#be33d40ac10ef1926701f6f08a2d86fbfd1ad3e4" -ignore@^3.2.0, ignore@^3.3.3: +ignore@^3.3.3: version "3.3.4" resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.3.4.tgz#85ab6d0a9ca8b27b31604c09efe1c14dc21ab872" @@ -4568,24 +4606,6 @@ inline-source-map@~0.6.0: dependencies: source-map "~0.5.3" -inquirer@^0.12.0: - version "0.12.0" - resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-0.12.0.tgz#1ef2bfd63504df0bc75785fff8c2c41df12f077e" - dependencies: - ansi-escapes "^1.1.0" - ansi-regex "^2.0.0" - chalk "^1.0.0" - cli-cursor "^1.0.1" - cli-width "^2.0.0" - figures "^1.3.5" - lodash "^4.3.0" - readline2 "^1.0.1" - run-async "^0.1.0" - rx-lite "^3.1.2" - string-width "^1.0.1" - strip-ansi "^3.0.0" - through "^2.3.6" - inquirer@^2: version "2.0.0" resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-2.0.0.tgz#e1351687b90d150ca403ceaa3cefb1e3065bef4b" @@ -4637,10 +4657,6 @@ insert-module-globals@^7.0.0: through2 "^2.0.0" xtend "^4.0.0" -interpret@^1.0.0: - version "1.0.3" - resolved "https://registry.yarnpkg.com/interpret/-/interpret-1.0.3.tgz#cbc35c62eeee73f19ab7b10a801511401afc0f90" - invariant@^2.2.2: version "2.2.2" resolved "https://registry.yarnpkg.com/invariant/-/invariant-2.2.2.tgz#9e1f56ac0acdb6bf303306f338be3b204ae60360" @@ -4665,11 +4681,11 @@ is-binary-path@^1.0.0: dependencies: binary-extensions "^1.0.0" -is-buffer@^1.1.0: +is-buffer@^1.1.0, is-buffer@~1.1.5: version "1.1.6" resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-1.1.6.tgz#efaa2ea9daa0d7ab2ea13a97b2b8ad51fefbe8be" -is-buffer@^1.1.5, is-buffer@~1.1.2: +is-buffer@^1.1.5: version "1.1.5" resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-1.1.5.tgz#1f3b26ef613b214b88cbca23cc6c01d87961eecc" @@ -4679,7 +4695,7 @@ is-builtin-module@^1.0.0: dependencies: builtin-modules "^1.0.0" -is-ci@^1.0.9: +is-ci@^1.0.10: version "1.0.10" resolved "https://registry.yarnpkg.com/is-ci/-/is-ci-1.0.10.tgz#f739336b2632365061a9d48270cd56ae3369318e" dependencies: @@ -4719,10 +4735,6 @@ is-fullwidth-code-point@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz#a3b30a5c4f199183167aaab93beefae3ddfb654f" -is-git-url@^0.2.0: - version "0.2.3" - resolved "https://registry.yarnpkg.com/is-git-url/-/is-git-url-0.2.3.tgz#445200d6fbd6da028fb5e01440d9afc93f3ccb64" - is-git-url@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-git-url/-/is-git-url-1.0.0.tgz#53f684cd143285b52c3244b4e6f28253527af66b" @@ -4739,15 +4751,6 @@ is-integer@^1.0.4: dependencies: is-finite "^1.0.0" -is-my-json-valid@^2.10.0: - version "2.16.1" - resolved "https://registry.yarnpkg.com/is-my-json-valid/-/is-my-json-valid-2.16.1.tgz#5a846777e2c2620d1e69104e5d3a03b1f6088f11" - dependencies: - generate-function "^2.0.0" - generate-object-property "^1.1.0" - jsonpointer "^4.0.0" - xtend "^4.0.0" - is-number@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/is-number/-/is-number-2.1.0.tgz#01fcbbb393463a548f2f466cce16dece49db908f" @@ -4792,10 +4795,6 @@ is-promise@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/is-promise/-/is-promise-2.1.0.tgz#79a2a9ece7f096e80f36d2b2f3bc16c1ff4bf3fa" -is-property@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/is-property/-/is-property-1.0.2.tgz#57fe1c4e48474edd65b09911f26b1cd4095dda84" - is-resolvable@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-resolvable/-/is-resolvable-1.0.0.tgz#8df57c61ea2e3c501408d100fb013cf8d6e0cc62" @@ -4878,7 +4877,7 @@ js-tokens@^3.0.0, js-tokens@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.2.tgz#9866df395102130e38f7f996bceb65443209c25b" -js-yaml@^3.2.5, js-yaml@^3.2.7, js-yaml@^3.4.3, js-yaml@^3.5.1, js-yaml@^3.6.1, js-yaml@^3.9.1: +js-yaml@^3.2.5, js-yaml@^3.2.7, js-yaml@^3.4.3, js-yaml@^3.6.1, js-yaml@^3.9.1: version "3.9.1" resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.9.1.tgz#08775cebdfdd359209f0d2acd383c8f86a6904a0" dependencies: @@ -4928,6 +4927,10 @@ json-schema@0.2.3: version "0.2.3" resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.2.3.tgz#b480c892e59a2f05954ce727bd3f2a4e882f9e13" +json-stable-stringify-without-jsonify@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651" + json-stable-stringify@^1.0.0, json-stable-stringify@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/json-stable-stringify/-/json-stable-stringify-1.0.1.tgz#9a759d39c5f2ff503fd5300646ed445f88c4f9af" @@ -4976,10 +4979,6 @@ jsonparse@^1.2.0: version "1.3.1" resolved "https://registry.yarnpkg.com/jsonparse/-/jsonparse-1.3.1.tgz#3f4dae4a91fac315f71062f8521cc239f1366280" -jsonpointer@^4.0.0: - version "4.0.1" - resolved "https://registry.yarnpkg.com/jsonpointer/-/jsonpointer-4.0.1.tgz#4fd92cb34e0e9db3c89c8622ecf51f9b978c6cb9" - jsprim@^1.2.2: version "1.4.1" resolved "https://registry.yarnpkg.com/jsprim/-/jsprim-1.4.1.tgz#313e66bc1e5cc06e438bc1b7499c2e5c56acb6a2" @@ -5436,7 +5435,7 @@ lodash.memoize@~3.0.3: version "3.0.4" resolved "https://registry.yarnpkg.com/lodash.memoize/-/lodash.memoize-3.0.4.tgz#2dcbd2c287cbc0a55cc42328bd0c736150d53e3f" -lodash.merge@^4.3.0, lodash.merge@^4.4.0, lodash.merge@^4.5.1, lodash.merge@^4.6.0: +lodash.merge@^4.3.0, lodash.merge@^4.4.0, lodash.merge@^4.6.0: version "4.6.0" resolved "https://registry.yarnpkg.com/lodash.merge/-/lodash.merge-4.6.0.tgz#69884ba144ac33fe699737a6086deffadd0f89c5" @@ -5620,6 +5619,12 @@ matcher-collection@^1.0.0: dependencies: minimatch "^3.0.2" +matcher-collection@^1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/matcher-collection/-/matcher-collection-1.0.5.tgz#2ee095438372cb8884f058234138c05c644ec339" + dependencies: + minimatch "^3.0.2" + md5-hex@^1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/md5-hex/-/md5-hex-1.3.0.tgz#d2c4afe983c4370662179b8cad145219135046c4" @@ -5814,9 +5819,9 @@ module-deps@^4.0.8: through2 "^2.0.0" xtend "^4.0.0" -moment-timezone@~0.5.11: - version "0.5.13" - resolved "https://registry.yarnpkg.com/moment-timezone/-/moment-timezone-0.5.13.tgz#99ce5c7d827262eb0f1f702044177f60745d7b90" +moment-timezone@^0.5.13: + version "0.5.14" + resolved "https://registry.yarnpkg.com/moment-timezone/-/moment-timezone-0.5.14.tgz#4eb38ff9538b80108ba467a458f3ed4268ccfcb1" dependencies: moment ">= 2.9.0" @@ -5854,10 +5859,6 @@ mustache@^2.2.1: version "2.3.0" resolved "https://registry.yarnpkg.com/mustache/-/mustache-2.3.0.tgz#4028f7778b17708a489930a6e52ac3bca0da41d0" -mute-stream@0.0.5: - version "0.0.5" - resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.5.tgz#8fbfabb0a98a253d3184331f9e8deb7372fac6c0" - mute-stream@0.0.6: version "0.0.6" resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.6.tgz#48962b19e169fd1dfc240b3f1e7317627bbc47db" @@ -5889,9 +5890,9 @@ node-fetch@^1.3.3: encoding "^0.1.11" is-stream "^1.0.1" -node-fetch@^2.0.0-alpha.3: - version "2.0.0-alpha.8" - resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.0.0-alpha.8.tgz#f586cf6730ce30431c7d4528ce561d81add8ba90" +node-fetch@^2.0.0-alpha.9: + version "2.0.0-alpha.9" + resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.0.0-alpha.9.tgz#990c0634f510f76449a0d6f6eaec96b22f273628" node-gyp@^3.3.1: version "3.6.2" @@ -6352,14 +6353,14 @@ pinkie@^2.0.0: version "2.0.4" resolved "https://registry.yarnpkg.com/pinkie/-/pinkie-2.0.4.tgz#72556b80cfa0d48a974e80e77248e80ed4f7f870" -pluralize@^1.2.1: - version "1.2.1" - resolved "https://registry.yarnpkg.com/pluralize/-/pluralize-1.2.1.tgz#d1a21483fd22bb41e58a12fa3421823140897c45" - pluralize@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/pluralize/-/pluralize-4.0.0.tgz#59b708c1c0190a2f692f1c7618c446b052fd1762" +pluralize@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/pluralize/-/pluralize-7.0.0.tgz#298b89df8b93b0221dbf421ad2b1b1ea23fc6777" + portfinder@^1.0.7: version "1.0.13" resolved "https://registry.yarnpkg.com/portfinder/-/portfinder-1.0.13.tgz#bb32ecd87c27104ae6ee44b5a3ccbf0ebb1aede9" @@ -6409,10 +6410,6 @@ process@~0.11.0: version "0.11.10" resolved "https://registry.yarnpkg.com/process/-/process-0.11.10.tgz#7332300e840161bda3e69a1d1d91a7d4bc16f182" -progress@^1.1.8: - version "1.1.8" - resolved "https://registry.yarnpkg.com/progress/-/progress-1.1.8.tgz#e260c78f6161cdd9b0e56cc3e0a85de17c7a57be" - progress@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/progress/-/progress-2.0.0.tgz#8a1be366bf8fc23db2bd23f10c6fe920b4389d1f" @@ -6465,8 +6462,8 @@ qs@~6.4.0: resolved "https://registry.yarnpkg.com/qs/-/qs-6.4.0.tgz#13e26d28ad6b0ffaa91312cd3bf708ed351e7233" query-string@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/query-string/-/query-string-5.0.0.tgz#fbdf7004b4d2aff792f9871981b7a2794f555947" + version "5.0.1" + resolved "https://registry.yarnpkg.com/query-string/-/query-string-5.0.1.tgz#6e2b86fe0e08aef682ecbe86e85834765402bd88" dependencies: decode-uri-component "^0.2.0" object-assign "^4.1.0" @@ -6621,14 +6618,6 @@ readdirp@^2.0.0: readable-stream "^2.0.2" set-immediate-shim "^1.0.1" -readline2@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/readline2/-/readline2-1.0.1.tgz#41059608ffc154757b715d9989d199ffbf372e35" - dependencies: - code-point-at "^1.0.0" - is-fullwidth-code-point "^1.0.0" - mute-stream "0.0.5" - recast@0.10.33, recast@^0.10.10: version "0.10.33" resolved "https://registry.yarnpkg.com/recast/-/recast-0.10.33.tgz#942808f7aa016f1fa7142c461d7e5704aaa8d697" @@ -6647,12 +6636,6 @@ recast@^0.11.17, recast@^0.11.3: private "~0.1.5" source-map "~0.5.0" -rechoir@^0.6.2: - version "0.6.2" - resolved "https://registry.yarnpkg.com/rechoir/-/rechoir-0.6.2.tgz#85204b54dba82d5742e28c96756ef43af50e3384" - dependencies: - resolve "^1.1.6" - redent@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/redent/-/redent-1.0.0.tgz#cf916ab1fd5f1f16dfb20822dd6ec7f730c2afde" @@ -6799,7 +6782,7 @@ require-main-filename@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-1.0.1.tgz#97f717b69d48784f5f526a6c5aa8ffdda055a4d1" -require-uncached@^1.0.2, require-uncached@^1.0.3: +require-uncached@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/require-uncached/-/require-uncached-1.0.3.tgz#4e0d56d6c9662fd31e43011c4b95aa49955421d3" dependencies: @@ -6837,7 +6820,7 @@ resolve@^1.1.2, resolve@^1.1.6, resolve@^1.1.7, resolve@^1.3.0, resolve@^1.3.3, dependencies: path-parse "^1.0.5" -resolve@^1.1.3, resolve@^1.1.4: +resolve@^1.1.3, resolve@^1.1.4, resolve@^1.5.0: version "1.5.0" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.5.0.tgz#1f09acce796c9a762579f31b2c1cc4c3cddf9f36" dependencies: @@ -6898,7 +6881,7 @@ rsvp@^3.0.14, rsvp@^3.0.16, rsvp@^3.0.17, rsvp@^3.0.18, rsvp@^3.0.21, rsvp@^3.0. version "3.6.2" resolved "https://registry.yarnpkg.com/rsvp/-/rsvp-3.6.2.tgz#2e96491599a96cde1b515d5674a8f7a91452926a" -rsvp@^4.7.0: +rsvp@^4.6.1, rsvp@^4.7.0: version "4.7.0" resolved "https://registry.yarnpkg.com/rsvp/-/rsvp-4.7.0.tgz#dc1b0b1a536f7dec9d2be45e0a12ad4197c9fd96" @@ -6910,12 +6893,6 @@ rsvp@~3.2.1: version "3.2.1" resolved "https://registry.yarnpkg.com/rsvp/-/rsvp-3.2.1.tgz#07cb4a5df25add9e826ebc67dcc9fd89db27d84a" -run-async@^0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/run-async/-/run-async-0.1.0.tgz#c8ad4a5e110661e402a7d21b530e009f25f8e389" - dependencies: - once "^1.3.0" - run-async@^2.2.0: version "2.3.0" resolved "https://registry.yarnpkg.com/run-async/-/run-async-2.3.0.tgz#0371ab4ae0bdd720d4166d7dfda64ff7a445a6c0" @@ -6932,10 +6909,6 @@ rx-lite@*, rx-lite@^4.0.8: version "4.0.8" resolved "https://registry.yarnpkg.com/rx-lite/-/rx-lite-4.0.8.tgz#0b1e11af8bc44836f04a6407e92da42467b79444" -rx-lite@^3.1.2: - version "3.1.2" - resolved "https://registry.yarnpkg.com/rx-lite/-/rx-lite-3.1.2.tgz#19ce502ca572665f3b647b10939f97fd1615f102" - rx@^4.1.0: version "4.1.0" resolved "https://registry.yarnpkg.com/rx/-/rx-4.1.0.tgz#a5f13ff79ef3b740fe30aa803fb09f98805d4782" @@ -6994,10 +6967,6 @@ scss-tokenizer@^0.2.3: version "5.4.1" resolved "https://registry.yarnpkg.com/semver/-/semver-5.4.1.tgz#e059c09d8571f0540823733433505d3a2f00b18e" -semver@^4.1.0: - version "4.3.6" - resolved "https://registry.yarnpkg.com/semver/-/semver-4.3.6.tgz#300bc6e0e86374f7ba61068b5b1ecd57fc6532da" - semver@~5.3.0: version "5.3.0" resolved "https://registry.yarnpkg.com/semver/-/semver-5.3.0.tgz#9b2ce5d3de02d17c6012ad326aa6b4d0cf54f94f" @@ -7074,14 +7043,6 @@ shell-quote@^1.6.1: array-reduce "~0.0.0" jsonify "~0.0.0" -shelljs@^0.7.5: - version "0.7.8" - resolved "https://registry.yarnpkg.com/shelljs/-/shelljs-0.7.8.tgz#decbcf874b0d1e5fb72e14b164a9683048e9acb3" - dependencies: - glob "^7.0.0" - interpret "^1.0.0" - rechoir "^0.6.2" - shellwords@^0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/shellwords/-/shellwords-0.1.1.tgz#d6b9181c1a48d397324c84871efbcfc73fc0654b" @@ -7207,6 +7168,10 @@ source-map-url@^0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/source-map-url/-/source-map-url-0.3.0.tgz#7ecaf13b57bcd09da8a40c5d269db33799d4aaf9" +source-map-url@^0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/source-map-url/-/source-map-url-0.4.0.tgz#3e935d7ddd73631b97659956d55128e87b5084a3" + source-map@0.1.32, source-map@~0.1.x: version "0.1.32" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.1.32.tgz#c8b6c167797ba4740a8ea33252162ff08591b266" @@ -7223,6 +7188,10 @@ source-map@^0.5.0, source-map@^0.5.3, source-map@^0.5.6, source-map@~0.5.0, sour version "0.5.7" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc" +source-map@~0.6.1: + version "0.6.1" + resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" + sourcemap-validator@^1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/sourcemap-validator/-/sourcemap-validator-1.0.5.tgz#f9b960f48c6469e288a19af305f005da3dc1df3a" @@ -7419,6 +7388,10 @@ strip-indent@^1.0.1: dependencies: get-stdin "^4.0.1" +strip-indent@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/strip-indent/-/strip-indent-2.0.0.tgz#5ef8db295d01e6ed6cbf7aab96998d7822527b68" + strip-json-comments@~2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a" @@ -7479,17 +7452,6 @@ syntax-error@^1.1.1: dependencies: acorn "^4.0.3" -table@^3.7.8: - version "3.8.3" - resolved "https://registry.yarnpkg.com/table/-/table-3.8.3.tgz#2bbc542f0fda9861a755d3947fefd8b3f513855f" - dependencies: - ajv "^4.7.0" - ajv-keywords "^1.0.0" - chalk "^1.1.1" - lodash "^4.0.0" - slice-ansi "0.0.4" - string-width "^2.0.0" - table@^4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/table/-/table-4.0.1.tgz#a8116c133fac2c61f4a420ab6cdf5c4d61f0e435" @@ -7718,7 +7680,14 @@ uc.micro@^1.0.1, uc.micro@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/uc.micro/-/uc.micro-1.0.3.tgz#7ed50d5e0f9a9fb0a573379259f2a77458d50192" -uglify-js@^2.6, uglify-js@^2.7.0: +uglify-es@^3.1.3: + version "3.2.2" + resolved "https://registry.yarnpkg.com/uglify-es/-/uglify-es-3.2.2.tgz#15c62b7775002c81b7987a1c49ecd3f126cace73" + dependencies: + commander "~2.12.1" + source-map "~0.6.1" + +uglify-js@^2.6: version "2.8.29" resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-2.8.29.tgz#29c5733148057bb4e1f75df35b7a9cb72e6a59dd" dependencies: @@ -7785,12 +7754,6 @@ user-home@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/user-home/-/user-home-1.1.1.tgz#2b5be23a32b63a7c9deb8d0f28d485724a3df190" -user-home@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/user-home/-/user-home-2.0.0.tgz#9c70bfd8169bc1dcbf48604e0f04b8b49cde9e9f" - dependencies: - os-homedir "^1.0.0" - username-sync@1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/username-sync/-/username-sync-1.0.1.tgz#1cde87eefcf94b8822984d938ba2b797426dae1f" @@ -7862,7 +7825,7 @@ walk-sync@^0.2.5, walk-sync@^0.2.7: ensure-posix-path "^1.0.0" matcher-collection "^1.0.0" -walk-sync@^0.3.0, walk-sync@^0.3.1: +walk-sync@^0.3.0, walk-sync@^0.3.1, walk-sync@^0.3.2: version "0.3.2" resolved "https://registry.yarnpkg.com/walk-sync/-/walk-sync-0.3.2.tgz#4827280afc42d0e035367c4a4e31eeac0d136f75" dependencies: From 8100dc94e472757eef3a96018e91c593c9351fa6 Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Wed, 13 Dec 2017 11:03:11 -0800 Subject: [PATCH 089/136] Update the reason why the router service is still not used --- ui/app/components/server-agent-row.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/ui/app/components/server-agent-row.js b/ui/app/components/server-agent-row.js index f853ada96..4ad41ee93 100644 --- a/ui/app/components/server-agent-row.js +++ b/ui/app/components/server-agent-row.js @@ -4,7 +4,8 @@ import { lazyClick } from '../helpers/lazy-click'; const { Component, inject, computed } = Ember; export default Component.extend({ - // TODO Switch back to the router service style when it is no longer feature-flagged + // TODO Switch back to the router service once the service behaves more like Route + // https://github.com/emberjs/ember.js/issues/15801 // router: inject.service('router'), _router: inject.service('-routing'), router: computed.alias('_router.router'), @@ -15,7 +16,8 @@ export default Component.extend({ agent: null, isActive: computed('agent', 'router.currentURL', function() { - // TODO Switch back to the router service style when it is no longer feature-flagged + // TODO Switch back to the router service once the service behaves more like Route + // https://github.com/emberjs/ember.js/issues/15801 // const targetURL = this.get('router').urlFor('servers.server', this.get('agent')); // const currentURL = `${this.get('router.rootURL').slice(0, -1)}${this.get('router.currentURL')}`; From 46783e18132e8b896b291eeeb60f402b2b5852ec Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Wed, 13 Dec 2017 16:21:44 -0800 Subject: [PATCH 090/136] Run ember out of node_modules This locks the version to what's described in package.json --- ui/package.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ui/package.json b/ui/package.json index 90e888938..f8162239a 100644 --- a/ui/package.json +++ b/ui/package.json @@ -8,9 +8,9 @@ }, "repository": "", "scripts": { - "build": "ember build -prod", - "start": "ember server --proxy=http://127.0.0.1:4646", - "test": "ember test", + "build": "./node_modules/ember-cli/bin/ember build -prod", + "start": "./node_modules/ember-cli/bin/ember server", + "test": "./node_modules/ember-cli/bin/ember test", "precommit": "lint-staged" }, "lint-staged": { From ab5cec4e1bbf3bdfd25d7c1475a0e721a7c7ba60 Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Wed, 13 Dec 2017 17:04:15 -0800 Subject: [PATCH 091/136] Lock down yarn version --- .travis.yml | 6 ++---- GNUmakefile | 2 +- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/.travis.yml b/.travis.yml index 258b59a16..3a9791d32 100644 --- a/.travis.yml +++ b/.travis.yml @@ -28,13 +28,11 @@ matrix: - os: osx fast_finish: true -cache: - directories: - - ui/node_modules - before_install: - if [[ "$TRAVIS_OS_NAME" == "osx" ]] && [[ -z "$SKIP_NOMAD_TESTS" ]]; then sudo -E bash ./scripts/travis-mac-priv.sh ; fi - if [[ "$TRAVIS_OS_NAME" == "linux" ]] && [[ -z "$SKIP_NOMAD_TESTS" ]]; then sudo -E bash ./scripts/travis-linux.sh ; fi + - if [[ "$RUN_UI_TESTS" ]]; then curl -o- -L https://yarnpkg.com/install.sh | bash -s -- --version 1.0.1 ; fi + - if [[ "$RUN_UI_TESTS" ]]; then export PATH="$HOME/.yarn/bin:$PATH" ; fi install: - if [[ -z "$SKIP_NOMAD_TESTS" ]]; then make deps ; fi diff --git a/GNUmakefile b/GNUmakefile index 3c9741a71..951e7a81b 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -283,8 +283,8 @@ static-assets: ## Compile the static routes to serve alongside the API .PHONY: test-ui test-ui: ## Run Nomad UI test suite @echo "--> Installing JavaScript assets" + @cd ui && npm rebuild node-sass @cd ui && yarn install - @cd ui && npm install phantomjs-prebuilt @echo "--> Running ember tests" @cd ui && phantomjs --version @cd ui && npm test From 2e19c2d8774699753f152e754deae8a484137e75 Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Fri, 15 Dec 2017 13:39:18 -0800 Subject: [PATCH 092/136] Use the new ember modules imports Generated with a codemode: https://github.com/ember-cli/ember-modules-codemod --- ui/app/adapters/application.js | 7 +++--- ui/app/adapters/job.js | 8 +++--- ui/app/adapters/token.js | 6 ++--- ui/app/app.js | 5 ++-- ui/app/components/allocation-row.js | 8 +++--- ui/app/components/allocation-status-bar.js | 4 +-- ui/app/components/attributes-section.js | 4 +-- ui/app/components/client-node-row.js | 4 +-- ui/app/components/distribution-bar.js | 7 ++++-- ui/app/components/gutter-menu.js | 8 +++--- ui/app/components/job-deployment.js | 4 +-- .../job-deployment/deployment-metrics.js | 4 +-- ui/app/components/job-deployments-stream.js | 5 ++-- .../components/job-diff-fields-and-objects.js | 4 +-- ui/app/components/job-diff.js | 11 ++++---- ui/app/components/job-row.js | 4 +-- ui/app/components/job-version.js | 5 ++-- ui/app/components/job-versions-stream.js | 5 ++-- ui/app/components/json-viewer.js | 6 ++--- ui/app/components/list-pagination.js | 13 +++++----- .../components/list-pagination/list-pager.js | 4 +-- ui/app/components/list-table.js | 5 ++-- ui/app/components/list-table/sort-by.js | 5 ++-- ui/app/components/list-table/table-body.js | 4 +-- ui/app/components/list-table/table-head.js | 4 +-- ui/app/components/search-box.js | 8 +++--- ui/app/components/server-agent-row.js | 11 ++++---- ui/app/components/task-group-row.js | 4 +-- ui/app/components/task-log.js | 9 ++++--- ui/app/controllers/allocations/allocation.js | 4 +-- .../allocations/allocation/index.js | 9 +++---- .../allocations/allocation/task/index.js | 8 +++--- ui/app/controllers/application.js | 8 +++--- ui/app/controllers/clients.js | 4 +-- ui/app/controllers/clients/client.js | 12 ++++----- ui/app/controllers/clients/index.js | 20 +++++++-------- ui/app/controllers/freestyle.js | 7 +++--- ui/app/controllers/jobs.js | 9 ++++--- ui/app/controllers/jobs/index.js | 25 ++++++++++--------- ui/app/controllers/jobs/job.js | 5 ++-- ui/app/controllers/jobs/job/definition.js | 11 ++++---- ui/app/controllers/jobs/job/deployments.js | 13 +++++----- ui/app/controllers/jobs/job/index.js | 19 +++++++------- ui/app/controllers/jobs/job/loading.js | 9 +++---- ui/app/controllers/jobs/job/task-group.js | 14 +++++------ ui/app/controllers/jobs/job/versions.js | 13 +++++----- ui/app/controllers/servers.js | 13 +++++----- ui/app/controllers/servers/index.js | 9 +++---- ui/app/controllers/servers/server.js | 5 ++-- ui/app/controllers/settings/tokens.js | 13 +++++----- ui/app/helpers/css-class.js | 4 +-- ui/app/helpers/format-bytes.js | 4 +-- ui/app/helpers/format-percentage.js | 4 +-- ui/app/helpers/is-object.js | 4 +-- ui/app/helpers/lazy-click.js | 5 ++-- ui/app/helpers/pluralize.js | 4 +-- ui/app/helpers/x-icon.js | 4 +-- ui/app/mixins/searchable.js | 5 ++-- ui/app/mixins/sortable.js | 5 ++-- ui/app/mixins/window-resizable.js | 8 +++--- ui/app/mixins/with-forbidden-state.js | 4 +-- ui/app/mixins/with-model-error-handling.js | 4 +-- ui/app/mixins/with-namespace-resetting.js | 10 ++++---- ui/app/models/agent.js | 7 +++--- ui/app/models/allocation.js | 11 ++++---- ui/app/models/deployment.js | 7 +++--- ui/app/models/evaluation.js | 6 ++--- ui/app/models/job.js | 13 +++++----- ui/app/models/namespace.js | 6 ++--- ui/app/models/node-attributes.js | 13 +++++----- ui/app/models/node.js | 4 +-- ui/app/models/task-event.js | 3 +-- .../models/task-group-deployment-summary.js | 6 ++--- ui/app/models/task-group-summary.js | 8 +++--- ui/app/models/task-group.js | 4 +-- ui/app/models/task-state.js | 7 +++--- ui/app/models/token.js | 6 ++--- ui/app/router.js | 4 +-- ui/app/routes/allocations/allocation.js | 4 +-- ui/app/routes/allocations/allocation/task.js | 8 +++--- .../allocations/allocation/task/logs.js | 4 +-- ui/app/routes/application.js | 7 +++--- ui/app/routes/clients.js | 10 ++++---- ui/app/routes/clients/client.js | 7 +++--- ui/app/routes/index.js | 4 +-- ui/app/routes/jobs.js | 10 ++++---- ui/app/routes/jobs/index.js | 4 +-- ui/app/routes/jobs/job.js | 8 +++--- ui/app/routes/jobs/job/definition.js | 4 +-- ui/app/routes/jobs/job/deployments.js | 5 ++-- ui/app/routes/jobs/job/task-group.js | 4 +-- ui/app/routes/jobs/job/versions.js | 4 +-- ui/app/routes/not-found.js | 5 ++-- ui/app/routes/servers.js | 10 ++++---- ui/app/routes/servers/server.js | 4 +-- ui/app/serializers/allocation.js | 7 +++--- ui/app/serializers/application.js | 4 +-- ui/app/serializers/deployment.js | 5 ++-- ui/app/serializers/evaluation.js | 8 +++--- ui/app/serializers/job-version.js | 4 +-- ui/app/serializers/job.js | 5 ++-- ui/app/serializers/node.js | 6 ++--- ui/app/serializers/task-group.js | 4 +-- ui/app/serializers/token.js | 4 +-- ui/app/services/config.js | 12 ++++----- ui/app/services/system.js | 9 +++---- ui/app/services/token.js | 6 ++--- ui/app/utils/classes/abstract-logger.js | 10 ++++---- ui/app/utils/classes/log.js | 14 +++++------ ui/app/utils/classes/poll-logger.js | 4 +-- ui/app/utils/classes/promise-object.js | 5 ++-- ui/app/utils/classes/stream-logger.js | 4 +-- ui/app/utils/properties/short-uuid.js | 4 +-- ui/app/utils/properties/style-string.js | 4 +-- ui/app/utils/properties/sum-aggregation.js | 8 +++--- ui/app/utils/timeout.js | 4 +-- ui/tests/acceptance/allocation-detail-test.js | 4 +-- ui/tests/acceptance/client-detail-test.js | 4 +-- ui/tests/acceptance/job-deployments-test.js | 4 +-- ui/tests/acceptance/job-detail-test.js | 4 +-- ui/tests/acceptance/job-versions-test.js | 4 +-- ui/tests/acceptance/jobs-list-test.js | 4 +-- ui/tests/acceptance/nodes-list-test.js | 4 +-- ui/tests/acceptance/server-detail-test.js | 4 +-- ui/tests/acceptance/task-detail-test.js | 4 +-- ui/tests/acceptance/task-group-detail-test.js | 4 +-- ui/tests/acceptance/task-logs-test.js | 4 +-- ui/tests/acceptance/token-test.js | 4 +-- ui/tests/helpers/destroy-app.js | 4 +-- ui/tests/helpers/module-for-acceptance.js | 4 +-- ui/tests/helpers/module-for-serializer.js | 4 +-- ui/tests/helpers/start-app.js | 9 ++++--- ui/tests/integration/task-log-test.js | 4 +-- ui/tests/unit/mixins/searchable-test.js | 10 ++++---- ui/tests/unit/models/task-group-test.js | 3 +-- ui/tests/unit/utils/log-test.js | 6 ++--- 136 files changed, 384 insertions(+), 517 deletions(-) diff --git a/ui/app/adapters/application.js b/ui/app/adapters/application.js index 1e5c97333..bcf223383 100644 --- a/ui/app/adapters/application.js +++ b/ui/app/adapters/application.js @@ -1,15 +1,14 @@ -import Ember from 'ember'; +import { inject as service } from '@ember/service'; +import { computed, get } from '@ember/object'; import RESTAdapter from 'ember-data/adapters/rest'; import codesForError from '../utils/codes-for-error'; -const { get, computed, inject } = Ember; - export const namespace = 'v1'; export default RESTAdapter.extend({ namespace, - token: inject.service(), + token: service(), headers: computed('token.secret', function() { const token = this.get('token.secret'); diff --git a/ui/app/adapters/job.js b/ui/app/adapters/job.js index 4d18d1625..80398adac 100644 --- a/ui/app/adapters/job.js +++ b/ui/app/adapters/job.js @@ -1,10 +1,10 @@ -import Ember from 'ember'; +import { inject as service } from '@ember/service'; +import RSVP from 'rsvp'; +import { assign } from '@ember/polyfills'; import ApplicationAdapter from './application'; -const { RSVP, inject, assign } = Ember; - export default ApplicationAdapter.extend({ - system: inject.service(), + system: service(), shouldReloadAll: () => true, diff --git a/ui/app/adapters/token.js b/ui/app/adapters/token.js index 0bd103334..32315037a 100644 --- a/ui/app/adapters/token.js +++ b/ui/app/adapters/token.js @@ -1,10 +1,8 @@ -import Ember from 'ember'; +import { inject as service } from '@ember/service'; import { default as ApplicationAdapter, namespace } from './application'; -const { inject } = Ember; - export default ApplicationAdapter.extend({ - store: inject.service(), + store: service(), namespace: namespace + '/acl', diff --git a/ui/app/app.js b/ui/app/app.js index 831ad6106..c5fb686f8 100644 --- a/ui/app/app.js +++ b/ui/app/app.js @@ -1,3 +1,4 @@ +import Application from '@ember/application'; import Ember from 'ember'; import Resolver from './resolver'; import loadInitializers from 'ember-load-initializers'; @@ -7,10 +8,10 @@ let App; Ember.MODEL_FACTORY_INJECTIONS = true; -App = Ember.Application.extend({ +App = Application.extend({ modulePrefix: config.modulePrefix, podModulePrefix: config.podModulePrefix, - Resolver + Resolver, }); loadInitializers(App, config.modulePrefix); diff --git a/ui/app/components/allocation-row.js b/ui/app/components/allocation-row.js index a258f5b24..5625c092f 100644 --- a/ui/app/components/allocation-row.js +++ b/ui/app/components/allocation-row.js @@ -1,10 +1,10 @@ -import Ember from 'ember'; +import { inject as service } from '@ember/service'; +import Component from '@ember/component'; +import { run } from '@ember/runloop'; import { lazyClick } from '../helpers/lazy-click'; -const { Component, inject, run } = Ember; - export default Component.extend({ - store: inject.service(), + store: service(), tagName: 'tr', diff --git a/ui/app/components/allocation-status-bar.js b/ui/app/components/allocation-status-bar.js index 0a3734626..7f2d1e2fc 100644 --- a/ui/app/components/allocation-status-bar.js +++ b/ui/app/components/allocation-status-bar.js @@ -1,8 +1,6 @@ -import Ember from 'ember'; +import { computed } from '@ember/object'; import DistributionBar from './distribution-bar'; -const { computed } = Ember; - export default DistributionBar.extend({ layoutName: 'components/distribution-bar', diff --git a/ui/app/components/attributes-section.js b/ui/app/components/attributes-section.js index f2503c9fc..479865264 100644 --- a/ui/app/components/attributes-section.js +++ b/ui/app/components/attributes-section.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { Component } = Ember; +import Component from '@ember/component'; export default Component.extend({ tagName: '', diff --git a/ui/app/components/client-node-row.js b/ui/app/components/client-node-row.js index e2f9dd19c..2775ed58f 100644 --- a/ui/app/components/client-node-row.js +++ b/ui/app/components/client-node-row.js @@ -1,8 +1,6 @@ -import Ember from 'ember'; +import Component from '@ember/component'; import { lazyClick } from '../helpers/lazy-click'; -const { Component } = Ember; - export default Component.extend({ tagName: 'tr', classNames: ['client-node-row', 'is-interactive'], diff --git a/ui/app/components/distribution-bar.js b/ui/app/components/distribution-bar.js index 105273df6..8c171b11b 100644 --- a/ui/app/components/distribution-bar.js +++ b/ui/app/components/distribution-bar.js @@ -1,10 +1,13 @@ -import Ember from 'ember'; +import Component from '@ember/component'; +import { computed } from '@ember/object'; +import { run } from '@ember/runloop'; +import { assign } from '@ember/polyfills'; +import { guidFor } from '@ember/object/internals'; import d3 from 'npm:d3-selection'; import 'npm:d3-transition'; import WindowResizable from '../mixins/window-resizable'; import styleStringProperty from '../utils/properties/style-string'; -const { Component, computed, run, assign, guidFor } = Ember; const sumAggregate = (total, val) => total + val; export default Component.extend(WindowResizable, { diff --git a/ui/app/components/gutter-menu.js b/ui/app/components/gutter-menu.js index 9ab098cbb..7a5086b76 100644 --- a/ui/app/components/gutter-menu.js +++ b/ui/app/components/gutter-menu.js @@ -1,9 +1,9 @@ -import Ember from 'ember'; - -const { Component, inject, computed } = Ember; +import { inject as service } from '@ember/service'; +import Component from '@ember/component'; +import { computed } from '@ember/object'; export default Component.extend({ - system: inject.service(), + system: service(), sortedNamespaces: computed('system.namespaces.@each.name', function() { const namespaces = this.get('system.namespaces').toArray() || []; diff --git a/ui/app/components/job-deployment.js b/ui/app/components/job-deployment.js index 1a2476be8..feb13f17d 100644 --- a/ui/app/components/job-deployment.js +++ b/ui/app/components/job-deployment.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { Component } = Ember; +import Component from '@ember/component'; export default Component.extend({ classNames: ['job-deployment', 'boxed-section'], diff --git a/ui/app/components/job-deployment/deployment-metrics.js b/ui/app/components/job-deployment/deployment-metrics.js index f2503c9fc..479865264 100644 --- a/ui/app/components/job-deployment/deployment-metrics.js +++ b/ui/app/components/job-deployment/deployment-metrics.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { Component } = Ember; +import Component from '@ember/component'; export default Component.extend({ tagName: '', diff --git a/ui/app/components/job-deployments-stream.js b/ui/app/components/job-deployments-stream.js index 65b700491..0ddb5fedb 100644 --- a/ui/app/components/job-deployments-stream.js +++ b/ui/app/components/job-deployments-stream.js @@ -1,8 +1,7 @@ -import Ember from 'ember'; +import Component from '@ember/component'; +import { computed } from '@ember/object'; import moment from 'moment'; -const { Component, computed } = Ember; - export default Component.extend({ tagName: 'ol', classNames: ['timeline'], diff --git a/ui/app/components/job-diff-fields-and-objects.js b/ui/app/components/job-diff-fields-and-objects.js index f2503c9fc..479865264 100644 --- a/ui/app/components/job-diff-fields-and-objects.js +++ b/ui/app/components/job-diff-fields-and-objects.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { Component } = Ember; +import Component from '@ember/component'; export default Component.extend({ tagName: '', diff --git a/ui/app/components/job-diff.js b/ui/app/components/job-diff.js index 2bba7310e..79371f333 100644 --- a/ui/app/components/job-diff.js +++ b/ui/app/components/job-diff.js @@ -1,6 +1,5 @@ -import Ember from 'ember'; - -const { Component, computed } = Ember; +import { equal } from '@ember/object/computed'; +import Component from '@ember/component'; export default Component.extend({ classNames: ['job-diff'], @@ -10,7 +9,7 @@ export default Component.extend({ verbose: true, - isEdited: computed.equal('diff.Type', 'Edited'), - isAdded: computed.equal('diff.Type', 'Added'), - isDeleted: computed.equal('diff.Type', 'Deleted'), + isEdited: equal('diff.Type', 'Edited'), + isAdded: equal('diff.Type', 'Added'), + isDeleted: equal('diff.Type', 'Deleted'), }); diff --git a/ui/app/components/job-row.js b/ui/app/components/job-row.js index e370cfba9..db9e6e369 100644 --- a/ui/app/components/job-row.js +++ b/ui/app/components/job-row.js @@ -1,8 +1,6 @@ -import Ember from 'ember'; +import Component from '@ember/component'; import { lazyClick } from '../helpers/lazy-click'; -const { Component } = Ember; - export default Component.extend({ tagName: 'tr', classNames: ['job-row', 'is-interactive'], diff --git a/ui/app/components/job-version.js b/ui/app/components/job-version.js index 0ffe77803..978111a93 100644 --- a/ui/app/components/job-version.js +++ b/ui/app/components/job-version.js @@ -1,6 +1,5 @@ -import Ember from 'ember'; - -const { Component, computed } = Ember; +import Component from '@ember/component'; +import { computed } from '@ember/object'; const changeTypes = ['Added', 'Deleted', 'Edited']; diff --git a/ui/app/components/job-versions-stream.js b/ui/app/components/job-versions-stream.js index 8ac011376..b2a92d71a 100644 --- a/ui/app/components/job-versions-stream.js +++ b/ui/app/components/job-versions-stream.js @@ -1,8 +1,7 @@ -import Ember from 'ember'; +import Component from '@ember/component'; +import { computed } from '@ember/object'; import moment from 'moment'; -const { Component, computed } = Ember; - export default Component.extend({ tagName: 'ol', classNames: ['timeline'], diff --git a/ui/app/components/json-viewer.js b/ui/app/components/json-viewer.js index 2d8442e33..cf966757d 100644 --- a/ui/app/components/json-viewer.js +++ b/ui/app/components/json-viewer.js @@ -1,8 +1,8 @@ -import Ember from 'ember'; +import Component from '@ember/component'; +import { computed } from '@ember/object'; +import { run } from '@ember/runloop'; import JSONFormatterPkg from 'npm:json-formatter-js'; -const { Component, computed, run } = Ember; - // json-formatter-js is packaged in a funny way that ember-cli-browserify // doesn't unwrap properly. const { default: JSONFormatter } = JSONFormatterPkg; diff --git a/ui/app/components/list-pagination.js b/ui/app/components/list-pagination.js index c18301d4a..c04aaa9f4 100644 --- a/ui/app/components/list-pagination.js +++ b/ui/app/components/list-pagination.js @@ -1,6 +1,5 @@ -import Ember from 'ember'; - -const { Component, computed } = Ember; +import Component from '@ember/component'; +import { computed } from '@ember/object'; export default Component.extend({ source: computed(() => []), @@ -31,9 +30,11 @@ export default Component.extend({ const lowerBound = Math.max(1, page - spread); const upperBound = Math.min(lastPage, page + spread) + 1; - return Array(upperBound - lowerBound).fill(null).map((_, index) => ({ - pageNumber: lowerBound + index, - })); + return Array(upperBound - lowerBound) + .fill(null) + .map((_, index) => ({ + pageNumber: lowerBound + index, + })); }), list: computed('source.[]', 'page', 'size', function() { diff --git a/ui/app/components/list-pagination/list-pager.js b/ui/app/components/list-pagination/list-pager.js index f2503c9fc..479865264 100644 --- a/ui/app/components/list-pagination/list-pager.js +++ b/ui/app/components/list-pagination/list-pager.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { Component } = Ember; +import Component from '@ember/component'; export default Component.extend({ tagName: '', diff --git a/ui/app/components/list-table.js b/ui/app/components/list-table.js index 39cf15fe6..0b6d63416 100644 --- a/ui/app/components/list-table.js +++ b/ui/app/components/list-table.js @@ -1,6 +1,5 @@ -import Ember from 'ember'; - -const { Component, computed } = Ember; +import Component from '@ember/component'; +import { computed } from '@ember/object'; export default Component.extend({ tagName: 'table', diff --git a/ui/app/components/list-table/sort-by.js b/ui/app/components/list-table/sort-by.js index 9edcb61e7..cd6e3fc2c 100644 --- a/ui/app/components/list-table/sort-by.js +++ b/ui/app/components/list-table/sort-by.js @@ -1,6 +1,5 @@ -import Ember from 'ember'; - -const { Component, computed } = Ember; +import Component from '@ember/component'; +import { computed } from '@ember/object'; export default Component.extend({ tagName: 'th', diff --git a/ui/app/components/list-table/table-body.js b/ui/app/components/list-table/table-body.js index 4c756a699..782917851 100644 --- a/ui/app/components/list-table/table-body.js +++ b/ui/app/components/list-table/table-body.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { Component } = Ember; +import Component from '@ember/component'; export default Component.extend({ tagName: 'tbody', diff --git a/ui/app/components/list-table/table-head.js b/ui/app/components/list-table/table-head.js index c1f0c7825..92a17d670 100644 --- a/ui/app/components/list-table/table-head.js +++ b/ui/app/components/list-table/table-head.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { Component } = Ember; +import Component from '@ember/component'; export default Component.extend({ tagName: 'thead', diff --git a/ui/app/components/search-box.js b/ui/app/components/search-box.js index 19aa76bef..8066f3e0b 100644 --- a/ui/app/components/search-box.js +++ b/ui/app/components/search-box.js @@ -1,13 +1,13 @@ -import Ember from 'ember'; - -const { Component, computed, run } = Ember; +import { reads } from '@ember/object/computed'; +import Component from '@ember/component'; +import { run } from '@ember/runloop'; export default Component.extend({ // Passed to the component (mutable) searchTerm: null, // Used as a debounce buffer - _searchTerm: computed.reads('searchTerm'), + _searchTerm: reads('searchTerm'), // Used to throttle sets to searchTerm debounce: 150, diff --git a/ui/app/components/server-agent-row.js b/ui/app/components/server-agent-row.js index 4ad41ee93..98d401fe0 100644 --- a/ui/app/components/server-agent-row.js +++ b/ui/app/components/server-agent-row.js @@ -1,14 +1,15 @@ -import Ember from 'ember'; +import { inject as service } from '@ember/service'; +import { alias } from '@ember/object/computed'; +import Component from '@ember/component'; +import { computed } from '@ember/object'; import { lazyClick } from '../helpers/lazy-click'; -const { Component, inject, computed } = Ember; - export default Component.extend({ // TODO Switch back to the router service once the service behaves more like Route // https://github.com/emberjs/ember.js/issues/15801 // router: inject.service('router'), - _router: inject.service('-routing'), - router: computed.alias('_router.router'), + _router: service('-routing'), + router: alias('_router.router'), tagName: 'tr', classNames: ['server-agent-row', 'is-interactive'], diff --git a/ui/app/components/task-group-row.js b/ui/app/components/task-group-row.js index 4fb239637..98753d615 100644 --- a/ui/app/components/task-group-row.js +++ b/ui/app/components/task-group-row.js @@ -1,8 +1,6 @@ -import Ember from 'ember'; +import Component from '@ember/component'; import { lazyClick } from '../helpers/lazy-click'; -const { Component } = Ember; - export default Component.extend({ tagName: 'tr', diff --git a/ui/app/components/task-log.js b/ui/app/components/task-log.js index 1b066db73..277023859 100644 --- a/ui/app/components/task-log.js +++ b/ui/app/components/task-log.js @@ -1,12 +1,13 @@ -import Ember from 'ember'; +import { inject as service } from '@ember/service'; +import Component from '@ember/component'; +import { computed } from '@ember/object'; +import { run } from '@ember/runloop'; import { task } from 'ember-concurrency'; import { logger } from 'nomad-ui/utils/classes/log'; import WindowResizable from 'nomad-ui/mixins/window-resizable'; -const { Component, computed, inject, run } = Ember; - export default Component.extend(WindowResizable, { - token: inject.service(), + token: service(), classNames: ['boxed-section', 'task-log'], diff --git a/ui/app/controllers/allocations/allocation.js b/ui/app/controllers/allocations/allocation.js index 1ee88420b..75ceaaec3 100644 --- a/ui/app/controllers/allocations/allocation.js +++ b/ui/app/controllers/allocations/allocation.js @@ -1,5 +1,3 @@ -import Ember from 'ember'; - -const { Controller } = Ember; +import Controller from '@ember/controller'; export default Controller.extend({}); diff --git a/ui/app/controllers/allocations/allocation/index.js b/ui/app/controllers/allocations/allocation/index.js index 5a764f2a6..810d0f728 100644 --- a/ui/app/controllers/allocations/allocation/index.js +++ b/ui/app/controllers/allocations/allocation/index.js @@ -1,8 +1,7 @@ -import Ember from 'ember'; +import { alias } from '@ember/object/computed'; +import Controller from '@ember/controller'; import Sortable from 'nomad-ui/mixins/sortable'; -const { Controller, computed } = Ember; - export default Controller.extend(Sortable, { queryParams: { sortProperty: 'sort', @@ -12,6 +11,6 @@ export default Controller.extend(Sortable, { sortProperty: 'name', sortDescending: false, - listToSort: computed.alias('model.states'), - sortedStates: computed.alias('listSorted'), + listToSort: alias('model.states'), + sortedStates: alias('listSorted'), }); diff --git a/ui/app/controllers/allocations/allocation/task/index.js b/ui/app/controllers/allocations/allocation/task/index.js index 7374af8fd..790e190ec 100644 --- a/ui/app/controllers/allocations/allocation/task/index.js +++ b/ui/app/controllers/allocations/allocation/task/index.js @@ -1,9 +1,9 @@ -import Ember from 'ember'; - -const { Controller, computed } = Ember; +import { alias } from '@ember/object/computed'; +import Controller from '@ember/controller'; +import { computed } from '@ember/object'; export default Controller.extend({ - network: computed.alias('model.resources.networks.firstObject'), + network: alias('model.resources.networks.firstObject'), ports: computed('network.reservedPorts.[]', 'network.dynamicPorts.[]', function() { return (this.get('network.reservedPorts') || []) .map(port => ({ diff --git a/ui/app/controllers/application.js b/ui/app/controllers/application.js index faa744e96..fc3c5e58e 100644 --- a/ui/app/controllers/application.js +++ b/ui/app/controllers/application.js @@ -1,10 +1,12 @@ +import { inject as service } from '@ember/service'; +import Controller from '@ember/controller'; +import { run } from '@ember/runloop'; +import { observer, computed } from '@ember/object'; import Ember from 'ember'; import codesForError from '../utils/codes-for-error'; -const { Controller, computed, inject, run, observer } = Ember; - export default Controller.extend({ - config: inject.service(), + config: service(), error: null, diff --git a/ui/app/controllers/clients.js b/ui/app/controllers/clients.js index 41e5c9e2f..f4d0631dc 100644 --- a/ui/app/controllers/clients.js +++ b/ui/app/controllers/clients.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { Controller } = Ember; +import Controller from '@ember/controller'; export default Controller.extend({ isForbidden: false, diff --git a/ui/app/controllers/clients/client.js b/ui/app/controllers/clients/client.js index ed463e813..008169f5e 100644 --- a/ui/app/controllers/clients/client.js +++ b/ui/app/controllers/clients/client.js @@ -1,9 +1,9 @@ -import Ember from 'ember'; +import { alias } from '@ember/object/computed'; +import Controller from '@ember/controller'; +import { computed } from '@ember/object'; import Sortable from 'nomad-ui/mixins/sortable'; import Searchable from 'nomad-ui/mixins/searchable'; -const { Controller, computed } = Ember; - export default Controller.extend(Sortable, Searchable, { queryParams: { currentPage: 'page', @@ -20,9 +20,9 @@ export default Controller.extend(Sortable, Searchable, { searchProps: computed(() => ['shortId', 'name']), - listToSort: computed.alias('model.allocations'), - listToSearch: computed.alias('listSorted'), - sortedAllocations: computed.alias('listSearched'), + listToSort: alias('model.allocations'), + listToSearch: alias('listSorted'), + sortedAllocations: alias('listSearched'), actions: { gotoAllocation(allocation) { diff --git a/ui/app/controllers/clients/index.js b/ui/app/controllers/clients/index.js index eedb9ebe8..ac19f9d9d 100644 --- a/ui/app/controllers/clients/index.js +++ b/ui/app/controllers/clients/index.js @@ -1,14 +1,14 @@ -import Ember from 'ember'; +import { alias } from '@ember/object/computed'; +import Controller, { inject as controller } from '@ember/controller'; +import { computed } from '@ember/object'; import Sortable from 'nomad-ui/mixins/sortable'; import Searchable from 'nomad-ui/mixins/searchable'; -const { Controller, computed, inject } = Ember; - export default Controller.extend(Sortable, Searchable, { - clientsController: inject.controller('clients'), + clientsController: controller('clients'), - nodes: computed.alias('model.nodes'), - agents: computed.alias('model.agents'), + nodes: alias('model.nodes'), + agents: alias('model.agents'), queryParams: { currentPage: 'page', @@ -25,11 +25,11 @@ export default Controller.extend(Sortable, Searchable, { searchProps: computed(() => ['id', 'name', 'datacenter']), - listToSort: computed.alias('nodes'), - listToSearch: computed.alias('listSorted'), - sortedNodes: computed.alias('listSearched'), + listToSort: alias('nodes'), + listToSearch: alias('listSorted'), + sortedNodes: alias('listSearched'), - isForbidden: computed.alias('clientsController.isForbidden'), + isForbidden: alias('clientsController.isForbidden'), actions: { gotoNode(node) { diff --git a/ui/app/controllers/freestyle.js b/ui/app/controllers/freestyle.js index 71e5bde38..552795608 100644 --- a/ui/app/controllers/freestyle.js +++ b/ui/app/controllers/freestyle.js @@ -1,10 +1,9 @@ -import Ember from 'ember'; +import { inject as service } from '@ember/service'; +import { computed } from '@ember/object'; import FreestyleController from 'ember-freestyle/controllers/freestyle'; -const { inject, computed } = Ember; - export default FreestyleController.extend({ - emberFreestyle: inject.service(), + emberFreestyle: service(), timerTicks: 0, diff --git a/ui/app/controllers/jobs.js b/ui/app/controllers/jobs.js index 88f3d60e1..e7a69a7d8 100644 --- a/ui/app/controllers/jobs.js +++ b/ui/app/controllers/jobs.js @@ -1,9 +1,10 @@ -import Ember from 'ember'; - -const { Controller, inject, observer, run } = Ember; +import { inject as service } from '@ember/service'; +import Controller from '@ember/controller'; +import { observer } from '@ember/object'; +import { run } from '@ember/runloop'; export default Controller.extend({ - system: inject.service(), + system: service(), queryParams: { jobNamespace: 'namespace', diff --git a/ui/app/controllers/jobs/index.js b/ui/app/controllers/jobs/index.js index 079d30dc3..d0d06e9ee 100644 --- a/ui/app/controllers/jobs/index.js +++ b/ui/app/controllers/jobs/index.js @@ -1,18 +1,19 @@ -import Ember from 'ember'; +import { inject as service } from '@ember/service'; +import { alias, filterBy } from '@ember/object/computed'; +import Controller, { inject as controller } from '@ember/controller'; +import { computed } from '@ember/object'; import Sortable from 'nomad-ui/mixins/sortable'; import Searchable from 'nomad-ui/mixins/searchable'; -const { Controller, computed, inject } = Ember; - export default Controller.extend(Sortable, Searchable, { - system: inject.service(), - jobsController: inject.controller('jobs'), + system: service(), + jobsController: controller('jobs'), - isForbidden: computed.alias('jobsController.isForbidden'), + isForbidden: alias('jobsController.isForbidden'), - pendingJobs: computed.filterBy('model', 'status', 'pending'), - runningJobs: computed.filterBy('model', 'status', 'running'), - deadJobs: computed.filterBy('model', 'status', 'dead'), + pendingJobs: filterBy('model', 'status', 'pending'), + runningJobs: filterBy('model', 'status', 'running'), + deadJobs: filterBy('model', 'status', 'dead'), queryParams: { currentPage: 'page', @@ -42,9 +43,9 @@ export default Controller.extend(Sortable, Searchable, { } ), - listToSort: computed.alias('filteredJobs'), - listToSearch: computed.alias('listSorted'), - sortedJobs: computed.alias('listSearched'), + listToSort: alias('filteredJobs'), + listToSearch: alias('listSorted'), + sortedJobs: alias('listSearched'), isShowingDeploymentDetails: false, diff --git a/ui/app/controllers/jobs/job.js b/ui/app/controllers/jobs/job.js index fab3c3204..5b8865a11 100644 --- a/ui/app/controllers/jobs/job.js +++ b/ui/app/controllers/jobs/job.js @@ -1,6 +1,5 @@ -import Ember from 'ember'; - -const { Controller, computed } = Ember; +import Controller from '@ember/controller'; +import { computed } from '@ember/object'; export default Controller.extend({ breadcrumbs: computed('model.{name,id}', function() { diff --git a/ui/app/controllers/jobs/job/definition.js b/ui/app/controllers/jobs/job/definition.js index 95144a831..b105b72b0 100644 --- a/ui/app/controllers/jobs/job/definition.js +++ b/ui/app/controllers/jobs/job/definition.js @@ -1,12 +1,11 @@ -import Ember from 'ember'; +import { alias } from '@ember/object/computed'; +import Controller, { inject as controller } from '@ember/controller'; import WithNamespaceResetting from 'nomad-ui/mixins/with-namespace-resetting'; -const { Controller, computed, inject } = Ember; - export default Controller.extend(WithNamespaceResetting, { - jobController: inject.controller('jobs.job'), + jobController: controller('jobs.job'), - job: computed.alias('model.job'), + job: alias('model.job'), - breadcrumbs: computed.alias('jobController.breadcrumbs'), + breadcrumbs: alias('jobController.breadcrumbs'), }); diff --git a/ui/app/controllers/jobs/job/deployments.js b/ui/app/controllers/jobs/job/deployments.js index a8c6b1761..0540c98b1 100644 --- a/ui/app/controllers/jobs/job/deployments.js +++ b/ui/app/controllers/jobs/job/deployments.js @@ -1,13 +1,12 @@ -import Ember from 'ember'; +import { alias } from '@ember/object/computed'; +import Controller, { inject as controller } from '@ember/controller'; import WithNamespaceResetting from 'nomad-ui/mixins/with-namespace-resetting'; -const { Controller, computed, inject } = Ember; - export default Controller.extend(WithNamespaceResetting, { - jobController: inject.controller('jobs.job'), + jobController: controller('jobs.job'), - job: computed.alias('model'), - deployments: computed.alias('model.deployments'), + job: alias('model'), + deployments: alias('model.deployments'), - breadcrumbs: computed.alias('jobController.breadcrumbs'), + breadcrumbs: alias('jobController.breadcrumbs'), }); diff --git a/ui/app/controllers/jobs/job/index.js b/ui/app/controllers/jobs/job/index.js index 2738cccf1..97b97efb5 100644 --- a/ui/app/controllers/jobs/job/index.js +++ b/ui/app/controllers/jobs/job/index.js @@ -1,12 +1,13 @@ -import Ember from 'ember'; +import { inject as service } from '@ember/service'; +import { alias } from '@ember/object/computed'; +import Controller, { inject as controller } from '@ember/controller'; +import { computed } from '@ember/object'; import Sortable from 'nomad-ui/mixins/sortable'; import WithNamespaceResetting from 'nomad-ui/mixins/with-namespace-resetting'; -const { Controller, computed, inject } = Ember; - export default Controller.extend(Sortable, WithNamespaceResetting, { - system: inject.service(), - jobController: inject.controller('jobs.job'), + system: service(), + jobController: controller('jobs.job'), queryParams: { currentPage: 'page', @@ -20,15 +21,15 @@ export default Controller.extend(Sortable, WithNamespaceResetting, { sortProperty: 'name', sortDescending: false, - breadcrumbs: computed.alias('jobController.breadcrumbs'), - job: computed.alias('model'), + breadcrumbs: alias('jobController.breadcrumbs'), + job: alias('model'), taskGroups: computed('model.taskGroups.[]', function() { return this.get('model.taskGroups') || []; }), - listToSort: computed.alias('taskGroups'), - sortedTaskGroups: computed.alias('listSorted'), + listToSort: alias('taskGroups'), + sortedTaskGroups: alias('listSorted'), sortedEvaluations: computed('model.evaluations.@each.modifyIndex', function() { return (this.get('model.evaluations') || []).sortBy('modifyIndex').reverse(); diff --git a/ui/app/controllers/jobs/job/loading.js b/ui/app/controllers/jobs/job/loading.js index bb159e836..2251e2d75 100644 --- a/ui/app/controllers/jobs/job/loading.js +++ b/ui/app/controllers/jobs/job/loading.js @@ -1,8 +1,7 @@ -import Ember from 'ember'; - -const { Controller, computed, inject } = Ember; +import { alias } from '@ember/object/computed'; +import Controller, { inject as controller } from '@ember/controller'; export default Controller.extend({ - jobController: inject.controller('jobs.job'), - breadcrumbs: computed.alias('jobController.breadcrumbs'), + jobController: controller('jobs.job'), + breadcrumbs: alias('jobController.breadcrumbs'), }); diff --git a/ui/app/controllers/jobs/job/task-group.js b/ui/app/controllers/jobs/job/task-group.js index 4fc628201..2e2ab25e7 100644 --- a/ui/app/controllers/jobs/job/task-group.js +++ b/ui/app/controllers/jobs/job/task-group.js @@ -1,12 +1,12 @@ -import Ember from 'ember'; +import { alias } from '@ember/object/computed'; +import Controller, { inject as controller } from '@ember/controller'; +import { computed } from '@ember/object'; import Sortable from 'nomad-ui/mixins/sortable'; import Searchable from 'nomad-ui/mixins/searchable'; import WithNamespaceResetting from 'nomad-ui/mixins/with-namespace-resetting'; -const { Controller, computed, inject } = Ember; - export default Controller.extend(Sortable, Searchable, WithNamespaceResetting, { - jobController: inject.controller('jobs.job'), + jobController: controller('jobs.job'), queryParams: { currentPage: 'page', @@ -27,9 +27,9 @@ export default Controller.extend(Sortable, Searchable, WithNamespaceResetting, { return this.get('model.allocations') || []; }), - listToSort: computed.alias('allocations'), - listToSearch: computed.alias('listSorted'), - sortedAllocations: computed.alias('listSearched'), + listToSort: alias('allocations'), + listToSearch: alias('listSorted'), + sortedAllocations: alias('listSearched'), breadcrumbs: computed('jobController.breadcrumbs.[]', 'model.{name}', function() { return this.get('jobController.breadcrumbs').concat([ diff --git a/ui/app/controllers/jobs/job/versions.js b/ui/app/controllers/jobs/job/versions.js index 3b2420213..eb669a22b 100644 --- a/ui/app/controllers/jobs/job/versions.js +++ b/ui/app/controllers/jobs/job/versions.js @@ -1,13 +1,12 @@ -import Ember from 'ember'; +import { alias } from '@ember/object/computed'; +import Controller, { inject as controller } from '@ember/controller'; import WithNamespaceResetting from 'nomad-ui/mixins/with-namespace-resetting'; -const { Controller, computed, inject } = Ember; - export default Controller.extend(WithNamespaceResetting, { - jobController: inject.controller('jobs.job'), + jobController: controller('jobs.job'), - job: computed.alias('model'), - versions: computed.alias('model.versions'), + job: alias('model'), + versions: alias('model.versions'), - breadcrumbs: computed.alias('jobController.breadcrumbs'), + breadcrumbs: alias('jobController.breadcrumbs'), }); diff --git a/ui/app/controllers/servers.js b/ui/app/controllers/servers.js index a8d0e1f8a..5e6f1bea4 100644 --- a/ui/app/controllers/servers.js +++ b/ui/app/controllers/servers.js @@ -1,11 +1,10 @@ -import Ember from 'ember'; +import { alias } from '@ember/object/computed'; +import Controller from '@ember/controller'; import Sortable from 'nomad-ui/mixins/sortable'; -const { Controller, computed } = Ember; - export default Controller.extend(Sortable, { - nodes: computed.alias('model.nodes'), - agents: computed.alias('model.agents'), + nodes: alias('model.nodes'), + agents: alias('model.agents'), queryParams: { currentPage: 'page', @@ -21,6 +20,6 @@ export default Controller.extend(Sortable, { isForbidden: false, - listToSort: computed.alias('agents'), - sortedAgents: computed.alias('listSorted'), + listToSort: alias('agents'), + sortedAgents: alias('listSorted'), }); diff --git a/ui/app/controllers/servers/index.js b/ui/app/controllers/servers/index.js index adf0eee4d..ee49e8f72 100644 --- a/ui/app/controllers/servers/index.js +++ b/ui/app/controllers/servers/index.js @@ -1,8 +1,7 @@ -import Ember from 'ember'; - -const { Controller, computed, inject } = Ember; +import { alias } from '@ember/object/computed'; +import Controller, { inject as controller } from '@ember/controller'; export default Controller.extend({ - serversController: inject.controller('servers'), - isForbidden: computed.alias('serversController.isForbidden'), + serversController: controller('servers'), + isForbidden: alias('serversController.isForbidden'), }); diff --git a/ui/app/controllers/servers/server.js b/ui/app/controllers/servers/server.js index 94f5f0bdd..dd455b3ad 100644 --- a/ui/app/controllers/servers/server.js +++ b/ui/app/controllers/servers/server.js @@ -1,6 +1,5 @@ -import Ember from 'ember'; - -const { Controller, computed } = Ember; +import Controller from '@ember/controller'; +import { computed } from '@ember/object'; export default Controller.extend({ activeTab: 'tags', diff --git a/ui/app/controllers/settings/tokens.js b/ui/app/controllers/settings/tokens.js index 2aad23469..be1db757d 100644 --- a/ui/app/controllers/settings/tokens.js +++ b/ui/app/controllers/settings/tokens.js @@ -1,12 +1,13 @@ -import Ember from 'ember'; - -const { Controller, inject, computed, getOwner } = Ember; +import { inject as service } from '@ember/service'; +import { reads } from '@ember/object/computed'; +import Controller from '@ember/controller'; +import { getOwner } from '@ember/application'; export default Controller.extend({ - token: inject.service(), - store: inject.service(), + token: service(), + store: service(), - secret: computed.reads('token.secret'), + secret: reads('token.secret'), tokenIsValid: false, tokenIsInvalid: false, diff --git a/ui/app/helpers/css-class.js b/ui/app/helpers/css-class.js index a23d3b90d..d7f30127c 100644 --- a/ui/app/helpers/css-class.js +++ b/ui/app/helpers/css-class.js @@ -1,4 +1,4 @@ -import Ember from 'ember'; +import { helper } from '@ember/component/helper'; /** * CSS Class @@ -12,4 +12,4 @@ export function cssClass([updateType]) { return updateType.replace(/\//g, '-').dasherize(); } -export default Ember.Helper.helper(cssClass); +export default helper(cssClass); diff --git a/ui/app/helpers/format-bytes.js b/ui/app/helpers/format-bytes.js index dc3ab3e15..b2c69ed06 100644 --- a/ui/app/helpers/format-bytes.js +++ b/ui/app/helpers/format-bytes.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { Helper } = Ember; +import Helper from '@ember/component/helper'; const UNITS = ['Bytes', 'KiB', 'MiB']; diff --git a/ui/app/helpers/format-percentage.js b/ui/app/helpers/format-percentage.js index ff4358bc7..cfd409c13 100644 --- a/ui/app/helpers/format-percentage.js +++ b/ui/app/helpers/format-percentage.js @@ -1,4 +1,4 @@ -import Ember from 'ember'; +import { helper } from '@ember/component/helper'; /** * Percentage Calculator @@ -35,4 +35,4 @@ function safeNumber(value) { return isNaN(value) ? 0 : +value; } -export default Ember.Helper.helper(formatPercentage); +export default helper(formatPercentage); diff --git a/ui/app/helpers/is-object.js b/ui/app/helpers/is-object.js index 0b7dae86d..97dd42e65 100644 --- a/ui/app/helpers/is-object.js +++ b/ui/app/helpers/is-object.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { Helper } = Ember; +import Helper from '@ember/component/helper'; export function isObject([value]) { const isObject = !Array.isArray(value) && value !== null && typeof value === 'object'; diff --git a/ui/app/helpers/lazy-click.js b/ui/app/helpers/lazy-click.js index f9d12dcd2..de96d1c0e 100644 --- a/ui/app/helpers/lazy-click.js +++ b/ui/app/helpers/lazy-click.js @@ -1,6 +1,5 @@ -import Ember from 'ember'; - -const { Helper, $ } = Ember; +import Helper from '@ember/component/helper'; +import $ from 'jquery'; /** * Lazy Click Event diff --git a/ui/app/helpers/pluralize.js b/ui/app/helpers/pluralize.js index 161b366a4..fcab84cbe 100644 --- a/ui/app/helpers/pluralize.js +++ b/ui/app/helpers/pluralize.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { Helper } = Ember; +import Helper from '@ember/component/helper'; export function pluralize([term, count]) { return count === 1 ? term : term.pluralize(); diff --git a/ui/app/helpers/x-icon.js b/ui/app/helpers/x-icon.js index d3c670e54..f53a50543 100644 --- a/ui/app/helpers/x-icon.js +++ b/ui/app/helpers/x-icon.js @@ -1,4 +1,4 @@ -import Ember from 'ember'; +import { helper } from '@ember/component/helper'; import { inlineSvg } from 'ember-inline-svg/helpers/inline-svg'; // Generated at compile-time by ember-inline-svg @@ -18,4 +18,4 @@ export function xIcon(params, options) { return inlineSvg(SVGs, name, { class: classes }); } -export default Ember.Helper.helper(xIcon); +export default helper(xIcon); diff --git a/ui/app/mixins/searchable.js b/ui/app/mixins/searchable.js index 99a929eed..26557f75a 100644 --- a/ui/app/mixins/searchable.js +++ b/ui/app/mixins/searchable.js @@ -1,6 +1,5 @@ -import Ember from 'ember'; - -const { Mixin, computed, get } = Ember; +import Mixin from '@ember/object/mixin'; +import { get, computed } from '@ember/object'; /** Searchable mixin diff --git a/ui/app/mixins/sortable.js b/ui/app/mixins/sortable.js index 269075cd8..e6a78aaf9 100644 --- a/ui/app/mixins/sortable.js +++ b/ui/app/mixins/sortable.js @@ -1,6 +1,5 @@ -import Ember from 'ember'; - -const { Mixin, computed } = Ember; +import Mixin from '@ember/object/mixin'; +import { computed } from '@ember/object'; /** Sortable mixin diff --git a/ui/app/mixins/window-resizable.js b/ui/app/mixins/window-resizable.js index 3f3c5b7aa..6a7055bdf 100644 --- a/ui/app/mixins/window-resizable.js +++ b/ui/app/mixins/window-resizable.js @@ -1,8 +1,8 @@ -import Ember from 'ember'; +import Mixin from '@ember/object/mixin'; +import { run } from '@ember/runloop'; +import $ from 'jquery'; -const { run, $ } = Ember; - -export default Ember.Mixin.create({ +export default Mixin.create({ setupWindowResize: function() { run.scheduleOnce('afterRender', this, () => { this.set('_windowResizeHandler', this.get('windowResizeHandler').bind(this)); diff --git a/ui/app/mixins/with-forbidden-state.js b/ui/app/mixins/with-forbidden-state.js index 4b1397e09..85f27676a 100644 --- a/ui/app/mixins/with-forbidden-state.js +++ b/ui/app/mixins/with-forbidden-state.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { Mixin } = Ember; +import Mixin from '@ember/object/mixin'; export default Mixin.create({ setupController(controller) { diff --git a/ui/app/mixins/with-model-error-handling.js b/ui/app/mixins/with-model-error-handling.js index 585c61595..484a80148 100644 --- a/ui/app/mixins/with-model-error-handling.js +++ b/ui/app/mixins/with-model-error-handling.js @@ -1,8 +1,6 @@ -import Ember from 'ember'; +import Mixin from '@ember/object/mixin'; import notifyError from 'nomad-ui/utils/notify-error'; -const { Mixin } = Ember; - export default Mixin.create({ model() { return this._super(...arguments).catch(notifyError(this)); diff --git a/ui/app/mixins/with-namespace-resetting.js b/ui/app/mixins/with-namespace-resetting.js index c40407568..ab57f3e3e 100644 --- a/ui/app/mixins/with-namespace-resetting.js +++ b/ui/app/mixins/with-namespace-resetting.js @@ -1,10 +1,10 @@ -import Ember from 'ember'; - -const { Mixin, inject } = Ember; +import { inject as controller } from '@ember/controller'; +import { inject as service } from '@ember/service'; +import Mixin from '@ember/object/mixin'; export default Mixin.create({ - system: inject.service(), - jobsController: inject.controller('jobs'), + system: service(), + jobsController: controller('jobs'), actions: { gotoJobs(namespace) { diff --git a/ui/app/models/agent.js b/ui/app/models/agent.js index aea6c7ee5..63bd7d2b0 100644 --- a/ui/app/models/agent.js +++ b/ui/app/models/agent.js @@ -1,11 +1,10 @@ -import Ember from 'ember'; +import { inject as service } from '@ember/service'; +import { computed } from '@ember/object'; import Model from 'ember-data/model'; import attr from 'ember-data/attr'; -const { computed, inject } = Ember; - export default Model.extend({ - system: inject.service(), + system: service(), name: attr('string'), address: attr('string'), diff --git a/ui/app/models/allocation.js b/ui/app/models/allocation.js index 6cf164a41..617c1d3f7 100644 --- a/ui/app/models/allocation.js +++ b/ui/app/models/allocation.js @@ -1,4 +1,7 @@ -import Ember from 'ember'; +import { inject as service } from '@ember/service'; +import { readOnly } from '@ember/object/computed'; +import { computed } from '@ember/object'; +import RSVP from 'rsvp'; import Model from 'ember-data/model'; import attr from 'ember-data/attr'; import { belongsTo } from 'ember-data/relationships'; @@ -7,8 +10,6 @@ import PromiseObject from '../utils/classes/promise-object'; import timeout from '../utils/timeout'; import shortUUIDProperty from '../utils/properties/short-uuid'; -const { computed, RSVP, inject } = Ember; - const STATUS_ORDER = { pending: 1, running: 2, @@ -18,7 +19,7 @@ const STATUS_ORDER = { }; export default Model.extend({ - token: inject.service(), + token: service(), shortId: shortUUIDProperty('id'), job: belongsTo('job'), @@ -56,7 +57,7 @@ export default Model.extend({ return taskGroups && taskGroups.findBy('name', this.get('taskGroupName')); }), - memoryUsed: computed.readOnly('stats.ResourceUsage.MemoryStats.RSS'), + memoryUsed: readOnly('stats.ResourceUsage.MemoryStats.RSS'), cpuUsed: computed('stats.ResourceUsage.CpuStats.TotalTicks', function() { return Math.floor(this.get('stats.ResourceUsage.CpuStats.TotalTicks') || 0); }), diff --git a/ui/app/models/deployment.js b/ui/app/models/deployment.js index 8f4440ba2..02dfb4c81 100644 --- a/ui/app/models/deployment.js +++ b/ui/app/models/deployment.js @@ -1,4 +1,5 @@ -import Ember from 'ember'; +import { alias } from '@ember/object/computed'; +import { computed } from '@ember/object'; import Model from 'ember-data/model'; import attr from 'ember-data/attr'; import { belongsTo, hasMany } from 'ember-data/relationships'; @@ -6,8 +7,6 @@ import { fragmentArray } from 'ember-data-model-fragments/attributes'; import shortUUIDProperty from '../utils/properties/short-uuid'; import sumAggregation from '../utils/properties/sum-aggregation'; -const { computed } = Ember; - export default Model.extend({ shortId: shortUUIDProperty('id'), @@ -35,7 +34,7 @@ export default Model.extend({ }), // Dependent keys can only go one level past an @each so an alias is needed - versionSubmitTime: computed.alias('version.submitTime'), + versionSubmitTime: alias('version.submitTime'), placedCanaries: sumAggregation('taskGroupSummaries', 'placedCanaries'), desiredCanaries: sumAggregation('taskGroupSummaries', 'desiredCanaries'), diff --git a/ui/app/models/evaluation.js b/ui/app/models/evaluation.js index 8afdf15ae..5fcb3550a 100644 --- a/ui/app/models/evaluation.js +++ b/ui/app/models/evaluation.js @@ -1,12 +1,10 @@ -import Ember from 'ember'; +import { bool } from '@ember/object/computed'; import Model from 'ember-data/model'; import attr from 'ember-data/attr'; import { belongsTo } from 'ember-data/relationships'; import { fragmentArray } from 'ember-data-model-fragments/attributes'; import shortUUIDProperty from '../utils/properties/short-uuid'; -const { computed } = Ember; - export default Model.extend({ shortId: shortUUIDProperty('id'), priority: attr('number'), @@ -16,7 +14,7 @@ export default Model.extend({ statusDescription: attr('string'), failedTGAllocs: fragmentArray('placement-failure', { defaultValue: () => [] }), - hasPlacementFailures: computed.bool('failedTGAllocs.length'), + hasPlacementFailures: bool('failedTGAllocs.length'), // TEMPORARY: https://github.com/emberjs/data/issues/5209 originalJobId: attr('string'), diff --git a/ui/app/models/job.js b/ui/app/models/job.js index 4f33983ac..511f89856 100644 --- a/ui/app/models/job.js +++ b/ui/app/models/job.js @@ -1,12 +1,11 @@ -import Ember from 'ember'; +import { collect, sum, bool, equal } from '@ember/object/computed'; +import { computed } from '@ember/object'; import Model from 'ember-data/model'; import attr from 'ember-data/attr'; import { belongsTo, hasMany } from 'ember-data/relationships'; import { fragmentArray } from 'ember-data-model-fragments/attributes'; import sumAggregation from '../utils/properties/sum-aggregation'; -const { computed } = Ember; - export default Model.extend({ region: attr('string'), name: attr('string'), @@ -35,7 +34,7 @@ export default Model.extend({ failedAllocs: sumAggregation('taskGroupSummaries', 'failedAllocs'), lostAllocs: sumAggregation('taskGroupSummaries', 'lostAllocs'), - allocsList: computed.collect( + allocsList: collect( 'queuedAllocs', 'startingAllocs', 'runningAllocs', @@ -44,7 +43,7 @@ export default Model.extend({ 'lostAllocs' ), - totalAllocs: computed.sum('allocsList'), + totalAllocs: sum('allocsList'), pendingChildren: attr('number'), runningChildren: attr('number'), @@ -56,7 +55,7 @@ export default Model.extend({ evaluations: hasMany('evaluations'), namespace: belongsTo('namespace'), - hasPlacementFailures: computed.bool('latestFailureEvaluation'), + hasPlacementFailures: bool('latestFailureEvaluation'), latestEvaluation: computed('evaluations.@each.modifyIndex', 'evaluations.isPending', function() { const evaluations = this.get('evaluations'); @@ -82,7 +81,7 @@ export default Model.extend({ } ), - supportsDeployments: computed.equal('type', 'service'), + supportsDeployments: equal('type', 'service'), runningDeployment: computed('deployments.@each.status', function() { return this.get('deployments').findBy('status', 'running'); diff --git a/ui/app/models/namespace.js b/ui/app/models/namespace.js index 7b05135e8..b5b5f5750 100644 --- a/ui/app/models/namespace.js +++ b/ui/app/models/namespace.js @@ -1,11 +1,9 @@ -import Ember from 'ember'; +import { readOnly } from '@ember/object/computed'; import Model from 'ember-data/model'; import attr from 'ember-data/attr'; -const { computed } = Ember; - export default Model.extend({ - name: computed.readOnly('id'), + name: readOnly('id'), hash: attr('string'), description: attr('string'), }); diff --git a/ui/app/models/node-attributes.js b/ui/app/models/node-attributes.js index 6bfaba7ca..c893d8500 100644 --- a/ui/app/models/node-attributes.js +++ b/ui/app/models/node-attributes.js @@ -1,9 +1,8 @@ -import Ember from 'ember'; +import { get, computed } from '@ember/object'; import attr from 'ember-data/attr'; import Fragment from 'ember-data-model-fragments/fragment'; import flat from 'npm:flat'; -const { computed, get } = Ember; const { unflatten } = flat; export default Fragment.extend({ @@ -12,10 +11,12 @@ export default Fragment.extend({ attributesStructured: computed('attributes', function() { // `unflatten` doesn't sort keys before unflattening, so manual preprocessing is necessary. const original = this.get('attributes'); - const attrs = Object.keys(original).sort().reduce((obj, key) => { - obj[key] = original[key]; - return obj; - }, {}); + const attrs = Object.keys(original) + .sort() + .reduce((obj, key) => { + obj[key] = original[key]; + return obj; + }, {}); return unflatten(attrs, { overwrite: true }); }), diff --git a/ui/app/models/node.js b/ui/app/models/node.js index 6966acfb9..56e489e1d 100644 --- a/ui/app/models/node.js +++ b/ui/app/models/node.js @@ -1,4 +1,4 @@ -import Ember from 'ember'; +import { computed } from '@ember/object'; import Model from 'ember-data/model'; import attr from 'ember-data/attr'; import { hasMany } from 'ember-data/relationships'; @@ -6,8 +6,6 @@ import { fragment } from 'ember-data-model-fragments/attributes'; import shortUUIDProperty from '../utils/properties/short-uuid'; import ipParts from '../utils/ip-parts'; -const { computed } = Ember; - export default Model.extend({ // Available from list response name: attr('string'), diff --git a/ui/app/models/task-event.js b/ui/app/models/task-event.js index 1a26daadc..3d6f464f3 100644 --- a/ui/app/models/task-event.js +++ b/ui/app/models/task-event.js @@ -1,10 +1,9 @@ -import Ember from 'ember'; +import { computed } from '@ember/object'; import Fragment from 'ember-data-model-fragments/fragment'; import attr from 'ember-data/attr'; import { fragmentOwner } from 'ember-data-model-fragments/attributes'; import moment from 'moment'; -const { computed } = Ember; const displayProps = [ 'message', 'validationError', diff --git a/ui/app/models/task-group-deployment-summary.js b/ui/app/models/task-group-deployment-summary.js index 9a6b0eab3..9d5c04035 100644 --- a/ui/app/models/task-group-deployment-summary.js +++ b/ui/app/models/task-group-deployment-summary.js @@ -1,10 +1,8 @@ -import Ember from 'ember'; +import { gt } from '@ember/object/computed'; import Fragment from 'ember-data-model-fragments/fragment'; import attr from 'ember-data/attr'; import { fragmentOwner } from 'ember-data-model-fragments/attributes'; -const { computed } = Ember; - export default Fragment.extend({ deployment: fragmentOwner(), @@ -12,7 +10,7 @@ export default Fragment.extend({ autoRevert: attr('boolean'), promoted: attr('boolean'), - requiresPromotion: computed.gt('desiredCanaries', 0), + requiresPromotion: gt('desiredCanaries', 0), placedCanaries: attr('number'), desiredCanaries: attr('number'), diff --git a/ui/app/models/task-group-summary.js b/ui/app/models/task-group-summary.js index 5d937f73b..9e713b8ab 100644 --- a/ui/app/models/task-group-summary.js +++ b/ui/app/models/task-group-summary.js @@ -1,10 +1,8 @@ -import Ember from 'ember'; +import { collect, sum } from '@ember/object/computed'; import Fragment from 'ember-data-model-fragments/fragment'; import attr from 'ember-data/attr'; import { fragmentOwner } from 'ember-data-model-fragments/attributes'; -const { computed } = Ember; - export default Fragment.extend({ job: fragmentOwner(), name: attr('string'), @@ -16,7 +14,7 @@ export default Fragment.extend({ failedAllocs: attr('number'), lostAllocs: attr('number'), - allocsList: computed.collect( + allocsList: collect( 'queuedAllocs', 'startingAllocs', 'runningAllocs', @@ -25,5 +23,5 @@ export default Fragment.extend({ 'lostAllocs' ), - totalAllocs: computed.sum('allocsList'), + totalAllocs: sum('allocsList'), }); diff --git a/ui/app/models/task-group.js b/ui/app/models/task-group.js index b3998a4cd..e5ea67d0e 100644 --- a/ui/app/models/task-group.js +++ b/ui/app/models/task-group.js @@ -1,11 +1,9 @@ -import Ember from 'ember'; +import { computed } from '@ember/object'; import Fragment from 'ember-data-model-fragments/fragment'; import attr from 'ember-data/attr'; import { fragmentOwner, fragmentArray } from 'ember-data-model-fragments/attributes'; import sumAggregation from '../utils/properties/sum-aggregation'; -const { computed } = Ember; - export default Fragment.extend({ job: fragmentOwner(), diff --git a/ui/app/models/task-state.js b/ui/app/models/task-state.js index a5b3bff22..217e87459 100644 --- a/ui/app/models/task-state.js +++ b/ui/app/models/task-state.js @@ -1,10 +1,9 @@ -import Ember from 'ember'; +import { none } from '@ember/object/computed'; +import { computed } from '@ember/object'; import Fragment from 'ember-data-model-fragments/fragment'; import attr from 'ember-data/attr'; import { fragment, fragmentOwner, fragmentArray } from 'ember-data-model-fragments/attributes'; -const { computed } = Ember; - export default Fragment.extend({ name: attr('string'), state: attr('string'), @@ -12,7 +11,7 @@ export default Fragment.extend({ finishedAt: attr('date'), failed: attr('boolean'), - isActive: computed.none('finishedAt'), + isActive: none('finishedAt'), allocation: fragmentOwner(), task: computed('allocation.taskGroup.tasks.[]', function() { diff --git a/ui/app/models/token.js b/ui/app/models/token.js index 07243dd8a..37db199ae 100644 --- a/ui/app/models/token.js +++ b/ui/app/models/token.js @@ -1,10 +1,8 @@ -import Ember from 'ember'; +import { alias } from '@ember/object/computed'; import Model from 'ember-data/model'; import attr from 'ember-data/attr'; import { hasMany } from 'ember-data/relationships'; -const { computed } = Ember; - export default Model.extend({ secret: attr('string'), name: attr('string'), @@ -14,5 +12,5 @@ export default Model.extend({ policies: hasMany('policy'), policyNames: attr(), - accessor: computed.alias('id'), + accessor: alias('id'), }); diff --git a/ui/app/router.js b/ui/app/router.js index bddf8813d..494a2173d 100644 --- a/ui/app/router.js +++ b/ui/app/router.js @@ -1,7 +1,7 @@ -import Ember from 'ember'; +import EmberRouter from '@ember/routing/router'; import config from './config/environment'; -const Router = Ember.Router.extend({ +const Router = EmberRouter.extend({ location: config.locationType, rootURL: config.rootURL, }); diff --git a/ui/app/routes/allocations/allocation.js b/ui/app/routes/allocations/allocation.js index 60eff663b..17aa8b10c 100644 --- a/ui/app/routes/allocations/allocation.js +++ b/ui/app/routes/allocations/allocation.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; +import Route from '@ember/routing/route'; import WithModelErrorHandling from 'nomad-ui/mixins/with-model-error-handling'; -const { Route } = Ember; - export default Route.extend(WithModelErrorHandling); diff --git a/ui/app/routes/allocations/allocation/task.js b/ui/app/routes/allocations/allocation/task.js index 4a57f1ad2..dcf2bda10 100644 --- a/ui/app/routes/allocations/allocation/task.js +++ b/ui/app/routes/allocations/allocation/task.js @@ -1,9 +1,9 @@ -import Ember from 'ember'; - -const { Route, inject, Error: EmberError } = Ember; +import { inject as service } from '@ember/service'; +import Route from '@ember/routing/route'; +import EmberError from '@ember/error'; export default Route.extend({ - store: inject.service(), + store: service(), model({ name }) { const allocation = this.modelFor('allocations.allocation'); diff --git a/ui/app/routes/allocations/allocation/task/logs.js b/ui/app/routes/allocations/allocation/task/logs.js index 5e4767eb5..399258f21 100644 --- a/ui/app/routes/allocations/allocation/task/logs.js +++ b/ui/app/routes/allocations/allocation/task/logs.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { Route } = Ember; +import Route from '@ember/routing/route'; export default Route.extend({ model() { diff --git a/ui/app/routes/application.js b/ui/app/routes/application.js index 0a2e57c39..f7437a18c 100644 --- a/ui/app/routes/application.js +++ b/ui/app/routes/application.js @@ -1,9 +1,8 @@ -import Ember from 'ember'; - -const { Route, inject } = Ember; +import { inject as service } from '@ember/service'; +import Route from '@ember/routing/route'; export default Route.extend({ - config: inject.service(), + config: service(), resetController(controller, isExiting) { if (isExiting) { diff --git a/ui/app/routes/clients.js b/ui/app/routes/clients.js index f2915a3a9..49559c8c9 100644 --- a/ui/app/routes/clients.js +++ b/ui/app/routes/clients.js @@ -1,12 +1,12 @@ -import Ember from 'ember'; +import { inject as service } from '@ember/service'; +import Route from '@ember/routing/route'; +import RSVP from 'rsvp'; import WithForbiddenState from 'nomad-ui/mixins/with-forbidden-state'; import notifyForbidden from 'nomad-ui/utils/notify-forbidden'; -const { Route, inject, RSVP } = Ember; - export default Route.extend(WithForbiddenState, { - store: inject.service(), - system: inject.service(), + store: service(), + system: service(), beforeModel() { return this.get('system.leader'); diff --git a/ui/app/routes/clients/client.js b/ui/app/routes/clients/client.js index 9571d975a..1be621e47 100644 --- a/ui/app/routes/clients/client.js +++ b/ui/app/routes/clients/client.js @@ -1,10 +1,9 @@ -import Ember from 'ember'; +import { inject as service } from '@ember/service'; +import Route from '@ember/routing/route'; import notifyError from 'nomad-ui/utils/notify-error'; -const { Route, inject } = Ember; - export default Route.extend({ - store: inject.service(), + store: service(), model() { return this._super(...arguments).catch(notifyError(this)); diff --git a/ui/app/routes/index.js b/ui/app/routes/index.js index f07c338c8..7de6fff38 100644 --- a/ui/app/routes/index.js +++ b/ui/app/routes/index.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { Route } = Ember; +import Route from '@ember/routing/route'; export default Route.extend({ redirect() { diff --git a/ui/app/routes/jobs.js b/ui/app/routes/jobs.js index 9d51a55b6..745e326e2 100644 --- a/ui/app/routes/jobs.js +++ b/ui/app/routes/jobs.js @@ -1,12 +1,12 @@ -import Ember from 'ember'; +import { inject as service } from '@ember/service'; +import Route from '@ember/routing/route'; +import { run } from '@ember/runloop'; import WithForbiddenState from 'nomad-ui/mixins/with-forbidden-state'; import notifyForbidden from 'nomad-ui/utils/notify-forbidden'; -const { Route, inject, run } = Ember; - export default Route.extend(WithForbiddenState, { - system: inject.service(), - store: inject.service(), + system: service(), + store: service(), beforeModel() { return this.get('system.namespaces'); diff --git a/ui/app/routes/jobs/index.js b/ui/app/routes/jobs/index.js index 8962abd90..0a8317fea 100644 --- a/ui/app/routes/jobs/index.js +++ b/ui/app/routes/jobs/index.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { Route } = Ember; +import Route from '@ember/routing/route'; export default Route.extend({ actions: { diff --git a/ui/app/routes/jobs/job.js b/ui/app/routes/jobs/job.js index fa40f07bd..558ea55e4 100644 --- a/ui/app/routes/jobs/job.js +++ b/ui/app/routes/jobs/job.js @@ -1,10 +1,10 @@ -import Ember from 'ember'; +import { inject as service } from '@ember/service'; +import Route from '@ember/routing/route'; +import RSVP from 'rsvp'; import notifyError from 'nomad-ui/utils/notify-error'; -const { Route, RSVP, inject } = Ember; - export default Route.extend({ - store: inject.service(), + store: service(), serialize(model) { return { job_name: model.get('plainId') }; diff --git a/ui/app/routes/jobs/job/definition.js b/ui/app/routes/jobs/job/definition.js index 4f24dbc60..8730f83b8 100644 --- a/ui/app/routes/jobs/job/definition.js +++ b/ui/app/routes/jobs/job/definition.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { Route } = Ember; +import Route from '@ember/routing/route'; export default Route.extend({ model() { diff --git a/ui/app/routes/jobs/job/deployments.js b/ui/app/routes/jobs/job/deployments.js index a048c898a..41363eff6 100644 --- a/ui/app/routes/jobs/job/deployments.js +++ b/ui/app/routes/jobs/job/deployments.js @@ -1,6 +1,5 @@ -import Ember from 'ember'; - -const { Route, RSVP } = Ember; +import Route from '@ember/routing/route'; +import RSVP from 'rsvp'; export default Route.extend({ model() { diff --git a/ui/app/routes/jobs/job/task-group.js b/ui/app/routes/jobs/job/task-group.js index 2be6107ab..def6e57ea 100644 --- a/ui/app/routes/jobs/job/task-group.js +++ b/ui/app/routes/jobs/job/task-group.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { Route } = Ember; +import Route from '@ember/routing/route'; export default Route.extend({ model({ name }) { diff --git a/ui/app/routes/jobs/job/versions.js b/ui/app/routes/jobs/job/versions.js index 637d663c3..6debc85db 100644 --- a/ui/app/routes/jobs/job/versions.js +++ b/ui/app/routes/jobs/job/versions.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { Route } = Ember; +import Route from '@ember/routing/route'; export default Route.extend({ model() { diff --git a/ui/app/routes/not-found.js b/ui/app/routes/not-found.js index 1974ee9ba..a7df89c01 100644 --- a/ui/app/routes/not-found.js +++ b/ui/app/routes/not-found.js @@ -1,6 +1,5 @@ -import Ember from 'ember'; - -const { Route, Error: EmberError } = Ember; +import Route from '@ember/routing/route'; +import EmberError from '@ember/error'; export default Route.extend({ model() { diff --git a/ui/app/routes/servers.js b/ui/app/routes/servers.js index f2915a3a9..49559c8c9 100644 --- a/ui/app/routes/servers.js +++ b/ui/app/routes/servers.js @@ -1,12 +1,12 @@ -import Ember from 'ember'; +import { inject as service } from '@ember/service'; +import Route from '@ember/routing/route'; +import RSVP from 'rsvp'; import WithForbiddenState from 'nomad-ui/mixins/with-forbidden-state'; import notifyForbidden from 'nomad-ui/utils/notify-forbidden'; -const { Route, inject, RSVP } = Ember; - export default Route.extend(WithForbiddenState, { - store: inject.service(), - system: inject.service(), + store: service(), + system: service(), beforeModel() { return this.get('system.leader'); diff --git a/ui/app/routes/servers/server.js b/ui/app/routes/servers/server.js index 60eff663b..17aa8b10c 100644 --- a/ui/app/routes/servers/server.js +++ b/ui/app/routes/servers/server.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; +import Route from '@ember/routing/route'; import WithModelErrorHandling from 'nomad-ui/mixins/with-model-error-handling'; -const { Route } = Ember; - export default Route.extend(WithModelErrorHandling); diff --git a/ui/app/serializers/allocation.js b/ui/app/serializers/allocation.js index 33cb3ebf5..8a7a5d43b 100644 --- a/ui/app/serializers/allocation.js +++ b/ui/app/serializers/allocation.js @@ -1,10 +1,9 @@ -import Ember from 'ember'; +import { inject as service } from '@ember/service'; +import { get } from '@ember/object'; import ApplicationSerializer from './application'; -const { get, inject } = Ember; - export default ApplicationSerializer.extend({ - system: inject.service(), + system: service(), attrs: { taskGroupName: 'TaskGroup', diff --git a/ui/app/serializers/application.js b/ui/app/serializers/application.js index bdec30fc1..3d63f5b63 100644 --- a/ui/app/serializers/application.js +++ b/ui/app/serializers/application.js @@ -1,8 +1,6 @@ -import Ember from 'ember'; +import { makeArray } from '@ember/array'; import JSONSerializer from 'ember-data/serializers/json'; -const { makeArray } = Ember; - export default JSONSerializer.extend({ primaryKey: 'ID', diff --git a/ui/app/serializers/deployment.js b/ui/app/serializers/deployment.js index 04e5475a0..2a21f484e 100644 --- a/ui/app/serializers/deployment.js +++ b/ui/app/serializers/deployment.js @@ -1,8 +1,7 @@ -import Ember from 'ember'; +import { get } from '@ember/object'; +import { assign } from '@ember/polyfills'; import ApplicationSerializer from './application'; -const { get, assign } = Ember; - export default ApplicationSerializer.extend({ attrs: { versionNumber: 'JobVersion', diff --git a/ui/app/serializers/evaluation.js b/ui/app/serializers/evaluation.js index 76a2b9b3c..e5faad410 100644 --- a/ui/app/serializers/evaluation.js +++ b/ui/app/serializers/evaluation.js @@ -1,10 +1,10 @@ -import Ember from 'ember'; +import { inject as service } from '@ember/service'; +import { get } from '@ember/object'; +import { assign } from '@ember/polyfills'; import ApplicationSerializer from './application'; -const { inject, get, assign } = Ember; - export default ApplicationSerializer.extend({ - system: inject.service(), + system: service(), normalize(typeHash, hash) { hash.FailedTGAllocs = Object.keys(hash.FailedTGAllocs || {}).map(key => { diff --git a/ui/app/serializers/job-version.js b/ui/app/serializers/job-version.js index 490b6d740..f05809b3f 100644 --- a/ui/app/serializers/job-version.js +++ b/ui/app/serializers/job-version.js @@ -1,8 +1,6 @@ -import Ember from 'ember'; +import { assign } from '@ember/polyfills'; import ApplicationSerializer from './application'; -const { assign } = Ember; - export default ApplicationSerializer.extend({ attrs: { number: 'Version', diff --git a/ui/app/serializers/job.js b/ui/app/serializers/job.js index 74eeb78b0..e09c95cd8 100644 --- a/ui/app/serializers/job.js +++ b/ui/app/serializers/job.js @@ -1,9 +1,8 @@ -import Ember from 'ember'; +import { get } from '@ember/object'; +import { assign } from '@ember/polyfills'; import ApplicationSerializer from './application'; import queryString from 'npm:query-string'; -const { get, assign } = Ember; - export default ApplicationSerializer.extend({ attrs: { parameterized: 'ParameterizedJob', diff --git a/ui/app/serializers/node.js b/ui/app/serializers/node.js index 376f15d12..e0ecfc9a7 100644 --- a/ui/app/serializers/node.js +++ b/ui/app/serializers/node.js @@ -1,10 +1,8 @@ -import Ember from 'ember'; +import { inject as service } from '@ember/service'; import ApplicationSerializer from './application'; -const { inject } = Ember; - export default ApplicationSerializer.extend({ - config: inject.service(), + config: service(), attrs: { httpAddr: 'HTTPAddr', diff --git a/ui/app/serializers/task-group.js b/ui/app/serializers/task-group.js index 107ddf11e..a834250c9 100644 --- a/ui/app/serializers/task-group.js +++ b/ui/app/serializers/task-group.js @@ -1,8 +1,6 @@ -import Ember from 'ember'; +import { copy } from '@ember/object/internals'; import ApplicationSerializer from './application'; -const { copy } = Ember; - export default ApplicationSerializer.extend({ normalize(typeHash, hash) { // Provide EphemeralDisk to each task diff --git a/ui/app/serializers/token.js b/ui/app/serializers/token.js index ede185aed..7ac46e611 100644 --- a/ui/app/serializers/token.js +++ b/ui/app/serializers/token.js @@ -1,8 +1,6 @@ -import Ember from 'ember'; +import { copy } from '@ember/object/internals'; import ApplicationSerializer from './application'; -const { copy } = Ember; - export default ApplicationSerializer.extend({ primaryKey: 'AccessorID', diff --git a/ui/app/services/config.js b/ui/app/services/config.js index 2c586d97c..80e38e1ea 100644 --- a/ui/app/services/config.js +++ b/ui/app/services/config.js @@ -1,14 +1,14 @@ -import Ember from 'ember'; +import { equal } from '@ember/object/computed'; +import Service from '@ember/service'; +import { get } from '@ember/object'; import config from '../config/environment'; -const { Service, get, computed } = Ember; - export default Service.extend({ unknownProperty(path) { return get(config, path); }, - isDev: computed.equal('environment', 'development'), - isProd: computed.equal('environment', 'production'), - isTest: computed.equal('environment', 'test'), + isDev: equal('environment', 'development'), + isProd: equal('environment', 'production'), + isTest: equal('environment', 'test'), }); diff --git a/ui/app/services/system.js b/ui/app/services/system.js index 111e3bfc2..558b411a9 100644 --- a/ui/app/services/system.js +++ b/ui/app/services/system.js @@ -1,12 +1,11 @@ -import Ember from 'ember'; +import Service, { inject as service } from '@ember/service'; +import { computed } from '@ember/object'; import PromiseObject from '../utils/classes/promise-object'; import { namespace } from '../adapters/application'; -const { Service, computed, inject } = Ember; - export default Service.extend({ - token: inject.service(), - store: inject.service(), + token: service(), + store: service(), leader: computed(function() { const token = this.get('token'); diff --git a/ui/app/services/token.js b/ui/app/services/token.js index d51d7510b..4ce27d9c3 100644 --- a/ui/app/services/token.js +++ b/ui/app/services/token.js @@ -1,8 +1,8 @@ -import Ember from 'ember'; +import Service from '@ember/service'; +import { computed } from '@ember/object'; +import { assign } from '@ember/polyfills'; import fetch from 'nomad-ui/utils/fetch'; -const { Service, computed, assign } = Ember; - export default Service.extend({ secret: computed({ get() { diff --git a/ui/app/utils/classes/abstract-logger.js b/ui/app/utils/classes/abstract-logger.js index 37ab2578b..55eb2da1e 100644 --- a/ui/app/utils/classes/abstract-logger.js +++ b/ui/app/utils/classes/abstract-logger.js @@ -1,16 +1,16 @@ -import Ember from 'ember'; +import { assert } from '@ember/debug'; +import Mixin from '@ember/object/mixin'; +import { computed } from '@ember/object'; +import { assign } from '@ember/polyfills'; import queryString from 'npm:query-string'; -const { Mixin, computed, assign } = Ember; const MAX_OUTPUT_LENGTH = 50000; export default Mixin.create({ url: '', params: computed(() => ({})), logFetch() { - Ember.assert( - 'Loggers need a logFetch method, which should have an interface like window.fetch' - ); + assert('Loggers need a logFetch method, which should have an interface like window.fetch'); }, endOffset: null, diff --git a/ui/app/utils/classes/log.js b/ui/app/utils/classes/log.js index 219be0b4e..5e873182a 100644 --- a/ui/app/utils/classes/log.js +++ b/ui/app/utils/classes/log.js @@ -1,11 +1,13 @@ -import Ember from 'ember'; +import { alias } from '@ember/object/computed'; +import { assert } from '@ember/debug'; +import Evented from '@ember/object/evented'; +import EmberObject, { computed } from '@ember/object'; +import { assign } from '@ember/polyfills'; import queryString from 'npm:query-string'; import { task } from 'ember-concurrency'; import StreamLogger from 'nomad-ui/utils/classes/stream-logger'; import PollLogger from 'nomad-ui/utils/classes/poll-logger'; -const { Object: EmberObject, Evented, computed, assign } = Ember; - const MAX_OUTPUT_LENGTH = 50000; const Log = EmberObject.extend(Evented, { @@ -14,14 +16,12 @@ const Log = EmberObject.extend(Evented, { url: '', params: computed(() => ({})), logFetch() { - Ember.assert( - 'Log objects need a logFetch method, which should have an interface like window.fetch' - ); + assert('Log objects need a logFetch method, which should have an interface like window.fetch'); }, // Read-only state - isStreaming: computed.alias('logStreamer.poll.isRunning'), + isStreaming: alias('logStreamer.poll.isRunning'), logPointer: null, logStreamer: null, diff --git a/ui/app/utils/classes/poll-logger.js b/ui/app/utils/classes/poll-logger.js index 5310f3e45..e6c7078a7 100644 --- a/ui/app/utils/classes/poll-logger.js +++ b/ui/app/utils/classes/poll-logger.js @@ -1,9 +1,7 @@ -import Ember from 'ember'; +import EmberObject from '@ember/object'; import { task, timeout } from 'ember-concurrency'; import AbstractLogger from './abstract-logger'; -const { Object: EmberObject } = Ember; - export default EmberObject.extend(AbstractLogger, { interval: 1000, diff --git a/ui/app/utils/classes/promise-object.js b/ui/app/utils/classes/promise-object.js index 8732062b3..fd762b728 100644 --- a/ui/app/utils/classes/promise-object.js +++ b/ui/app/utils/classes/promise-object.js @@ -1,5 +1,4 @@ -import Ember from 'ember'; - -const { ObjectProxy, PromiseProxyMixin } = Ember; +import ObjectProxy from '@ember/object/proxy'; +import PromiseProxyMixin from '@ember/object/promise-proxy-mixin'; export default ObjectProxy.extend(PromiseProxyMixin); diff --git a/ui/app/utils/classes/stream-logger.js b/ui/app/utils/classes/stream-logger.js index f19f0c668..ee1018734 100644 --- a/ui/app/utils/classes/stream-logger.js +++ b/ui/app/utils/classes/stream-logger.js @@ -1,10 +1,8 @@ -import Ember from 'ember'; +import EmberObject, { computed } from '@ember/object'; import { task } from 'ember-concurrency'; import TextDecoder from 'nomad-ui/utils/classes/text-decoder'; import AbstractLogger from './abstract-logger'; -const { Object: EmberObject, computed } = Ember; - export default EmberObject.extend(AbstractLogger, { reader: null, diff --git a/ui/app/utils/properties/short-uuid.js b/ui/app/utils/properties/short-uuid.js index 67ac94ea6..0a7af211c 100644 --- a/ui/app/utils/properties/short-uuid.js +++ b/ui/app/utils/properties/short-uuid.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { computed } = Ember; +import { computed } from '@ember/object'; // An Ember.Computed property for taking the first segment // of a uuid. diff --git a/ui/app/utils/properties/style-string.js b/ui/app/utils/properties/style-string.js index 0f91706f8..e6119aced 100644 --- a/ui/app/utils/properties/style-string.js +++ b/ui/app/utils/properties/style-string.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { computed } = Ember; +import { computed } from '@ember/object'; // An Ember.Computed property for transforming an object into an // html compatible style attribute diff --git a/ui/app/utils/properties/sum-aggregation.js b/ui/app/utils/properties/sum-aggregation.js index e6561ced3..41a486a0e 100644 --- a/ui/app/utils/properties/sum-aggregation.js +++ b/ui/app/utils/properties/sum-aggregation.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { computed } = Ember; +import { computed } from '@ember/object'; // An Ember.Computed property for summating all properties from a // set of objects. @@ -9,6 +7,8 @@ const { computed } = Ember; // sum: sumAggregationProperty('list', 'foo') // 4 export default function sumAggregationProperty(listKey, propKey) { return computed(`${listKey}.@each.${propKey}`, function() { - return this.get(listKey).mapBy(propKey).reduce((sum, count) => sum + count, 0); + return this.get(listKey) + .mapBy(propKey) + .reduce((sum, count) => sum + count, 0); }); } diff --git a/ui/app/utils/timeout.js b/ui/app/utils/timeout.js index f9db48850..5cff0fa99 100644 --- a/ui/app/utils/timeout.js +++ b/ui/app/utils/timeout.js @@ -1,6 +1,4 @@ -import Ember from 'ember'; - -const { RSVP } = Ember; +import RSVP from 'rsvp'; // An always failing promise used to race against other promises export default function timeout(duration) { diff --git a/ui/tests/acceptance/allocation-detail-test.js b/ui/tests/acceptance/allocation-detail-test.js index cd31e6c00..f8a7eff95 100644 --- a/ui/tests/acceptance/allocation-detail-test.js +++ b/ui/tests/acceptance/allocation-detail-test.js @@ -1,11 +1,9 @@ -import Ember from 'ember'; +import $ from 'jquery'; import { click, findAll, currentURL, find, visit } from 'ember-native-dom-helpers'; import { test } from 'qunit'; import moduleForAcceptance from 'nomad-ui/tests/helpers/module-for-acceptance'; import moment from 'moment'; -const { $ } = Ember; - let job; let node; let allocation; diff --git a/ui/tests/acceptance/client-detail-test.js b/ui/tests/acceptance/client-detail-test.js index 6cc1743ea..19da35151 100644 --- a/ui/tests/acceptance/client-detail-test.js +++ b/ui/tests/acceptance/client-detail-test.js @@ -1,12 +1,10 @@ -import Ember from 'ember'; +import $ from 'jquery'; import { click, find, findAll, currentURL, visit } from 'ember-native-dom-helpers'; import { test } from 'qunit'; import moduleForAcceptance from 'nomad-ui/tests/helpers/module-for-acceptance'; import { formatBytes } from 'nomad-ui/helpers/format-bytes'; import moment from 'moment'; -const { $ } = Ember; - let node; moduleForAcceptance('Acceptance | client detail', { diff --git a/ui/tests/acceptance/job-deployments-test.js b/ui/tests/acceptance/job-deployments-test.js index f69bebea0..45a6ae426 100644 --- a/ui/tests/acceptance/job-deployments-test.js +++ b/ui/tests/acceptance/job-deployments-test.js @@ -1,10 +1,10 @@ +import { get } from '@ember/object'; +import $ from 'jquery'; import { click, findAll, find, visit } from 'ember-native-dom-helpers'; -import Ember from 'ember'; import { test } from 'qunit'; import moment from 'moment'; import moduleForAcceptance from 'nomad-ui/tests/helpers/module-for-acceptance'; -const { get, $ } = Ember; const sum = (list, key) => list.reduce((sum, item) => sum + get(item, key), 0); let job; diff --git a/ui/tests/acceptance/job-detail-test.js b/ui/tests/acceptance/job-detail-test.js index cf3b1bcc5..efe84c465 100644 --- a/ui/tests/acceptance/job-detail-test.js +++ b/ui/tests/acceptance/job-detail-test.js @@ -1,10 +1,10 @@ +import { get } from '@ember/object'; +import $ from 'jquery'; import { click, findAll, currentURL, find, visit } from 'ember-native-dom-helpers'; -import Ember from 'ember'; import moment from 'moment'; import { test } from 'qunit'; import moduleForAcceptance from 'nomad-ui/tests/helpers/module-for-acceptance'; -const { get, $ } = Ember; const sum = (list, key) => list.reduce((sum, item) => sum + get(item, key), 0); let job; diff --git a/ui/tests/acceptance/job-versions-test.js b/ui/tests/acceptance/job-versions-test.js index 9c63240a4..4d8b161ce 100644 --- a/ui/tests/acceptance/job-versions-test.js +++ b/ui/tests/acceptance/job-versions-test.js @@ -1,11 +1,9 @@ -import Ember from 'ember'; +import $ from 'jquery'; import { findAll, visit } from 'ember-native-dom-helpers'; import { test } from 'qunit'; import moduleForAcceptance from 'nomad-ui/tests/helpers/module-for-acceptance'; import moment from 'moment'; -const { $ } = Ember; - let job; let versions; diff --git a/ui/tests/acceptance/jobs-list-test.js b/ui/tests/acceptance/jobs-list-test.js index c1cbaadbe..4de2869ea 100644 --- a/ui/tests/acceptance/jobs-list-test.js +++ b/ui/tests/acceptance/jobs-list-test.js @@ -1,10 +1,8 @@ -import Ember from 'ember'; +import $ from 'jquery'; import { click, find, findAll, currentURL, visit, fillIn } from 'ember-native-dom-helpers'; import { test } from 'qunit'; import moduleForAcceptance from 'nomad-ui/tests/helpers/module-for-acceptance'; -const { $ } = Ember; - moduleForAcceptance('Acceptance | jobs list', { beforeEach() { // Required for placing allocations (a result of creating jobs) diff --git a/ui/tests/acceptance/nodes-list-test.js b/ui/tests/acceptance/nodes-list-test.js index c78d83b4b..cc0ab00bc 100644 --- a/ui/tests/acceptance/nodes-list-test.js +++ b/ui/tests/acceptance/nodes-list-test.js @@ -1,12 +1,10 @@ -import Ember from 'ember'; +import $ from 'jquery'; import { click, find, findAll, currentURL, visit } from 'ember-native-dom-helpers'; import { test } from 'qunit'; import moduleForAcceptance from 'nomad-ui/tests/helpers/module-for-acceptance'; import { findLeader } from '../../mirage/config'; import ipParts from 'nomad-ui/utils/ip-parts'; -const { $ } = Ember; - function minimumSetup() { server.createList('node', 1); server.createList('agent', 1); diff --git a/ui/tests/acceptance/server-detail-test.js b/ui/tests/acceptance/server-detail-test.js index 94bd414b6..07c14324c 100644 --- a/ui/tests/acceptance/server-detail-test.js +++ b/ui/tests/acceptance/server-detail-test.js @@ -1,10 +1,8 @@ -import Ember from 'ember'; +import $ from 'jquery'; import { find, findAll, currentURL, visit } from 'ember-native-dom-helpers'; import { test } from 'qunit'; import moduleForAcceptance from 'nomad-ui/tests/helpers/module-for-acceptance'; -const { $ } = Ember; - let agent; moduleForAcceptance('Acceptance | server detail', { diff --git a/ui/tests/acceptance/task-detail-test.js b/ui/tests/acceptance/task-detail-test.js index 2c90da4d7..76beef6c8 100644 --- a/ui/tests/acceptance/task-detail-test.js +++ b/ui/tests/acceptance/task-detail-test.js @@ -1,12 +1,10 @@ -import Ember from 'ember'; +import $ from 'jquery'; import { click, findAll, currentURL, find, visit } from 'ember-native-dom-helpers'; import { test } from 'qunit'; import moduleForAcceptance from 'nomad-ui/tests/helpers/module-for-acceptance'; import moment from 'moment'; import ipParts from 'nomad-ui/utils/ip-parts'; -const { $ } = Ember; - let allocation; let task; diff --git a/ui/tests/acceptance/task-group-detail-test.js b/ui/tests/acceptance/task-group-detail-test.js index e729e1300..75404ae1e 100644 --- a/ui/tests/acceptance/task-group-detail-test.js +++ b/ui/tests/acceptance/task-group-detail-test.js @@ -1,12 +1,10 @@ -import Ember from 'ember'; +import $ from 'jquery'; import { click, find, findAll, fillIn, currentURL, visit } from 'ember-native-dom-helpers'; import { test } from 'qunit'; import moduleForAcceptance from 'nomad-ui/tests/helpers/module-for-acceptance'; import { formatBytes } from 'nomad-ui/helpers/format-bytes'; import moment from 'moment'; -const { $ } = Ember; - let job; let taskGroup; let tasks; diff --git a/ui/tests/acceptance/task-logs-test.js b/ui/tests/acceptance/task-logs-test.js index 77614c1e6..9d75fa391 100644 --- a/ui/tests/acceptance/task-logs-test.js +++ b/ui/tests/acceptance/task-logs-test.js @@ -1,10 +1,8 @@ -import Ember from 'ember'; +import { run } from '@ember/runloop'; import { find } from 'ember-native-dom-helpers'; import { test } from 'qunit'; import moduleForAcceptance from 'nomad-ui/tests/helpers/module-for-acceptance'; -const { run } = Ember; - let allocation; let task; diff --git a/ui/tests/acceptance/token-test.js b/ui/tests/acceptance/token-test.js index 2e62bd9e1..028f0d708 100644 --- a/ui/tests/acceptance/token-test.js +++ b/ui/tests/acceptance/token-test.js @@ -1,10 +1,8 @@ +import $ from 'jquery'; import { find, findAll, fillIn, click, visit } from 'ember-native-dom-helpers'; -import Ember from 'ember'; import { test, skip } from 'ember-qunit'; import moduleForAcceptance from 'nomad-ui/tests/helpers/module-for-acceptance'; -const { $ } = Ember; - let job; let node; let managementToken; diff --git a/ui/tests/helpers/destroy-app.js b/ui/tests/helpers/destroy-app.js index 1807e213c..28dec908e 100644 --- a/ui/tests/helpers/destroy-app.js +++ b/ui/tests/helpers/destroy-app.js @@ -1,7 +1,7 @@ -import Ember from 'ember'; +import { run } from '@ember/runloop'; export default function destroyApp(application) { - Ember.run(application, 'destroy'); + run(application, 'destroy'); if (window.server) { window.server.shutdown(); } diff --git a/ui/tests/helpers/module-for-acceptance.js b/ui/tests/helpers/module-for-acceptance.js index e37a54003..44fe4e0e2 100644 --- a/ui/tests/helpers/module-for-acceptance.js +++ b/ui/tests/helpers/module-for-acceptance.js @@ -1,10 +1,8 @@ +import { Promise } from 'rsvp'; import { module } from 'qunit'; -import Ember from 'ember'; import startApp from '../helpers/start-app'; import destroyApp from '../helpers/destroy-app'; -const { RSVP: { Promise } } = Ember; - export default function(name, options = {}) { module(name, { beforeEach() { diff --git a/ui/tests/helpers/module-for-serializer.js b/ui/tests/helpers/module-for-serializer.js index e2a1fec8a..d5cd2fc8b 100644 --- a/ui/tests/helpers/module-for-serializer.js +++ b/ui/tests/helpers/module-for-serializer.js @@ -1,9 +1,7 @@ -import Ember from 'ember'; +import { getOwner } from '@ember/application'; import { moduleForModel } from 'ember-qunit'; import { initialize as fragmentSerializerInitializer } from 'nomad-ui/initializers/fragment-serializer'; -const { getOwner } = Ember; - export default function(modelName, description, options = { needs: [] }) { // moduleForModel correctly wires up #Serializer.store, // but module does not. diff --git a/ui/tests/helpers/start-app.js b/ui/tests/helpers/start-app.js index 56b8b8e02..2ff98a176 100644 --- a/ui/tests/helpers/start-app.js +++ b/ui/tests/helpers/start-app.js @@ -1,4 +1,5 @@ -import Ember from 'ember'; +import { run } from '@ember/runloop'; +import { merge } from '@ember/polyfills'; import Application from '../../app'; import config from '../../config/environment'; import registerPowerSelectHelpers from '../../tests/helpers/ember-power-select'; @@ -6,10 +7,10 @@ import registerPowerSelectHelpers from '../../tests/helpers/ember-power-select'; registerPowerSelectHelpers(); export default function startApp(attrs) { - let attributes = Ember.merge({}, config.APP); - attributes = Ember.merge(attributes, attrs); // use defaults, but you can override; + let attributes = merge({}, config.APP); + attributes = merge(attributes, attrs); // use defaults, but you can override; - return Ember.run(() => { + return run(() => { let application = Application.create(attributes); application.setupForTesting(); application.injectTestHelpers(); diff --git a/ui/tests/integration/task-log-test.js b/ui/tests/integration/task-log-test.js index 2d58d6fe4..7c1999d2c 100644 --- a/ui/tests/integration/task-log-test.js +++ b/ui/tests/integration/task-log-test.js @@ -1,4 +1,4 @@ -import Ember from 'ember'; +import { run } from '@ember/runloop'; import { test, moduleForComponent } from 'ember-qunit'; import wait from 'ember-test-helpers/wait'; import { find, click } from 'ember-native-dom-helpers'; @@ -6,8 +6,6 @@ import hbs from 'htmlbars-inline-precompile'; import Pretender from 'pretender'; import { logEncode } from '../../mirage/data/logs'; -const { run } = Ember; - const HOST = '1.1.1.1:1111'; const commonProps = { interval: 50, diff --git a/ui/tests/unit/mixins/searchable-test.js b/ui/tests/unit/mixins/searchable-test.js index dbe9d56a6..4478913a2 100644 --- a/ui/tests/unit/mixins/searchable-test.js +++ b/ui/tests/unit/mixins/searchable-test.js @@ -1,15 +1,15 @@ -import Ember from 'ember'; +import { alias } from '@ember/object/computed'; +import { getOwner } from '@ember/application'; +import EmberObject, { computed } from '@ember/object'; import { moduleFor, test } from 'ember-qunit'; import Searchable from 'nomad-ui/mixins/searchable'; -const { getOwner, computed } = Ember; - moduleFor('mixin:searchable', 'Unit | Mixin | Searchable', { subject() { - const SearchableObject = Ember.Object.extend(Searchable, { + const SearchableObject = EmberObject.extend(Searchable, { source: null, searchProps: computed(() => ['id', 'name']), - listToSearch: computed.alias('source'), + listToSearch: alias('source'), }); this.register('test-container:searchable-object', SearchableObject); diff --git a/ui/tests/unit/models/task-group-test.js b/ui/tests/unit/models/task-group-test.js index b5262e4fa..7f7014bcd 100644 --- a/ui/tests/unit/models/task-group-test.js +++ b/ui/tests/unit/models/task-group-test.js @@ -1,7 +1,6 @@ -import Ember from 'ember'; +import { get } from '@ember/object'; import { moduleForModel, test } from 'ember-qunit'; -const { get } = Ember; const sum = (list, key) => list.reduce((sum, item) => sum + get(item, key), 0); moduleForModel('task-group', 'Unit | Model | task-group', { diff --git a/ui/tests/unit/utils/log-test.js b/ui/tests/unit/utils/log-test.js index e4842301a..94faed822 100644 --- a/ui/tests/unit/utils/log-test.js +++ b/ui/tests/unit/utils/log-test.js @@ -1,11 +1,11 @@ -import Ember from 'ember'; +import EmberObject from '@ember/object'; +import RSVP from 'rsvp'; +import { run } from '@ember/runloop'; import sinon from 'sinon'; import wait from 'ember-test-helpers/wait'; import { module, test } from 'ember-qunit'; import _Log from 'nomad-ui/utils/classes/log'; -const { Object: EmberObject, RSVP, run } = Ember; - let startSpy, stopSpy, initSpy, fetchSpy; const MockStreamer = EmberObject.extend({ From 54e083538efd2931136a28a627f7e197b70eab1a Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Fri, 15 Dec 2017 13:59:52 -0800 Subject: [PATCH 093/136] Remove the MODEL_FACTORY_INJECTIONS cruft --- ui/app/app.js | 3 --- 1 file changed, 3 deletions(-) diff --git a/ui/app/app.js b/ui/app/app.js index c5fb686f8..7d6bae3ce 100644 --- a/ui/app/app.js +++ b/ui/app/app.js @@ -1,13 +1,10 @@ import Application from '@ember/application'; -import Ember from 'ember'; import Resolver from './resolver'; import loadInitializers from 'ember-load-initializers'; import config from './config/environment'; let App; -Ember.MODEL_FACTORY_INJECTIONS = true; - App = Application.extend({ modulePrefix: config.modulePrefix, podModulePrefix: config.podModulePrefix, From c65fff82caaefb76f0a0241949aca56296afd8ec Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Tue, 19 Dec 2017 14:00:45 -0800 Subject: [PATCH 094/136] Shuffle around styles to better organize around net new code and bulma overrides --- ui/app/styles/components.scss | 1 + .../{core => components}/page-layout.scss | 5 --- ui/app/styles/core.scss | 45 ++----------------- ui/app/styles/core/variables.scss | 35 +++++++++++++++ ui/app/styles/{core => utils}/bumper.scss | 0 ui/app/styles/utils/reset.scss | 6 +++ 6 files changed, 46 insertions(+), 46 deletions(-) rename ui/app/styles/{core => components}/page-layout.scss (92%) create mode 100644 ui/app/styles/core/variables.scss rename ui/app/styles/{core => utils}/bumper.scss (100%) create mode 100644 ui/app/styles/utils/reset.scss diff --git a/ui/app/styles/components.scss b/ui/app/styles/components.scss index cb2162c2f..f3e2a30cd 100644 --- a/ui/app/styles/components.scss +++ b/ui/app/styles/components.scss @@ -12,6 +12,7 @@ @import "./components/loading-spinner"; @import "./components/metrics"; @import "./components/node-status-light"; +@import "./components/page-layout"; @import "./components/simple-list"; @import "./components/status-text"; @import "./components/timeline"; diff --git a/ui/app/styles/core/page-layout.scss b/ui/app/styles/components/page-layout.scss similarity index 92% rename from ui/app/styles/core/page-layout.scss rename to ui/app/styles/components/page-layout.scss index 26c8de78e..d463be113 100644 --- a/ui/app/styles/core/page-layout.scss +++ b/ui/app/styles/components/page-layout.scss @@ -1,8 +1,3 @@ -html, body, body > .ember-view { - height: 100%; - width: 100%; -} - .page-layout { height: 100%; display: flex; diff --git a/ui/app/styles/core.scss b/ui/app/styles/core.scss index 3021d6be0..78e76677c 100644 --- a/ui/app/styles/core.scss +++ b/ui/app/styles/core.scss @@ -1,47 +1,14 @@ // Utils +@import "./utils/reset.scss"; @import "./utils/z-indices"; +@import "./utils/product-colors"; +@import "./utils/bumper"; // Start with Bulma variables as a foundation @import "bulma/sass/utilities/initial-variables"; // Override variables where appropriate -@import "./utils/product-colors"; - -$orange: #fa8e23; -$green: #2eb039; -$blue: $vagrant-blue; -$purple: $terraform-purple; -$red: #c84034; -$grey-blue: #bbc4d1; - -$primary: $nomad-green; -$warning: $orange; -$warning-invert: $white; -$danger: $red; -$dark: #234; - -$radius: 2px; - -$body-size: 14px; -$title-size: 1.75rem; -$size-5: 1.15rem; -$size-4: 1.3rem; -$size-7: 0.85rem; - -$title-weight: $weight-semibold; - -$family-sans-serif: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, - Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif; - -$text: $black; - -$header-height: 112px; -$gutter-width: 250px; - -$icon-dimensions: 1.25rem; -$icon-dimensions-small: 1rem; -$icon-dimensions-medium: 1.5rem; -$icon-dimensions-large: 2.5rem; +@import "./core/variables.scss"; // Bring in the rest of Bulma @import "bulma/bulma"; @@ -64,7 +31,3 @@ $icon-dimensions-large: 2.5rem; @import "./core/tag"; @import "./core/title"; @import "./core/typography"; - -// Add unique core extensions -@import "./core/page-layout"; -@import "./core/bumper"; diff --git a/ui/app/styles/core/variables.scss b/ui/app/styles/core/variables.scss new file mode 100644 index 000000000..6e957033e --- /dev/null +++ b/ui/app/styles/core/variables.scss @@ -0,0 +1,35 @@ +$orange: #fa8e23; +$green: #2eb039; +$blue: $vagrant-blue; +$purple: $terraform-purple; +$red: #c84034; +$grey-blue: #bbc4d1; + +$primary: $nomad-green; +$warning: $orange; +$warning-invert: $white; +$danger: $red; +$dark: #234; + +$radius: 2px; + +$body-size: 14px; +$title-size: 1.75rem; +$size-5: 1.15rem; +$size-4: 1.3rem; +$size-7: 0.85rem; + +$title-weight: $weight-semibold; + +$family-sans-serif: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, + Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif; + +$text: $black; + +$header-height: 112px; +$gutter-width: 250px; + +$icon-dimensions: 1.25rem; +$icon-dimensions-small: 1rem; +$icon-dimensions-medium: 1.5rem; +$icon-dimensions-large: 2.5rem; diff --git a/ui/app/styles/core/bumper.scss b/ui/app/styles/utils/bumper.scss similarity index 100% rename from ui/app/styles/core/bumper.scss rename to ui/app/styles/utils/bumper.scss diff --git a/ui/app/styles/utils/reset.scss b/ui/app/styles/utils/reset.scss new file mode 100644 index 000000000..42d609252 --- /dev/null +++ b/ui/app/styles/utils/reset.scss @@ -0,0 +1,6 @@ +html, +body, +body > .ember-view { + height: 100%; + width: 100%; +} From 72d5359de44a542c462eb99352e6981f4e7705e2 Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Tue, 19 Dec 2017 15:41:35 -0800 Subject: [PATCH 095/136] Upgrade Bulma to 5.0 --- ui/package.json | 2 +- ui/yarn.lock | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ui/package.json b/ui/package.json index f8162239a..0d1b0c549 100644 --- a/ui/package.json +++ b/ui/package.json @@ -28,7 +28,7 @@ }, "devDependencies": { "broccoli-asset-rev": "^2.4.5", - "bulma": "0.4.2", + "bulma": "0.5.0", "core-js": "^2.4.1", "d3-selection": "^1.1.0", "d3-transition": "^1.1.0", diff --git a/ui/yarn.lock b/ui/yarn.lock index 37cf1a911..d0bb75a12 100644 --- a/ui/yarn.lock +++ b/ui/yarn.lock @@ -1710,9 +1710,9 @@ builtins@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/builtins/-/builtins-1.0.3.tgz#cb94faeb61c8696451db36534e1422f94f0aee88" -bulma@0.4.2: - version "0.4.2" - resolved "https://registry.yarnpkg.com/bulma/-/bulma-0.4.2.tgz#3be8c832cf6658bfc421ecb41f6dc5a8a0c7c0e5" +bulma@0.5.0: + version "0.5.0" + resolved "https://registry.yarnpkg.com/bulma/-/bulma-0.5.0.tgz#09a7932c1c15aa7ef92840f7a50b1bfebbfd5461" bytes@1: version "1.0.0" From 2c7cb11a7268bc7de99c9fdfc3de4f6b21a5e464 Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Tue, 19 Dec 2017 15:44:47 -0800 Subject: [PATCH 096/136] Default to 100% wide tables Bulma 0.5.0 makes tables auto by default and adds the full-width modifier. --- ui/app/styles/core/table.scss | 1 + 1 file changed, 1 insertion(+) diff --git a/ui/app/styles/core/table.scss b/ui/app/styles/core/table.scss index 171379635..e1c14d6ee 100644 --- a/ui/app/styles/core/table.scss +++ b/ui/app/styles/core/table.scss @@ -3,6 +3,7 @@ border-radius: $radius; border: 1px solid $grey-blue; border-collapse: separate; + width: 100%; &.is-fixed { table-layout: fixed; From d458ae7e4e8a6c0f4b5634d4ae2bb9c25b02e893 Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Tue, 19 Dec 2017 15:45:38 -0800 Subject: [PATCH 097/136] Update variable names --- ui/app/styles/core/message.scss | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ui/app/styles/core/message.scss b/ui/app/styles/core/message.scss index b5e71e6b7..dba6ffa4b 100644 --- a/ui/app/styles/core/message.scss +++ b/ui/app/styles/core/message.scss @@ -1,8 +1,8 @@ .message { - background: $body-background; + background: $body-background-color; .message-header { - background: $body-background; + background: $body-background-color; color: $text; font-size: $size-5; font-weight: $weight-semibold; From dbdbde4f9aadd2f820170fc3f75fea18bdfa2937 Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Tue, 19 Dec 2017 17:25:35 -0800 Subject: [PATCH 098/136] Replace custom breadcrumbs CSS with new Bulma provided CSS --- ui/app/styles/components.scss | 1 - ui/app/styles/components/breadcrumbs.scss | 26 ------------------- ui/app/styles/core.scss | 1 + ui/app/styles/core/breadcrumb.scss | 15 +++++++++++ ui/app/styles/core/variables.scss | 5 ++++ .../allocations/allocation/index.hbs | 8 +++--- .../allocations/allocation/task/index.hbs | 18 ++++++++----- .../allocations/allocation/task/logs.hbs | 18 ++++++++----- ui/app/templates/clients/client.hbs | 6 +++-- ui/app/templates/clients/index.hbs | 4 ++- ui/app/templates/clients/loading.hbs | 4 ++- ui/app/templates/components/global-header.hbs | 14 +++++----- ui/app/templates/jobs/index.hbs | 4 ++- ui/app/templates/jobs/job/definition.hbs | 6 +++-- ui/app/templates/jobs/job/deployments.hbs | 6 +++-- ui/app/templates/jobs/job/index.hbs | 6 +++-- ui/app/templates/jobs/job/loading.hbs | 6 +++-- ui/app/templates/jobs/job/task-group.hbs | 19 +++++++------- ui/app/templates/jobs/job/versions.hbs | 6 +++-- ui/app/templates/jobs/loading.hbs | 4 ++- ui/app/templates/servers.hbs | 4 ++- ui/tests/acceptance/client-detail-test.js | 10 ++++--- ui/tests/acceptance/job-detail-test.js | 6 ++--- ui/tests/acceptance/task-detail-test.js | 10 +++---- ui/tests/acceptance/task-group-detail-test.js | 14 ++++++---- 25 files changed, 127 insertions(+), 94 deletions(-) delete mode 100644 ui/app/styles/components/breadcrumbs.scss create mode 100644 ui/app/styles/core/breadcrumb.scss diff --git a/ui/app/styles/components.scss b/ui/app/styles/components.scss index f3e2a30cd..afd92f4e0 100644 --- a/ui/app/styles/components.scss +++ b/ui/app/styles/components.scss @@ -1,6 +1,5 @@ @import "./components/badge"; @import "./components/boxed-section"; -@import "./components/breadcrumbs"; @import "./components/cli-window"; @import "./components/ember-power-select"; @import "./components/empty-message"; diff --git a/ui/app/styles/components/breadcrumbs.scss b/ui/app/styles/components/breadcrumbs.scss deleted file mode 100644 index c3ec634a6..000000000 --- a/ui/app/styles/components/breadcrumbs.scss +++ /dev/null @@ -1,26 +0,0 @@ -.breadcrumbs { - .breadcrumb { - color: $white; - opacity: 0.7; - text-decoration: none; - - + .breadcrumb { - margin-left: 15px; - &::before { - content: "/"; - color: $primary; - position: relative; - left: -7px; - } - } - - &:last-child { - opacity: 1; - } - } - - a.breadcrumb:hover { - color: $primary-invert; - opacity: 1; - } -} diff --git a/ui/app/styles/core.scss b/ui/app/styles/core.scss index 78e76677c..e7c657bac 100644 --- a/ui/app/styles/core.scss +++ b/ui/app/styles/core.scss @@ -15,6 +15,7 @@ // Override Bulma details where appropriate @import "./core/buttons"; +@import "./core/breadcrumb"; @import "./core/columns"; @import "./core/forms"; @import "./core/icon"; diff --git a/ui/app/styles/core/breadcrumb.scss b/ui/app/styles/core/breadcrumb.scss new file mode 100644 index 000000000..182decee3 --- /dev/null +++ b/ui/app/styles/core/breadcrumb.scss @@ -0,0 +1,15 @@ +.breadcrumb { + a { + text-decoration: none; + opacity: 0.7; + + &:hover { + text-decoration: none; + opacity: 1; + } + } + + li.is-active a { + opacity: 1; + } +} diff --git a/ui/app/styles/core/variables.scss b/ui/app/styles/core/variables.scss index 6e957033e..b81a50b4e 100644 --- a/ui/app/styles/core/variables.scss +++ b/ui/app/styles/core/variables.scss @@ -33,3 +33,8 @@ $icon-dimensions: 1.25rem; $icon-dimensions-small: 1rem; $icon-dimensions-medium: 1.5rem; $icon-dimensions-large: 2.5rem; + +$breadcrumb-item-color: $white; +$breadcrumb-item-hover-color: $white; +$breadcrumb-item-active-color: $white; +$breadcrumb-item-separator-color: $primary; diff --git a/ui/app/templates/allocations/allocation/index.hbs b/ui/app/templates/allocations/allocation/index.hbs index 96cb194b5..8c12406d4 100644 --- a/ui/app/templates/allocations/allocation/index.hbs +++ b/ui/app/templates/allocations/allocation/index.hbs @@ -1,8 +1,8 @@ {{#global-header class="page-header"}} - Allocations - {{#link-to "allocations.allocation" model class="breadcrumb"}} - {{model.shortId}} - {{/link-to}} +
        • Allocations
        • +
        • + {{#link-to "allocations.allocation" model}}{{model.shortId}}{{/link-to}} +
        • {{/global-header}} {{#gutter-menu class="page-body"}}
          diff --git a/ui/app/templates/allocations/allocation/task/index.hbs b/ui/app/templates/allocations/allocation/task/index.hbs index 20dcf01ac..f7d646a54 100644 --- a/ui/app/templates/allocations/allocation/task/index.hbs +++ b/ui/app/templates/allocations/allocation/task/index.hbs @@ -1,11 +1,15 @@ {{#global-header class="page-header"}} - Allocations - {{#link-to "allocations.allocation" model.allocation class="breadcrumb"}} - {{model.allocation.shortId}} - {{/link-to}} - {{#link-to "allocations.allocation.task" model.allocation model class="breadcrumb"}} - {{model.name}} - {{/link-to}} +
        • Allocations
        • +
        • + {{#link-to "allocations.allocation" model.allocation}} + {{model.allocation.shortId}} + {{/link-to}} +
        • +
        • + {{#link-to "allocations.allocation.task" model.allocation model}} + {{model.name}} + {{/link-to}} +
        • {{/global-header}} {{#gutter-menu class="page-body"}} {{partial "allocations/allocation/task/subnav"}} diff --git a/ui/app/templates/allocations/allocation/task/logs.hbs b/ui/app/templates/allocations/allocation/task/logs.hbs index 887d2a7d1..5628e69fc 100644 --- a/ui/app/templates/allocations/allocation/task/logs.hbs +++ b/ui/app/templates/allocations/allocation/task/logs.hbs @@ -1,11 +1,15 @@ {{#global-header class="page-header"}} - Allocations - {{#link-to "allocations.allocation" model.allocation class="breadcrumb"}} - {{model.allocation.shortId}} - {{/link-to}} - {{#link-to "allocations.allocation.task" model.allocation model class="breadcrumb"}} - {{model.name}} - {{/link-to}} +
        • Allocations
        • +
        • + {{#link-to "allocations.allocation" model.allocation}} + {{model.allocation.shortId}} + {{/link-to}} +
        • +
        • + {{#link-to "allocations.allocation.task" model.allocation model}} + {{model.name}} + {{/link-to}} +
        • {{/global-header}} {{#gutter-menu class="page-body"}} {{partial "allocations/allocation/task/subnav"}} diff --git a/ui/app/templates/clients/client.hbs b/ui/app/templates/clients/client.hbs index a4f10bd3a..228f30100 100644 --- a/ui/app/templates/clients/client.hbs +++ b/ui/app/templates/clients/client.hbs @@ -1,6 +1,8 @@ {{#global-header class="page-header"}} - {{#link-to "clients" class="breadcrumb"}}Clients{{/link-to}} - {{model.shortId}} +
        • {{#link-to "clients.index"}}Clients{{/link-to}}
        • +
        • + {{#link-to "clients.client" model.id}}{{model.shortId}}{{/link-to}} +
        • {{/global-header}} {{#gutter-menu class="page-body"}}
          diff --git a/ui/app/templates/clients/index.hbs b/ui/app/templates/clients/index.hbs index b6f0c7275..503341e44 100644 --- a/ui/app/templates/clients/index.hbs +++ b/ui/app/templates/clients/index.hbs @@ -1,5 +1,7 @@ {{#global-header class="page-header"}} - Clients +
        • + {{#link-to "clients.index"}}Clients{{/link-to}} +
        • {{/global-header}} {{#gutter-menu class="page-body"}}
          diff --git a/ui/app/templates/clients/loading.hbs b/ui/app/templates/clients/loading.hbs index 7014a5a9d..4bfa29cb2 100644 --- a/ui/app/templates/clients/loading.hbs +++ b/ui/app/templates/clients/loading.hbs @@ -1,5 +1,7 @@ {{#global-header class="page-header"}} - Clients +
        • + {{#link-to "clients.index"}}Clients{{/link-to}} +
        • {{/global-header}} {{#gutter-menu class="page-body"}}
          {{partial "partials/loading-spinner"}}
          diff --git a/ui/app/templates/components/global-header.hbs b/ui/app/templates/components/global-header.hbs index 41eeba082..4d51652f0 100644 --- a/ui/app/templates/components/global-header.hbs +++ b/ui/app/templates/components/global-header.hbs @@ -12,11 +12,11 @@ {{#link-to "settings.tokens" class="nav-item"}}ACL Tokens{{/link-to}} - + + + diff --git a/ui/app/templates/jobs/index.hbs b/ui/app/templates/jobs/index.hbs index 71f976903..76d63662e 100644 --- a/ui/app/templates/jobs/index.hbs +++ b/ui/app/templates/jobs/index.hbs @@ -1,5 +1,7 @@ {{#global-header class="page-header"}} - Jobs +
        • + {{#link-to "jobs.index"}}Jobs{{/link-to}} +
        • {{/global-header}} {{#gutter-menu class="page-body" onNamespaceChange=(action "refresh")}}
          diff --git a/ui/app/templates/jobs/job/definition.hbs b/ui/app/templates/jobs/job/definition.hbs index f984fcbe7..51cf8345f 100644 --- a/ui/app/templates/jobs/job/definition.hbs +++ b/ui/app/templates/jobs/job/definition.hbs @@ -1,6 +1,8 @@ {{#global-header class="page-header"}} - {{#each breadcrumbs as |breadcrumb|}} - {{#link-to params=breadcrumb.args class="breadcrumb"}}{{breadcrumb.label}}{{/link-to}} + {{#each breadcrumbs as |breadcrumb index|}} + {{/each}} {{/global-header}} {{#gutter-menu class="page-body" onNamespaceChange=(action "gotoJobs")}} diff --git a/ui/app/templates/jobs/job/deployments.hbs b/ui/app/templates/jobs/job/deployments.hbs index 35afe908c..c293bfaef 100644 --- a/ui/app/templates/jobs/job/deployments.hbs +++ b/ui/app/templates/jobs/job/deployments.hbs @@ -1,6 +1,8 @@ {{#global-header class="page-header"}} - {{#each breadcrumbs as |breadcrumb|}} - {{#link-to params=breadcrumb.args class="breadcrumb"}}{{breadcrumb.label}}{{/link-to}} + {{#each breadcrumbs as |breadcrumb index|}} + {{/each}} {{/global-header}} {{#gutter-menu class="page-body" onNamespaceChange=(action "gotoJobs")}} diff --git a/ui/app/templates/jobs/job/index.hbs b/ui/app/templates/jobs/job/index.hbs index 07a83d98f..3366d4ab8 100644 --- a/ui/app/templates/jobs/job/index.hbs +++ b/ui/app/templates/jobs/job/index.hbs @@ -1,6 +1,8 @@ {{#global-header class="page-header"}} - {{#each breadcrumbs as |breadcrumb|}} - {{#link-to params=breadcrumb.args class="breadcrumb"}}{{breadcrumb.label}}{{/link-to}} + {{#each breadcrumbs as |breadcrumb index|}} + {{/each}} {{/global-header}} {{#gutter-menu class="page-body" onNamespaceChange=(action "gotoJobs")}} diff --git a/ui/app/templates/jobs/job/loading.hbs b/ui/app/templates/jobs/job/loading.hbs index 503faa81f..666de358d 100644 --- a/ui/app/templates/jobs/job/loading.hbs +++ b/ui/app/templates/jobs/job/loading.hbs @@ -1,6 +1,8 @@ {{#global-header class="page-header"}} - {{#each breadcrumbs as |breadcrumb|}} - {{#link-to params=breadcrumb.args class="breadcrumb"}}{{breadcrumb.label}}{{/link-to}} + {{#each breadcrumbs as |breadcrumb index|}} + {{/each}} {{/global-header}} {{#gutter-menu class="page-body"}} diff --git a/ui/app/templates/jobs/job/task-group.hbs b/ui/app/templates/jobs/job/task-group.hbs index 3d94ee812..679600a1a 100644 --- a/ui/app/templates/jobs/job/task-group.hbs +++ b/ui/app/templates/jobs/job/task-group.hbs @@ -1,13 +1,14 @@ {{#global-header class="page-header"}} - {{#each breadcrumbs as |breadcrumb|}} - {{#link-to - params=(append - breadcrumb.args - (query-params jobNamespace=(or model.namespace.id "default")) - ) - class="breadcrumb"}} - {{breadcrumb.label}} - {{/link-to}} + {{#each breadcrumbs as |breadcrumb index|}} + {{/each}} {{/global-header}} {{#gutter-menu class="page-body" onNamespaceChange=(action "gotoJobs")}} diff --git a/ui/app/templates/jobs/job/versions.hbs b/ui/app/templates/jobs/job/versions.hbs index fac0992db..6aadbe617 100644 --- a/ui/app/templates/jobs/job/versions.hbs +++ b/ui/app/templates/jobs/job/versions.hbs @@ -1,6 +1,8 @@ {{#global-header class="page-header"}} - {{#each breadcrumbs as |breadcrumb|}} - {{#link-to params=breadcrumb.args class="breadcrumb"}}{{breadcrumb.label}}{{/link-to}} + {{#each breadcrumbs as |breadcrumb index|}} + {{/each}} {{/global-header}} {{#gutter-menu class="page-body" onNamespaceChange=(action "gotoJobs")}} diff --git a/ui/app/templates/jobs/loading.hbs b/ui/app/templates/jobs/loading.hbs index f754d94ff..58bc6ef5b 100644 --- a/ui/app/templates/jobs/loading.hbs +++ b/ui/app/templates/jobs/loading.hbs @@ -1,5 +1,7 @@ {{#global-header class="page-header"}} - Jobs +
        • + {{#link-to "jobs.index"}}Jobs{{/link-to}} +
        • {{/global-header}} {{#gutter-menu class="page-body"}}
          {{partial "partials/loading-spinner"}}
          diff --git a/ui/app/templates/servers.hbs b/ui/app/templates/servers.hbs index 133422482..5b97959ed 100644 --- a/ui/app/templates/servers.hbs +++ b/ui/app/templates/servers.hbs @@ -1,6 +1,8 @@
          {{#global-header class="page-header"}} - Servers +
        • + {{#link-to "servers.index"}}Servers{{/link-to}} +
        • {{/global-header}} {{#gutter-menu class="page-body"}}
          diff --git a/ui/tests/acceptance/client-detail-test.js b/ui/tests/acceptance/client-detail-test.js index 19da35151..03e28ed6a 100644 --- a/ui/tests/acceptance/client-detail-test.js +++ b/ui/tests/acceptance/client-detail-test.js @@ -23,16 +23,20 @@ test('/clients/:id should have a breadrcumb trail linking back to clients', func visit(`/clients/${node.id}`); andThen(() => { - assert.equal(findAll('.breadcrumb')[0].textContent, 'Clients', 'First breadcrumb says clients'); assert.equal( - findAll('.breadcrumb')[1].textContent, + findAll('.breadcrumb a')[0].textContent, + 'Clients', + 'First breadcrumb says clients' + ); + assert.equal( + findAll('.breadcrumb a')[1].textContent, node.id.split('-')[0], 'Second breadcrumb says the node short id' ); }); andThen(() => { - click(findAll('.breadcrumb')[0]); + click(findAll('.breadcrumb a')[0]); }); andThen(() => { diff --git a/ui/tests/acceptance/job-detail-test.js b/ui/tests/acceptance/job-detail-test.js index efe84c465..758e40c91 100644 --- a/ui/tests/acceptance/job-detail-test.js +++ b/ui/tests/acceptance/job-detail-test.js @@ -22,14 +22,14 @@ test('visiting /jobs/:job_id', function(assert) { }); test('breadcrumbs includes job name and link back to the jobs list', function(assert) { - assert.equal(findAll('.breadcrumb')[0].textContent, 'Jobs', 'First breadcrumb says jobs'); + assert.equal(findAll('.breadcrumb a')[0].textContent, 'Jobs', 'First breadcrumb says jobs'); assert.equal( - findAll('.breadcrumb')[1].textContent, + findAll('.breadcrumb a')[1].textContent, job.name, 'Second breadcrumb says the job name' ); - click(findAll('.breadcrumb')[0]); + click(findAll('.breadcrumb a')[0]); andThen(() => { assert.equal(currentURL(), '/jobs', 'First breadcrumb links back to jobs'); }); diff --git a/ui/tests/acceptance/task-detail-test.js b/ui/tests/acceptance/task-detail-test.js index 76beef6c8..84dd97708 100644 --- a/ui/tests/acceptance/task-detail-test.js +++ b/ui/tests/acceptance/task-detail-test.js @@ -36,16 +36,16 @@ test('/allocation/:id/:task_name should name the task and list high-level task i }); test('breadcrumbs includes allocations and link to the allocation detail page', function(assert) { - const breadcrumbs = findAll('.breadcrumb'); + const breadcrumbs = findAll('.breadcrumb a'); assert.equal( breadcrumbs[0].textContent.trim(), 'Allocations', 'Allocations is the first breadcrumb' ); - assert.notEqual( - breadcrumbs[0].tagName.toLowerCase(), - 'a', - 'Allocations breadcrumb is not a link' + assert.equal( + breadcrumbs[0].getAttribute('href'), + '#', + "Allocations breadcrumb doesn't link anywhere" ); assert.equal( breadcrumbs[1].textContent.trim(), diff --git a/ui/tests/acceptance/task-group-detail-test.js b/ui/tests/acceptance/task-group-detail-test.js index 75404ae1e..1757f42a9 100644 --- a/ui/tests/acceptance/task-group-detail-test.js +++ b/ui/tests/acceptance/task-group-detail-test.js @@ -78,21 +78,25 @@ test('/jobs/:id/:task-group should list high-level metrics for the allocation', }); test('/jobs/:id/:task-group should have breadcrumbs for job and jobs', function(assert) { - assert.equal(findAll('.breadcrumb')[0].textContent.trim(), 'Jobs', 'First breadcrumb says jobs'); assert.equal( - findAll('.breadcrumb')[1].textContent.trim(), + findAll('.breadcrumb a')[0].textContent.trim(), + 'Jobs', + 'First breadcrumb says jobs' + ); + assert.equal( + findAll('.breadcrumb a')[1].textContent.trim(), job.name, 'Second breadcrumb says the job name' ); assert.equal( - findAll('.breadcrumb')[2].textContent.trim(), + findAll('.breadcrumb a')[2].textContent.trim(), taskGroup.name, 'Third breadcrumb says the job name' ); }); test('/jobs/:id/:task-group first breadcrumb should link to jobs', function(assert) { - click(findAll('.breadcrumb')[0]); + click(findAll('.breadcrumb a')[0]); andThen(() => { assert.equal(currentURL(), '/jobs', 'First breadcrumb links back to jobs'); }); @@ -101,7 +105,7 @@ test('/jobs/:id/:task-group first breadcrumb should link to jobs', function(asse test('/jobs/:id/:task-group second breadcrumb should link to the job for the task group', function( assert ) { - click(findAll('.breadcrumb')[1]); + click(findAll('.breadcrumb a')[1]); andThen(() => { assert.equal( currentURL(), From 10a9370289047e026c1d1325a10cebe996649caf Mon Sep 17 00:00:00 2001 From: Michael Lange Date: Wed, 20 Dec 2017 07:34:46 -0800 Subject: [PATCH 099/136] Replace nav with navbar Bulma introduced navbar while deprecating nav in 0.4.3 Bulma removed deprecated nav in 0.6.0 --- ui/app/styles/core.scss | 2 +- ui/app/styles/core/{nav.scss => navbar.scss} | 11 ++++++----- ui/app/templates/components/global-header.hbs | 18 +++++++++--------- 3 files changed, 16 insertions(+), 15 deletions(-) rename ui/app/styles/core/{nav.scss => navbar.scss} (90%) diff --git a/ui/app/styles/core.scss b/ui/app/styles/core.scss index e7c657bac..e4391415b 100644 --- a/ui/app/styles/core.scss +++ b/ui/app/styles/core.scss @@ -22,7 +22,7 @@ @import "./core/level"; @import "./core/menu"; @import "./core/message"; -@import "./core/nav"; +@import "./core/navbar"; @import "./core/notification"; @import "./core/pagination"; @import "./core/progress"; diff --git a/ui/app/styles/core/nav.scss b/ui/app/styles/core/navbar.scss similarity index 90% rename from ui/app/styles/core/nav.scss rename to ui/app/styles/core/navbar.scss index b1c6d6079..87f15b13c 100644 --- a/ui/app/styles/core/nav.scss +++ b/ui/app/styles/core/navbar.scss @@ -1,4 +1,4 @@ -.nav { +.navbar { &.is-primary { background: linear-gradient( to right, @@ -10,12 +10,13 @@ padding-left: 20px; padding-right: 20px; - .nav-item { + .navbar-item { color: rgba($primary-invert, 0.8); text-decoration: none; &:hover { color: $primary-invert; + background: transparent; } &.is-active, @@ -24,7 +25,7 @@ border-bottom-color: $primary-invert; } - + .nav-item { + + .navbar-item { position: relative; &::before { @@ -53,12 +54,12 @@ font-weight: $weight-semibold; color: $primary-invert; - .nav-item { + .navbar-item { font-size: $size-4; } } - .nav-item { + .navbar-item { &.is-gutter { width: $gutter-width; } diff --git a/ui/app/templates/components/global-header.hbs b/ui/app/templates/components/global-header.hbs index 4d51652f0..8996b11d4 100644 --- a/ui/app/templates/components/global-header.hbs +++ b/ui/app/templates/components/global-header.hbs @@ -1,19 +1,19 @@ -
          Addresses
          +
          {{#link-to "allocations.allocation.task" row.model.allocation row.model}} {{row.model.task.name}} {{/link-to}} {{row.model.state}} + {{row.model.state}} {{#if row.model.events.lastObject.displayMessage}} {{row.model.events.lastObject.displayMessage}} {{else}} No message {{/if}} {{moment-format row.model.events.lastObject.time "MM/DD/YY HH:mm:ss"}} + {{moment-format row.model.events.lastObject.time "MM/DD/YY HH:mm:ss"}}
            {{#each row.model.resources.networks.firstObject.reservedPorts as |port|}}
          • diff --git a/ui/app/templates/allocations/allocation/task/index.hbs b/ui/app/templates/allocations/allocation/task/index.hbs index f7d646a54..aebe8eeed 100644 --- a/ui/app/templates/allocations/allocation/task/index.hbs +++ b/ui/app/templates/allocations/allocation/task/index.hbs @@ -1,12 +1,12 @@ {{#global-header class="page-header"}} -
          • Allocations
          • +
          • Allocations
          • - {{#link-to "allocations.allocation" model.allocation}} + {{#link-to "allocations.allocation" model.allocation data-test-breadcrumb="allocation"}} {{model.allocation.shortId}} {{/link-to}}
          • - {{#link-to "allocations.allocation.task" model.allocation model}} + {{#link-to "allocations.allocation.task" model.allocation model data-test-breadcrumb="task"}} {{model.name}} {{/link-to}}
          • @@ -14,15 +14,15 @@ {{#gutter-menu class="page-body"}} {{partial "allocations/allocation/task/subnav"}}
            -

            +

            {{model.name}} - {{model.state}} + {{model.state}}

            Task Details - + Started At {{moment-format model.startedAt "MM/DD/YY HH:mm:ss"}} @@ -40,22 +40,22 @@
            {{#if ports.length}} -
            +
            Addresses
            - {{#list-table source=ports class="addresses-list" as |t|}} + {{#list-table source=ports as |t|}} {{#t.head}}
          Dynamic? Name Address
          {{if row.model.isDynamic "Yes" "No"}}{{row.model.name}} +
          {{if row.model.isDynamic "Yes" "No"}}{{row.model.name}} {{model.allocation.node.address}}:{{row.model.port}} @@ -72,17 +72,17 @@ Recent Events
          - {{#list-table source=(reverse model.events) class="is-striped task-events" as |t|}} + {{#list-table source=(reverse model.events) class="is-striped" as |t|}} {{#t.head}}
          Time Type Description
          {{moment-format row.model.time "MM/DD/YY HH:mm:ss"}}{{row.model.type}} +
          {{moment-format row.model.time "MM/DD/YY HH:mm:ss"}}{{row.model.type}} {{#if row.model.displayMessage}} {{row.model.displayMessage}} {{else}} diff --git a/ui/app/templates/allocations/allocation/task/logs.hbs b/ui/app/templates/allocations/allocation/task/logs.hbs index 5628e69fc..01a7440cf 100644 --- a/ui/app/templates/allocations/allocation/task/logs.hbs +++ b/ui/app/templates/allocations/allocation/task/logs.hbs @@ -14,6 +14,6 @@ {{#gutter-menu class="page-body"}} {{partial "allocations/allocation/task/subnav"}}
          - {{task-log allocation=model.allocation task=model.name}} + {{task-log data-test-task-log allocation=model.allocation task=model.name}}
          {{/gutter-menu}} diff --git a/ui/app/templates/application.hbs b/ui/app/templates/application.hbs index 2ee39614a..8d1a11672 100644 --- a/ui/app/templates/application.hbs +++ b/ui/app/templates/application.hbs @@ -3,23 +3,23 @@ {{outlet}} {{else}}
          -
          +
          {{#if is500}} -

          Server Error

          -

          A server error prevented data from being sent to the client.

          +

          Server Error

          +

          A server error prevented data from being sent to the client.

          {{else if is404}} -

          Not Found

          -

          What you're looking for couldn't be found. It either doesn't exist or you are not authorized to see it.

          +

          Not Found

          +

          What you're looking for couldn't be found. It either doesn't exist or you are not authorized to see it.

          {{else if is403}} -

          Not Authorized

          +

          Not Authorized

          {{#if token.secret}} -

          Your {{#link-to "settings.tokens"}}ACL token{{/link-to}} does not provide the required permissions. Contact your administrator if this is an error.

          +

          Your {{#link-to "settings.tokens" data-test-error-acl-link}}ACL token{{/link-to}} does not provide the required permissions. Contact your administrator if this is an error.

          {{else}} -

          Provide an {{#link-to "settings.tokens"}}ACL token{{/link-to}} with requisite permissions to view this.

          +

          Provide an {{#link-to "settings.tokens" data-test-error-acl-link}}ACL token{{/link-to}} with requisite permissions to view this.

          {{/if}} {{else}} -

          Error

          -

          Something went wrong.

          +

          Error

          +

          Something went wrong.

          {{/if}} {{#if (eq config.environment "development")}}
          {{errorStr}}
          diff --git a/ui/app/templates/clients/client.hbs b/ui/app/templates/clients/client.hbs index 228f30100..09423d9d4 100644 --- a/ui/app/templates/clients/client.hbs +++ b/ui/app/templates/clients/client.hbs @@ -1,13 +1,15 @@ {{#global-header class="page-header"}} -
        • {{#link-to "clients.index"}}Clients{{/link-to}}
        • +
        • + {{#link-to "clients.index" data-test-breadcrumb="clients"}}Clients{{/link-to}} +
        • - {{#link-to "clients.client" model.id}}{{model.shortId}}{{/link-to}} + {{#link-to "clients.client" model.id data-test-breadcrumb="client"}}{{model.shortId}}{{/link-to}}
        • {{/global-header}} {{#gutter-menu class="page-body"}}
          -

          - +

          + {{or model.name model.shortId}} {{model.id}}

          @@ -15,9 +17,9 @@
          Client Details - Status {{model.status}} - Address {{model.httpAddr}} - Datacenter {{model.datacenter}} + Status {{model.status}} + Address {{model.httpAddr}} + Datacenter {{model.datacenter}}
          @@ -39,7 +41,7 @@ source=p.list sortProperty=sortProperty sortDescending=sortDescending - class="allocations with-foot" as |t|}} + class="with-foot" as |t|}} {{#t.head}} {{#t.sort-by prop="shortId"}}ID{{/t.sort-by}} {{#t.sort-by prop="modifyIndex" title="Modify Index"}}Modified{{/t.sort-by}} @@ -51,7 +53,11 @@
          Memory # Allocs + {{#link-to "allocations.allocation" allocation class="is-primary"}} {{allocation.shortId}} {{/link-to}} {{moment-format allocation.modifyTime "MM/DD HH:mm:ss"}}{{allocation.name}} +{{moment-format allocation.modifyTime "MM/DD HH:mm:ss"}}{{allocation.name}} {{allocation.clientStatus}} {{allocation.jobVersion}}{{#link-to "clients.client" allocation.node}}{{allocation.node.shortId}}{{/link-to}}{{allocation.jobVersion}}{{#link-to "clients.client" allocation.node}}{{allocation.node.shortId}}{{/link-to}} {{#if (or allocation.job.isPending allocation.job.isReloading)}} ... {{else}} - {{#link-to "jobs.job" allocation.job (query-params jobNamespace=allocation.job.namespace.id)}}{{allocation.job.name}}{{/link-to}} - / {{allocation.taskGroup.name}} + {{#link-to "jobs.job" allocation.job (query-params jobNamespace=allocation.job.namespace.id) data-test-job}}{{allocation.job.name}}{{/link-to}} + / {{allocation.taskGroup.name}} {{/if}} {{allocation.jobVersion}}{{allocation.jobVersion}} + {{#if allocation.stats.isPending}} ... {{else if allocation.stats.isRejected}} @@ -40,7 +40,7 @@ {{/if}} + {{#if allocation.stats.isPending}} ... {{else if allocation.stats.isRejected}} diff --git a/ui/app/templates/components/client-node-row.hbs b/ui/app/templates/components/client-node-row.hbs index b6eb25413..184a00e2b 100644 --- a/ui/app/templates/components/client-node-row.hbs +++ b/ui/app/templates/components/client-node-row.hbs @@ -1,10 +1,10 @@ -{{#link-to "clients.client" node.id class="is-primary"}}{{node.shortId}}{{/link-to}}{{node.name}}{{node.status}}{{node.address}}{{node.port}}{{node.datacenter}} +{{#link-to "clients.client" node.id class="is-primary"}}{{node.shortId}}{{/link-to}}{{node.name}}{{node.status}}{{node.address}}{{node.port}}{{node.datacenter}} {{#if node.allocations.isPending}} ... {{else}} diff --git a/ui/app/templates/components/gutter-menu.hbs b/ui/app/templates/components/gutter-menu.hbs index 765b53ab9..055e8e323 100644 --- a/ui/app/templates/components/gutter-menu.hbs +++ b/ui/app/templates/components/gutter-menu.hbs @@ -9,6 +9,7 @@
        • Memory Unhealthy Allocs
          {{row.model.name}} +
          {{row.model.name}} {{#if row.model.requiresPromotion}} {{if row.model.promoted "No" "Yes"}} {{else}} N/A {{/if}} {{if row.model.autoRevert "Yes" "No"}}{{or row.model.placedCanaries 0}} / {{row.model.desiredCanaries}}{{row.model.placedAllocs}} / {{row.model.desiredTotal}}{{row.model.healthyAllocs}}{{row.model.unhealthyAllocs}}{{if row.model.autoRevert "Yes" "No"}}{{or row.model.placedCanaries 0}} / {{row.model.desiredCanaries}}{{row.model.placedAllocs}} / {{row.model.desiredTotal}}{{row.model.healthyAllocs}}{{row.model.unhealthyAllocs}}
          {{#link-to "jobs.job" job class="is-primary"}}{{job.name}}{{/link-to}} +{{#link-to "jobs.job" job class="is-primary"}}{{job.name}}{{/link-to}} {{job.status}} {{job.type}}{{job.priority}} +{{job.type}}{{job.priority}} {{#if job.isReloading}} ... {{else}} {{job.taskGroups.length}} {{/if}} +
          {{allocation-status-bar allocationContainer=job isNarrow=true}}
          {{#link-to "servers.server" agent.id class="is-primary"}}{{agent.name}}{{/link-to}}{{agent.status}}{{if agent.isLeader "True" "False"}}{{agent.address}}{{agent.serfPort}}{{agent.datacenter}}{{#link-to "servers.server" agent.id class="is-primary"}}{{agent.name}}{{/link-to}}{{agent.status}}{{if agent.isLeader "True" "False"}}{{agent.address}}{{agent.serfPort}}{{agent.datacenter}} + {{#link-to "jobs.job.task-group" taskGroup.job taskGroup class="is-primary"}} {{taskGroup.name}} {{/link-to}} {{taskGroup.count}} +{{taskGroup.count}}
          {{allocation-status-bar allocationContainer=taskGroup.summary isNarrow=true}}
          {{taskGroup.reservedCPU}} MHz{{taskGroup.reservedMemory}} MiB{{taskGroup.reservedEphemeralDisk}} MiB{{taskGroup.reservedCPU}} MHz{{taskGroup.reservedMemory}} MiB{{taskGroup.reservedEphemeralDisk}} MiBAllocation Status Placement Failures
          {{row.model.shortId}}{{row.model.priority}}{{row.model.triggeredBy}}{{row.model.status}} +
          {{row.model.shortId}}{{row.model.priority}}{{row.model.triggeredBy}}{{row.model.status}} {{#if (eq row.model.status "blocked")}} N/A - In Progress {{else if row.model.hasPlacementFailures}} diff --git a/ui/app/templates/jobs/job/subnav.hbs b/ui/app/templates/jobs/job/subnav.hbs index 63e712a6c..cfbdeb672 100644 --- a/ui/app/templates/jobs/job/subnav.hbs +++ b/ui/app/templates/jobs/job/subnav.hbs @@ -1,10 +1,10 @@
            -
          • {{#link-to "jobs.job.index" job activeClass="is-active"}}Overview{{/link-to}}
          • -
          • {{#link-to "jobs.job.definition" job activeClass="is-active"}}Definition{{/link-to}}
          • -
          • {{#link-to "jobs.job.versions" job activeClass="is-active"}}Versions{{/link-to}}
          • +
          • {{#link-to "jobs.job.index" job activeClass="is-active"}}Overview{{/link-to}}
          • +
          • {{#link-to "jobs.job.definition" job activeClass="is-active"}}Definition{{/link-to}}
          • +
          • {{#link-to "jobs.job.versions" job activeClass="is-active"}}Versions{{/link-to}}
          • {{#if job.supportsDeployments}} -
          • {{#link-to "jobs.job.deployments" job activeClass="is-active"}}Deployments{{/link-to}}
          • +
          • {{#link-to "jobs.job.deployments" job activeClass="is-active"}}Deployments{{/link-to}}
          • {{/if}}
          diff --git a/ui/app/templates/jobs/job/task-group.hbs b/ui/app/templates/jobs/job/task-group.hbs index 679600a1a..90928f830 100644 --- a/ui/app/templates/jobs/job/task-group.hbs +++ b/ui/app/templates/jobs/job/task-group.hbs @@ -2,6 +2,7 @@ {{#each breadcrumbs as |breadcrumb index|}}
          Memory
          {{tag.name}} {{tag.value}}
          - {{#if prefix}}{{prefix}}.{{/if}}{{key}} +
          + {{#if prefix}}{{prefix}}.{{/if}}{{key}}
          - {{#if prefix}}{{prefix}}.{{/if}} +
          + {{#if prefix}}{{prefix}}.{{/if}} {{~key}} {{value}}{{value}}